Co-authored-by: Matt <77928207+mattzcarey@users.noreply.github.com> Co-authored-by: Konstantin Konstantinov <KKonstantinov@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
656 B
656 B
| @modelcontextprotocol/core-internal | @modelcontextprotocol/server |
|---|---|
| minor | major |
Fix error handling for unknown tools and resources per MCP spec.
Tools: Unknown or disabled tool calls now return JSON-RPC protocol errors with
code -32602 (InvalidParams) instead of CallToolResult with isError: true.
Callers who checked result.isError for unknown tools should catch rejected promises instead.
Resources: Added ProtocolErrorCode.ResourceNotFound (-32002) as receive-tolerated
vocabulary. The wire code emitted for an unknown resources/read URI is -32602
(Invalid Params) — see the resource-not-found-32602 changeset.