Endpoint
Authentication
This endpoint requires authentication via Bearer token and CSRF protection.Request Body
The UUID of the account where the category will be created. Must be a valid UUID format.
The category name. Must be between 3 and 23 characters.
Optional encrypted version of the category name for end-to-end encryption.
Hex color code for the category (e.g.,
#6B7280). Must be a valid 6-digit hex color. Defaults to #6B7280 if not provided.Optional icon identifier for the category. Maximum 50 characters.
Response
Indicates whether the request was successful.
The created category object.
Example Request
Example Response
Error Responses
Bad Request - Invalid input data.
Forbidden - User does not have access to the specified account.
Conflict - Category with this name already exists.
Notes
- The
namefield is automatically sanitized for storage - If
coloris not provided, it defaults to#6B7280(gray) - The user must have access to the specified account
- Category names must be unique within an account
