Skip to main content

Base URL

Interactive Docs

Draft auto-generates interactive API documentation via Swagger UI: http://localhost:8000/docs

Authentication

In development mode, no authentication is required. For production deployments, Draft uses JWT tokens.

Common Endpoints

Response Format

All endpoints return JSON. Successful responses use standard HTTP status codes:

Idempotency

LLM-powered endpoints support idempotency keys to prevent duplicate operations:
Same key + same body = returns cached result. Same key + different body = returns 409 Conflict.

Rate Limiting

LLM endpoints use cost-based rate limiting per client. If you hit a rate limit, you’ll receive a 429 response with a Retry-After header.

WebSocket

Real-time log streaming is available via WebSocket:
This streams job execution logs as they happen.