openrouter-sdk-patterns
/openrouter-sdk-patterns
Implement common SDK patterns for OpenRouter integration. Use when building production applications. Trigger with phrases like 'openrouter sdk', 'openrouter client pattern', 'openrouter best practices', 'openrouter code patterns'.
- Author
- HelixDevelopment ↗
- Repository
- agent ↗
- Licence
- MIT
- Last repository change
- 14.10.2026
Assessment and security
- Files in this package
- 1
- Scripts
- 0
- HTML comments
- 0
- URLs in SKILL.md
- 1
No signals detected. Repository changed on 14.10.2026, without references to retired models or APIs.
MIT, open: use and modify while retaining author attribution.
What it does and when to use it
Implement common SDK patterns for OpenRouter integration. Use when building production applications. Trigger with phrases like 'openrouter sdk', 'openrouter client pattern', 'openrouter best practices', 'openrouter code patterns'.
Triggers from the description
Original author description
Implement common SDK patterns for OpenRouter integration. Use when building production applications. Trigger with phrases like 'openrouter sdk', 'openrouter client pattern', 'openrouter best practices', 'openrouter code patterns'.
How it works
- Overview
- Prerequisites
- Instructions
- Python with OpenAI SDK
SKILL.md preview
---
name: openrouter-sdk-patterns
description: |
Implement common SDK patterns for OpenRouter integration. Use when building production applications. Trigger with phrases like 'openrouter sdk', 'openrouter client pattern', 'openrouter best practices', 'openrouter code patterns'.
allowed-tools: Read, Write, Edit, Grep
version: 1.0.0
license: MIT
author: Jeremy Longshore <jeremy@intentsolutions.io>
---
# OpenRouter SDK Patterns
## Overview
This skill covers proven SDK patterns including client initialization, error handling, retry logic, and configuration management for robust OpenRouter integrations.
## Prerequisites
- OpenRouter API key configured
- Python 3.8+ or Node.js 18+
- OpenAI SDK installed
## Instructions
Follow these steps to implement this skill:
1. **Verify Prerequisites**: Ensure all prerequisites listed above are met
2. **Review the Implementation**: Study the code examples and patterns below
3. **Adapt to Your Environment**: Modify configuration values for your setup
4. **Test the Integration**: Run the verification steps to confirm functionality
5. **Monitor in Production**: Set up appropriate logging and monitoring
## Overview
This skill covers proven SDK patterns including client initialization, error handling, retry logic, and configuration management for robust OpenRouter integrations.
## Prerequisites
- OpenRouter API key configured
- Python 3.8+ or Node.js 18+
- OpenAI SDK installed
## Python with OpenAI SDK
### Basic Setup
```python
from openai import OpenAI
import os
client = OpenAI(
base_url="https://openrouter.ai/api/v1",
## Detailed Reference
See `{baseDir}/references/implementation.md` for complete implementation guide.
Versions
The database has no other skills named openrouter-sdk-patterns.
Database snapshot: 13.11.2026 · package version aeec11cef440 (SHA-256 digest of the entire package)
Downloads in the last 30 days: 0 · ranking
Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.
Similar skills
- 100openrouter-install-auth
Execute set up OpenRouter API authentication and configure API keys. Use when starting a new OpenRouter integration or troubleshooting auth issues. Trigger with phrases like 'openrouter setup', 'openrouter api key', 'openrouter authentication', 'configure openrouter'. - 100openrouter-model-routing
Implement advanced model routing with A/B testing. Use when optimizing model selection or running experiments. Trigger with phrases like 'openrouter a/b test', 'model experiment', 'openrouter routing', 'model comparison'. - 100openrouter
Design, build, debug, and optimize OpenRouter API integrations. Use for any OpenRouter API work, including models, reasoning, routing, media, tools, structured output, cost, or performance. - 100openrouter-usage
Query OpenRouter API costs, credits, and usage breakdown by model, provider, and date for the last 30 days. Triggers on API spending, check costs, openrouter usage, how much have I spent. - 100openrouter
Choose OpenRouter models and routers, query live catalog data, use structured outputs and batch inference, and debug routing with metadata. Use when working with OpenRouter APIs, openrouter/auto, openrouter/free, model discovery, pricing, providers, batch jobs, or structured JSON responses. - 90openrouter-troubleshoot
Diagnose OpenRouter MCP connection, authentication, discovery, credit, generation, routing, or tool failures using safe local diagnostics and current service information. Prepare or submit generation feedback only when the user explicitly requests that action.