openrouter-multi-provider
Use multiple AI providers through OpenRouter. Use when leveraging different providers for different capabilities. Trigger with phrases like 'openrouter providers', 'multi provider', 'openrouter openai anthropic', 'use multiple models'.
- License 许可
- MIT
- 最近更新
- 2026-05-26
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- openrouter-multi-provider
- author
- Jeremy Longshore <jeremy@intentsolutions.io>
- license
- MIT
- version
- 1.0.0
- description
- Use multiple AI providers through OpenRouter. Use when leveraging different providers for different capabilities. Trigger with phrases like 'openrouter providers', 'multi provider', 'openrouter openai anthropic', 'use multiple models'.
- allowed-tools
- Read, Write, Edit, Grep
- compatible-with
- claude-code, codex, openclaw
02 资源文件 9
- 参考文档references/cost-optimization-across-providers.md1.5 KB
- 参考文档references/errors.md323 B
- 参考文档references/examples.md3.8 KB
- 参考文档references/model-comparison.md2.1 KB
- 参考文档references/multi-provider-router.md1.9 KB
- 参考文档references/provider-fallback-chain.md1.9 KB
- 参考文档references/provider-health-monitoring.md1.4 KB
- 参考文档references/provider-overview.md1.4 KB
- 参考文档references/provider-specific-features.md1.6 KB
03 SKILL.md 正文
Openrouter Multi Provider
Overview
This skill shows how to leverage OpenRouter's unified API to access models from OpenAI, Anthropic, Google, Meta, Mistral, and other providers through a single integration point.
Prerequisites
- OpenRouter integration with sufficient credits
- Familiarity with models from at least two providers
Instructions
- Understand the provider namespace: OpenRouter model IDs use
provider/model-nameformat (e.g.,openai/gpt-4-turbo,anthropic/claude-3.5-sonnet,google/gemini-pro) - Compare provider strengths: Test the same prompt across providers to evaluate quality, speed, and cost; each provider excels at different task types
- Route by task type: Use OpenAI models for code generation, Anthropic for analysis and safety, Google for multimodal, and open-source models for cost-sensitive tasks
- Handle provider-specific features: Some features (like system prompts, tool calling, or JSON mode) work differently across providers; test each model's behavior
- Build a provider abstraction: Create a thin wrapper that normalizes provider differences so your application code doesn't need to know which provider is serving the request
Output
- A unified client that works with any provider through OpenRouter
- Provider comparison matrix for your specific use cases
- Task-to-provider routing logic that optimizes for quality and cost
Error Handling
| Error | Cause | Fix |
|---|---|---|
| Feature not supported | Provider doesn't support the requested feature (e.g., tools) | Check model capabilities via /models endpoint before sending |
| Different response formats | Providers return slightly different structures | Normalize responses through your abstraction layer |
| Provider outage | Single provider is down | Implement cross-provider fallback (e.g., OpenAI -> Anthropic -> Google) |
See ${CLAUDE_SKILL_DIR}/references/errors.md for full error reference.
Examples
See ${CLAUDE_SKILL_DIR}/references/examples.md for runnable code samples.
Resources
04 同仓库更多 Skills
zustand-store-ts
Create Zustand stores with TypeScript, subscribeWithSelector middleware, and proper state/action separation. Use when building React state management, creating global stores, or implementing reactive state patterns with Zustand.
zustand-store-creator
Zustand Store Creator - Auto-activating skill for Frontend Development. Triggers on: zustand store creator, zustand store creator Part of the Frontend Development skill category.
zero-trust-config-helper
Zero Trust Config Helper - Auto-activating skill for Security Advanced. Triggers on: zero trust config helper, zero trust config helper Part of the Security Advanced skill category.
zapier-integration-helper
Zapier Integration Helper - Auto-activating skill for Business Automation. Triggers on: zapier integration helper, zapier integration helper Part of the Business Automation skill category.
zai-cli
Execute z.AI CLI providing vision, search, reader, and GitHub exploration via CLI and MCP. Use when user needs image/video analysis, OCR, UI-to-code conversion, error diagnosis, real-time web search, web page to markdown extraction, or GitHub code exploration. Trigger with phrases like "analyze this image", "search the web for", "read this page", "explore this repo", or "use zai". Requires Z_AI_API_KEY.
yt-research
Research competitor YouTube channels, niches, and trending topics for your content strategy. Use this skill whenever the user says "research channels", "analyze competitors", "find trending topics", "niche analysis", "competitive research", "what are other creators doing", "scrape YouTube channels", or wants to understand the competitive landscape for a specific tool or topic area. Use when working with yt research. Trigger with 'yt', 'research'.