Skip to main content
BYOK keeps your own provider contracts and rate limits while you still get Orbitrage’s routing, observability, and dashboards. Save a provider key once; for any model matching that provider, Orbitrage forwards the request with your key.

How it works

1

Save a provider key

On the Models page, add a key for any of OpenAI, Anthropic, Google, Groq, xAI, Mistral, DeepSeek, or Cohere. Optionally set a custom base URL (e.g. an Azure endpoint).
2

Orbitrage encrypts it

Keys are encrypted at rest with AES-256-GCM. The plaintext is never logged and never returned to the browser again.
3

Matching models use your key

When a call resolves to a model from that provider, the gateway decrypts your key in-memory and forwards the request to the provider directly. Your provider account is billed; your Orbitrage pooled credits are untouched (cost_usd = 0).

Seeing the split

Every call surfaces whether BYOK applied — in the dashboard (byok=true) and in the response headers:
HeaderValue
X-Orbitrage-BYOKThe provider name used (e.g. anthropic), or pooled.
X-Orbitrage-BYOK-ReasonWhy BYOK did or didn’t apply (see below).
Common X-Orbitrage-BYOK-Reason values:
ReasonMeaning
appliedYour key was found, enabled, and used.
applied-with-model-rewriteUsed, with the upstream model id adjusted.
no-key-for-providerThe model maps to a provider you haven’t saved a key for.
key-disabledYou saved the key but toggled it off.
unmapped-modelThe model doesn’t map to a BYOK provider.
decrypt-failedThe stored key couldn’t be decrypted (re-save it).

Pooled fallback

Enable an org-level setting so a failed BYOK provider call silently retries on pooled credits to keep production up. Turn it off for strict BYOK (fail rather than spend pooled credits).

BYOK vs. pooled credits

Pooled credits

Orbitrage bills your credit balance at the upstream price plus a 2.5% markup. Nothing to configure — works out of the box.

BYOK

Your provider bills you directly at your negotiated rates. Orbitrage credits are untouched. You still get full routing and observability.
BYOK and pooled credits coexist. Save keys for providers where you have good rates; everything else routes on pooled credits. Each call’s headers and dashboard row show which path it took.

Security

  • Keys are encrypted with AES-256-GCM using a server-only key; plaintext is never stored or logged.
  • Decryption happens in-memory at the gateway, per request, only for the matching provider.
  • Provider keys are scoped to your organization and protected by row-level security — no other org can read them.