GoMCP — Gin-like Framework for MCP Servers in Go
@zhangpanda
About GoMCP — Gin-like Framework for MCP Servers in Go
The fast, idiomatic way to build MCP servers in Go. Struct-tag auto schema, middleware chain, tool groups, auth, adapters for Gin/OpenAPI/gRPC, async tasks, Inspector UI, and more.
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"gomcp": {
"command": "go",
"args": [
"run",
"github.com/zhangpanda/gomcp/examples/basic@latest"
]
}
}
}Tools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is GoMCP?
GoMCP is a framework for building Model Context Protocol (MCP) servers in Go, designed as "Gin for MCP." It lets developers create servers that AI applications like Claude Desktop, Cursor, Kiro, and VS Code Copilot can use to call external tools, read data sources, and use prompt templates.
How to use GoMCP?
Install via go get github.com/zhangpanda/gomcp, then create a server with gomcp.New("name", "version"), register tools using s.ToolFunc(), and start a transport such as s.Stdio(). Use struct tags (e.g., mcp:"required,desc=...") to define parameter schemas with automatic validation.
Core features of GoMCP
- Struct-tag auto schema generation and validation
- Typed handlers with automatic parameter parsing and validation
- Middleware chain: Logger, Recovery, Auth, RateLimit, OTel
- Tool groups with prefix naming and group-level middleware
- Adapters for Gin, OpenAPI/Swagger, and gRPC services
- Built-in Bearer, API Key, Basic auth with RBAC
Use cases of GoMCP
- Building MCP servers for AI-powered tool calling
- Importing existing Gin web routes as MCP tools in one line
- Generating MCP tools from OpenAPI/Swagger documentation
- Exposing gRPC service methods as MCP tools
- Developing async task tools with polling and cancellation support
FAQ from GoMCP
What Go version does GoMCP require?
Go ≥ 1.25 is required.
What MCP protocol version is supported?
2024-11-05, with backward compatibility for 2025-11-25.
Does GoMCP have built-in authentication?
Yes: BearerAuth (JWT), APIKeyAuth, BasicAuth, plus RBAC via RequireRole and RequirePermission on tool groups.
What transports does GoMCP support?
stdio (for Claude Desktop, Cursor, Kiro) and Streamable HTTP with SSE.
Is there a testing utility included?
Yes, the mcptest package provides an in-memory client for unit testing with snapshot support.
Frequently asked questions
What Go version does GoMCP require?
Go ≥ 1.25 is required.
What MCP protocol version is supported?
2024-11-05, with backward compatibility for 2025-11-25.
Does GoMCP have built-in authentication?
Yes: BearerAuth (JWT), APIKeyAuth, BasicAuth, plus RBAC via RequireRole and RequirePermission on tool groups.
What transports does GoMCP support?
stdio (for Claude Desktop, Cursor, Kiro) and Streamable HTTP with SSE.
Is there a testing utility included?
Yes, the `mcptest` package provides an in-memory client for unit testing with snapshot support.
Basic information
More Developer Tools MCP servers
Altronis
sypherinMCP server + CLI for Altronis — Singapore AI consulting. Ask the Lyra consultant, generate a grant-matched AI transformation plan, pull curated SG AI events/news. Read-only, wraps altronis.sg.

TaskerArmy Agent
TaskerArmyAsk Claude or ChatGPT what Shopify theme optimization tasks are pending on your store, a remote MCP server for TaskerArmy Agent accounts.
MCP-Scan: An MCP Security Scanner
invariantlabs-aiSecurity scanner for AI agents, MCP servers and agent skills.

discoverGPT
Joe MonastierodiscoverGPT is visualAI's unified MCP gateway for AI commerce, exposing 29 tools across four capabilities on one canonical product catalog: trimodal search (natural-language, precise-color, and image-similarity), AI cata
DevDocs by CyberAGI 🚀
cyberagiincCompletely free, private, UI based Tech Documentation MCP server. Designed for coders and software developers in mind. Easily integrate into Cursor, Windsurf, Cline, Roo Code, Claude Desktop App
Comments