catalog.product.create
Create a product with its options and one or more SKUs, atomically.
- Scope:
catalog.product.write - System: no
- Reachable from:
POST /v1/commands/catalog.product.create(tenant credential) · MCP toolcatalog.product.create· SDKclient.call('catalog.product.create', …) - Events:
catalog.product.created,catalog.sku.created
Input (JSON Schema)
Section titled “Input (JSON Schema)”{ "properties": { "brand_id": { "anyOf": [ { "minLength": 1, "type": "string" }, { "type": "null" } ] }, "content_sections": { "items": { "properties": { "body": { "maxLength": 20000, "type": "string" }, "title": { "maxLength": 200, "minLength": 1, "type": "string" } }, "required": [ "title", "body" ], "type": "object" }, "maxItems": 20, "type": "array" }, "description": { "anyOf": [ { "type": "string" }, { "type": "null" } ] }, "handle": { "minLength": 1, "type": "string" }, "media": { "items": { "properties": { "alt": { "type": "string" }, "kind": { "default": "image", "enum": [ "image", "document", "video_external" ], "type": "string" }, "position": { "maximum": 9007199254740991, "minimum": -9007199254740991, "type": "integer" }, "provider_key": { "minLength": 1, "type": "string" }, "role": { "type": "string" } }, "required": [ "provider_key" ], "type": "object" }, "type": "array" }, "meta_description": { "anyOf": [ { "maxLength": 500, "type": "string" }, { "type": "null" } ] }, "meta_title": { "anyOf": [ { "maxLength": 200, "type": "string" }, { "type": "null" } ] }, "metadata": { "additionalProperties": {}, "propertyNames": { "type": "string" }, "type": "object" }, "options": { "items": { "properties": { "name": { "minLength": 1, "type": "string" }, "values": { "items": { "minLength": 1, "type": "string" }, "minItems": 1, "type": "array" } }, "required": [ "name", "values" ], "type": "object" }, "type": "array" }, "skus": { "items": { "properties": { "amount": { "maximum": 9007199254740991, "minimum": 0, "type": "integer" }, "code": { "minLength": 1, "type": "string" }, "compare_at_amount": { "anyOf": [ { "maximum": 9007199254740991, "minimum": 0, "type": "integer" }, { "type": "null" } ] }, "currency": { "maxLength": 3, "minLength": 3, "type": "string" }, "ean": { "type": "string" }, "is_default": { "type": "boolean" }, "media": { "items": { "properties": { "alt": { "type": "string" }, "kind": { "default": "image", "enum": [ "image", "document", "video_external" ], "type": "string" }, "position": { "maximum": 9007199254740991, "minimum": -9007199254740991, "type": "integer" }, "provider_key": { "minLength": 1, "type": "string" }, "role": { "type": "string" } }, "required": [ "provider_key" ], "type": "object" }, "type": "array" }, "metadata": { "additionalProperties": {}, "propertyNames": { "type": "string" }, "type": "object" }, "name": { "type": "string" }, "option_values": { "items": { "properties": { "option": { "type": "string" }, "value": { "type": "string" } }, "required": [ "option", "value" ], "type": "object" }, "type": "array" }, "ref": { "type": "string" }, "status": { "type": "string" } }, "required": [ "amount" ], "type": "object" }, "minItems": 1, "type": "array" }, "status": { "enum": [ "draft", "active", "archived" ], "type": "string" }, "title": { "minLength": 1, "type": "string" } }, "required": [ "title", "handle", "skus" ], "type": "object"}Result (200)
Section titled “Result (200)”{ "additionalProperties": false, "properties": { "product_id": { "type": "string" }, "sku_ids": { "items": { "type": "string" }, "type": "array" } }, "required": [ "product_id", "sku_ids" ], "type": "object"}Errors
Section titled “Errors”validation_failed (400) · unauthorized (401) · forbidden (403) · conflict (409) · internal (500)