Logo
Emporix Digital Commerce Platform API Documentation

Creating a new product template

POST {{api-url}}/product/{{tenant}}/product-templates

Preview Creates a new product template. The product template defines a set of attributes which are common for all product instances based on the product template.

 

Body PARAM

Key Datatype Required Description 



HEADERS

Key Datatype Required Description 
Content-Language
string The Content-Language request HTTP header defines language(s) of the payload.
Content-Type
string
Accept
string




RESPONSES

status Created

{ "id": "624c3e7c3406122baacc7e93" }



Curl
curl -X POST 'api-url/product/api-url/product-templates' -H 'Content-Language: en' -H 'Content-Type: application/json' -H 'Accept: application/json' -d '{"name":{"en":"T-shirt"},"attributes":[{"key":"color","name":{"en":"Color"},"type":"TEXT","metadata":{"mandatory":false,"defaultValue":null,"variantAttribute":false},"values":[{"key":"WHITE"},{"key":"RED"},{"key":"BLACK"}]},{"key":"size","name":{"en":"Size"},"type":"TEXT","metadata":{"mandatory":false,"defaultValue":null,"variantAttribute":false},"values":[{"key":"L"},{"key":"M"},{"key":"S"}]}]}'

ENDPOINTS