Skip to main content
PUT
Update Metafield Definition

Update Metafield Definition

Admin API only — requires a merchant JWT. Not exposed to OAuth apps.
Updates label, description, validations, or pinned state of an existing definition. namespace, key, ownerType, and type are immutable — delete and recreate if you need to change them.

Request

Path parameters

id
string
required
The definition UUID.

Body parameters (all optional)

name
string
Human label.
description
string
Tooltip / helper text.
validations
object
Replace the entire validations object. Existing values that fail the new rules are not retroactively rejected — they continue to exist but future writes must comply.
pinned
boolean
Pin / unpin from the resource detail page.

Response

Same shape as Get definition.

Error codes

CodeDescription
UNAUTHORIZEDInvalid or missing JWT
FORBIDDENWrong store / insufficient role
NOT_FOUNDDefinition does not exist
VALIDATION_ERRORValidation rule incompatible with the definition’s type