openroutermcptest4
OpenRouter MCP Client for Cursor
Documentation
OpenRouter MCP Client for Cursor
A Model Context Protocol (MCP) client for Cursor that utilizes OpenRouter.ai to access multiple AI models.
Requirements
- Node.js v18.0.0 or later (important!)
- OpenRouter API key (get one at openrouter.ai/keys)
Features
- Connect to OpenRouter.ai via MCP
- Access multiple AI models from various providers (Google, DeepSeek, Meta, etc.)
- Use MCP transport mechanism to communicate with Cursor
- Cache model information to reduce API calls
- Support for both free and paid models
- Multi-model completion utility to combine results from multiple models
Available Models
This client provides access to all models available on OpenRouter, including:
- Google Gemini 2.5 Pro
- DeepSeek Chat v3
- Meta Llama 3.1
- DeepSeek R1
- Qwen Coder
- Mistral Small 3.1
- And many more!
Quick Installation
The easiest way to install is to use the setup script:
# Clone the repository
git clone https://your-repo-url/openrouter-mcp-client.git
cd openrouter-mcp-client
# Run the installation script
node install.cjsThe script will:
1. Help you create a `.env` file with your OpenRouter API key
2. Install all dependencies
3. Build the project
4. Provide next steps
Manual Installation
If you prefer to install manually:
# Clone the repository
git clone https://your-repo-url/openrouter-mcp-client.git
cd openrouter-mcp-client
# Install dependencies
npm install
# Copy environment file and edit it with your API key
cp .env.example .env
# Edit .env file with your OpenRouter API key
# Build the project
npm run buildConfiguration
Edit the `.env` file with your OpenRouter API key and default model:
OPENROUTER_API_KEY=your_api_key_here
OPENROUTER_DEFAULT_MODEL=google/gemini-2.5-pro-exp-03-25:freeGet your API key from OpenRouter Keys.
Cursor Integration
To use this client with Cursor, you need to update Cursor's MCP configuration file:
1. Find Cursor's configuration directory:
2. Edit or create the `mcp.json` file in that directory. Add a configuration like this:
{
"mcpServers": {
"custom-openrouter-client": {
"command": "node",
"args": [
"FULL_PATH_TO/openrouter-mcp-client/dist/index.js"
],
"env": {
"OPENROUTER_API_KEY": "your_api_key_here",
"OPENROUTER_DEFAULT_MODEL": "google/gemini-2.5-pro-exp-03-25:free"
}
}
}
}Replace `FULL_PATH_TO` with the actual path to your client installation.
3. Restart Cursor
4. Select the client by:
Direct Testing (without MCP)
Uncomment the test functions in `src/index.ts` to test direct API interaction:
// Uncomment to test the direct API
testDirectApi().catch(console.error);
testMultiModelCompletion().catch(console.error);Then run:
npm startDevelopment
# Watch mode for development
npm run devTroubleshooting
Node.js Version Requirements
Important: This project requires Node.js v18.0.0 or later. If you're using an older version, you will see EBADENGINE warnings and may encounter errors. To check your Node.js version:
node --versionIf you have an older version, download and install the latest LTS version from nodejs.org.
Module System Errors
If you encounter errors related to ES modules vs CommonJS:
- The main codebase uses ES modules (indicated by `"type": "module"` in package.json)
- The installation script uses CommonJS (with a .cjs extension)
- Make sure to run the installation script with `node install.cjs`
Cursor Not Connecting
If Cursor doesn't seem to connect to your client:
1. Make sure the path in `mcp.json` is correct and uses forward slashes
2. Check that you've built the client with `npm run build`
3. Verify that your OpenRouter API key is correct in the env settings
4. Check Cursor logs for any errors
Related Resources
Smithery Deployment
You can deploy this MCP client to Smithery to make it available to various AI agents and applications.
Prerequisites
- GitHub account
- OpenRouter API key
Steps to Deploy
1. Fork this repository to your GitHub account
2. Sign in to Smithery at smithery.ai using your GitHub account
3. Add a new server:
4. Deploy your server:
Using Your Deployed Server
After deployment, users can access your server through the Smithery registry:
1. In their MCP client (like Claude, or any other MCP-compatible client), add the server using Smithery's registry
2. Configure their OpenRouter API key and preferred default model
3. Start using the server to access multiple AI models through OpenRouter
Smithery vs. Local Installation
- Smithery: Easier for distribution to others; no need for users to clone and build the repository
- Local Installation: Better for personal use and development; more control over the environment
Choose the approach that best fits your needs.
Frequently asked questions
What is openroutermcptest4?
openroutermcptest4 is OpenRouter MCP Client for Cursor
How do I install openroutermcptest4?
Open the GitHub repository and follow its README. Most MCP servers are added to your client's MCP config, then called by your agent.
Is openroutermcptest4 open source?
Yes — it is hosted on GitHub at https://github.com/ParsaSarcheshmeh/openroutermcptest4 and has 2 stars.
Related MCP tools
🔥 Official Firecrawl MCP Server - Adds powerful web scraping and search to Cursor, Claude and any other LLM clients.
Use any LLMs (Large Language Models) for Deep Research. Support SSE API and MCP server.
Enhanced MCP server for interactive user feedback and command execution in AI-assisted development, featuring dual interface support (Web UI and Desktop Application) with intelligent environment detection and cross-platform compatibility.
A powerful Zotero AI and MCP plugin with ChatGPT, Gemini 3.7, Claude Fable 5, Claude Opus 5, DeepSeek V4, Grok, OpenRouter, Kimi k3, GLM 5.3, SiliconFlow, GPT-oss, Gemma 4, Qwen 3.8
Connect your browser to AI models. Just use Dia on Chrome, Arc or Firefox.
文颜 MCP Server 可以让 AI 自动将 Markdown 文章排版后发布至微信公众号。
Run your own MCP server? See who uses it and what to fix.
Measure it with TrackMCP