Skip to main content
GET
/
api
/
v1
/
metafields.json
List Metafields
curl --request GET \
  --url https://api.launchmystore.io/api/v1/metafields.json \
  --header 'Authorization: Bearer <token>'
{
  "status": 123,
  "state": "<string>",
  "data.metafields": [
    {
      "id": "<string>",
      "namespace": "<string>",
      "key": "<string>",
      "value": "<any>",
      "raw_value": "<string>",
      "type": "<string>",
      "owner_type": "<string>",
      "owner_id": "<string>",
      "app_id": "<string>",
      "created_at": "<string>",
      "updated_at": "<string>"
    }
  ],
  "data.total": 123,
  "data.page": 123,
  "data.limit": 123
}

Documentation Index

Fetch the complete documentation index at: https://docs.launchmystore.io/llms.txt

Use this file to discover all available pages before exploring further.

List Metafields

Returns metafields written by your app (scoped by appId). Filter by owner type, owner id, namespace, or key.
This endpoint returns only the metafields your app has written. To list all metafields on a resource (including those written by other apps or merchants), the merchant must use the Admin API (GET /metafields?ownerType=...&ownerId=...).

Request

curl -X GET "https://api.launchmystore.io/api/v1/metafields.json?ownerType=product&ownerId=<productId>" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"

Required scope

read_metafields

Query parameters

ownerType
string
Filter by owner type. One of shop, product, variant, collection, customer, order, page, blog, article. Lowercase only.
ownerId
string
Filter by the owning resource id. Required for every owner type except shop.
namespace
string
Filter by namespace.
key
string
Filter by exact key.
page
integer
default:"1"
1-indexed page number.
limit
integer
default:"50"
Items per page. Max 250.

Response

status
integer
HTTP status code (200 on success).
state
string
success or error.
data.metafields
array
Array of metafield objects.
data.total
integer
Total matching records.
data.page
integer
Current page.
data.limit
integer
Page size.

Example response

{
  "status": 200,
  "state": "success",
  "data": {
    "metafields": [
      {
        "id": "e607f43e-9251-451e-a45c-38bf28d61154",
        "namespace": "custom",
        "key": "badge",
        "value": "BESTSELLER",
        "raw_value": "BESTSELLER",
        "type": "single_line_text_field",
        "owner_type": "product",
        "owner_id": "94995c07-e8a5-43f2-9d1a-18ccf8199adf",
        "app_id": "your-app-id",
        "created_at": "2026-05-09T13:32:53.135Z",
        "updated_at": "2026-05-09T13:32:53.135Z"
      },
      {
        "id": "48b24b31-b1a4-4997-9827-a1668a886ea6",
        "namespace": "custom",
        "key": "warranty_years",
        "value": 5,
        "raw_value": "5",
        "type": "number_integer",
        "owner_type": "product",
        "owner_id": "94995c07-e8a5-43f2-9d1a-18ccf8199adf",
        "app_id": "your-app-id",
        "created_at": "2026-05-09T13:32:53.135Z",
        "updated_at": "2026-05-09T13:32:53.135Z"
      }
    ],
    "total": 2,
    "page": 1,
    "limit": 50
  }
}

Error codes

CodeDescription
UNAUTHORIZEDInvalid or missing access token
FORBIDDENApp doesn’t have read_metafields scope
VALIDATION_ERRORInvalid ownerType value