mcp

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package mcp discovers tools from MCP (Model Context Protocol) servers and converts them to pith-sdk Tools for use in agent sessions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Tools

func Tools(ctx context.Context, cfg Config) (tools []pithsdk.Tool, close func() error, err error)

Tools discovers tools from an MCP server and returns them as pith-sdk Tools. The returned close function should be called to shut down the MCP server connection.

Types

type Config

type Config struct {
	// Command is the path to the MCP server executable.
	// Required for stdio transport.
	Command string
	// Args are command-line arguments passed to the MCP server.
	Args []string
	// Env are environment variables passed to the MCP server (KEY=VALUE format).
	Env []string
}

Config configures an MCP server connection.

Jump to

Keyboard shortcuts

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