Skip to main content
object

Metafields enable you to attach additional information to a Shop domain resource, such as a User.

•MetafieldDefinition!
non-null

The metafield definition that the metafield belongs to.

•String!
non-null

The GID of resource that this metafield belongs to.

•CustomDataOwnerType!
non-null

The type of resource that this metafield belongs to.

•String!
non-null

The data stored in the metafield. Always stored as a string, regardless of the metafield's type.


Was this section helpful?

•query

Retrieve a Metafield by their Definition's Key or Namspace and Key. Leave blank to retreive all metafields on the user that your client has access to.

Arguments

•CustomDataKeyPairInput!
required

Key and namespace pair that together form the path to the definition. Key is required, Namespace defaults to the Client's implicit, reserved namespace if not provided.


•query

Retrieve Metafields by their Definition's Key or Namspace and Key. Leave blank to retreive all metafields on the user that your client has access to.

Arguments

•String

Returns the elements that come after the specified cursor.

•String

Returns the elements that come before the specified cursor.

•Int

Returns up to the first n elements from the list.

•[CustomDataKeyPairInput!]
Default:[]

Key and namespace pair that together form the path to the definition. Key is required, Namespace defaults to the Client's implicit, reserved namespace if not provided. Leave blank to see everything available to the client on the user.

•Int

Returns up to the last n elements from the list.

•Boolean

Reverse the order of the underlying list.

•MetafieldPermissibleSortKeys
Default:KEY

Sort the underlying listing by the given key.



Was this section helpful?

•mutation

Remove a Metafield corresponding to a definition from a user.

Arguments

•CustomDataKeyPairInput!
required

Key and namespace pair that together form the path to the definition. Key is required, Namespace defaults to the Client's implicit, reserved namespace if not provided


•mutation

Set or Update a Metafield on a resource.

Arguments

•[MetafieldSetInput!]!
required


Was this section helpful?