Docs / Routing

Model fallbacks

Degrade gracefully across models, not just providers.

The models array

Send models instead of model to list candidates in priority order. If the first model is unavailable everywhere, the request tries the next, and so on.

JSON
{
  "models": [
    "anthropic/claude-opus-5",
    "anthropic/claude-sonnet-5",
    "google/gemini-3.8-flash"
  ],
  "messages": [{"role": "user", "content": "Hello"}]
}

The response includes which model actually served the request, so you can log downgrade rates.