Sponsored by Deepsite.site

Samurai MCP Super Server

Created By
exprays8 months ago
The Next generation MCP toolkit
Content

Samurai MCP Super Server

A comprehensive Model Context Protocol (MCP) super server with plugin architecture, secure vault integration, and real-time web dashboard.

🚀 Features

Core Features

  • Plugin-Based Architecture: Modular MCP instances for different services (SMS via Twilio, etc.)
  • LLM Provider Management: Support for multiple LLM providers with API key management
  • Secure Vault Integration: Industry-standard API key storage and encryption
  • Real-time Web Dashboard: Live monitoring and management interface
  • Rate Limiting & Throttling: Per-provider and per-plugin request control
  • Comprehensive Logging: Request/response analytics with queryable history

Advanced Features

  • Plugin Marketplace: Community-contributed plugins
  • A/B Testing Framework: Different LLM configuration testing
  • Cost Tracking: Budgeting per user/organization
  • Response Caching: API cost reduction through intelligent caching
  • Plugin Sandboxing: Security isolation for plugins
  • Metrics & Observability: Prometheus/Grafana integration

Developer Experience

  • Plugin SDK/CLI: Easy plugin development tools
  • Hot-reloading: Development-time plugin reloading
  • OpenAPI Documentation: Auto-generated API docs
  • Testing Framework: Mock services for plugin testing

📁 Project Structure

├── README.md
├── go.mod
├── go.sum
├── samurai.go                 # Development CLI tool
├── docker-compose.yml         # Database services
├── .env.example              # Environment template
├── backend/
│   ├── cmd/
│   │   └── server/
│   │       └── main.go       # Application entry point
│   └── internal/
│       ├── api/
│       │   ├── handlers/     # HTTP request handlers
│       │   ├── middleware/   # HTTP middleware
│       │   └── routes/       # Route definitions
│       ├── config/           # Configuration management
│       ├── database/         # Database connection & models
│       └── utils/            # Utilities (logging, etc.)
├── config/
│   └── development.json      # Development configuration
├── logs/                     # Application logs
├── bin/                      # Compiled binaries
└── data/                     # Database data

🛠️ Prerequisites

⚡ Quick Start

1. Clone Repository

git clone https://github.com/exprays/samurai
cd exprays-samurai

2. Setup Development Environment

go run samurai.go setup

This will:

  • Create necessary directories
  • Copy .env.example to .env
  • Download Go dependencies
  • Pull required Docker images

3. Start Development Environment

go run samurai.go dev

This will:

  • Start PostgreSQL database
  • Start the backend server
  • Display service URLs and status

4. Verify Installation

go run samurai.go status

🔧 Development Commands

CommandDescription
go run samurai.go devStart full development environment
go run samurai.go setupSetup development environment
go run samurai.go buildBuild the application
go run samurai.go testRun all tests
go run samurai.go statusShow service status
go run samurai.go logsShow service logs
go run samurai.go stopStop all services
go run samurai.go cleanClean build artifacts

🌐 Service Endpoints

ServiceURLDescription
Health Checkhttp://localhost:8080/healthService health status
Ready Checkhttp://localhost:8080/health/readyDatabase readiness
API Basehttp://localhost:8080/api/v1REST API endpoints
Databaselocalhost:5432PostgreSQL database

📊 Logging

The application uses structured logging with separate log files:

  • Application Logs: logs/app.log - Main application events
  • Access Logs: logs/access.log - HTTP request/response logs
  • Database Logs: logs/database.log - Database queries and operations

Log Configuration

Logs are configured via environment variables:

  • LOG_LEVEL: debug, info, warn, error (default: info)
  • LOG_FORMAT: json, console (default: json)

🔒 Environment Configuration

Copy .env.example to .env and configure:

# Server Configuration
SERVER_PORT=8080
SERVER_HOST=localhost
SERVER_ENVIRONMENT=development

# Database Configuration
DATABASE_HOST=localhost
DATABASE_PORT=5432
DATABASE_USER=samurai
DATABASE_PASSWORD=samurai_password
DATABASE_NAME=samurai_db
DATABASE_SSL_MODE=disable

# Authentication
JWT_SECRET=your-jwt-secret-here
JWT_EXPIRY=24h

# Logging
LOG_LEVEL=info
LOG_FORMAT=json

🏗️ Architecture

Current Implementation (Phase 1)

  • ✅ Go project structure with module management
  • ✅ HTTP server with Gin framework
  • ✅ Configuration management system
  • ✅ PostgreSQL database with GORM
  • ✅ Structured logging infrastructure
  • ✅ JWT-based authentication
  • ✅ User registration and login APIs
  • ✅ Role-based access control (RBAC)
  • ✅ API middleware (auth, CORS, logging, recovery)

Upcoming Features (Phase 2+)

  • 🔄 MCP Protocol Implementation
  • 🔄 LLM Provider Integration
  • 🔄 Plugin System Architecture
  • 🔄 Vault Integration
  • 🔄 Frontend Dashboard
  • 🔄 Monitoring & Observability

🧪 Testing

# Run all tests
go run samurai.go test

# Run specific package tests
cd backend && go test ./internal/...

# Run tests with coverage
cd backend && go test -cover ./...

📦 Building

# Build for current platform
go run samurai.go build

# Build for specific platform
cd backend && GOOS=linux GOARCH=amd64 go build -o ../bin/mcp-server-linux ./cmd/server

🔍 Monitoring

Health Checks

  • GET /health - Basic service health
  • GET /health/ready - Database connectivity check

Logs

View real-time logs:

# Application logs
tail -f logs/app.log

# Access logs
tail -f logs/access.log

# Database logs
tail -f logs/database.log

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes
  4. Add tests for new functionality
  5. Run tests and ensure they pass
  6. Submit a pull request

📋 Development Phases

Phase 1: Foundation (Completed)

  • Project setup & basic backend
  • Authentication & security foundation
  • Database models and connections
  • Logging infrastructure
  • Basic API documentation

Phase 2: Core MCP Integration (In Progress)

  • MCP protocol implementation
  • LLM provider integration
  • Plugin-MCP bridge
  • API key management

Phase 3+: Advanced Features

  • Vault integration
  • Frontend dashboard
  • Monitoring & observability
  • Plugin marketplace
  • Enterprise features

📞 Support

For support and questions:

📄 License

[License information to be added]

Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
CursorThe AI Code Editor
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
Y GuiA web-based graphical interface for AI chat interactions with support for multiple AI models and MCP (Model Context Protocol) servers.
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright McpPlaywright MCP server
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
ChatWiseThe second fastest AI chatbot™
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
Tavily Mcp
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
Serper MCP ServerA Serper MCP Server
WindsurfThe new purpose-built IDE to harness magic
DeepChatYour AI Partner on Desktop
Amap Maps高德地图官方 MCP Server