Skip to main content
POST
Create a topic
Creates a topic label. The API path keeps the name keywords; the resource is a topic. Use Update a prompt to assign it. Requires an active Business, Agency Business or Enterprise plan. Use an API token with write access enabled. See Writing data for idempotency, conditional requests and error handling.
string
required
Bearer token for your team.
string
required
Unique key for this operation. Completed responses replay for 24 hours.
string
required
Workspace identifier. The workspace must belong to the token’s team.
string
required
Topic text, 1 to 255 characters after trimming.

Response

Returns 201 with Location, ETag and a topic containing id, text, version, createdAt and updatedAt.

Synthetic request and response

Errors

Invalid text returns 400 INVALID_REQUEST; an inaccessible workspace returns 404 RESOURCE_NOT_FOUND; a duplicate label returns 409 CONFLICT. See Error codes for authentication, plan, idempotency and server errors. On 429, honor Retry-After; writes can return 503 SERVICE_UNAVAILABLE if the write limiter is unavailable.