Route every request
through one endpoint
AXON is an inference router. Point your existing OpenAI client at our base URL and reach every model this instance exposes — with latency-aware routing, automatic failover between providers, and billing that stops at the tokens you actually spent.
- 2
- models configured
- 1
- endpoint
- 0
- markup
- receivePOST /api/v1/chat/completions
- authbearer token → sha-256 → active key
- resolvemodel id → provider (1:1 mapping)
- forwardrequest sent to provider verbatim
Real requests report measured TTFT, token counts and cost in the console — this panel shows the sequence, not live figures.
What sits between your app and the model
A router is infrastructure — it should be boring, observable and honest about its limits. This is what the current build does.
POST /v1/chat/completionsOpenAI-compatible surface
The request body is the standard chat-completions schema, forwarded to the upstream unchanged. Point any OpenAI client at the base URL and change the model string — that is the whole integration.
self-configured catalogBring your own providers
A provider is a base URL plus that provider's key. Models are bound to a provider and exposed under whatever id you choose, with the prices you set. Nothing is bundled or resold.
30-day request logEvery request logged
Success or failure, each attempt writes one row: status, measured TTFT and total latency, token counts, computed cost, and which upstream served it. Errors keep the upstream's own message.
sha-256, shown onceHashed API keys
A key's plaintext exists once, at creation. Only a SHA-256 hash is stored, so a database dump hands over nothing usable. Revoke keeps the audit row; delete removes it entirely.
sql aggregatesUsage from real rows
Charts and totals are SQL aggregates over your own request log, not estimates. A new account shows zeros because it has served zero requests.
metadata onlyPrompts are not stored
The router records metadata — model, status, latency, token counts, cost — and never writes prompt or completion text to the database.
One hop, one provider, no surprises
Authenticate, resolve the model to its provider, forward the request. There is no proxy chain and no hidden retry — if the upstream fails you see its error, not a substitute.
- 01
Client sends
Standard OpenAI chat-completions payload. Only the base URL differs.
- 02
Key is checked
The bearer token is hashed and matched against active keys. Revoked or unknown keys stop here with a 401.
- 03
Model resolves
The model id maps to exactly one configured provider. An unknown id returns 404 — never a silent substitution.
- 04
Provider serves
The request is forwarded verbatim and the response streams straight back. Whatever the provider returns is what you get, errors included.
Every model, one endpoint
2 models available right now. Prices are per 1M tokens — the rate you actually pay, taken from this instance's configuration.
claude-opus-5
Palz
- ctx
- —
- in
- 0 cr
- out
- 0 cr
claude-opus-5per 1M tokensclaude-opus-4-8
Palz
- ctx
- —
- in
- 1.480 cr
- out
- 2.400 cr
claude-opus-4-8per 1M tokensOne base URL to switch, one to switch back
If your code already talks to OpenAI it already talks to AXON, for the two endpoints this build implements. Same request shape, same streaming semantics, same error objects — so a rollback is one env var.
- Any OpenAI-compatible client works unmodified against /v1/chat/completions and /v1/models.
- Streaming forwards the upstream's SSE frames byte-for-byte, plus one appended frame with the recorded totals.
- Errors carry the upstream's real status and message, so your existing retry logic stays put.
- Not implemented: embeddings, Assistants, fine-tuning, files, images and audio. Those return 404.
import OpenAI from "openai";
const axon = new OpenAI({
baseURL: "https://your-axon-host/api/v1",
apiKey: process.env.AXON_API_KEY,
});
const res = await axon.chat.completions.create({
model: "claude-opus-5",
messages: [{ role: "user", content: "Say hello" }],
});
console.log(res.choices[0].message.content);
// AXON adds its own block with the recorded request id,
// measured latency and the cost computed for this call.
console.log(res.axon);const stream = await axon.chat.completions.create({
model: "claude-opus-5",
stream: true,
messages: [{ role: "user", content: "Explain routing in two lines" }],
});
for await (const chunk of stream) {
process.stdout.write(chunk.choices[0]?.delta?.content ?? "");
// The final frame AXON appends carries the recorded totals.
if (chunk.axon) console.error("\n", chunk.axon);
}Work out the bill before you write the code
Enter the traffic you expect. The numbers below come straight from the published rate card — nothing is rounded up.
Rp 0 pada kurs 1.000 kredit
INPUT 0% · OUTPUT 0%
No model in the catalog serves this traffic shape for less.
The questions that actually decide it
For POST /v1/chat/completions and GET /v1/models, yes — including streaming. Anything else in the OpenAI surface (embeddings, Assistants, fine-tuning, files, images, audio) is not implemented in this build and returns 404.
Swap the base URL. Keep the rest of your stack.
Create an account, add a key, point your client at one base URL. Nothing is charged — this instance records cost, it does not bill it.