-
Notifications
You must be signed in to change notification settings - Fork 752
Labels
good first issueGood for new contributorsGood for new contributorshelp wantedExtra attention is neededExtra attention is neededtype: documentationImprovements or additions to documentationImprovements or additions to documentation
Description
Description
The documentation on mcp-go.dev shows an incorrect method signature for ListTools.
Issue
Documentation shows (incorrect):
c.ListTools(ctx)
Actual API signature:
func (c *Client) ListTools(
ctx context.Context,
request mcp.ListToolsRequest,
) (*mcp.ListToolsResult, error)
Correct usage:
toolsResult, err := c.ListTools(ctx, mcp.ListToolsRequest{})
Evidence
1. https://pkg.go.dev/github.com/mark3labs/mcp-go/client#Client.ListTools shows the correct 2-parameter signature
2. https://github.com/mark3labs/mcp-go/blob/main/examples/simple_client/main.go#L127-L138 uses 2 parameters
3. https://github.com/mark3labs/mcp-go/blob/main/client/client.go#L425 requires 2 parameters
Impact
New users following the mcp-go.dev documentation will encounter compilation errors when calling ListTools with only one parameter.
Suggested Fix
Update the documentation on mcp-go.dev to show the correct method signature with both parameters.
Environment
- mcp-go version: v0.43.2 (latest)coderabbitai
Metadata
Metadata
Assignees
Labels
good first issueGood for new contributorsGood for new contributorshelp wantedExtra attention is neededExtra attention is neededtype: documentationImprovements or additions to documentationImprovements or additions to documentation