Commit 7335e3a
authored
fix(tools): add
When there is no input to a tool, the `Properies` map is `nil` if the
Tool is not created using `NewTool`. This causes the `property` field to
be set to `null` and clients such as `claude-desktop` to skip the tools
silently.
Annotating the field as `omitempty` is inline with the behavior of the
[typescript-sdk](https://github.com/modelcontextprotocol/typescript-sdk/blob/fbdeb06a4185ba2f7581603a768cd7171c64d6fc/src/types.ts#L749).omitempty to properties (#116)1 parent 342c14d commit 7335e3a
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
108 | | - | |
| 108 | + | |
109 | 109 | | |
110 | 110 | | |
111 | 111 | | |
| |||
0 commit comments