Build with the AuraRoute API
One OpenAI-compatible endpoint. Send Aura Auto as model AuraAuto (legacy alias auto), or pick a model by name.
Try it
Send a real request from your browser before writing any code. Pick a model, paste a key and chat — answers stream live and the model's thinking appears as it is produced. Your conversations are saved in this browser only.
Quick start
AuraRoute speaks the OpenAI API. Point any OpenAI SDK at the base URL below, use your AuraRoute key, and set model to Aura Auto (`AuraAuto`) — or, on a plan that allows choosing, to the name of one of the models listed below.
| Base URL | https://auraroute.dev/api |
| Endpoint | POST /chat/completions |
| Auth | Authorization: Bearer <your key> |
1. Create a key
Create a free account, then create a key under API keys. It is shown once.
2. Keep it in an environment variable
export AURAROUTE_API_KEY=az_live_…
$env:AURAROUTE_API_KEY = "az_live_…"3. Send a request
curl https://auraroute.dev/api/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $AURAROUTE_API_KEY" \
-d '{
"model": "AuraAuto",
"messages": [{ "role": "user", "content": "Say hello in one sentence." }]
}'
import OpenAI from 'openai';
const client = new OpenAI({
baseURL: 'https://auraroute.dev/api',
apiKey: process.env.AURAROUTE_API_KEY,
});
const res = await client.chat.completions.create({
model: 'AuraAuto',
messages: [{ role: 'user', content: 'Say hello in one sentence.' }],
});
console.log(res.choices[0].message.content);
import os
from openai import OpenAI
client = OpenAI(
base_url="https://auraroute.dev/api",
api_key=os.environ["AURAROUTE_API_KEY"],
)
res = client.chat.completions.create(
model="AuraAuto",
messages=[{"role": "user", "content": "Say hello in one sentence."}],
)
print(res.choices[0].message.content)Agents
Hermes and OpenClaw use the same three values as any other client: base URL https://auraroute.dev/api, your key, and model set to Aura Auto (`AuraAuto`). Each guide is the commands in order, then one bash script that installs the agent and writes the config.
Authentication
Send your key as a bearer token. Keys look like az_live_<id>_<secret>. You can hold several, and revoke any of them from the dashboard — a revoked key stops working within seconds.
Only a hash of each key is stored, so it cannot be shown again after creation. If you lose it, revoke it and make a new one.
Choosing a model
The model is named Aura Auto. Send it as `AuraAuto`, or send the name of a model from GET /v1/models. With Aura Auto, every request goes to the model AuraRoute’s operators chose, and a fallback takes over if it cannot answer. Choosing a model by name needs a plan that allows it; without one, only `AuraAuto` is accepted. A chosen model is never swapped for another — if it is down you get an error. Anything unknown (for example gpt-4o) is rejected.
| model | Use it for |
|---|---|
| AuraAuto | Aura Auto. Send `AuraAuto`. The model AuraRoute’s operators chose for everyone. Every response names the model that answered. Works on every plan. |
| <model name> | The name of a model from GET /v1/models, with its own price per 1M tokens. Needs a plan that allows choosing a model. |
List them any time with GET /models.
curl https://auraroute.dev/api/models \
-H "Authorization: Bearer $AURAROUTE_API_KEY"
import OpenAI from 'openai';
const client = new OpenAI({
baseURL: 'https://auraroute.dev/api',
apiKey: process.env.AURAROUTE_API_KEY,
});
const models = await client.models.list();
console.log(models.data.map((m) => m.id));
import os
from openai import OpenAI
client = OpenAI(
base_url="https://auraroute.dev/api",
api_key=os.environ["AURAROUTE_API_KEY"],
)
print([m.id for m in client.models.list().data])Chat completions
POST /chat/completions follows the OpenAI request and response shape. Parameters such as temperature, top_p and stop are passed through.
| Field | Notes |
|---|---|
| model | Aura Auto (`AuraAuto`), or the name of a model from GET /v1/models. Defaults to `AuraAuto`. Workload names such as chat, coding or agent are gone — this API takes a model, not a task. |
| messages | Required. Array of { role, content }. Images as image_url parts are supported by vision-capable models. |
| stream | true streams the answer as server-sent events. See Streaming. |
| stream_options.include_usage | true adds a final chunk with token counts. |
| max_tokens / max_completion_tokens | Capped at the platform limit; if omitted, the cap is used. A reasoning model spends part of it on thinking, so give it room: too small and the answer comes back empty. |
| reasoning_effort | Optional. How much a reasoning model thinks, e.g. low, medium or high (some models also take none or minimal). More effort means more reasoning tokens, billed as output tokens, so the cost follows what the model actually used. A model that does not support it answers 400 unsupported_value; leave the field out for those. How finely a model tells the levels apart is its own: some treat several of them alike, and none (where accepted) switches thinking off. |
| tools | Function tools, in the OpenAI shape. The request is served by a model that supports them. See Tools. |
| n | Must be 1. |
Fields that would steer the upstream — models, provider, route, plugins, preset, transforms — are removed. In responses, id is ours and model names the model that actually answered — for Aura Auto, the one it chose.
Streaming & thinking
Set stream: true to receive the answer as it is generated. Models that think before answering send that thinking first, in delta.reasoning_content or delta.reasoning (we pass along whichever the model uses), followed by the answer in delta.content. Some models instead wrap thinking in <think>…</think> inside the content. Show or hide it as you like; do not send it back in your next request.
curl -N https://auraroute.dev/api/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $AURAROUTE_API_KEY" \
-d '{
"model": "AuraAuto",
"stream": true,
"stream_options": { "include_usage": true },
"messages": [{ "role": "user", "content": "Explain recursion briefly." }]
}'
import OpenAI from 'openai';
const client = new OpenAI({
baseURL: 'https://auraroute.dev/api',
apiKey: process.env.AURAROUTE_API_KEY,
});
const stream = await client.chat.completions.create({
model: 'AuraAuto',
stream: true,
stream_options: { include_usage: true },
messages: [{ role: 'user', content: 'Explain recursion briefly.' }],
});
for await (const chunk of stream) {
const delta = chunk.choices[0]?.delta;
// Thinking arrives first, in a field the OpenAI types do not declare.
const thinking = delta?.reasoning_content ?? delta?.reasoning;
if (thinking) process.stderr.write(thinking);
if (delta?.content) process.stdout.write(delta.content);
}
import os
from openai import OpenAI
client = OpenAI(
base_url="https://auraroute.dev/api",
api_key=os.environ["AURAROUTE_API_KEY"],
)
stream = client.chat.completions.create(
model="AuraAuto",
stream=True,
stream_options={"include_usage": True},
messages=[{"role": "user", "content": "Explain recursion briefly."}],
)
for chunk in stream:
if not chunk.choices:
continue # the final usage chunk has no choices
delta = chunk.choices[0].delta
# Thinking arrives first, in a field the OpenAI types do not declare.
thinking = getattr(delta, "reasoning_content", None) or getattr(delta, "reasoning", None)
if thinking:
print(thinking, end="", flush=True)
if delta.content:
print(delta.content, end="", flush=True)If a provider fails before the first token, the request moves to another provider and you only see a slightly later first token. After the first token the stream cannot switch; a failure then ends the stream with an error event, shaped like the errors below.
Tools & images
Pass tools as you would to OpenAI. Requests with tools are served by models that support them, and the model replies with tool_calls for you to run and answer. Requests containing images go only to vision-capable models. If nothing capable is available you get a 503 rather than a silently degraded answer.
curl https://auraroute.dev/api/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $AURAROUTE_API_KEY" \
-d '{
"model": "AuraAuto",
"messages": [{ "role": "user", "content": "What is the weather in Dhaka?" }],
"tools": [{
"type": "function",
"function": {
"name": "get_weather",
"description": "Current weather for a city",
"parameters": {
"type": "object",
"properties": { "city": { "type": "string" } },
"required": ["city"]
}
}
}]
}'
import OpenAI from 'openai';
const client = new OpenAI({
baseURL: 'https://auraroute.dev/api',
apiKey: process.env.AURAROUTE_API_KEY,
});
const res = await client.chat.completions.create({
model: 'AuraAuto',
messages: [{ role: 'user', content: 'What is the weather in Dhaka?' }],
tools: [{
type: 'function',
function: {
name: 'get_weather',
description: 'Current weather for a city',
parameters: {
type: 'object',
properties: { city: { type: 'string' } },
required: ['city'],
},
},
}],
});
console.log(res.choices[0].message.tool_calls);
import os
from openai import OpenAI
client = OpenAI(
base_url="https://auraroute.dev/api",
api_key=os.environ["AURAROUTE_API_KEY"],
)
res = client.chat.completions.create(
model="AuraAuto",
messages=[{"role": "user", "content": "What is the weather in Dhaka?"}],
tools=[{
"type": "function",
"function": {
"name": "get_weather",
"description": "Current weather for a city",
"parameters": {
"type": "object",
"properties": {"city": {"type": "string"}},
"required": ["city"],
},
},
}],
)
print(res.choices[0].message.tool_calls)Response headers
Every response says how it was served. These are for observability — they are never inputs.
| Header | Meaning |
|---|---|
| X-Request-Id | Quote this when asking for help. |
| X-AuraRoute-Routed-Model | The model that actually answered. |
| X-AuraRoute-Attempts | More than 1 means a provider failed and the request was retried elsewhere. |
Limits
| Limit | Detail |
|---|---|
| Concurrency | Each key can have a few requests in flight at once. Beyond that you get 429 concurrency_limit_exceeded; wait for one to finish. |
| Credit | Requests are paid from your account’s credit, shared by every key and the web chat: first the plan’s monthly credit, then your top-up balance (which never expires). Each request costs what its model charges for the tokens used; cached input is billed at the cached price, and the final usage object carries usage.cost in USD. With no credit left you get 402 credit_exhausted before the request starts; if credit runs out mid-stream, the stream ends with an error event whose code is credit_exhausted. A non-streamed request may have max_tokens lowered to what your credit can pay for (header X-AuraRoute-Credit-Capped: true). |
| Output length | max_tokens is capped at a platform limit. |
| Request size | Bodies above the size limit are rejected with 413 request_too_large. |
Errors
Errors use the OpenAI shape: { "error": { "type", "code", "message", "param" } }. Match on code, not on the message.
| Status | code | What to do |
|---|---|---|
| 400 | model_not_found | model is unknown, or your plan does not allow choosing one. Use Aura Auto (`AuraAuto`), or a name from GET /v1/models. |
| 400 | invalid_value | A parameter is wrong; param says which. |
| 400 | invalid_json / invalid_body | The body is not valid JSON. |
| 401 | invalid_api_key | The key is missing, malformed or revoked. |
| 402 | credit_exhausted | No credit left. Top up or renew your plan, then retry. Mid-stream it arrives as an error event and the stream ends. |
| 413 | request_too_large | Shorten the input. |
| 429 | concurrency_limit_exceeded | Too many requests at once on this key. Retry when one finishes. |
| 429 | daily_quota_exceeded | The plan’s request allowance for this period is used up. It resets when the next billing period starts. |
| 503 | capacity_busy / upstream_unavailable / no_provider_available | Retry shortly with backoff; honour Retry-After. |
| 504 | timeout | The request took too long. Retry, or shorten it. |