Docs
Keep your code.
Change one line.
Quickstart
Kairos speaks the OpenAI chat-completions format. Point any OpenAI SDK at this server, pass a Kairos key, and pick any model id from the catalog.
from openai import OpenAI client = OpenAI( base_url="https://kairos.example/api/v1", api_key="kai_...", ) r = client.chat.completions.create( model="anthropic/claude-sonnet", messages=[{"role": "user", "content": "Hello"}], ) print(r.usage.cost) # USD
Authentication
Sign in with one wallet signature (no transaction, no gas) and create a key in the Console. Send it as Authorization: Bearer kai_…. Keys are signed tokens bound to your wallet address.
Endpoints
POST /api/v1/chat/completionsBody: model, messages, optional max_tokens. Returns an OpenAI-shaped completion with usage.cost in USD. Only the model id and messages are forwarded upstream.
GET /api/v1/modelsPublic. Every model with its list price. No key needed.
Errors
| Status | Type | When |
|---|---|---|
| 400 | invalid_request_error | Body failed validation, or stream: true. |
| 401 | authentication_error | Missing, malformed or revoked key. |
| 404 | api_error | Unknown model id. See /api/v1/models. |
| 502 | api_error | The upstream lab returned an error. |