Menu
Post Category
Create a new category
POST
/api/rest/v1/categoriesUse it in a workflow
- Add a step and choose the Akeneo connector.
- Pick the Post Category action (under Category).
- Fill in the fields below, then reference the result from later steps as
{{postCategory.response.data}}.
Request
Request body
Enter the body as JSON in the step's Body field.
{
"code": "winter_collection",
"parent": "root_category",
"updated": "2021-05-21T11:32:00+02:00",
"position": 1,
"labels": {
"en_US": "Winter collection",
"fr_FR": "Collection hiver",
"de_DE": "Winter-Kollektion"
},
"channel_requirements": [
"ecommerce",
"mobile"
],
"values": [
{
"data": "<p>Winter collection description</p>",
"channel": "ecommerce",
"locale": "en_US",
"attribute_code": "a_text_area_attribute"
},
{
"data": false,
"channel": "ecommerce",
"locale": null,
"attribute_code": "a_boolean_attribute"
}
],
"validations": {
"max_categories_per_product": 5,
"only_leaves": true,
"is_mandatory": false
}
}
Response
Returns 201 with a any. Read it in later steps with {{postCategory.response.data.<field>}}.
Need more? See the Akeneo guide for connection setup and behaviour shared by every action.
Was this page helpful?