SuperAPIAI Directory

mcp-gateway

github.com · AI developer platforms

MCP Server Gateway is a gateway service used to bridge the stdio-based Model Context Protocol (MCP) implementation in Claude Desktop with HTTP/SSE-based MCP servers. Since Claude Desktop currently only supports MCP servers using the stdio protocol, this gateway acts as a protocol converter, enabling Claude Desktop to communicate with any HTTP/SSE MCP server. It works as follows: it receives stdio input from Claude Desktop, converts and forwards requests to the HTTP/SSE MCP server, and then converts SSE responses back to stdio format. To use it, you need to install it globally via npm (the material mentions using a global npm install, but does not provide the complete installation command), locate the gateway path, configure Claude Desktop's config.json, and specify the MCP server to connect to via environment variables; by default it connects to MCP Hub's https://server.mcphub.ai/api/mcp。项目采用 Apache 2.0 License.

Open website Alternatives
PricingOpen source开源项目(可免费自部署)
PlatformsmacOS · Linux

About this tool

MCP Server Gateway is a gateway service used to bridge the stdio-based Model Context Protocol (MCP) implementation in Claude Desktop with HTTP/SSE-based MCP servers. It addresses a protocol compatibility gap: Claude Desktop currently only supports stdio-based MCP servers, while many MCP servers use HTTP and Server-Sent Events (SSE) transport.

Purpose The gateway acts as a protocol converter, enabling Claude Desktop to communicate with any HTTP/SSE MCP server. Specifically, it:

  • Receives stdio input from Claude Desktop;
  • Converts and forwards requests to the HTTP/SSE MCP server;
  • Converts SSE responses back to stdio format for use by Claude Desktop.

Installation The material states that the gateway can be installed globally via npm, but does not provide the complete installation command. After installation, you need to locate where npm installed the gateway. Common global package paths include: macOS (Homebrew Node): /opt/homebrew/lib/node_modules/@mcphub/gateway/dist/src/mcphub-gateway.js macOS (default): /usr/local/lib/node_modules/@mcphub/gateway/dist/src/mcphub-gateway.js Windows: %AppData%\npm\node_modules@mcphub\gateway\dist\src\mcphub-gateway.js You can also confirm the installation and path via npm list -g or npm list -g @mcphub/gateway.

Configuring Claude Desktop You need to create or update the Claude Desktop configuration file: macOS: ~/Library/Application Support/Claude Desktop/config.json Windows: %APPDATA%\Claude Desktop\config.json Add the corresponding configuration to this file, and replace the path in args with the actual path found in step 1. The material does not provide a complete configuration example.

Configuring the MCP Server Connection The gateway uses environment variables to specify the MCP server to connect to. By default, the gateway connects to the MCP Hub server https://server.mcphub.ai/api/mcp,该服务器提供多种预配置的 MCP service. The material does not provide the environment variable names.

Starting Start or restart Claude Desktop to apply the changes.

Troubleshooting If you cannot find the gateway path:

  • List all global packages and look for @mcphub/gateway: npm list -g
  • Or specifically check the gateway: npm list -g @mcphub/gateway Verify the Node.js installation:
  • Check the Node version: node --version
  • Check the npm version: npm --version Common issues:
  • When using Homebrew on macOS, ensure Node.js is correctly linked: brew doctor, brew link node
  • If you encounter permission errors, you may need to use sudo during installation

Use Cases Suitable for users who want Claude Desktop to connect to HTTP/SSE MCP servers, especially when the target MCP server does not provide stdio transport.

Limitations and Notes Claude Desktop currently only supports MCP servers using the stdio protocol; this gateway solves this protocol compatibility issue. By default it connects to MCP Hub's https://server.mcphub.ai/api/mcp。项目为 Gateway demo for MCP SSE Server, licensed under the Apache 2.0 License. The materials do not provide information on pricing, fees, the scope of support for other platforms, performance metrics, or security. If you encounter issues, you can submit an issue on GitHub; contributions to the project are welcome, and you can submit a Pull Request.

Up/Down to navigate · Enter to open · ESC to closeBrowse all tools