Uh oh!
There was an error while loading. Please reload this page.
Add support for _meta field on tool schema - #124
Conversation
Uh oh!
There was an error while loading. Please reload this page.
0f5b460 to
3127bb6Comparecodenamev
commented
Sep 9, 2025
I really need this! Looking forward to seeing this. |
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
can you please update the name to meta to closely match the field's name in the spec?
LGTM otherwise, thanks @tuntisz!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Ateş Göral <ates@magnetiq.com>
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Ateş Göral <ates@magnetiq.com>
Uh oh!
There was an error while loading. Please reload this page.
Co-authored-by: Ateş Göral <ates@magnetiq.com>
Motivation and Context
This PR adds support for the
_metaproperty in tool definitions, bringing the Ruby SDK to feature parity with the TypeScript SDK and other official MCP implementations. Previously, Ruby-based MCP servers couldn't attach metadata to tools, limiting interoperability with protocol extensions that rely on this standard field. Resolves issue #123 .How Has This Been Tested?
test/mcp/tool_test.rbdefinemethod approaches_metaappears correctly in tool serialization fortools/listresponses_metafield. Screenshot belowBreaking Changes
None. The
metadataparameter is optional and existing code continues to work unchanged.Types of changes
Checklist
Additional context
The implementation follows the MCP specification exactly:
_metain the serialized tool schema (matching the spec)metadatafor consistency with other SDK methodsdefinemethod approaches are supportedExample usage: