Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client manages a single MCP server connection, backed by modelcontextprotocol/go-sdk
func NewClient ¶
func NewClient(cfg ServerConfig) *Client
NewClient creates a Client for the given server config.
type ServerConfig ¶
type ServerConfig struct {
Name string `json:"name"`
Command string `json:"command,omitempty"`
Args []string `json:"args,omitempty"`
URL string `json:"url,omitempty"`
Env map[string]string `json:"env,omitempty"`
Headers map[string]string `json:"headers,omitempty"`
Tools []string `json:"tools,omitempty"`
}
ServerConfig describes how to launch and connect to an MCP server. For local servers, specify Command and Args. For remote servers, specify URL.
Click to show internal directories.
Click to hide internal directories.