OpenRouter MCP Server
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| DISABLE_REDACTION | No | Set to 'true' to disable the security firewall redaction | |
| OPENROUTER_API_KEY | Yes | Your OpenRouter API key (sk-or-...) | |
| OPENROUTER_MCP_ENV_PATH | No | Optional path to a custom .env file location |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {} |
| prompts | {} |
| resources | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| chat_completionC | Generate a chat completion using an OpenRouter model |
| chat_with_presetB | Generate a chat completion using a predefined model preset (smart, cheap, creative, fast, coder) |
| recommend_modelA | Analyze a task and recommend the best model preset (smart, cheap, creative, fast, coder) |
| optimize_promptB | Refine and optimize a draft prompt using best practices for LLMs |
| chat_ensembleA | Generate a consensus completion by querying multiple distinct models in parallel and synthesizing their responses using a synthesizer model. |
| chat_routedA | Execute a chat completion with intelligent, automatic cost-aware model routing based on prompt size, required context length, and task attributes. |
| list_modelsB | List available models on OpenRouter |
| filter_modelsA | Filter and search available OpenRouter models based on requirements (e.g. cost, context window, vision) |
| get_session_usageA | Get the total token usage and estimated cost for the current session |
| get_balanceA | Check your OpenRouter credit balance |
| get_key_infoA | Get information about the current API key (limits, usage, etc.) |
| set_budgetA | Set a session-wide spending limit (in USD) and warning threshold |
| get_budget_statusA | Check the current session spending and budget status |
| vision_analyzeB | Analyze an image (local file or URL) using a vision-capable model |
| index_projectB | Scan a project directory to index symbols (functions, classes, variables) for cross-project awareness |
| search_symbolsA | Search for symbols across all indexed projects |
| reindex_projectB | Perform deep semantic indexing of a project (code chunking + embeddings) for code search |
| semantic_code_searchA | Search for code logic across indexed projects using natural language |
| pin_contextB | Store text with optional tags and project association for semantic retrieval |
| retrieve_contextB | Search for semantically similar information in memory |
| clear_contextA | Delete entries from semantic memory by tag or project |
| correlate_errorsA | Analyze log snippets from multiple systems to find root causes and correlations |
| dependency_graphA | Analyze shared dependencies and semver conflicts across multiple projects |
| verify_setupA | Perform diagnostic checks on OpenRouter credentials, files, and server environment |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
| cost-aware-orchestration | Instructs AI agents to manage API consumption costs, check credit levels, and use budget-safe model routing. |
| multi-model-consensus | Configures parallel multi-model peer review and consensus voting across up to 5 models. |
| autonomous-budget-safety | Strict financial circuit breaker and loop-stall prevention policy for autonomous background executions. |
| distributed-diagnostics | Instructs agents on multi-service log correlation, trace isolation, and cascading fault analysis. |
| workspace-memory-pinning | Teaches agents to persistently pin architectural decisions, domain constraints, and workspace memory. |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| OpenRouter Models Catalog & Pricing | Cached model catalog, context limits, and token pricing rates |
| Budget & Rate Limiting Status | Session spend metrics, budget caps, token bucket limits, and active circuit breaker states |
| OpenRouter Account Credits & Key Info | Current credit balance, spending limits, and API key details |
| Pinned Semantic Memory Context | All pinned architectural decisions, domain constraints, and workspace memory |
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/villagertim/universal-mcp-for-openrouter'
If you have feedback or need assistance with the MCP directory API, please join our Discord server