custom

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2025 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Overview

Package custom shows how to implement a fully custom MCP tool and register it with a server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(config *Config) protoserver.NewHandler

New creates a new Server instance

Types

type Config

type Config struct {
	BaseURL string
	Options []storage.Option
}

type Server added in v0.2.11

type Server struct {
	*protoserver.DefaultHandler
	// contains filtered or unexported fields
}

func (*Server) Implements added in v0.2.11

func (i *Server) Implements(method string) bool

Implements returns true if the method is supported by this implementer

func (*Server) ListResources added in v0.2.11

func (*Server) ReadResource added in v0.2.11

func (*Server) Subscribe added in v0.2.11

func (i *Server) Subscribe(ctx context.Context, request *schema.SubscribeRequest) (*schema.SubscribeResult, *jsonrpc.Error)

Subscribe adds the URI to the subscription map.

Jump to

Keyboard shortcuts

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