0.9.0
Minor Changes
-
#4123
c8d036eThanks @gesh! - feat(mcp): stable sessions and client metadata on stateless / multi-pod MCP serversOn stateless servers every request became its own session and
$mcp_client_name/$mcp_client_versionwere missing afterinitialize. The SDK now mints theMcp-Session-Idresponse header atinitializeas a token carrying the session id and client name/version; clients replay it on every request, so any pod recovers both with no server-side store. Auto-minting requiresenableJsonResponse: trueonStreamableHTTPServerTransport; SSE-mode servers can set the header at the HTTP layer with the new exports.New exports:
encodeSessionId,decodeSessionId,MCP_SESSION_HEADER,SessionTokenPayload,newSessionId. (2026-07-10)