Overall architecture design and module description of MCP Gateway system
Overview of the overall architecture of MCP Gateway system, including the gateway itself, management backend, supporting APIs, storage mechanisms, and integration methods with external services.
The architecture diagram is being updated and will provide detailed system architecture diagrams in future versions.
MCP Gateway is the core component of the system, responsible for handling all MCP protocol requests:
/*
listens to all HTTP requestsRequest Routing
Request distribution based on route prefix and suffix (/sse
, /message
, /mcp
)
Protocol Parsing
Parse JSON-RPC format to extract methods and parameters
Service Invocation
Invoke external services and parse results
Configuration Reading
Dynamically load and apply configuration information
Provides a visual management interface with the following core modules:
Proxy Configuration Module
Used to configure MCP gateway proxies and tools, supporting graphical configuration interface
Conversation Experiment Platform
Simple Chat for testing MCP, mainly provided for developers and users who need to integrate into custom systems for reference
User Management Module
User permissions, information maintenance, and access control
Provides complete backend API services:
Stores all MCP services, tools, routing and other configuration information:
YAML file format, suitable for development environments
Lightweight database, suitable for single-machine deployment
Enterprise-grade database, suitable for production environments
Stores user data, session records, etc.:
MCP Gateway is designed for seamless integration with existing business systems:
REST API Services
Supports standard REST API calls, including GET, POST, PUT, DELETE and other methods
Webhook Services
Supports Webhook callbacks and event trigger mechanisms
Database Services
Can directly integrate with existing database systems, supporting multiple database types
Request Reception
MCP Client sends requests to specified endpoints of MCP Gateway
Protocol Parsing
Gateway parses MCP protocol format and extracts tool invocation information
Configuration Lookup
Look up corresponding configuration information based on tool name
Service Invocation
Call backend services using configured templates and parameters
Response Processing
Process backend service responses and convert to MCP protocol format
Result Return
Return processing results to MCP Client
All services run on the same machine, suitable for development and testing environments
Each component is deployed independently, supporting horizontal scaling and load balancing
Use Docker and Kubernetes for containerized deployment
MCP Gateway adopts a modular design and supports the following extensions:
To deeply understand the specific implementation of each component, please refer to the corresponding configuration documentation and development guides.