Skip to content

Conversation

@hashemix
Copy link
Member

📌 Summary

This PR introduces significant improvements to the generated schema, with a particular focus on schema_utils.
The key changes in schema_utils include refactoring structs and enums to better support the new MCP 2025-11-25 version, as well as removing many trait implementations that are no longer necessary under the new architecture. As a result, the new version is more lightweight and maintainable.

✨ Changes Made

  • Refreshed the generated schema to align with the latest updates to the official specifications.
  • Updated method constants to return &'static str instead of String.
  • Refactored FromMessage and ToMessage implementations for requests and notifications.
  • Simplified message handling in the examples.
  • Simplified TryFrom implementations by matching directly on variants instead of using intermediate enums.
  • Added request_id() methods to ServerRequest and ClientRequest.
  • Enhanced RpcError with builder methods and improved error handling.
  • Removed redundant nested matches in TryFrom implementations for results and notifications.
  • Refactored code snippets for message handling, initialization, and response detection to use direct enum matching and new structs (for example, ServerJsonrpcResponse and ClientRequest::InitializeRequest).
  • Improved clarity and readability in client-side message handling examples.
  • Refined build scripts to improve feature-specific testing and linting.

🛠️ Testing Steps

from the project root folder run:

./scripts/run_test.sh

@hashemix hashemix merged commit afa6a7b into main Dec 13, 2025
2 checks passed
@hashemix hashemix changed the title feat!: improve shema_utils, generqted new schema sets feat!: improve schema_utils, generqted new schema sets Dec 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant