Metafield definition validations
A Metafield definition validation is a single validation rule on a Metafield definition - for example “max length 500”. It references the metafieldDefinition it belongs to, a name (the validation type), and a value (the rule’s parameter).
The same rules also appear inline as the validations array on a definition. This resource lets you manage them individually - create, update or delete one rule without rewriting the whole definition.
The name must be one of the types that are compatible with the definition’s data type - see Type compatibility. An incompatible rule is rejected with 422.
The Metafield definition validation object
Section titled “The Metafield definition validation object”| Property | Type | Required | Description |
|---|---|---|---|
id | string | - | The resource's unique identifier (UUID). |
metafieldDefinition | string | required | The metafield definition this validation belongs to |
name | string | required | The type of validation rule |
value | string | required | The validation parameter value. Format depends on the validation type. |
Conventions
Section titled “Conventions”All requests require an OAuth 2.0 bearer token and the organization scope header:
Authorization: Bearer <token>X-Flowkiwi-Organization-Id: <organization-id>PATCH uses JSON Merge Patch with Content-Type: application/merge-patch+json.