---
title: "Creates new metafield."
method: POST
path: "/admin/metafields.json"
tags: ["Metafield"]
---

# Creates new metafield.

`POST /admin/metafields.json`

## Request body

- APIRequestMetafield
  - `metafield` MetafieldDto
    - `description` string
    - `id` integer — A unique numeric identifier for the meta field. Each id is unique across the ShopBase system. No two metafield will have the same id, even if they're from different shops.
    - `key` string
    - `namespace` string
    - `owner_id` integer
    - `owner_resource` string
    - `updated_at` integer
    - `value` object
    - `value_type` string

## Response `200`

OK

- APIResponseMetafieldDto
  - `metafield` MetafieldDto
    - `description` string
    - `id` integer — A unique numeric identifier for the meta field. Each id is unique across the ShopBase system. No two metafield will have the same id, even if they're from different shops.
    - `key` string
    - `namespace` string
    - `owner_id` integer
    - `owner_resource` string
    - `updated_at` integer
    - `value` object
    - `value_type` string

---

[API](https://skmtc.net/shopbase/apis/shopbase-internal-api.md) · [All operations](https://skmtc.net/shopbase/apis/shopbase-internal-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/shopbase/shopbase-internal-api/revisions/353ccde6240d/schema)
