JSON-RPC and MCP

MCP uses JSON-RPC 2.0 messages. Start with the protocol and its message types, then follow a small JSON-RPC server in Go. The calculator example shows parsing, validation, dispatch, and response handling; it is a JSON-RPC example, not a complete MCP server.

2025