Skip to main content
Anchor to standardMetafieldDefinitionEnable

standardMetafieldDefinitionEnable

mutation

Requires API client to have access to the resource type associated with the metafield definition owner type.

Activates the specified standard metafield definition from its template.

Refer to the list of standard metafield definition templates.

ID

The ID of the standard metafield definition template to enable.

String

The key of the standard metafield to enable. Used in combination with namespace.

String

The namespace of the standard metafield to enable. Used in combination with key.

MetafieldOwnerType!
required

The resource type that the metafield definition is scoped to.

Boolean!
requiredDefault:false

Whether to pin the metafield definition.

Anchor to visibleToStorefrontApivisibleToStorefrontApi
Boolean
Default:null

Whether metafields for the definition are visible using the Storefront API.

Anchor to useAsCollectionConditionuseAsCollectionCondition
Boolean
DeprecatedDefault:false

Was this section helpful?

Anchor to StandardMetafieldDefinitionEnablePayload returnsStandardMetafieldDefinitionEnablePayload returns

MetafieldDefinition

The metafield definition that was created.

[StandardMetafieldDefinitionEnableUserError!]!
non-null

The list of errors that occurred from executing the mutation.


Was this section helpful?