Deterministic strategies
Priority routing with ordered failover across models and vendors
The Priority strategy tries models in your order and moves to the next when one fails. Use it for predictable routing: a primary model, then backups. To have Gateway match each prompt to a model, use Intelligent routing.
How it works
For each model in the list, Gateway tries its eligible vendors, cheapest first, before moving to the next model. A request error stops the chain; throttles, outages, and billing failures move it forward (status codes).
A one-model list is valid. It still fails over across that model’s vendors unless you pin one, so outages reach callers only when the model has a single vendor or every vendor fails. Add a second model for production traffic.
Configure a Priority policy
Callers select a policy by its model alias: "model": "@alias/<slug>".