Authentication
Authenticate API requests with Bearer API keys and manage key lifecycle safely.
Bearer API keys
Pass your API key in the Authorization header on every request to https://api.kerox.ai/v1:
curl https://api.kerox.ai/v1/account \
-H "Authorization: Bearer $KEROX_API_KEY"GET /v1/models and GET /v1/models/{id} can be called without a key to inspect public rates and schemas. Passing your key returns your account's effective pricing (including any account-level or model-specific discount).
Key security & rotation
- Hashed at rest: Kerox only stores a cryptographic hash of each key. The full key is shown once, when you create it in Console → API → API keys.
- Server-side only: Do not embed live API keys in client-side browser apps or mobile binaries.
- Zero-downtime rotation: Create a new key, deploy it to your services, verify traffic on the new key in the console, and then revoke the old key. A revoked key is rejected with HTTP
401(invalid_api_key); allow up to a minute for the revocation to reach every server.
Account prerequisites
Before POST /v1/tasks accepts submissions:
- Your email address must be verified, which signing in with an emailed code or with Google does (otherwise HTTP
403email_not_verified). - Your account must be active (otherwise HTTP
403account_disabled). - Your available wallet balance must cover the estimated task cost (otherwise HTTP
402insufficient_balance).