go-sdk/internal/readme
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2025-10-06 10:57:13 -04:00
..
client many: minor cosmetic changes (#529) 2025-09-25 16:06:24 -04:00
server many: minor cosmetic changes (#529) 2025-09-25 16:06:24 -04:00
doc.go internal/readme: use go:generate rather than Make 2025-09-11 10:38:07 -04:00
README.src.md Update readme generation instructions 2025-10-06 10:57:13 -04:00

MCP Go SDK

Open in GitHub Codespaces

PkgGoDev

This repository contains an implementation of the official Go software development kit (SDK) for the Model Context Protocol (MCP).

Package / Feature documentation

The SDK consists of several importable packages:

The SDK endeavors to implement the full MCP spec. The docs/ directory contains feature documentation, mapping the MCP spec to the packages above.

Getting started

To get started creating an MCP server, create an mcp.Server instance, add features to it, and then run it over an mcp.Transport. For example, this server adds a single simple tool, and then connects it to clients over stdin/stdout:

%include server/server.go -

To communicate with that server, create an mcp.Client and connect it to the corresponding server, by running the server command and communicating over its stdin/stdout:

%include client/client.go -

The examples/ directory contains more example clients and servers.

Contributing

We welcome contributions to the SDK! Please see CONTRIBUTING.md for details of how to contribute.

Acknowledgements / Alternatives

Several third party Go MCP SDKs inspired the development and design of this official SDK, and continue to be viable alternatives, notably mcp-go, originally authored by Ed Zynda. We are grateful to Ed as well as the other contributors to mcp-go, and to authors and contributors of other SDKs such as mcp-golang and go-mcp. Thanks to their work, there is a thriving ecosystem of Go MCP clients and servers.

License

This project is licensed under the MIT License - see the LICENSE file for details.