Fix CallToolAsync for tools with no arguments (#18)

This commit is contained in:
Peder Holdgaard Pedersen 2025-02-07 09:26:42 +01:00 • committed by GitHub
commit c384c7d3de
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View file

@ -346,7 +346,7 @@ internal class McpClient : IMcpClient
new JsonRpcRequest
{
Method = "tools/call",
Params = CreateParametersDictionary(toolName, arguments)
Params = CreateParametersDictionary(toolName, arguments ?? new())
},
cancellationToken
).ConfigureAwait(false);

View file

@ -9,7 +9,7 @@
<PropertyGroup>
<!-- license and package properties -->
<PackageId>mcpdotnet</PackageId>
<Version>0.9.0.1</Version>
<Version>0.10.0.1</Version>
<Authors>PederHP</Authors>
<Description>.NET client library for the Model Context Protocol (MCP)</Description>
<PackageProjectUrl>https://github.com/PederHP/mcpdotnet</PackageProjectUrl>