Expand description
JSON-RPC 2.0 Protocol Handler for Model Context Protocol (MCP).
Complies with MCP specification (protocol version “2024-11-05”).
Strictly adheres to JSON-RPC 2.0 notification rules: notifications (requests without id)
NEVER receive a response, preventing client socket closure.
Follows AGENTS.md §0-B (<500 lines).
Constants§
Functions§
- process_
jsonrpc_ message - Handle a single incoming JSON-RPC 2.0 line.
Returns
Some(response_json)if the request requires a response, orNoneif it was a notification.