Skip to main content

Create a product category

POST 

/categories

Creates a category as the acting user. Omit parent_id for a top-level category.

  • Categories can be nested up to 5 levels, and a category that already has products cannot get a child.

Errors​

StatusCodeWhen
400VALIDATION_FAILEDThe category would sit deeper than 5 levels.
404NOT_FOUNDUnknown parent.
409DATA_CONFLICTThe name is already used under the same parent, or the parent already has products (the message tells which).

Request​

Responses​

The new category