OauthRouter is an OpenAI-compatible LLM router. Bring your own API keys or OAuth tokens for any of 11+ providers and get a single unified endpoint.
curl https://api.oauthrouter.com/v1/chat/completions \
-H "Authorization: Bearer lr_live_YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"model": "anthropic/claude-sonnet-4-5",
"messages": [{"role": "user", "content": "Hello!"}]
}'Get your token at dashboard/api.
All requests require a Bearer token in the Authorization header. Tokens start with lr_live_.
Authorization: Bearer lr_live_xxxxxxxxxxxxxxxxxxxxxxxx
/v1/chat/completionsCreate a chat completion. OpenAI-compatible. Supports streaming via stream: true.
/v1/modelsReturns models available to the caller's token. Filtered by the user's configured providers.
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| model | string | yes | — | provider/model-name (e.g. anthropic/claude-sonnet-4-5) |
| messages | array | yes | — | Array of {role, content} objects |
| max_tokens | number | no | 8192 | Max tokens in response |
| temperature | number | no | 1.0 | Sampling temperature 0-2 |
| top_p | number | no | 1.0 | Nucleus sampling threshold |
| stream | boolean | no | false | Stream partial tokens as SSE |
| Provider | Example model IDs |
|---|---|
| anthropic | claude-opus-4-6, claude-sonnet-4-5, claude-haiku-4-5 |
| openai | gpt-4o, gpt-4o-mini, o1, o1-mini |
| gemini-2.5-pro, gemini-2.5-flash, gemini-2.0-flash | |
| mistral | mistral-large-latest, codestral-latest |
| groq | llama-3.3-70b-versatile, llama-3.1-8b-instant |
| xai | grok-3, grok-3-mini |
| deepseek | deepseek-chat, deepseek-reasoner |
| together | Meta-Llama-3.1-405B-Instruct-Turbo |
| cohere | command-r-plus, command-r |
| cloudflare-ai | @cf/meta/llama-3.1-8b-instruct |
| openrouter | any openrouter model ID |
| Code | Type | Message | Solution |
|---|---|---|---|
| 401 | authentication_error | Invalid or missing token | Reveal/regenerate at /dashboard/api |
| 400 | invalid_request_error | Invalid request body | Check model and messages format |
| 429 | rate_limit_error | Monthly limit reached | Upgrade plan or wait for reset |
| 502 | api_error | Provider request failed | Check provider API key is valid |
For GUI tools (OpenClaw, Cursor, Cline, Continue.dev, OpenWebUI, LibreChat), choose "OpenAI-compatible" or "Custom OpenAI" and fill:
| Free | $0 | 100 messages/month |
| Starter | $29 | 1,000 messages/month |
| Pro | $49 | 5,000 messages/month |
| Enterprise | $69 | Unlimited |