mcpserver

package
v0.21.4 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2026 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ControlClient

type ControlClient interface {
	Status(runtimeID string) (map[string]any, error)
	List() ([]map[string]any, error)
	Spawn(params map[string]any) (map[string]any, error)
	Shutdown(mode string) error
	Close() error
	AnswerPermission(runtimeID, requestID, optionID string) error
}

type Options

type Options struct {
	Transport        string
	ControlSocket    string
	SupervisorSocket string
	NoAutostart      bool
	IdleTimeout      time.Duration
	Addr             string
	AuthToken        string
	ControlClient    ControlClient
}

type RunInfo

type RunInfo struct {
	RunID        string
	Label        string
	RuntimeID    string
	SessionID    string
	SupervisorID string
	SentinelPath string
	EventLogPath string
	Agent        string
	Backend      string
	Dir          string
	CreatedAt    time.Time
}

type RunRegistry

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

func NewRunRegistry

func NewRunRegistry() *RunRegistry

func (*RunRegistry) All

func (r *RunRegistry) All() []*RunInfo

func (*RunRegistry) Lookup

func (r *RunRegistry) Lookup(key string) *RunInfo

func (*RunRegistry) Remove

func (r *RunRegistry) Remove(runID string) *RunInfo

func (*RunRegistry) Store

func (r *RunRegistry) Store(info *RunInfo) error

type Server

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

func NewServer

func NewServer(opts Options) (*Server, error)

func (*Server) Close

func (s *Server) Close() error

func (*Server) HTTPHandler

func (s *Server) HTTPHandler() http.Handler

func (*Server) RegisteredToolNames

func (s *Server) RegisteredToolNames() []string

func (*Server) Run

func (s *Server) Run() error

func (*Server) RunHTTP

func (s *Server) RunHTTP(addr string) error

Jump to

Keyboard shortcuts

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