Categories
Create, update, query, move in the tree and delete categories in the catalog.
Tree
URL key
Display mode
Overview
Category routes cover the full lifecycle: create a new category in the tree, update metadata, query by ID, move within the hierarchy and delete.
POST/api2/category
Create a new category.
{
"parent_id": 2,
"name": "Especialidades",
"position": 5,
"is_active": 1,
"is_anchor": 1,
"include_in_menu": 1,
"description": "Dental specialties category",
"display_mode": "PRODUCTS",
"url_key": "especialidades"
}
PATCH/api2/category
Update an existing category.
{
"name": "Especialidades",
"categoria": {
"name": "New name",
"description": "New description",
"is_anchor": 1
}
}
GET/api2/category?id=61
Get a category by ID.
PATCH/api2/category/categoryMove
Move a category in the tree.
{
"name": "Especialidades",
"parent_name": "Produtos",
"after_id": null
}
DELETE/api2/category
Delete a category.
{
"category_id": 546
}