Sessions, Errors, and Cancellation
Sessions
When session evidence storage is available, initialization returns a cryptographically random persisted session UID in MCP-Session-Id. Current clients send that header with subsequent requests.
The server validates that the session belongs to the authenticated workspace and remains open. Missing, closed, expired, or foreign sessions fail without revealing another workspace.
Cancellation
Send authenticated HTTP DELETE to the same MCP endpoint with MCP-Session-Id to cancel and close the recorded session. A missing or unknown session returns 404.
JSON-RPC notifications receive an empty accepted response. Synchronous requests that have already completed cannot be retroactively cancelled.
Limits
- Request bodies are limited to 1 MiB.
- Responses are limited to 2 MiB.
- Current clients accept both
application/jsonandtext/event-stream. - Request IDs are bounded and replaced when malformed.
Error classes
-32700invalid JSON.-32600invalid JSON-RPC, transport, media type, or protocol request.-32601unknown or unauthorized method or tool.-32602invalid arguments or resource URI.-32001authentication or host registration failed.-32002session validation failed.