This repository provides a flexible gateway server that bridges MCP STDIO servers to HTTP, enabling multi-instance MCP servers to be exposed via REST API with OpenAPI schema generation.
MCP Gateway bridges Model Context Protocol (MCP) STDIO servers to HTTP+SSE and REST APIs, enabling multi-instance MCP servers to be exposed over HTTP. It supports running multiple instances of the same or different MCP server types with flexible network binding and YAML-based configuration. Session IDs ensure separation between server instances, with automatic resource cleanup on connection close.
Key features include optional Basic and Bearer token authentication, configurable debug logging, and REST API support for integration with OpenAI's custom GPTs. The REST API uses endpoints like /api/{serverName}/{toolName}?sessionId={session-id}
. OpenAPI schemas can be generated for configured tools.
MCP Gateway allows HTTP+SSE clients to interact with MCP servers running remotely, addressing deployment scenarios where certain MCP servers have limited functionality. It's configured via a YAML file, supporting various network configurations and server-specific arguments.
acehoss/mcp-gateway
December 18, 2024
March 26, 2025
TypeScript