Sponsored by Deepsite.site

Remote MCP Adapter

Created By
aakashh24217 days ago
Config-driven MCP proxy that adds session-safe file uploads, artifact handling, and robust state and health controls for upstream MCP servers.
Content

Remote MCP Adapter

An MCP gateway that makes remote servers feel local — it manages file uploads to tools and captures generated files back to the client.


The Model Context Protocol supports remote servers over Streamable HTTP. But most MCP servers were built assuming the client and server share a filesystem. When you move a server to a container or a remote machine, two things break: tools that read local files can't reach files on the client's machine, and tools that write files (screenshots, PDFs) save them on the server where the client can't retrieve them.

This adapter sits between your client and your upstream MCP servers. It stages uploaded files so tools can read them, captures tool output files as artifacts the client can read back, and forwards everything else unchanged.


Key Features

  • 🌐 Multiserver relay - Expose multiple upstream MCP servers under one gateway (/mcp/<server>).
  • ⬆️ File uploads - Stage client files and pass them to tools via upload://... handles.
  • 📬 File outputs - Capture screenshots, PDFs, and more, returning them as artifact://... MCP resources with optional download links.
  • Sessions - Provide per-session isolation, TTL cleanup, and optional “revival” on reconnect.
  • 💾 State backends - Use in-memory (dev), SQLite (single node), or Redis (multi-node).
  • 💓 Upstream health - Perform active checks and implement a circuit breaker to prevent cascading failures.
  • 🔁 Resilience - Retry and reconnect when upstream sessions drop.
  • 🔒 Auth - Use bearer tokens and signed, one-time upload URLs.
  • 📊 Observability - Collect OpenTelemetry metrics with optional log export.
  • 🛡️ Safe storage - Ensure atomic writes, orphan cleanup, and enforce quota limits.

Getting started

The repo includes a compose.yaml that starts Playwright MCP on port 8931 and the adapter on port 8932.

git clone https://github.com/aakashH242/remote-mcp-adapter.git
cd remote-mcp-adapter
docker compose up --build

Verify the adapter is running:

curl http://localhost:8932/healthz

From source

Requires Python 3.12+ and uv.

git clone https://github.com/aakashH242/remote-mcp-adapter.git
cd remote-mcp-adapter
uv sync
uv run remote-mcp-adapter --config config.yaml

Configure in IDE/Agent

OpenAI Codex

Add the adapter in config.toml.

[mcp_servers.playwright]
url = "http://localhost:8932/mcp/playwright"

GitHub Copilot

Add the adapter in mcp.json.

{
	"servers": {
      "playwright": {
        "url": "http://localhost:8932/mcp/playwright",
			"type": "http"
      }
    }
    
}

Antigravity

Add the adapter in mcp_config.json.

{
    "mcpServers": {
        "playwright": {
            "serverUrl": "http://localhost:8932/mcp/playwright"
        }
    }
}

Documentation

Full documentation lives in the MkDocs site:

PageWhat it covers
Getting StartedRun the adapter in under 5 minutes
Core ConceptsSessions, upload:// handles, artifact:// references
How It WorksTool buckets, request flow diagram
ConfigurationQuick config guide with examples
Config ReferenceEvery field and default
SecurityAuth setup and upload URL signing
TelemetryOpenTelemetry metrics catalog
Health/healthz semantics and example payloads
TroubleshootingCommon problems and fixes

License

MIT

Server Config

{
  "_comments": "Docker Compose (recommended) - See ReadME at https://github.com/aakashh242/remote-mcp-adapter",
  "mcpServers": {
    "mcpAdapter": {
      "url": "http://localhost:8932/mcp/playwright"
    }
  }
}
Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
WindsurfThe new purpose-built IDE to harness magic
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
Amap Maps高德地图官方 MCP Server
CursorThe AI Code Editor
Serper MCP ServerA Serper MCP Server
ChatWiseThe second fastest AI chatbot™
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
RedisA Model Context Protocol server that provides access to Redis databases. This server enables LLMs to interact with Redis key-value stores through a set of standardized tools.
DeepChatYour AI Partner on Desktop
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
Playwright McpPlaywright MCP server
Y GuiA web-based graphical interface for AI chat interactions with support for multiple AI models and MCP (Model Context Protocol) servers.
Tavily Mcp
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"