Create a size
POST
Creates a product size that items can use as a variant attribute. The name is required and must be unique. Returns 201 with the new size, including its ID.
How to use it
- Send a name that is not already used by another size, e.g. XL; status defaults to active.
- The new size is returned with its ID (201 Created) and can be used as an item variant attribute.
BearerAuthheader
AuthorizationBearer <JWT>application/json- body
id?|Numeric size ID; use it as sizeId on items.
Format
int64name*stringSize name, unique across the catalog.
status*stringSize status, e.g. active.
modifiedTime*stringWhen the size was last changed (ISO 8601 timestamp).
Format
date-timeOK
*/*- response
id?|Numeric size ID; use it as sizeId on items.
Format
int64name*stringSize name, unique across the catalog.
status*stringSize status, e.g. active.
modifiedTime*stringWhen the size was last changed (ISO 8601 timestamp).
Format
date-timeExample Request
curl -X POST 'https://beta.iotoms.com/api/v1/catalog/attributes/sizes' \ -H 'Content-Type: application/json' \ -d '{ "name": "string", "status": "string", "modifiedTime": "2019-08-24T14:15:22Z"}'Example Response
{ "id": 0, "name": "string", "status": "string", "modifiedTime": "2019-08-24T14:15:22Z"}