[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M78E353N9AQW2RN29Y0TDBFT":3,"skill-same:01M78E353N9AQW2RN29Y0TDBFT":76},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":14,"repositoryHtmlUrl":27,"repositoryHomepageUrl":6,"ownerHtmlUrl":28,"ownerBlogUrl":29,"ownerDescription":30,"updatedAt":31,"install":32,"resources":45},"01M78E353N9AQW2RN29Y0TDBFT","openrouter",null,"OpenRouter API - Unified access to 400+ AI models through one API","justin-pitt\u002Fpitt-skills","justin-pitt","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F112410033?v=4","01M78E1625ASNK5WY5C3ZN55T3","Justin Pitt","01M78E1630ZDV7CZJBEWA7CCZH",0,"MIT","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: openrouter\ndescription: OpenRouter API - Unified access to 400+ AI models through one API\nlicense: MIT\nuser-invocable: false\n---\n\n# OpenRouter Skill\n\nComprehensive assistance with OpenRouter API development, providing unified access to hundreds of AI models through a single endpoint with intelligent routing, automatic fallbacks, and standardized interfaces.\n\n## When to Use This Skill\n\nThis skill should be triggered when:\n- Making API calls to multiple AI model providers through a unified interface\n- Implementing model fallback strategies or auto-routing\n- Working with OpenAI-compatible SDKs but targeting multiple providers\n- Configuring advanced sampling parameters (temperature, top_p, penalties)\n- Setting up streaming responses or structured JSON outputs\n- Comparing costs across different AI models\n- Building applications that need automatic provider failover\n- Implementing function\u002Ftool calling across different models\n- Questions about OpenRouter-specific features (routing, fallbacks, zero completion insurance)\n\n## Quick Reference\n\n### Basic Chat Completion (Python)\n```python\nfrom openai import OpenAI\n\nclient = OpenAI(\n  base_url=\"https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\",\n  api_key=\"\u003COPENROUTER_API_KEY>\",\n)\n\ncompletion = client.chat.completions.create(\n  model=\"openai\u002Fgpt-4o\",\n  messages=[{\"role\": \"user\", \"content\": \"What is the meaning of life?\"}]\n)\nprint(completion.choices[0].message.content)\n```\n\n### Basic Chat Completion (JavaScript\u002FTypeScript)\n```typescript\nimport OpenAI from 'openai';\n\nconst openai = new OpenAI({\n  baseURL: 'https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1',\n  apiKey: '\u003COPENROUTER_API_KEY>',\n});\n\nconst completion = await openai.chat.completions.create({\n  model: 'openai\u002Fgpt-4o',\n  messages: [{\"role\": 'user', \"content\": 'What is the meaning of life?'}],\n});\nconsole.log(completion.choices[0].message);\n```\n\n### cURL Request\n```bash\ncurl https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fchat\u002Fcompletions \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -H \"Authorization: Bearer $OPENROUTER_API_KEY\" \\\n  -d '{\n    \"model\": \"openai\u002Fgpt-4o\",\n    \"messages\": [{\"role\": \"user\", \"content\": \"What is the meaning of life?\"}]\n  }'\n```\n\n### Model Fallback Configuration (Python)\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    extra_body={\n        \"models\": [\"anthropic\u002Fclaude-3.5-sonnet\", \"gryphe\u002Fmythomax-l2-13b\"],\n    },\n    messages=[{\"role\": \"user\", \"content\": \"Your prompt here\"}]\n)\n```\n\n### Model Fallback Configuration (TypeScript)\n```typescript\nconst completion = await client.chat.completions.create({\n    model: 'openai\u002Fgpt-4o',\n    models: ['anthropic\u002Fclaude-3.5-sonnet', 'gryphe\u002Fmythomax-l2-13b'],\n    messages: [{ role: 'user', content: 'Your prompt here' }],\n});\n```\n\n### Auto Router (Dynamic Model Selection)\n```python\ncompletion = client.chat.completions.create(\n    model=\"openrouter\u002Fauto\",  # Automatically selects best model for the prompt\n    messages=[{\"role\": \"user\", \"content\": \"Your prompt here\"}]\n)\n```\n\n### Advanced Parameters Example\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\"role\": \"user\", \"content\": \"Write a creative story\"}],\n    temperature=0.8,           # Higher for creativity (0.0-2.0)\n    max_tokens=500,            # Limit response length\n    top_p=0.9,                 # Nucleus sampling (0.0-1.0)\n    frequency_penalty=0.5,     # Reduce repetition (-2.0-2.0)\n    presence_penalty=0.3       # Encourage topic diversity (-2.0-2.0)\n)\n```\n\n### Streaming Response\n```python\nstream = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\"role\": \"user\", \"content\": \"Tell me a story\"}],\n    stream=True\n)\n\nfor chunk in stream:\n    if chunk.choices[0].delta.content:\n        print(chunk.choices[0].delta.content, end='')\n```\n\n### JSON Mode (Structured Output)\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\n        \"role\": \"user\",\n        \"content\": \"Extract person's name, age, and city from: John is 30 and lives in NYC\"\n    }],\n    response_format={\"type\": \"json_object\"}\n)\n```\n\n### Deterministic Output with Seed\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\"role\": \"user\", \"content\": \"Generate a random number\"}],\n    seed=42,            # Same seed = same output (when supported)\n    temperature=0.0     # Deterministic sampling\n)\n```\n\n## Key Concepts\n\n### Model Routing\nOpenRouter provides intelligent routing capabilities:\n- **Auto Router** (`openrouter\u002Fauto`): Automatically selects the best model based on your prompt using NotDiamond\n- **Fallback Models**: Specify multiple models that automatically retry if primary fails\n- **Provider Routing**: Automatically routes across providers for reliability\n\n### Authentication\n- Uses Bearer token authentication with API keys\n- API keys can be managed programmatically\n- Compatible with OpenAI SDK authentication patterns\n\n### Model Naming Convention\nModels use the format `provider\u002Fmodel-name`:\n- `openai\u002Fgpt-4o` - OpenAI's GPT-4 Optimized\n- `anthropic\u002Fclaude-3.5-sonnet` - Anthropic's Claude 3.5 Sonnet\n- `google\u002Fgemini-2.0-flash-exp:free` - Google's free Gemini model\n- `openrouter\u002Fauto` - Auto-routing system\n\n### Sampling Parameters\n\n**Temperature** (0.0-2.0, default: 1.0)\n- Lower = more predictable, focused responses\n- Higher = more creative, diverse responses\n- Use low (0.0-0.3) for factual tasks, high (0.8-1.5) for creative work\n\n**Top P** (0.0-1.0, default: 1.0)\n- Limits choices to percentage of likely tokens\n- Dynamic filtering of improbable options\n- Balance between consistency and variety\n\n**Frequency\u002FPresence Penalties** (-2.0-2.0, default: 0.0)\n- Frequency: Discourages repeating tokens proportional to use\n- Presence: Simpler penalty not scaled by count\n- Positive values reduce repetition, negative encourage reuse\n\n**Max Tokens** (integer)\n- Sets maximum response length\n- Cannot exceed context length minus prompt length\n- Use to control costs and enforce concise replies\n\n### Response Formats\n- **Standard JSON**: Default chat completion format\n- **Streaming**: Server-Sent Events (SSE) with `stream: true`\n- **JSON Mode**: Guaranteed valid JSON with `response_format: {\"type\": \"json_object\"}`\n- **Structured Outputs**: Schema-validated JSON responses\n\n### Advanced Features\n- **Tool\u002FFunction Calling**: Connect models to external APIs\n- **Multimodal Inputs**: Support for images, PDFs, audio\n- **Prompt Caching**: Reduce costs for repeated prompts\n- **Web Search Integration**: Enhanced responses with web data\n- **Zero Completion Insurance**: Protection against failed responses\n- **Logprobs**: Access token probabilities for confidence analysis\n\n## Reference Files\n\nThis skill includes comprehensive documentation in `references\u002F`:\n\n- **llms-full.md** - Complete list of available models with metadata\n- **llms-small.md** - Curated subset of popular models\n- **llms.md** - Standard model listings\n\nUse `view` to read specific reference files when detailed model information is needed.\n\n## Working with This Skill\n\n### For Beginners\n1. Start with basic chat completion examples (Python\u002FJavaScript\u002FcURL above)\n2. Use the standard OpenAI SDK for easy integration\n3. Try simple model names like `openai\u002Fgpt-4o` or `anthropic\u002Fclaude-3.5-sonnet`\n4. Keep parameters simple initially (just model and messages)\n\n### For Intermediate Users\n1. Implement model fallback arrays for reliability\n2. Experiment with sampling parameters (temperature, top_p)\n3. Use streaming for better UX in conversational apps\n4. Try `openrouter\u002Fauto` for automatic model selection\n5. Implement JSON mode for structured data extraction\n\n### For Advanced Users\n1. Fine-tune multiple sampling parameters together\n2. Implement custom routing logic with fallback chains\n3. Use logprobs for confidence scoring\n4. Leverage tool\u002Ffunction calling capabilities\n5. Optimize costs by selecting appropriate models per task\n6. Implement prompt caching strategies\n7. Use seed parameter for reproducible testing\n\n## Common Patterns\n\n### Error Handling with Fallbacks\n```python\ntry:\n    completion = client.chat.completions.create(\n        model=\"openai\u002Fgpt-4o\",\n        extra_body={\n            \"models\": [\n                \"anthropic\u002Fclaude-3.5-sonnet\",\n                \"google\u002Fgemini-2.0-flash-exp:free\"\n            ]\n        },\n        messages=[{\"role\": \"user\", \"content\": \"Your prompt\"}]\n    )\nexcept Exception as e:\n    print(f\"All models failed: {e}\")\n```\n\n### Cost-Optimized Routing\n```python\n# Use cheaper models for simple tasks\nsimple_completion = client.chat.completions.create(\n    model=\"google\u002Fgemini-2.0-flash-exp:free\",\n    messages=[{\"role\": \"user\", \"content\": \"Simple question\"}]\n)\n\n# Use premium models for complex tasks\ncomplex_completion = client.chat.completions.create(\n    model=\"openai\u002Fo1\",\n    messages=[{\"role\": \"user\", \"content\": \"Complex reasoning task\"}]\n)\n```\n\n### Context-Aware Temperature\n```python\n# Low temperature for factual responses\nfactual = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    temperature=0.2,\n    messages=[{\"role\": \"user\", \"content\": \"What is the capital of France?\"}]\n)\n\n# High temperature for creative content\ncreative = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    temperature=1.2,\n    messages=[{\"role\": \"user\", \"content\": \"Write a unique story opening\"}]\n)\n```\n\n## Resources\n\n### Official Documentation\n- API Reference: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fapi-reference\u002Foverview\n- Quickstart Guide: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fquickstart\n- Model List: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fmodels\n- Parameters Guide: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fapi-reference\u002Fparameters\n\n### Key Endpoints\n- Chat Completions: `POST https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fchat\u002Fcompletions`\n- List Models: `GET https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fmodels`\n- Generation Info: `GET https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fgeneration`\n\n## Notes\n\n- OpenRouter normalizes API schemas across all providers\n- Uses OpenAI-compatible API format for easy migration\n- Automatic provider fallback if models are rate-limited or down\n- Pricing based on actual model used (important for fallbacks)\n- Response includes metadata about which model processed the request\n- All models support streaming via Server-Sent Events\n- Compatible with popular frameworks (LangChain, Vercel AI SDK, etc.)\n\n## Best Practices\n\n1. **Always implement fallbacks** for production applications\n2. **Use appropriate temperature** based on task type (low for factual, high for creative)\n3. **Set max_tokens** to control costs and response length\n4. **Enable streaming** for better user experience in chat applications\n5. **Use JSON mode** when you need guaranteed structured output\n6. **Test with seed parameter** for reproducible results during development\n7. **Monitor costs** by selecting appropriate models per task\n8. **Use auto-routing** when unsure which model performs best\n9. **Implement proper error handling** for rate limits and failures\n10. **Cache prompts** for repeated requests to reduce costs\n","# OpenRouter Skill\n\nComprehensive assistance with OpenRouter API development, providing unified access to hundreds of AI models through a single endpoint with intelligent routing, automatic fallbacks, and standardized interfaces.\n\n## When to Use This Skill\n\nThis skill should be triggered when:\n- Making API calls to multiple AI model providers through a unified interface\n- Implementing model fallback strategies or auto-routing\n- Working with OpenAI-compatible SDKs but targeting multiple providers\n- Configuring advanced sampling parameters (temperature, top_p, penalties)\n- Setting up streaming responses or structured JSON outputs\n- Comparing costs across different AI models\n- Building applications that need automatic provider failover\n- Implementing function\u002Ftool calling across different models\n- Questions about OpenRouter-specific features (routing, fallbacks, zero completion insurance)\n\n## Quick Reference\n\n### Basic Chat Completion (Python)\n```python\nfrom openai import OpenAI\n\nclient = OpenAI(\n  base_url=\"https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\",\n  api_key=\"\u003COPENROUTER_API_KEY>\",\n)\n\ncompletion = client.chat.completions.create(\n  model=\"openai\u002Fgpt-4o\",\n  messages=[{\"role\": \"user\", \"content\": \"What is the meaning of life?\"}]\n)\nprint(completion.choices[0].message.content)\n```\n\n### Basic Chat Completion (JavaScript\u002FTypeScript)\n```typescript\nimport OpenAI from 'openai';\n\nconst openai = new OpenAI({\n  baseURL: 'https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1',\n  apiKey: '\u003COPENROUTER_API_KEY>',\n});\n\nconst completion = await openai.chat.completions.create({\n  model: 'openai\u002Fgpt-4o',\n  messages: [{\"role\": 'user', \"content\": 'What is the meaning of life?'}],\n});\nconsole.log(completion.choices[0].message);\n```\n\n### cURL Request\n```bash\ncurl https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fchat\u002Fcompletions \\\n  -H \"Content-Type: application\u002Fjson\" \\\n  -H \"Authorization: Bearer $OPENROUTER_API_KEY\" \\\n  -d '{\n    \"model\": \"openai\u002Fgpt-4o\",\n    \"messages\": [{\"role\": \"user\", \"content\": \"What is the meaning of life?\"}]\n  }'\n```\n\n### Model Fallback Configuration (Python)\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    extra_body={\n        \"models\": [\"anthropic\u002Fclaude-3.5-sonnet\", \"gryphe\u002Fmythomax-l2-13b\"],\n    },\n    messages=[{\"role\": \"user\", \"content\": \"Your prompt here\"}]\n)\n```\n\n### Model Fallback Configuration (TypeScript)\n```typescript\nconst completion = await client.chat.completions.create({\n    model: 'openai\u002Fgpt-4o',\n    models: ['anthropic\u002Fclaude-3.5-sonnet', 'gryphe\u002Fmythomax-l2-13b'],\n    messages: [{ role: 'user', content: 'Your prompt here' }],\n});\n```\n\n### Auto Router (Dynamic Model Selection)\n```python\ncompletion = client.chat.completions.create(\n    model=\"openrouter\u002Fauto\",  # Automatically selects best model for the prompt\n    messages=[{\"role\": \"user\", \"content\": \"Your prompt here\"}]\n)\n```\n\n### Advanced Parameters Example\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\"role\": \"user\", \"content\": \"Write a creative story\"}],\n    temperature=0.8,           # Higher for creativity (0.0-2.0)\n    max_tokens=500,            # Limit response length\n    top_p=0.9,                 # Nucleus sampling (0.0-1.0)\n    frequency_penalty=0.5,     # Reduce repetition (-2.0-2.0)\n    presence_penalty=0.3       # Encourage topic diversity (-2.0-2.0)\n)\n```\n\n### Streaming Response\n```python\nstream = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\"role\": \"user\", \"content\": \"Tell me a story\"}],\n    stream=True\n)\n\nfor chunk in stream:\n    if chunk.choices[0].delta.content:\n        print(chunk.choices[0].delta.content, end='')\n```\n\n### JSON Mode (Structured Output)\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\n        \"role\": \"user\",\n        \"content\": \"Extract person's name, age, and city from: John is 30 and lives in NYC\"\n    }],\n    response_format={\"type\": \"json_object\"}\n)\n```\n\n### Deterministic Output with Seed\n```python\ncompletion = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    messages=[{\"role\": \"user\", \"content\": \"Generate a random number\"}],\n    seed=42,            # Same seed = same output (when supported)\n    temperature=0.0     # Deterministic sampling\n)\n```\n\n## Key Concepts\n\n### Model Routing\nOpenRouter provides intelligent routing capabilities:\n- **Auto Router** (`openrouter\u002Fauto`): Automatically selects the best model based on your prompt using NotDiamond\n- **Fallback Models**: Specify multiple models that automatically retry if primary fails\n- **Provider Routing**: Automatically routes across providers for reliability\n\n### Authentication\n- Uses Bearer token authentication with API keys\n- API keys can be managed programmatically\n- Compatible with OpenAI SDK authentication patterns\n\n### Model Naming Convention\nModels use the format `provider\u002Fmodel-name`:\n- `openai\u002Fgpt-4o` - OpenAI's GPT-4 Optimized\n- `anthropic\u002Fclaude-3.5-sonnet` - Anthropic's Claude 3.5 Sonnet\n- `google\u002Fgemini-2.0-flash-exp:free` - Google's free Gemini model\n- `openrouter\u002Fauto` - Auto-routing system\n\n### Sampling Parameters\n\n**Temperature** (0.0-2.0, default: 1.0)\n- Lower = more predictable, focused responses\n- Higher = more creative, diverse responses\n- Use low (0.0-0.3) for factual tasks, high (0.8-1.5) for creative work\n\n**Top P** (0.0-1.0, default: 1.0)\n- Limits choices to percentage of likely tokens\n- Dynamic filtering of improbable options\n- Balance between consistency and variety\n\n**Frequency\u002FPresence Penalties** (-2.0-2.0, default: 0.0)\n- Frequency: Discourages repeating tokens proportional to use\n- Presence: Simpler penalty not scaled by count\n- Positive values reduce repetition, negative encourage reuse\n\n**Max Tokens** (integer)\n- Sets maximum response length\n- Cannot exceed context length minus prompt length\n- Use to control costs and enforce concise replies\n\n### Response Formats\n- **Standard JSON**: Default chat completion format\n- **Streaming**: Server-Sent Events (SSE) with `stream: true`\n- **JSON Mode**: Guaranteed valid JSON with `response_format: {\"type\": \"json_object\"}`\n- **Structured Outputs**: Schema-validated JSON responses\n\n### Advanced Features\n- **Tool\u002FFunction Calling**: Connect models to external APIs\n- **Multimodal Inputs**: Support for images, PDFs, audio\n- **Prompt Caching**: Reduce costs for repeated prompts\n- **Web Search Integration**: Enhanced responses with web data\n- **Zero Completion Insurance**: Protection against failed responses\n- **Logprobs**: Access token probabilities for confidence analysis\n\n## Reference Files\n\nThis skill includes comprehensive documentation in `references\u002F`:\n\n- **llms-full.md** - Complete list of available models with metadata\n- **llms-small.md** - Curated subset of popular models\n- **llms.md** - Standard model listings\n\nUse `view` to read specific reference files when detailed model information is needed.\n\n## Working with This Skill\n\n### For Beginners\n1. Start with basic chat completion examples (Python\u002FJavaScript\u002FcURL above)\n2. Use the standard OpenAI SDK for easy integration\n3. Try simple model names like `openai\u002Fgpt-4o` or `anthropic\u002Fclaude-3.5-sonnet`\n4. Keep parameters simple initially (just model and messages)\n\n### For Intermediate Users\n1. Implement model fallback arrays for reliability\n2. Experiment with sampling parameters (temperature, top_p)\n3. Use streaming for better UX in conversational apps\n4. Try `openrouter\u002Fauto` for automatic model selection\n5. Implement JSON mode for structured data extraction\n\n### For Advanced Users\n1. Fine-tune multiple sampling parameters together\n2. Implement custom routing logic with fallback chains\n3. Use logprobs for confidence scoring\n4. Leverage tool\u002Ffunction calling capabilities\n5. Optimize costs by selecting appropriate models per task\n6. Implement prompt caching strategies\n7. Use seed parameter for reproducible testing\n\n## Common Patterns\n\n### Error Handling with Fallbacks\n```python\ntry:\n    completion = client.chat.completions.create(\n        model=\"openai\u002Fgpt-4o\",\n        extra_body={\n            \"models\": [\n                \"anthropic\u002Fclaude-3.5-sonnet\",\n                \"google\u002Fgemini-2.0-flash-exp:free\"\n            ]\n        },\n        messages=[{\"role\": \"user\", \"content\": \"Your prompt\"}]\n    )\nexcept Exception as e:\n    print(f\"All models failed: {e}\")\n```\n\n### Cost-Optimized Routing\n```python\n# Use cheaper models for simple tasks\nsimple_completion = client.chat.completions.create(\n    model=\"google\u002Fgemini-2.0-flash-exp:free\",\n    messages=[{\"role\": \"user\", \"content\": \"Simple question\"}]\n)\n\n# Use premium models for complex tasks\ncomplex_completion = client.chat.completions.create(\n    model=\"openai\u002Fo1\",\n    messages=[{\"role\": \"user\", \"content\": \"Complex reasoning task\"}]\n)\n```\n\n### Context-Aware Temperature\n```python\n# Low temperature for factual responses\nfactual = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    temperature=0.2,\n    messages=[{\"role\": \"user\", \"content\": \"What is the capital of France?\"}]\n)\n\n# High temperature for creative content\ncreative = client.chat.completions.create(\n    model=\"openai\u002Fgpt-4o\",\n    temperature=1.2,\n    messages=[{\"role\": \"user\", \"content\": \"Write a unique story opening\"}]\n)\n```\n\n## Resources\n\n### Official Documentation\n- API Reference: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fapi-reference\u002Foverview\n- Quickstart Guide: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fquickstart\n- Model List: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fmodels\n- Parameters Guide: https:\u002F\u002Fopenrouter.ai\u002Fdocs\u002Fapi-reference\u002Fparameters\n\n### Key Endpoints\n- Chat Completions: `POST https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fchat\u002Fcompletions`\n- List Models: `GET https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fmodels`\n- Generation Info: `GET https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\u002Fgeneration`\n\n## Notes\n\n- OpenRouter normalizes API schemas across all providers\n- Uses OpenAI-compatible API format for easy migration\n- Automatic provider fallback if models are rate-limited or down\n- Pricing based on actual model used (important for fallbacks)\n- Response includes metadata about which model processed the request\n- All models support streaming via Server-Sent Events\n- Compatible with popular frameworks (LangChain, Vercel AI SDK, etc.)\n\n## Best Practices\n\n1. **Always implement fallbacks** for production applications\n2. **Use appropriate temperature** based on task type (low for factual, high for creative)\n3. **Set max_tokens** to control costs and response length\n4. **Enable streaming** for better user experience in chat applications\n5. **Use JSON mode** when you need guaranteed structured output\n6. **Test with seed parameter** for reproducible results during development\n7. **Monitor costs** by selecting appropriate models per task\n8. **Use auto-routing** when unsure which model performs best\n9. **Implement proper error handling** for rate limits and failures\n10. **Cache prompts** for repeated requests to reduce costs\n",{"name":5,"license":15,"description":7,"user-invocable":20},"main","9f1f296b9b682f7dbd6a45516cec063c022fd01b","plugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills","https:\u002F\u002Fgithub.com\u002Fjustin-pitt","https:\u002F\u002Fexecbound.ai","Security engineer building ExecBound, a deterministic policy layer for AI-agent actions","2026-11-04 01:00:27",{"source":8,"skillName":5,"commands":33,"prompt":43,"zipAvailable":44},[34,37,40],{"tool":35,"command":36},"npx","npx skills add justin-pitt\u002Fpitt-skills --skill openrouter",{"tool":38,"command":39},"bunx","bunx skills add justin-pitt\u002Fpitt-skills --skill openrouter",{"tool":41,"command":42},"pnpm","pnpm dlx skills add justin-pitt\u002Fpitt-skills --skill openrouter","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002FSKILL.md",true,[46,52,56,60,64,68,72],{"path":47,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":50,"sourceHtmlUrl":51},"plugin.json","REFERENCE","参考文档",434,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002Fplugin.json",{"path":53,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":54,"sourceHtmlUrl":55},"references\u002Findex.md",93,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002Freferences\u002Findex.md",{"path":57,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":58,"sourceHtmlUrl":59},"references\u002Fllms-full.md",76752,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002Freferences\u002Fllms-full.md",{"path":61,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":62,"sourceHtmlUrl":63},"references\u002Fllms-small.md",76762,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002Freferences\u002Fllms-small.md",{"path":65,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":66,"sourceHtmlUrl":67},"references\u002Fllms.md",76702,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002Freferences\u002Fllms.md",{"path":69,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":70,"sourceHtmlUrl":71},"references\u002Fother.md",82677,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002Freferences\u002Fother.md",{"path":73,"resourceType":48,"resourceTypeDesc":49,"sizeBytes":74,"sourceHtmlUrl":75},"UPSTREAM.md",1352,"https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fopenrouter\u002FUPSTREAM.md",[77,85,92,98,105,112],{"skillNo":78,"name":79,"nameZh":6,"description":80,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":81,"licenseFileUrl":6,"sourceHtmlUrl":82,"categories":83,"keywords":84,"publishedAt":19},"01M78E5NQS1QSV0EEE2TWVXQ0X","vibesec","This skill helps Claude write secure web applications. Use this when working on any web application or when a user requests a scan or audit to ensure security best practices are followed.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fvibesec\u002FSKILL.md",[],[],{"skillNo":86,"name":87,"nameZh":6,"description":88,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":81,"licenseFileUrl":6,"sourceHtmlUrl":89,"categories":90,"keywords":91,"publishedAt":19},"01M78E5DNJTX8NEQKVX8RTXYM2","ui-ux-guide","Modern, clean UI\u002FUX guidance + review skill. Use when you need actionable UX\u002FUI recommendations, design principles, or a design review checklist for new features or existing systems (web\u002Fapp). Focus on CRAP (Contrast\u002FRepetition\u002FAlignment\u002FProximity) plus task-first UX, information architecture, feedback & system status, consistency, affordances, error prevention\u002Frecovery, and cognitive load. Enforce a modern minimal style (clean, spacious, typography-led), reduce unnecessary copy, forbid emoji as icons, and recommend intuitive refined icons from a consistent icon set.","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fui-ux-guide\u002FSKILL.md",[],[],{"skillNo":93,"name":94,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":95,"categories":96,"keywords":97,"publishedAt":19},"01M78E5BQCKGV89JJ394VAP3QF","tufin","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Ftufin\u002FSKILL.md",[],[],{"skillNo":99,"name":100,"nameZh":6,"description":101,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":102,"categories":103,"keywords":104,"publishedAt":19},"01M78E52863FJJS5WX88WW93SY","tines","Tines is a no-code automation and orchestration platform commonly used as a SOAR replacement, IT automation engine, and workflow builder. Use this skill whenever the user mentions Tines, Tines stories, actions, the AI Agent action, Story copilot, Webhook actions, HTTP Request actions, Event Transform, Send to Story, Resources, Pages, Cases, Records, credentials, Connect Flows, formulas, pills (`\u003C\u003Cslug.body.field>>` syntax), the Tines API, the Tines Terraform provider, tenants, change control, self-hosted Tines, Helm charts for Tines, Tines Tunnel, Command-over-HTTP, Tines on Azure or AWS, Tines credits and the AI credit pool, the Workbench, MCP server templates exposed by Tines, or any automation or workflow build inside Tines. Also trigger when the user asks about migrating from Cortex XSOAR \u002F XSIAM or other SOAR platforms to Tines, designing playbook or story patterns, integrating security tools through Tines, building forms with Pages, running case management in Tines, or is debugging a Tines workflow, even if they don't name a specific Tines concept.","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Ftines\u002FSKILL.md",[],[],{"skillNo":106,"name":107,"nameZh":6,"description":108,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":109,"categories":110,"keywords":111,"publishedAt":19},"01M78E4VKT2QKNF2KRVFHH5ZFT","tines-3b","Tines 3B is a separate product from Tines (Stories), not an upgrade path. Workflows are git repositories, steps are containerized code directories that pipe stdin to stdout, and an AI agent builds them from prompts. Use this skill whenever the user mentions Tines 3B, 3B spaces, 3B workflows, steps, config.toml, route_auth, route_type, webpage routes, volumes and \u002Fstorage, Tines units (TUs), connectors and the credential proxy, 3B skills, watchtower, autofix, autotune, solo runs, 3B branches or push-live, the 3B REST API or MCP endpoint, GitSync, tunnels and networks, or docs.3b.tines.com. Also trigger when comparing 3B against Tines Stories, deciding which of the two a use case belongs in, or migrating between them. For classic Tines (stories, actions, pills, formulas, Cases, Records, Pages), use the `tines` skill instead.","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Ftines-3b\u002FSKILL.md",[],[],{"skillNo":113,"name":114,"nameZh":6,"description":115,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":116,"categories":117,"keywords":118,"publishedAt":19},"01M78E4K8ZYVEGAN4PQ1ZFY5DT","threatconnect","ThreatConnect TIP and Polarity overlay expert. Use for any task involving ThreatConnect or Polarity: REST API calls (v2\u002Fv3), authentication (Token\u002FHMAC), TQL queries, Indicators, Groups, Cases, Workflow, Tags, Security Labels, Associations, ThreatAssess scoring, CAL configuration, indicator deprecation, exclusion lists, TAXII feeds (inbound\u002Foutbound), feed metrics, dashboards, Query Cards, Threat Graph, ATT&CK Visualizer, Risk Quantifier, Polarity integrations (Core, IOC Submission, Intel Search, CAL, XSOAR), Polarity custom development (Node.js), Polarity server administration, Playbooks, Components, Workflow Playbooks, App Builder, TcEx, indicator distribution to SIEM\u002FSOAR (XSIAM, Sentinel, Splunk, Elastic, Tines, Torq, BlinkOps), HTTP errors, HMAC signature failures, indicator formatting (ASN, CIDR, Host, URL, Registry Key), or troubleshooting. Trigger even without explicit ThreatConnect\u002FPolarity mention if the task involves threat intelligence platform operations.","https:\u002F\u002Fgithub.com\u002Fjustin-pitt\u002Fpitt-skills\u002Fblob\u002Fmain\u002Fplugins\u002Fpitt-skills\u002Fskills\u002Fthreatconnect\u002FSKILL.md",[],[]]