MCPcopy Create free account
hub / github.com/modelcontextprotocol/go-sdk / ListResources

Method ListResources

mcp/client.go:1007–1009  ·  view source on GitHub ↗

ListResources lists the resources that are currently available on the server.

(ctx context.Context, params *ListResourcesParams)

Source from the content-addressed store, hash-verified

1005
1006// ListResources lists the resources that are currently available on the server.
1007func (cs *ClientSession) ListResources(ctx context.Context, params *ListResourcesParams) (*ListResourcesResult, error) {
1008 return handleSend[*ListResourcesResult](ctx, methodListResources, newClientRequest(cs, orZero[Params](params)))
1009}
1010
1011// ListResourceTemplates lists the resource templates that are currently available on the server.
1012func (cs *ClientSession) ListResourceTemplates(ctx context.Context, params *ListResourceTemplatesParams) (*ListResourceTemplatesResult, error) {

Callers 3

TestEndToEndFunction · 0.80
TestNoJSONNullFunction · 0.80
TestListFunction · 0.80

Calls 1

newClientRequestFunction · 0.85

Tested by 3

TestEndToEndFunction · 0.64
TestNoJSONNullFunction · 0.64
TestListFunction · 0.64