tool

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 26, 2025 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package tool provides tool handling functionality for the MCP server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

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

Handler manages tool execution and authentication.

func NewHandler

func NewHandler(authEnabled bool) *Handler

NewHandler creates a new tool handler.

func (*Handler) CreateHandler

func (h *Handler) CreateHandler(tool *mcp.Tool, executor requester.RouteExecutor) func(context.Context, mcp.CallToolRequest) (*mcp.CallToolResult, error)

CreateHandler creates a handler function for a specific tool. It handles authentication validation and request execution.

Jump to

Keyboard shortcuts

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