proxy

package
v0.2.65 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 6, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Proxy

type Proxy struct {
	// contains filtered or unexported fields
}

Proxy wraps an MCP client to normalize tool names and provide simple helpers.

func NewProxy

func NewProxy(_ context.Context, server string, cli mcpclient.Interface) (*Proxy, error)

NewProxy constructs a proxy bound to a specific server name.

func (*Proxy) CallTool

func (p *Proxy) CallTool(ctx context.Context, name string, args map[string]interface{}, opts ...mcpclient.RequestOption) (*mcpschema.CallToolResult, error)

CallTool normalizes name and dispatches to the underlying client.

func (*Proxy) ListAllTools

func (p *Proxy) ListAllTools(ctx context.Context, opts ...mcpclient.RequestOption) ([]mcpschema.Tool, error)

ListAllTools returns all tools for the server by paging through cursors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL