Authentication
Create API keys, send them with each request, and understand scopes and endpoints.
API key
Create keys in the console with a name and expiration, including no expiration. New keys include all standard API permissions and can be viewed again after signing in. Never put keys in client-side code or public repositories.
| Scope | Allows |
|---|---|
jobs:create | Submit tasks |
jobs:read | Poll and list tasks |
media:write | Upload input images or video |
media:read | Download result files |
usage:read | Read credits and ledger |
chat:create | Call chat completions |
Send the key
Send the key as Authorization: Bearer <key> or x-api-key: <key> — not both. The web console and playground use your signed-in session instead.
A missing or invalid key returns 401 AUTH_REQUIRED; a key without the needed scope returns 403 INSUFFICIENT_SCOPE.
Endpoints
| Method | Path | Purpose | Auth |
|---|---|---|---|
GET | /api/v1/models | List the public model catalog | Public |
GET | /api/v1/models/{slug} | One model with its input schema | Public |
GET | /api/v1/prices | Configured per-task prices (USD micro-units) | Public |
POST | /api/v1/media | Upload image or video bytes, returns media:<uuid> | media:write |
POST | /api/v1/jobs | Submit one asynchronous model task | jobs:create |
GET | /api/v1/jobs/{id} | Poll one task for status and results | jobs:read |
GET | /api/v1/jobs | Your latest 100 tasks | jobs:read |
GET | /api/v1/results/{id} | Download an owned result file | media:read |
GET | /api/v1/usage | Credit balance and recent ledger | usage:read |
GET | /api/v1/chat/models | Callable chat models with token prices (OpenAI list format) | Public |
POST | /api/v1/chat/completions | OpenAI-compatible chat completion, billed per token | chat:create |
GET | /api/v1/chat/requests | Your chat requests with charges, limit (1–100) and before cursor | usage:read |
GET | /api/v1/chat/requests/{id} | One chat request belonging to your account | usage:read |
AI agents
AI agents can sign in with OAuth through the MCP server instead of using a key. MCP & Skill