Nexus MCP Server
AI integration without the complexity
Key Features
Use Cases
README
🔍 Nexus MCP Server
AI integration without the complexity
Intelligent AI model search and discovery with zero-install simplicity
Quick Start • Features • Documentation • Contributing
What is Nexus?
Nexus is a Model Context Protocol (MCP) server that provides AI-powered web search functionality through the OpenRouter API. It integrates with MCP-compatible clients including Claude Desktop and Cursor, providing search capabilities via the Perplexity Sonar model family.
Key Characteristics
- Zero-install deployment: Executable via
npxwith no build requirements - OpenRouter integration: Uses Perplexity Sonar models for web search with citations
- MCP protocol compliance: Implements standard MCP tool and resource interfaces
- Production architecture: Includes request caching, deduplication, retry logic, and error handling
- Type-safe implementation: Full TypeScript coverage with strict type checking
Features
Deployment
- NPX-based execution with zero local installation
- Cross-platform compatibility (macOS, Linux, Windows)
- Node.js 18+ runtime requirement
- Automated version updates via npm registry
Search Capabilities
- Perplexity Sonar model family integration
- Real-time web search with current information
- Structured citation extraction from responses
- Configurable model parameters (temperature, max tokens, penalties)
Architecture
- Comprehensive error handling with typed error classes
- Request caching with configurable TTL
- Request deduplication for concurrent identical queries
- Automatic retry logic with exponential backoff
- Winston-based structured logging
- TypeScript strict mode implementation with full type coverage
Quick Start
Prerequisites
- Node.js 18 or higher
- OpenRouter API key (register at openrouter.ai)
NPX Installation
Execute the server without local installation:
# Set your OpenRouter API key
export OPENROUTER_API_KEY=your-api-key-here
# Run the server via NPX
npx nexus-mcp
The server starts and listens for MCP client connections via STDIO transport.
Testing the NPX Installation
# Test the CLI help
npx nexus-mcp --help
# Test the version
npx nexus-mcp --version
# Run with your API key
OPENROUTER_API_KEY=your-key npx nexus-mcp
Alternative: Local Development Installation
For local development or customization:
- Clone the repository:
git clone https://github.com/adawalli/nexus.git
cd nexus
- Install dependencies:
npm install
- Build the server:
npm run build
- Configure your OpenRouter API key:
# Copy the example environment file
cp .env.example .env
# Edit .env and add your actual API key
# OPENROUTER_API_KEY=your-api-key-here
- Test the server:
npm start
Integration with MCP Clients
NPX-Based Integration (Recommended)
Configure MCP clients to execute the server via NPX:
Claude Code
Configuration in ~/.claude/mcp_settings.json:
{
"mcpServers": {
"nexus": {
"command": "npx",
"args": ["nexus-mcp"],
"env": {
"OPENROUTER_API_KEY": "your-api-key-here"
}
}
}
}
Restart Claude Code after configuration changes.
Cursor
Add server configuration in Cursor's MCP settings:
- Name:
nexus - Command:
npx - Args:
["nexus-mcp"] - Environment Variables:
OPENROUTER_API_KEY=your-api-key-here
Restart Cursor after configuration changes.
Generic MCP Client Configuration
Standard MCP client connection parameters:
- Transport: stdio
- Command:
npx - Args:
["nexus-mcp"] - Environment:
OPENROUTER_API_KEY=your-api-key-here
Alternative: Local Installation
If you prefer using a local installation (after following the local development setup):
{
"mcpServers": {
"nexus": {
"command": "node",
"args": ["/path/to/nexus-mcp/dist/cli.js"],
"env": {
"OPENROUTER_API_KEY": "your-api-key-here"
}
}
}
}
Usage
Once integrated, you can use the search tool in your MCP client:
Basic Search
Use the search tool to find information about "latest developments in AI"
Advanced Search with Parameters
Search for "climate change solutions" using:
- Model: perplexity/sonar
- Max tokens: 2000
- Temperature: 0.3
Available Tools
search
The main search tool that provides AI-powered web search capabilities.
Parameters:
query(required): Search query (1-2000 characters)model(optional): Perplexity model to use (default: "perplexity/sonar")maxTokens(optional): Maximum response tokens (1-4000, default: 1000)temperature(optional): Response randomness (0-2, default: 0.7)
Example Response:
Based on current information, here are the latest developments in AI...
[Detailed AI-generated response with current information]
---
**Search Metadata:**
- Model: perplexity/sonar
- Response time: 1250ms
- Tokens used: 850
- Sources: 5 found
Configuration
Environment Variables
OPENROUTER_API_KEY(required): Your OpenRouter API keyNODE_ENV(optional): Environment setting (development, production, test)LOG_LEVEL(optional): Logging level (debug, info, warn, error)
Advanced Configuration
The server supports additional configuration through environment variables:
OPENROUTER_TIMEOUT_MS: Request timeout in milliseconds (default: 30000)OPENROUTER_MAX_RETRIES: Maximum retry attempts (default: 3)OPENROUTER_BASE_URL: Custom OpenRouter API base URL
Resources
The server provides a configuration status resource at config://status that shows:
- Server health status
- Configuration information (with masked API key)
- Search tool availability
- Server uptime and version
Troubleshooting
NPX-Specific Issues
"npx: command not found"
- Ensure Node.js 18+ is installed:
node --version - Update npm:
npm install -g npm@latest
"Cannot find package 'nexus-mcp'"
- The package may not be published yet. Use local installation instead
- Verify network connectivity for npm registry access
NPX takes a long time to start
- This is normal on first run as NPX downloads the package
- Subsequent runs will be faster due to caching
- For faster startup, use local installation instead
"Permission denied" errors with NPX
- Try:
npx --yes nexus-mcp --stdio - Or set npm permissions:
npm config set user 0 && npm config set unsafe-perm true
Common Issues
"Search functionality is not available"
- Ensure
OPENROUTER_API_KEYenvironment variable is set - Verify your API key is valid at OpenRouter
- Check the server logs for initialization errors
"Authentication failed: Invalid API key"
- Double-check your API key format and validity
- Ensure the key has sufficient credits/permissions
- Test the key directly at OpenRouter dashboard
"Rate limit exceeded"
- Wait for the rate limit to reset (usually 1 minute)
- Consider upgrading your OpenRouter plan for higher limits
- Monitor usage in your OpenRouter dashboard
Connection timeouts
- Check your internet connection
- The server will automatically retry failed requests
- Increase timeout if needed:
OPENROUTER_TIMEOUT_MS=60000
MCP client can't connect to server
- Verify your MCP configuration uses the correct command and arguments
- Check that Node.js 18+ is available in your MCP client's environment
- Ensure the API key is properly set in the environment variables
Debug Logging
Enable debug logging by:
For local development: Add LOG_LEVEL=debug to your .env file
For MCP clients: Add LOG_LEVEL: "debug" to the env section of your MCP configuration
This will provide detailed information about:
- Configuration loading
- API requests and responses
- Error details and stack traces
- Performance metrics
Testing Connection
You can test if the server is working by checking the configuration status resource in your MCP client, or by running a simple search query.
Development
For developers working on this server:
# Development with hot reload
npm run dev
# Run tests
npm test
# Run tests with coverage
npm run test:coverage
# Lint code
npm run lint
# Format code
npm run format
API Costs
OpenRouter charges for API usage based on token consumption:
- Pricing: See current rates at OpenRouter Models
- Monitoring: Usage tracking available in OpenRouter dashboard
- Limits: Configure spending limits in OpenRouter account settings
- Optimization: Server implements response caching and request deduplication to minimize redundant API calls
📚 Documentation
| 📖 Guide | 🔗 Link | 📝 Description |
|---|---|---|
| Quick Start | Getting Started | Zero-install setup in 30 seconds |
| API Reference | MCP Tools | Complete command reference |
| Configuration | Environment Setup | Advanced configuration options |
| Contributing | Contributing Guide | Join our open source community |
| Troubleshooting | Common Issues | Solutions to common problems |
🤝 Contributing
We welcome contributions from developers of all experience levels!
🚀 Get Started
- Fork the repository
- Read our Contributing Guide
- Check out good first issues
🐛 Report Issues
💬 Join Community
🌟 Recognition
Contributors are recognized in our:
- Contributors list
- Release notes for significant contributions
- Community spotlights and testimonials
🔗 Related Projects
- Model Context Protocol - The standard we implement
- OpenRouter - Our AI model provider
- Claude Desktop - Primary MCP client
- Cursor - AI-powered code editor with MCP support
📞 Support & Community
| 💬 Need Help? | 🔗 Resource |
|---|---|
| Quick Questions | GitHub Discussions |
| Bug Reports | GitHub Issues |
| Documentation | OpenRouter Docs • MCP Specification |
| Feature Requests | Enhancement Proposals |
📄 License
MIT License - see LICENSE file for details.
Made with ❤️ by the open source community
⭐ Star us on GitHub • 📦 View on NPM • 📚 Read the Docs
Nexus: AI integration without the complexity
Star History
Repository Owner
User
Repository Details
Programming Languages
Tags
Join Our Newsletter
Stay updated with the latest AI tools, news, and offers by subscribing to our weekly newsletter.
Related MCPs
Discover similar Model Context Protocol servers
OpenAI WebSearch MCP Server
Intelligent web search with OpenAI reasoning model support, fully MCP-compatible.
OpenAI WebSearch MCP Server provides advanced web search functionality integrated with OpenAI's latest reasoning models, such as gpt-5 and o3-series. It features full compatibility with the Model Context Protocol, enabling easy integration into AI assistants that require up-to-date information and contextual awareness. Built with flexible configuration options, smart reasoning effort controls, and support for location-based search customization. Suitable for environments such as Claude Desktop, Cursor, and automated research workflows.
- ⭐ 75
- MCP
- ConechoAI/openai-websearch-mcp
SearXNG MCP Server
MCP-compliant server integrating the SearXNG API for advanced web search capabilities
SearXNG MCP Server implements the Model Context Protocol and integrates the SearXNG API to provide extensive web search functionalities. It features intelligent caching, advanced content extraction, and multiple configurable search parameters such as language, time range, and safe search levels. The server exposes tools for both web searching and URL content reading, supporting detailed output customization through input parameters. Designed for seamless MCP deployments, it supports Docker and NPX-based installation with rich configuration options.
- ⭐ 321
- MCP
- ihor-sokoliuk/mcp-searxng
Exa MCP Server
Fast, efficient web and code context for AI coding assistants.
Exa MCP Server provides a Model Context Protocol (MCP) server interface that connects AI assistants to Exa AI’s powerful search capabilities, including code, documentation, and web search. It enables coding agents to retrieve precise, token-efficient context from billions of sources such as GitHub, StackOverflow, and documentation sites, reducing hallucinations in coding agents. The platform supports integration with popular tools like Cursor, Claude, and VS Code through standardized MCP configuration, offering configurable access to various research and code-related tools via HTTP.
- ⭐ 3,224
- MCP
- exa-labs/exa-mcp-server
@dealx/mcp-server
MCP server enabling LLMs to search and interact with the DealX platform.
Implements the Model Context Protocol, providing a standardized interface for large language models to interact with the DealX platform. Supports searching for ads through structured prompts and is designed for easy integration with tools like Claude and VS Code extensions. Flexible configuration options are available for environment variables, logging, and deployment. Extensible architecture supports future feature additions beyond ad search.
- ⭐ 0
- MCP
- DealExpress/mcp-server
MCP-searxng
MCP server bridging agentic systems with SearXNG web search
MCP-searxng enables agentic systems to interface with web search engines via the SearXNG platform by implementing the Model Context Protocol. It supports both command-line and local server deployment, providing flexible integration options. Users can configure custom SearXNG server URLs and connect through clients like uvx or claude desktop. The tool simplifies access to structured web search within agentic workflows.
- ⭐ 107
- MCP
- SecretiveShell/MCP-searxng
Vectorize MCP Server
MCP server for advanced vector retrieval and text extraction with Vectorize integration.
Vectorize MCP Server is an implementation of the Model Context Protocol (MCP) that integrates with the Vectorize platform to enable advanced vector retrieval and text extraction. It supports seamless installation and integration within development environments such as VS Code. The server is configurable through environment variables or JSON configuration files and is suitable for use in collaborative and individual workflows requiring vector-based context management for models.
- ⭐ 97
- MCP
- vectorize-io/vectorize-mcp-server
Didn't find tool you were looking for?