get
https://{subdomain}.myshoplaza.com/openapi/2025-06/metafields///
Retrieve a metafield by its ID
The Get Metafield Details API allows to retrieve detailed information about a specific resource's metafield by its unique identifier.
This API is especially useful for:
- Provides metafield data including ownership information, field type, and timestamps for creation and modification.
- Inspecting custom metadata associated with specific resources.
Request Parameters
Public Request Parameters
Path Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
owner_resource | string | Yes | The type of resource the metafield is attached to | product |
owner_id | string | Yes | The unique ID of the resource | prod_12345 |
id | string | Yes | The unique ID of the metafield | meta_67890 |
Response Explanation
Public Response Parameters
Successful Response
| Field | Type | Example | Description |
|---|---|---|---|
code | string | "Success" | Response status (e.g., "Success"). |
message | string | "Metafield retrieved successfully" | Response message. |
data.metafield.id | string | "mf_001" | Unique ID of the metafield. |
data.metafield.store_id | integer | 12345 | ID of the store that owns the metafield. |
data.metafield.owner_resource | string | "product" | Resource type that owns the metafield (e.g., "product"). |
data.metafield.owner_id | string | "prod_001" | ID of the owner resource. |
data.metafield.namespace | string | "global" | Namespace of the metafield. |
data.metafield.key | string | "color" | Key of the metafield. |
data.metafield.type | string | "string" | Type of the metafield ("json" or "string"). |
data.metafield.description | string | "Product color" | Description of the metafield. |
data.metafield.definition_id | string | "df_001" | ID of the metafield definition. |
data.metafield.created_at | string | "2023-01-15T10:00:00Z" | Timestamp when the metafield was created (ISO 8601 format). |
data.metafield.updated_at | string | "2023-06-20T14:30:00Z" | Timestamp when the metafield was last updated (ISO 8601 format). |
Error Response
| Field | Type | Example | Description |
|---|---|---|---|
code | string | InvalidParameter | Error http message |
message | string | `` | Error message |
