
oliverye7/mcp-gateway
Developer tools이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기
Model Context Protocol (MCP) 서버에 에이전트 트래픽에 대한 프록시를 라우팅합니다. 이 게이트웨이는 AI 에이전트와 MCP 서버 간의 원활한 통합을 가능하게하며 지능형 요청 라우팅, 세션...
개요
Model Context Protocol (MCP) 서버에 에이전트 트래픽에 대한 프록시를 라우팅합니다. 이 게이트웨이는 AI 에이전트와 MCP 서버 간의 원활한 통합을 가능하게 하며, 지능형 요청 라우팅, 세션 관리 및 사용 분석 제공. 몇 가지 매우 흥미로운 다운스트림 응용 프로그램의 더 많은 관련 버전의 이하지만 난 그냥 매우 경량 및 확장 버전 출시 원 :) : 최소 의존성으로 단일 Python 파일 배포 : 확장, 수정, 사용자 정의 : 인프라 및 데이터에 대한 전체 제어 - : OpenAI-powered tool matching을 사용하여 적절한 MCP 서버에 대한 경로 요청 - : 순차적 상호 작용을위한 지속적 인 세션 처리 - : Redis 백엔드로 처리 된 큐 기반 요청 - : 모든 에이전트 실행 시간과 쉽게 통합을위한 RESTful 인터페이스 - : 내장 미터 및 모니터링 기능 - : 새로운 MCP 서버를 추가하고 사용자 정의 로깅 논리 MCP Gateway는 단순한 모듈식 아키텍처를 사용합니다.
개요(AI 번역)
** 경량, 모듈 및 자체 호스팅 ** 모델 Context Protocol (MCP) 서버에 에이전트 트래픽에 대한 라우팅 프록시. 이 게이트웨이는 AI 에이전트와 MCP 서버 간의 원활한 통합을 가능하게 하며, 지능형 요청 라우팅, 세션 관리 및 사용 분석 제공. 몇 가지 매우 흥미로운 다운스트림 응용 프로그램의 더 많은 관련 버전의 이하지만 난 그냥 매우 경량 및 확장 버전 출시 원 :)
Self-Host Ready: 최소 의존성으로 단일 Python 파일 배포 Highly Modular: 확장, 수정, 사용자 지정 **Zero Lock-in **: 인프라 및 데이터에 대한 전체 제어
특징
- Intelligent Routing: OpenAI-powered tool matching을 사용하여 적절한 MCP 서버에 대한 경로 요청
- Session Management: 상태의 상호 작용을 위한 Persistent 세션 취급
- Redis 통합: Redis backend로 처리하는 Queue 기반 요청
- **HTTP API **: 모든 에이전트 실행 시간과 쉽게 통합을위한 RESTful 인터페이스
- Usage Analytics: 내장 미터 및 모니터링 기능
- Extensible: 새로운 MCP 서버와 사용자 정의 라우팅 로직을 추가하기 쉬운
건축
이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.
README
원문 README의 일부입니다. 원문 보기.
MCP Gateway
A lightweight, modular, and self-hostable routing proxy for agent traffic to Model Context Protocol (MCP) servers. This gateway enables seamless integration between AI agents and MCP servers, providing intelligent request routing, session management, and usage analytics. There are some very interesting downstream applications of a more involved version of this but I wanted to just release a very lightweight and extendable version :)
Self-Host Ready: Single Python file deployment with minimal dependencies
Highly Modular: Easy to extend, modify, and customize for your specific needs
Zero Lock-in: Full control over your infrastructure and data
Features
- Intelligent Routing: Routes requests to appropriate MCP servers using OpenAI-powered tool matching
- Session Management: Persistent session handling for stateful interactions
- Redis Integration: Queue-based request processing with Redis backend
- HTTP API: RESTful interface for easy integration with any agent runtime
- Usage Analytics: Built-in metrics and monitoring capabilities
- Extensible: Easy to add new MCP servers and custom routing logic
Architecture
The MCP Gateway uses a simple, modular architecture designed for easy self-hosting and customization:
┌─────────────────┐ ┌─────────────────┐ ┌─────────────────┐
│ AI Agents │ │ MCP Gateway │ │ Any Tool │
│ │ │ │ │ │
│ • Claude Code │◄──►│ • Smart Routing │◄──►│ • MCP │
│ • Custom Agents │ │ • Session Mgmt │ │ • Other Agents │
│ • LLM Apps │ │ • HTTP/MCP APIs │ │ • (any endpoint)│
│ │ │ │ │ │
└─────────────────┘ └─────────────────┘ └─────────────────┘
Two Integration Paths
-
HTTP API Mode: Direct REST API calls to the gateway
- Perfect for web apps, microservices, and custom integrations
- Simple HTTP POST/GET requests
- Session management via headers
-
MCP Server Mode: Gateway acts as an MCP server itself
- Use
mcp_remote.pyto expose gateway as an MCP server - Native MCP protocol support
- Seamless integration with MCP-compatible agents
- Use
Core Components
gateway.py: Main routing engine with intelligent tool matching (currently supports all MCPs, can be extended to generic tools)session.py: Stateful session management for multi-turn conversationsmcp_remote.py: MCP server wrapper for native protocol supportmcp_servers/: Example server implementations you can extendservers.txt: List of any MCPs you want to support
🚀 Quick Start (30 seconds)
설치
This server does not publish a one-line install command.
Open the repository installation guide MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →