Organizations and users · GraphQL query

userGetMetadata query

Reads one value from the caller's own key-value metadata store, which clients use to keep per-user preferences and UI state on the server. A key that has never been set returns a null value rather than an error. Write values with userSetMetadata.

Response

Returns a UserMetadataPayload!

Arguments

Name Description
key - String! The metadata key, 1 to 256 bytes.

Example

Query

query userGetMetadata($key: String!) {
  userGetMetadata(key: $key) {
    key
    value
  }
}

Variables

{"key": "abc123"}

Response

{
  "data": {
    "userGetMetadata": {
      "key": "abc123",
      "value": Binary
    }
  }
}