pkg/mcp/client and passes them via WithMCPClients.
Source: examples/agent_with_mcp_client/
What it demonstrates
mcpclient.NewClientwithWithTimeout,WithRetryAttempts,WithToolFilter- Mixing config-based and client-based registration patterns
- Pre-built clients for custom transport wiring
Run
Fromexamples/:
MCP_TRANSPORT, stdio or HTTP URLs, and auth in .env — see MCP Config for transport details and Configuration for the full variable reference.
Key code
Expected output
Learn more
MCP
MCP feature documentation
MCP Config
WithMCPConfig variant