Open
Conversation
BREAKING CHANGE: This SDK now requires Zod v4.0 or later. - Remove all Zod v3 imports, types, and runtime detection - Simplify `SchemaOutput<S>` to use direct indexed access `S['_zod']['output']` - Remove `zod-to-json-schema` dependency (z4-mini has built-in JSON schema support) - Add closure-based handlers for prompts and tools to eliminate runtime type casts - Simplify `executeToolHandler` and `handleAutomaticTaskPolling` - Remove v3 test blocks from integration tests
- Create mapping.ts as single source of truth for method-to-schema mappings - Remove resultSchema parameter from Protocol.request() - now derived from method name - Add HandlerResultTypeMap for typed setRequestHandler return values - Update Client/Server setRequestHandler to use method-specific result types - Remove schema arguments from all call sites (examples, tests) - Fix test method names to use real MCP methods (ping, tools/call, etc.) BREAKING CHANGE: Protocol.request() no longer accepts a resultSchema parameter. The result type is now automatically inferred from the method name.
…args - Update Server/Client setRequestHandler to use HandlerResultTypeMap[M] - Remove schema arguments from all this.request() calls - Clean up unused schema imports
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
mapping.tsas single source of truth for method → schema mappingsresultSchemaparameter fromProtocol.request()- now derived from method nameHandlerResultTypeMapfor typedsetRequestHandlerreturn valuesClientandServerrequest methodsBreaking Changes
Protocol.request()no longer accepts aresultSchemaparameterClient.callTool()no longer accepts aresultSchemaparameterTest plan
🤖 Generated with Claude Code