mcpruntime

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2026 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DiscoverAllTools

func DiscoverAllTools(ctx context.Context, configs []mcp.MCPConfig, register RegisterTool) (cleanup func())

DiscoverAllTools connects to each MCP server in configs and invokes register for every tool found. It returns a cleanup function that closes all open connections. Unreachable servers are logged and skipped.

Types

type RegisterTool

type RegisterTool func(name, description, namespace string, schema map[string]any, handler ToolHandler)

RegisterTool is called once per tool discovered on a connected MCP server.

type ToolHandler

type ToolHandler func(ctx context.Context, args map[string]any) (string, error)

ToolHandler is the call signature for a discovered MCP tool.

Jump to

Keyboard shortcuts

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