GitHubスター
0
ユーザー評価
未評価
フォーク
0
イシュー
0
閲覧数
2
お気に入り
0
OpenAI MCP Adapter
A powerful Electron-based desktop application that aggregates Model Context Protocol (MCP) servers and exposes them as OpenAI Custom Actions. This cross-platform application (Windows, Mac, Linux) provides a unified interface for managing multiple MCP servers and makes their tools accessible via a local REST API.
Features
🌐 MCP Server Management
- Add, edit, and remove MCP servers with different transport types (SSE, STDIO, HTTP)
- Real-time server status monitoring
- Granular control over tool exposure
- Auto-start and auto-restart capabilities
🔄 Unified REST API
- Automatic conversion of MCP tools to REST endpoints
- Local Fastify server with localhost-only access
- OpenAPI schema generation for ChatGPT custom actions
- Comprehensive request/response validation
🚇 Ngrok Integration
- Secure tunneling with custom domain support
- Automatic retry with exponential backoff
- Real-time connection status monitoring
- API key management
🛠️ Tool Management
- Enable/disable individual tools
- Detailed tool information and capabilities
- Tool-level configuration options
- Real-time tool status updates
📊 Monitoring & Logging
- Comprehensive logging system
- Real-time status updates
- Error tracking and reporting
- Performance metrics
Installation
Clone the repository:
git clone https://github.com/yourusername/open-ai-mcp-adapter.git cd open-ai-mcp-adapter
Install dependencies:
npm install
Build the application:
npm run build
Start the application:
npm start
Development
Prerequisites
- Node.js 18+
- npm 8+
- Electron development environment
Development Scripts
npm run dev
- Start the application in development mode with hot reloadnpm run build
- Build the applicationnpm run watch
- Watch for changes and rebuildnpm run lint
- Run ESLintnpm run test
- Run Jest testsnpm run clean
- Clean build artifacts
Project Structure
├── src/ # React frontend code
│ ├── components/ # UI components
│ ├── services/ # Frontend services
│ ├── types/ # TypeScript type definitions
│ └── utils/ # Utility functions
├── electron/ # Electron main process code
│ ├── mcp/ # MCP client implementations
│ ├── local-server/ # Fastify server implementation
│ ├── services/ # Backend services
│ └── utils/ # Backend utilities
└── package.json # Project configuration
Architecture
The application follows a modular architecture with clear separation of concerns:
Frontend Layer (src/)
- React-based UI components
- Material-UI for styling
- Event-based state management
- Real-time updates
Backend Layer (electron/)
- MCP server management
- Local REST API server
- Ngrok integration
- Configuration persistence
Communication Layer
- IPC for frontend-backend communication
- Event system for real-time updates
- Type-safe message passing
Configuration
The application supports various configuration options:
MCP Server Configuration
- Server name and endpoint
- Transport type (SSE, STDIO, HTTP)
- Authentication settings
- Auto-start options
Ngrok Configuration
- API key
- Custom domain
- Tunnel options
- Retry settings
Local Server Configuration
- Port settings
- CORS configuration
- Rate limiting
- Security options
Security
- 🔒 Localhost-only API access
- 🔐 Secure configuration storage
- 🛡️ Input validation and sanitization
- 🔑 API key management
- 🚫 Context isolation in Electron
Contributing
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Acknowledgments
58
フォロワー
100
リポジトリ
29
Gist
3
貢献数