What is ModelRiver, and why not just call OpenAI directly?
ModelRiver is a single API in front of the AI providers you already use (OpenAI, Anthropic, Google, Mistral, xAI and more). Your app calls one endpoint, and ModelRiver handles routing, failover, structured output checks, logging and spend limits around each request.
What do I get that a direct API call doesn't give me?#
Calling one provider directly is fine until something goes wrong. ModelRiver adds:
- Failover: if your main model errors, times out or rate-limits, a backup model from the same or another provider answers instead.
- Structured outputs: responses are checked against your JSON schema before they reach your app.
- One place for changes: swap providers, models or prompts in the console without redeploying your code.
- Request logs: every call, with tokens, timing, status and each failover attempt.
- Spend limits: caps per project or per workflow, so a bug can't run up a surprise bill.
- Streaming and live updates: results can go straight to the browser over WebSocket.
Do I have to rewrite my app?#
No. If you use the OpenAI SDK, LangChain, LlamaIndex or the Vercel AI SDK, you change the base URL and the API key, and set model to the name of your ModelRiver workflow. See Can I use the OpenAI SDK with ModelRiver?.
Does ModelRiver replace my AI provider account?#
No. You connect your own provider API keys and pay providers directly for tokens. ModelRiver charges only for the platform. More in Do I pay for AI tokens through ModelRiver?
Which providers are supported?#
13 providers: OpenAI, Anthropic, Google, xAI, Mistral AI, Cohere, DeepSeek, Qwen, Groq, Kimi, MiniMax, Azure OpenAI and Amazon Bedrock. The full, current model list is on the providers page.