Claude Code model router
Claude Code Openrouter
Claude Code agent that routes to external LLMs (Grok, Gemini, GPT-5, etc.) via OpenRouter - just mention the model name
Install
git clone https://github.com/derek-larson14/claude-code-openrouter.gitFrom the README
OpenRouter Claude Code Agent Use external LLMs (Kimi, Grok, Gemini, GLM, GPT-5) directly from Claude Code by mentioning them in your prompts. Setup New Project Clone this repo and add your API key: Get your API key from OpenRouter.ai Existing Project Run this from your project directory: Then add your API key: Usage In Claude Code, just mention the model name: - "Use kimi to write a blog post about AI" - "Ask grok to explain quantum computing" - "Have gemini create a marketing presentation and use @marketing/project-plan.md as context" Add "external-llm" to your prompt if it doesn't trigger automatically. First Run: Claude Code will ask for approval the first time. Select "Yes, and don't ask again..." to auto-approve future calls. Available Models Default models configured in models.conf: - kimi - Moonshot AI's K2 model (great for creative writing) - grok - Grok 4 from X.AI - grok-fast - Grok 4 Fast from X.AI - glm - GLM-4.6 from Zhipu AI - gemini - Gemini 2.5 Pro from Google - gpt-5 - GPT-5 from OpenAI Adding Your Own Models Edit models.conf to add any OpenRouter model: Find model IDs at OpenRouter.ai/models Output Locations Default behavior - saves to llm-outputs/: Custom paths - specify where to save: Direct CLI Usage You can also use the script directly from the command line: CLI Options - --model - Which model to use (from models.conf) - --query - Your prompt - --output - Where to save the response - --system-prompt - Add instructions - --context-file - Include file content - --temperature - Creativity (0-2, default 0.7) - --max-tokens - Max length (default 4000) File Locations - API key: .env or ~/.openrouter.env - Model config: models.conf - Generated files: llm-outputs/ - Agent config:…
Details
- Repository
- derek-larson14/claude-code-openrouter
- Language
- Shell
- License
- MIT
- Last updated
- 30 November 2025
FAQ
What is Claude Code Openrouter?
Claude Code agent that routes to external LLMs (Grok, Gemini, GPT-5, etc.) via OpenRouter - just mention the model name It is a model router for Claude Code, from derek-larson14/claude-code-openrouter on GitHub.
How do I install Claude Code Openrouter?
Clone derek-larson14/claude-code-openrouter from GitHub and follow the setup steps in its README.
Is Claude Code Openrouter popular?
derek-larson14/claude-code-openrouter has 28 GitHub stars and 3 forks. It was last updated on 30 November 2025.
More model routers & proxies
Clancy
28bazumo/clancy
HTTP/HTTPS proxy with real-time monitoring for Agent traffic. Designed for debugging and monitoring Claude Code, Anthropic API calls, and other AI agent communications.
Kiro Claude Proxy
27alexandephilia/kiro-claude-proxy
A local proxy to intercept and replace standard CLI or BYOK authentication with Kiro/AWS creds... basically letting Claude Code operate independently from Anthropic’s native billing backend
Workbuddy2api
25hawklithm/workbuddy2api
A lightweight API proxy for domestic and international CodeBuddy backends, providing OpenAI, Anthropic, and Responses-compatible APIs with native support for Claude Code, Codex CLI, and DeepSeek Harness.
Freemodel Auto Router
25will-17173/freemodel-auto-router
一个聚合多个服务商的免费模型,自动切换可用模型的桌面工具,并可将 OpenCode Go 订阅转为 Claude Code 可用代理。
Zerokey
26downloaddoctor/zerokey
OpenAI-compatible local AI proxy for DeepSeek, Claude , ChatGPT and Qwen — pipe any of them into VS Code or Terax using your real browser session. Just paste a fetch().
Claude Proxy
34sunflower0305/claude-proxy
Claude Code / Claude Agent SDK proxy for DeepSeek, Qwen, GLM, MiniMax, Kimi and MiMo via Anthropic Messages API with observability
Browse the most popular Claude Code mods, all model routers & proxies, or the skills and MCP server directories.