API Overview
The Clarive REST API lets you fetch and render published prompts programmatically. All requests require an API key. See API Endpoints for the full endpoint reference.
Authentication
Include your API key in every request via the X-Api-Key header. Keys use the format cl_....
Base URL
/public/v1
Template Field Types
| Type | Validation |
|---|---|
| string | Must be non-empty |
| int | Must be a valid integer; optional min/max range |
| float | Must be a valid number; optional min/max range |
| enum | Must match one of the allowed values (case-insensitive) |
Rate Limiting
All /public/v1/ endpoints are rate-limited to 600 requests per minute per API key. Every response includes rate limit headers:
| Header | Description |
|---|---|
| X-RateLimit-Limit | Maximum requests per window |
| X-RateLimit-Remaining | Requests remaining in current window |
| X-RateLimit-Reset | Unix timestamp when the window resets |
Error Responses
| Status | Code | Meaning |
|---|---|---|
| 401 | — | Missing or invalid API key |
| 404 | ENTRY_NOT_FOUND | Entry doesn't exist or is trashed |
| 404 | NOT_PUBLISHED | Entry exists but has no published version |
| 404 | TAB_NOT_FOUND | Tab doesn't exist or isn't a valid working tab |
| 422 | VALIDATION_ERROR | Template field validation failed (generate only) |
| 429 | RATE_LIMITED | Too many requests (limit: 600/min per API key) |
All errors return a JSON body: {"error": {"code": "...", "message": "..."}}. Validation errors include a details object with per-field messages.
OpenAPI Specification
Download the full OpenAPI specification at /public/v1/openapi.json for use with API clients, code generators, or documentation tools.