inputSchema interface requires type key
When defining a tool without any arguments taken, it should be allowed
to not have to define the `input_schema` at all, and the default value
for such a scenario should be `{ type: "object" }` as per the schema.
16d91abb68/schema/2025-06-18/schema.ts (L896-L900)
This commit is contained in:
parent
4ba1e2b7f4
commit
2508defc79
1 changed files with 38 additions and 6 deletions
|
|
@ -164,7 +164,7 @@ module MCP
|
|||
assert_kind_of Array, result[:tools]
|
||||
assert_equal "test_tool", result[:tools][0][:name]
|
||||
assert_equal "Test tool", result[:tools][0][:description]
|
||||
assert_empty(result[:tools][0][:inputSchema])
|
||||
assert_equal({ type: "object" }, result[:tools][0][:inputSchema])
|
||||
assert_instrumentation_data({ method: "tools/list" })
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue