rupinder2/mcp-orchestrator

šŸ”— Aggregators
0 Views
0 Installs

šŸ šŸ  šŸŽ 🪩 🐧 - Central hub that aggregates tools from multiple MCP servers with unified BM25/regex search and deferred loading.

Quick Install

One-Click IDE Configuration
claude_desktop_config.json
{
  "mcpServers": {
    "rupinder2-mcp-orchestrator": {
      "command": "npx",
      "args": [
        "-y",
        "rupinder2-mcp-orchestrator"
      ]
    }
  }
}
Or

Using an AI coding agent (Claude Code, Cursor, etc.)? Copy a ready-made prompt that tells it to fetch the setup instructions and install this server for you.

Documentation Overview

MCP Orchestrator

PyPI Version Python Version License: MIT Tests Contributions Welcome

A central hub that connects to multiple downstream MCP servers, aggregates their tools, and provides unified access with powerful tool search capabilities.

Built around deferred tool loading — search across all your servers without blowing Claude's context window.

Features

  • Config-based Server Registration: Add downstream MCP servers via JSON config file
  • Tool Namespacing: Automatic server_name__tool_name format
  • Tool Search: Unified BM25/regex search with deferred loading support
  • Flexible Authentication: Static saved headers or token forwarding
  • Multiple Transports: stdio or HTTP
  • Tool Definition Caching: Cached definitions, raw result passthrough
  • Storage Backends: In-memory (development) or Redis (production)

Quick Start

Installation

pip install mcp-orchestrator

Running the MCP Server

# Run as stdio MCP server (for Claude Desktop, Cursor, etc.)
mcp-orchestrator

# Or run with Python directly
python -m mcp_orchestrator.main

HTTP Transport:

ORCHESTRATOR_TRANSPORT=http ORCHESTRATOR_PORT=8080 python -m mcp_orchestrator.main

This starts the server on http://localhost:8080/mcp with CORS enabled.

Configuring Servers

Add downstream MCP servers in server_config.json:

{
  "servers": [
    {
      "name": "my-server",
      "url": "http://localhost:8080/mcp",
      "transport": "http",
      "auth_type": "static",
      "auth_headers": {
        "Authorization": "Bearer my-token"
      }
    },
    {
      "name": "my-stdio-server",
      "url": "server.py",
      "transport": "stdio",
      "command": "uv",
      "args": ["run", "python", "server.py"]
    }
  ]
}

Searching for Tools

The orchestrator provides unified tool search (BM25 by default, regex optional):

# BM25 search (default - natural language)
results = await mcp_client.call_tool("tool_search", {
    "query": "get weather information",
    "max_results": 3
})

# Regex search (set use_regex=true)
results = await mcp_client.call_tool("tool_search", {
    "query": "weather|forecast",
    "use_regex": true,
    "max_results": 3
})

Architecture

ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”
│                  MCP Orchestrator                    │
│                                                      │
│  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”   │
│  │              FastMCP Server                   │   │
│  │  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”   │   │
│  │  │ tool_search │  │ call_remote_tool  │   │   │
│  │  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜   │   │
│  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜   │
│                                                      │
│  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”  ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”      │
│  │  Server  │  │   Tool   │  │   Storage    │      │
│  │ Registry │  │  Search  │  │(Memory/Redis)│      │
│  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜  ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜      │
ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜
                           │
        ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”¼ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”
        ā–¼                   ā–¼                   ā–¼
   ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”        ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”        ā”Œā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”
   │ MCP Svr │        │ MCP Svr │        │ MCP Svr │
   │   #1    │        │   #2    │        │   #N    │
   ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜        ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜        ā””ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”€ā”˜

Configuration

Environment Variables

VariableDefaultDescription
STORAGE_BACKENDmemoryStorage backend (memory or redis)
REDIS_URLredis://localhost:6379/0Redis connection URL
MCP_ORCHESTRATOR_TOOL_CACHE_TTL300Tool schema cache TTL in seconds
MCP_ORCHESTRATOR_DEFAULT_CONNECTION_MODEstatelessDefault connection mode
MCP_ORCHESTRATOR_CONNECTION_TIMEOUT30.0Connection timeout in seconds
MCP_ORCHESTRATOR_MAX_RETRIES3Maximum retry attempts
ORCHESTRATOR_TRANSPORTstdioMCP transport (stdio or http)
ORCHESTRATOR_PORT8080Port for HTTP transport
ORCHESTRATOR_HOST0.0.0.0Host for HTTP transport
ORCHESTRATOR_LOG_LEVELINFOLogging level
SERVER_CONFIG_PATHserver_config.jsonPath to server configuration file

Claude Desktop Integration

Add to your Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "mcp-orchestrator": {
      "command": "mcp-orchestrator",
      "env": {
        "STORAGE_BACKEND": "memory",
        "ORCHESTRATOR_LOG_LEVEL": "INFO"
      }
    }
  }
}

MCP Tools

tool_search

Search for tools using BM25 relevance ranking or regex pattern matching.

@mcp.tool()
async def tool_search(
    query: str,
    max_results: int = 3,
    use_regex: bool = False,
) -> dict:
    """Search for tools using BM25 or regex.

    By default uses BM25 natural language search. Set use_regex=True
    to search using Python regex patterns instead.
    """

