Create or Restore Category
POST/api/v1/customer-data/taxonomies/:taxonomyLevelCustomId/categories
Creates a new category at the given taxonomy level, or restores a soft-deleted
category with the same customId at the same level (201 in both cases).
Create: A new row is inserted. businessId must be unique among live siblings
(same parent). parentCustomId, if provided, must resolve to a live category at
the level immediately above.
Restore: If a soft-deleted category with the same customId exists at this
level it is restored. name and description are updated from the request body;
businessId is immutable and ignored on restore. parentCustomId, if provided,
must match the category's original parent — omit it (or send null) to keep the
original parent, or supply the same value; a different value returns 400
REPARENT_NOT_SUPPORTED (re-parenting on restore is not supported). An explicit
null is treated the same as omission and keeps the original parent — it does not
re-root the category.
Request​
Responses​
- 201
- 400
- 401
- 404
- 409
- 500
Category created or restored.
Missing required field, parent not found, level has no business-id attribute, or a restore request supplied a parentCustomId different from the original parent.
Authentication credentials were not provided or are invalid.
The taxonomy level in the path does not exist for the org.
A category already uses the given customId or businessId.
Internal Server Error