Auth
Keys are issued from Get API key — email contact@routerlab.buzz. Prefix sk-rlb-. Never commit a full key.
Docs · api.routerlab.buzz/v1
The gateway is OpenAI-compatible and also speaks the Anthropic Messages API. Everything is served under https://api.routerlab.buzz/v1 with one header: Authorization: Bearer <key>.
POST https://api.routerlab.buzz/v1/chat/completions
Keys are issued from Get API key — email contact@routerlab.buzz. Prefix sk-rlb-. Never commit a full key.
GET /v1/models does not spend. Use the model ids exactly as returned. Local and BYOK lanes show up on the same list.
Server-sent events pass straight through, token by token. Errors name the problem and the recovery so an agent can fix the next call.
PUT /api/models/<id>/waterfall replaces the ordered provider chain. Org overrides win over the default. Clear them and the default returns.
curl https://api.routerlab.buzz/v1/chat/completions \
-H "Authorization: Bearer $ROUTERLAB_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "haiku-class",
"messages": [{"role":"user","content":"reply with the single word: ok"}]
}'
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://api.routerlab.buzz/v1",
apiKey: process.env.ROUTERLAB_API_KEY,
});
const r = await client.chat.completions.create({
model: "haiku-class",
messages: [{ role: "user", content: "reply with the single word: ok" }],
});
from openai import OpenAI
import os
client = OpenAI(
base_url="https://api.routerlab.buzz/v1",
api_key=os.environ["ROUTERLAB_API_KEY"],
)
r = client.chat.completions.create(
model="haiku-class",
messages=[{"role": "user", "content": "reply with the single word: ok"}],
)
Point the Anthropic client’s base_url at https://api.routerlab.buzz/v1 (not /v1/messages — the SDK appends the path). Text only on that lane: extended thinking and image blocks are dropped.
from anthropic import Anthropic
client = Anthropic(
base_url="https://api.routerlab.buzz/v1",
api_key=os.environ["ROUTERLAB_API_KEY"],
)
m = client.messages.create(
model="haiku-class",
max_tokens=16,
messages=[{"role": "user", "content": "reply with the single word: ok"}],
)
Paste this into Claude Code, Cursor, or Codex. It asks for your email, never invents a key, and wires the endpoint. Full onboarding (BYOK connect, optional trace import) is a conversation with contact@routerlab.buzz until the hosted signup is live.
I pasted this myself. Create a Router Lab account for the email I give you — wait for that address, never guess. Store the gateway key as ROUTERLAB_API_KEY. Wire OpenAI-compatible clients to https://api.routerlab.buzz/v1. Confirm with GET /v1/models (no spend). Do not make a paid completion until I say so. BYOK pass-through on keys I later connect is unaffected.