discover_tools

Discover tools from a registered downstream server.

@mcp.tool()
async def discover_tools(
    server_name: str,
) -> dict:
    """Discover tools from a registered server and index them for search.

    Returns the list of discovered tools with their schemas.
    """

call_remote_tool

Call a tool directly on a downstream MCP server.

@mcp.tool()
async def call_remote_tool(
    tool_name: str,
    arguments: Optional[dict] = None,
    auth_header: Optional[str] = None,
) -> Any:
    """Call a tool on a downstream server.

    Args:
        tool_name: Namespaced tool name (server_name__tool_name)
        arguments: Tool arguments
        auth_header: Optional auth header to override server's configured auth
    """

Tool Search Results

The search tools return results in the format expected by Claude's tool search system:

{
  "success": true,
  "tool_references": [
    {
      "type": "tool_reference",
      "tool_name": "server_name__tool_name"
    }
  ],
  "total_matches": 5,
  "query": "weather"
}

Testing

Run the test suite:

uv run pytest

Run with coverage:

uv run pytest --cov=mcp_orchestrator

Project Structure

mcp-orchestrator/
ā”œā”€ā”€ src/mcp_orchestrator/
│   ā”œā”€ā”€ __init__.py
│   ā”œā”€ā”€ main.py              # Entry point
│   ā”œā”€ā”€ models.py            # Pydantic models
│   ā”œā”€ā”€ mcp_server.py        # FastMCP server
│   ā”œā”€ā”€ config_loader.py     # Config file loader
│   ā”œā”€ā”€ server/
│   │   └── registry.py      # Server registry
│   ā”œā”€ā”€ tools/
│   │   ā”œā”€ā”€ router.py       # Tool router
│   │   └── search.py       # Tool search service
│   └── storage/
│       ā”œā”€ā”€ base.py          # Storage interface
│       ā”œā”€ā”€ memory.py        # In-memory backend
│       └── redis.py         # Redis backend
ā”œā”€ā”€ tests/
│   ā”œā”€ā”€ test_registry.py
│   ā”œā”€ā”€ test_search.py
│   ā”œā”€ā”€ test_storage.py
│   ā”œā”€ā”€ test_models.py
│   └── test_integration.py
ā”œā”€ā”€ server_config.json       # Pre-configured downstream servers
ā”œā”€ā”€ pyproject.toml
ā”œā”€ā”€ README.md
└── .env                    # Environment variables (not committed)

License

MIT License

Contributing

Contributions are welcome! Please see CONTRIBUTING.md for guidelines.

Related MCP Servers

thebrierfox/the-stall

šŸ“‡ ā˜ļø - 209 pay-per-call AI capabilities via x402 USDC micropayments on Base mainnet. Covers US/global equities, crypto/DeFi analytics, options chains, dealer GEX, macro indicators, congressional trades, prediction markets, on-chain intelligence, EVM & Solana analysis, SEC filings, weather, aviation, and more. No API key — pay per call from $0.001 USDC.

šŸ”— Aggregators2 views
1mcp/agent

šŸ“‡ ā˜ļø šŸ  šŸŽ 🪟 🐧 - A unified Model Context Protocol server implementation that aggregates multiple MCP servers into one.

šŸ”— Aggregators0 views
2s-io/sdk

šŸ“‡ ā˜ļø šŸŽ 🪟 🐧 - Unified API for AI agents — 180+ tools across geocoding, weather (NWS), climate stations (NOAA), earthquakes (USGS), tides (NOAA), points of interest (OpenStreetMap), patents (USPTO ODP), US case law (CourtListener / Free Law Project), Federal Register, Wikipedia, scientific papers (arXiv / PubMed / Semantic Scholar), AI summarize / translate / extract / screenshot / image-describe, image compression, DNS / WHOIS, crypto address-validate + EVM gas oracle, OFAC sanctions screening, US Census ACS demographics, airport / ZIP lookup. Sub-cent to a few cents per call in USDC on Base via x402 — no API keys, no signup. npx -y @2sio/mcp

šŸ”— Aggregators0 views
8randonpickart5/alderpost-mcp

šŸ“‡ ā˜ļø - 8 bundled intelligence endpoints (security, company, threat, compliance, sales, sports, property, health) via x402 micropayments on Base.

šŸ”— Aggregators0 views

Engagement

Views
0
Installs
0
Upvotes
0

Views and upvotes are unique per visitor network (hashed IP). Installs count copy actions.

Status

Health: Not checked yet

We have not completed a health check for this listing yet.

No check timestamp yet.

Unclaimed listing (imported or pending owner verification). Claim it →
ā˜… Spotlight Slot

Feature Your MCP Server

Get maximum visibility for your server across our directory, search results, and detail pages.

Spotlight Your Server

Own this project?

This directory is pre-filled from public sources. Claim via GitHub README, site badge, or DNS TXT to get the verified badge and attach your website.

Claim this listing

Promote this listing

Optional paid placement. Free listings stay free forever.

Share & Embed

Add our SVG badge (dark/light directory styles) or embeddable widget to your site.