modelcontextprotocol/go-sdk
The official Go SDK for Model Context Protocol servers and clients. Maintained in collaboration with Google.
What it solves
Building applications that connect AI models to external tools and data sources requires a standard communication protocol. This project provides the official Go software development kit for the Model Context Protocol (MCP), letting developers easily build and run MCP clients and servers in Go.
How it works
The SDK implements the official Model Context Protocol specification and offers several importable packages. The primary mcp package provides APIs to define servers, add tools, and create clients. Other packages support custom transports via jsonrpc, OAuth authentication primitives, and opt-in extensions like Skills for directory browsing and content verification. Developers can connect clients and servers using standard input/output or custom transport layers.
Who it’s for
This SDK is designed for Go developers who want to build Model Context Protocol servers or clients to integrate AI models with external tools, prompts, and resources.
Highlights
- Official Go implementation of the Model Context Protocol specification
- Primary APIs for constructing and running both clients and servers
- Support for custom transports using the JSON-RPC package
- Built-in OAuth primitives and protocol extensions like Skills for discovery and content verification
- Full support for communicating over standard input/output or command execution
Related
- Project
- Project
- Project
- Project
- Project