Use rawroute with LibreChat. One librechat.yaml block for every frontier model.
Replacing 4 separate vendor keys in LibreChat with one custom endpoint block in librechat.yaml cuts team AI spend by 50–70%, removes OpenRouter's 5.5% top-up fee, auto-fetches every new model from /v1/models, and protects teams from upstream 429/529 outages via multi-provider failover.
Quick setup for LibreChat
- Add RAWROUTE_API_KEY to your LibreChat .env file.
- Paste the custom endpoint block below into librechat.yaml.
- Restart LibreChat — all models appear under the rawroute provider dropdown.
endpoints:
custom:
- name: "rawroute"
apiKey: "${RAWROUTE_API_KEY}"
baseURL: "https://api.rawroute.dev/v1"
models:
default:
- "claude-sonnet-5-5"
- "gpt-6.2-sol"
- "gemini-4-neon"
- "grok-4.7"
fetch: true
titleConvo: true
titleModel: "claude-haiku-5-5"Recommended models for LibreChat
| Model | Model ID | Official | OpenRouter +5.5% | rawroute (0%) | Providers |
|---|---|---|---|---|---|
| Claude Sonnet 5.5 | claude-sonnet-5-5 | $2.11 / $10.55 | $1.00 / $5.00 | 4 | |
| Claude Haiku 5.5 | claude-haiku-5-5 | $0.11 / $0.53 | $0.05 / $0.25 | 3 | |
| GPT-6.2 Sol | gpt-6.2-sol | $2.11 / $10.55 | $0.60 / $3.00 | 3 | |
| Gemini 4 Neon | gemini-4-neon | $3.17 / $15.82 | $1.50 / $7.50 | 2 |
When NOT to use rawroute
- — If you need LibreChat Assistants API file-search threads hosted exclusively inside an OpenAI enterprise org, keep the built-in OpenAI endpoint enabled alongside rawroute.
FAQ
Does fetch: true work with rawroute in LibreChat?
Yes. GET /v1/models returns all active model IDs in standard OpenAI list format so LibreChat stays in sync automatically.