58ELLISEKIZ
All ModelsImageVideoAudioChatCompare
Get started
Getting startedIntroductionQuickstart
AuthenticationCreate an appAPI tokens
GenerationsList models and pricesSubmit a generationPoll until done
ReferenceRouting and BYOKBillingErrors
58 ElliSekiz LLC · Wyoming, USAellisekiz.aiModelsCompareDocsBlogTermsPrivacyRefunds
Reference

Routing and BYOK

The same model often runs on three providers at three prices. Routing is the rule that decides which one serves a request — and it is a rule you can take over entirely.

The order of precedence

Four inputs can decide a request. They are consulted in this order, and the first one that names a usable provider wins:

  • The request. A provider field on the POST body overrides everything else.
  • A per-model pin.A provider you fixed for that one model in account settings — useful when one provider's output for a given model is simply better.
  • The account policy. Your ordered provider priority list, if you set one.
  • Price. The default: the cheapest offer that can be billed.
Pinning per request
{
  "model": "flux-schnell",
  "prompt": "a lighthouse at dawn",
  "provider": "replicate"
}

Pinning a provider that does not serve the model returns 400 rather than silently falling back — a wrong pin should fail loudly, not quietly cost you a different price.

Two ways to work

You are the router. Pull the price table from the catalog endpoint, apply your own logic — cost ceilings, latency history, provider allow-lists — and send provider on every request. We execute; the decision stays in your code.

ElliSekiz is the router. Omit provider and the account policy decides. Cheapest-first by default, which tracks price changes without a deploy on your side. The response always reports the provider that ran it, so you can log and audit the choice.

Bring your own key

Store a fal.ai, Replicate, Atlas Cloud or OpenRouter key in account settings and the router prefers it for that provider. The generation then bills your upstream account directly instead of your ElliSekiz balance, and the response carries "used_own_key": true.

  • Keys are encrypted at rest with AES-GCM and are never returned by any endpoint.
  • There is currently no platform fee on your own keys — you pay the provider, we route.
  • BYOK also unlocks offers marked byok_only: models a provider serves but does not publish a price for.
Removing a key does not break anything: requests fall back to platform keys and your prepaid balance on the next call.
← PreviousPoll until doneNext →Billing