Skip to main content

Update Category

PATCH/api/v1/dashboard/content/categories/{category_id}

Overview

Updates an existing category. Only the fields included in the request body are updated. You can move a category in the hierarchy by changing its parent_id.

Authentication

info

Bearer authentication required - Pass your credentials as Authorization: Bearer <client_id>:<api_key>:<api_secret>.

Headers

HeaderTypeRequiredDescription
AuthorizationstringYesBearer <client_id>:<api_key>:<api_secret>
Content-TypestringYesapplication/json

Path Parameters

ParameterTypeRequiredDescription
category_idstring (UUID)YesThe unique identifier of the category

Request Body

All fields are optional.

ParameterTypeDescription
namestringCategory display name
slugstringURL-friendly slug
descriptionstringCategory description
parent_idstring (UUID) | nullParent category ID (set to null to make top-level)
sort_orderintegerSort position within parent level

Response

Returns the full updated category object.

Example Request

curl -X PATCH "https://spideriq.ai/api/v1/dashboard/content/categories/cat-004-uuid" \
-H "Authorization: Bearer $CLIENT_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "API Integration Guides",
"description": "Complete guides for integrating with the SpiderIQ API",
"sort_order": 0
}'

Example Response

{
"id": "cat-004-uuid",
"name": "API Integration Guides",
"slug": "api-guides",
"description": "Complete guides for integrating with the SpiderIQ API",
"parent_id": "cat-001-uuid",
"sort_order": 0,
"children": []
}

Status Codes

Status CodeMeaningDescription
200OKCategory updated successfully
400Bad RequestInvalid field values or circular parent reference
401UnauthorizedInvalid or missing Bearer token
404Not FoundCategory not found or belongs to another client
409ConflictSlug already in use by another category