Delete a category
delete
https://api.flactrum.com/v1/product-categories/{category}
A category that still holds products cannot be deleted; the products would vanish from the menu. Move them first.
| Required scope | categories.write |
| Success status | 204 |
Parameters
| Name | In | Type | Description |
|---|---|---|---|
| category * | path | string | ULID of the record. |
Examples
Recorded from the test suite — these are real requests and their real responses.
curl -X DELETE 'https://api.flactrum.com/v1/product-categories/01m43mxnx6zj6kjqekc1keygkj' \
-H 'Authorization: Bearer flk_your_key:your_secret' \
-H 'Accept: application/json'
HTTP 204
(empty body)
curl -X DELETE 'https://api.flactrum.com/v1/product-categories/01m43mxnsv5myzn863qhgj70zk' \
-H 'Authorization: Bearer flk_your_key:your_secret' \
-H 'Accept: application/json'
HTTP 409 · application/json
{
"error": {
"code": "conflict",
"message": "This category still has 1 product(s). Move them to another category first.",
"details": {
"product_count": 1
}
}
}