Get a shop metafield translation
Fetch one translated shop-level custom-data value.
The definition must be visible to the token and translatable.
Path parameters
| Name | Type | Description |
|---|---|---|
namespace
required
|
string |
Metafield definition namespace. URL-encode |
key
required
|
string |
Metafield definition key. |
locale
required
|
string |
Enabled non-default store locale. |
Headers
| Name | Type | Description |
|---|---|---|
Authorization
required
|
string |
Bearer Store API token. |
Errors
-
400METAFIELD_NAMESPACE_INVALIDThe namespace or key path segment is not valid URL encoding.
-
400PRODUCT_METAFIELD_DEF_NOT_FOUNDThe namespace and key do not identify a translatable definition visible to this token.
-
400TRANSLATION_LOCALE_REQUIREDLocale is missing.
-
400TRANSLATION_LOCALE_NOT_ENABLEDLocale is not enabled for this store.
-
400TRANSLATION_DEFAULT_LOCALE_FORBIDDENThe default locale cannot be a translation target.
Set a shop metafield translation
Set or clear one translated shop-level custom-data value.
Sets this value's translation in an enabled non-default locale without changing the source value. App tokens can translate only definitions their app owns. Send an explicit string in value; omit neither the field nor its value, and do not send null. An empty string clears the translation. For list.string, send a JSON-encoded string array with one translated item for each source item, in the same order.
Path parameters
| Name | Type | Description |
|---|---|---|
namespace
required
|
string |
Metafield definition namespace. URL-encode |
key
required
|
string |
Metafield definition key. |
locale
required
|
string |
Enabled non-default store locale. |
Headers
| Name | Type | Description |
|---|---|---|
Authorization
required
|
string |
Bearer Store API token. |
Idempotency-Key
|
string |
Optional key for this translation write. Reuse it only with the same payload when repeating the request. |
Body parameters
| Name | Type | Description |
|---|---|---|
value
required
|
string |
Translated value; an empty string clears it. |
Errors
-
400METAFIELD_NAMESPACE_INVALIDThe namespace or key path segment is not valid URL encoding.
-
400PRODUCT_METAFIELD_DEF_NOT_FOUNDThe namespace and key do not identify a translatable definition visible to this token.
-
400TRANSLATION_LOCALE_REQUIREDLocale is missing.
-
400TRANSLATION_LOCALE_NOT_ENABLEDLocale is not enabled for this store.
-
400TRANSLATION_DEFAULT_LOCALE_FORBIDDENThe default locale cannot be a translation target.
-
403METAFIELD_WRITE_APP_OWN_ONLYAn app token can translate only definitions its app owns. Visible merchant-owned and shared definitions of other apps return this code.
-
403METAFIELD_WRITE_MERCHANT_READ_ONLYA non-app token addressed an app-owned definition whose merchant_access is not read_write.
-
400STORE_API_INVALID_REQUEST_BODYThe body is not one JSON object with only a value field.
-
400INVALID_INPUTvalue is missing or null; send an empty string to clear the translation.
-
400TRANSLATION_LIST_LENGTH_MISMATCHThe translated list must have the same number of items as the source list.
Webhook events#
Subscribe to these events when your integration mirrors localized shop metafields. Update and clear events identify the locale and changed fields. One write can emit both events when it sets some fields and clears others.
Store metafield translations updated
Fired when a store metafield's translation is added or updated for a locale.
Payload fields
| Field | Type | Description |
|---|---|---|
metafield.store_name |
string |
Selectable in the Payload builder |
metafield.definition_id |
string |
Always present |
metafield.namespace |
string |
Selectable in the Payload builder |
metafield.key |
string |
Selectable in the Payload builder |
metafield.name |
string |
Selectable in the Payload builder |
metafield.type |
string |
Selectable in the Payload builder |
metafield.app_id |
string |
Selectable in the Payload builder |
metafield.app_access |
string |
Selectable in the Payload builder |
metafield.merchant_access |
string |
Selectable in the Payload builder |
locale |
string |
Selectable in the Payload builder |
translation.value |
string |
Selectable in the Payload builder |
updated_at |
string |
Selectable in the Payload builder |
Store metafield translations deleted
Fired when a store metafield's translation is cleared for a locale.
Payload fields
| Field | Type | Description |
|---|---|---|
metafield.store_name |
string |
Selectable in the Payload builder |
metafield.definition_id |
string |
Always present |
metafield.namespace |
string |
Selectable in the Payload builder |
metafield.key |
string |
Selectable in the Payload builder |
metafield.name |
string |
Selectable in the Payload builder |
metafield.type |
string |
Selectable in the Payload builder |
metafield.app_id |
string |
Selectable in the Payload builder |
metafield.app_access |
string |
Selectable in the Payload builder |
metafield.merchant_access |
string |
Selectable in the Payload builder |
locale |
string |
Selectable in the Payload builder |
translation.value |
string |
Selectable in the Payload builder |
updated_at |
string |
Selectable in the Payload builder |