Start here
Three commands answer most of it before you read any further:Authentication
401 — every request rejected
401 — every request rejected
x-api-key; OpenAI-style endpoints take
Authorization: Bearer. /v1/messages accepts either. Keys start with sdn_.
See Authentication.Claude Code ignores the gateway and talks to Anthropic
Claude Code ignores the gateway and talks to Anthropic
/logout first, then re-run npx sideren. Check
ANTHROPIC_BASE_URL is the bare origin — https://api.sideren.io, with no /v1;
the Anthropic SDK appends the path itself.Claude on Windows rejects my sdn_ key
Claude on Windows rejects my sdn_ key
sdn_; they are not Anthropic sk-ant- credentials.
Configure Claude Code with npx sideren setup --tool claude-code --key sdn_your_key, or set
ANTHROPIC_BASE_URL=https://api.sideren.io and put the key in ANTHROPIC_AUTH_TOKEN from
PowerShell. Do not paste it into the consumer Claude desktop app’s Anthropic key/sign-in field;
that app does not configure a custom gateway. See Claude Code.Codex can't find a key / missing SIDEREN_API_KEY
Codex can't find a key / missing SIDEREN_API_KEY
npx sideren setup --tool codex --key sdn_your_key so the key is stored as
experimental_bearer_token in ~/.codex/config.toml. See Codex CLI.Models
404 — no such model
404 — no such model
GET /v1/models. Unknown ids fail closed
rather than silently becoming something else, and the compatibility handles for foreign
SDK names are a finite list — an invented id is a 404 by design. See
Model routing.The model in the catalog page isn't in GET /v1/models
The model in the catalog page isn't in GET /v1/models
400 on a request with an image
400 on a request with an image
capabilities.vision on the catalog entry. See
Vision.422 — the model can't guarantee what you asked for
422 — the model can't guarantee what you asked for
tool_choice, a strict
response_format, a reasoning effort level) that no placement of that model can honour
exactly. Switch to a model whose supported_parameters includes it, or drop the
requirement.Output
Empty response, or an answer that stops mid-sentence
Empty response, or an answer that stops mid-sentence
finish_reason: "length" — you hit max_tokens. On a reasoning model, hidden
reasoning is charged against the same ceiling and can consume all of it, leaving
nothing for the answer. Raise the budget; 4,000+ is a safe floor on reasoning models.
See Reasoning.Unexpected thinking blocks break my client
Unexpected thinking blocks break my client
thinking, reasoning_effort or reasoning — often an SDK default.
Remove it.The stream just stops
The stream just stops
A different model answered than the one I named
A different model answered than the one I named
delivery field says which ids are pinned and which are compatibility
handles: optimized ids are served by whichever comparable model the gateway picks
today, exact ids keep their own placement. The response always echoes the id you
sent. Pin a delivery: "exact" id for anything whose exact behavior you depend on.
See Model routing.Limits and cost
429 with a short retry-after
429 with a short retry-after
retry-after exactly
and pace off the x-ratelimit-* headers instead of discovering the limit by hitting
it. Parallel agent fleets usually hit concurrency first. See Plans & limits.402 allowance_exhausted
402 allowance_exhausted
402 allowance_exhausted. The message says how much of the month you have used, when your
credits renew and which plan has more, and the error object carries the same facts as
fields (limit, used_percent, resets_at, upgrade_url). In-flight requests finish:
nothing is cut off mid-stream, and your subscription is never billed extra for it. A 402
carries no retry-after, because waiting a few seconds doesn’t clear it.Two ways to keep going:- Use purchased credit in PAYG mode. Add credit on the
billing page, then turn on PAYG mode for your
key or send the
x-sideren-payment-mode: paygheader. The setup helper’snpx sideren setup --payment-mode paygstamps it into the agents it configures. - Upgrade. The higher plan’s credits apply right away. Downgrades take effect at renewal.
402 credit_used_up. Free credits don’t renew, so only purchased credit or a subscription
clears it.400 plan_upgrade_required
400 plan_upgrade_required
402 credit_used_up with no retry-after
402 credit_used_up with no retry-after
retry-after. Subscribe, or add credit and turn on PAYG mode for your key. Don’t retry
it in a loop. (Before 2026-10-17 this code was credits_exhausted.)402 paid_credit_required
402 paid_credit_required
x-sideren-payment-mode: payg header) and there is no purchased credit left. Only a
top-up clears it; or turn PAYG mode off to use your plan’s credits.Requests are slower than expected under load
Requests are slower than expected under load
Usage is burning faster than expected
Usage is burning faster than expected
x-sideren-monthly-used-percent on every response
shows how much of the month is gone. Two levers: move the hot path to a lighter model,
and keep the prompt prefix stable so repeated context is served from the cache
(Prompt caching).Getting help
support@sideren.io
- What you sent — endpoint, model id, and the request body with secrets removed.
- What came back — the status code and the full
error.message. - When — a rough timestamp with timezone, so the trace can be found.
- The
sideren-modelresponse header, if you have it — it names what actually served the request.