Help us shape the future of Go! Take the 2026 Go Developer Survey

catalog

package
v0.30.0 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2025 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DockerCatalogFilename = "docker-mcp.yaml"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Catalog

type Catalog struct {
	Servers map[string]Server
}

func Get

func Get(ctx context.Context) (Catalog, error)

func GetWithOptions

func GetWithOptions(ctx context.Context, useConfigured bool, additionalCatalogs []string) (Catalog, error)

GetWithOptions loads catalogs with enhanced options for configured catalogs and additional catalogs

func ReadFrom

func ReadFrom(ctx context.Context, fileOrURLs []string) (Catalog, error)

func ReadOne added in v0.28.0

func ReadOne(ctx context.Context, fileOrURL string) (Catalog, string, string, error)

type Config

type Config struct {
	Secrets []Secret `yaml:"secrets,omitempty" json:"secrets,omitempty"`
	Env     []Env    `yaml:"env,omitempty" json:"env,omitempty"`
}

type Container

type Container struct {
	Image   string   `yaml:"image" json:"image"`
	Command []string `yaml:"command" json:"command"`
	Volumes []string `yaml:"volumes" json:"volumes"`
	User    string   `yaml:"user,omitempty" json:"user,omitempty"`
}

type Env

type Env struct {
	Name  string `yaml:"name" json:"name"`
	Value string `yaml:"value" json:"value"`
}

type Items

type Items struct {
	Type string `yaml:"type" json:"type"`
}

type Metadata added in v0.29.0

type Metadata struct {
	Pulls       int      `yaml:"pulls,omitempty" json:"pulls,omitempty"`
	Stars       int      `yaml:"stars,omitempty" json:"stars,omitempty"`
	GithubStars int      `yaml:"githubStars,omitempty" json:"githubStars,omitempty"`
	Category    string   `yaml:"category,omitempty" json:"category,omitempty"`
	Tags        []string `yaml:"tags,omitempty" json:"tags,omitempty"`
	License     string   `yaml:"license,omitempty" json:"license,omitempty"`
	Owner       string   `yaml:"owner,omitempty" json:"owner,omitempty"`
}

type OAuth

type OAuth struct {
	Providers []OAuthProvider `yaml:"providers,omitempty" json:"providers,omitempty"`
	Scopes    []string        `yaml:"scopes,omitempty" json:"scopes,omitempty"`
}

type OAuthProvider

type OAuthProvider struct {
	Provider string `yaml:"provider" json:"provider"`
	Secret   string `json:"secret,omitempty" yaml:"secret,omitempty"`
	Env      string `json:"env,omitempty" yaml:"env,omitempty"`
}

type Parameters

type Parameters struct {
	Type       string     `yaml:"type" json:"type"`
	Properties Properties `yaml:"properties" json:"properties"`
	Required   []string   `yaml:"required" json:"required"`
}

type Properties

type Properties map[string]Property

func (*Properties) ToMap

func (p *Properties) ToMap() map[string]any

type Property

type Property struct {
	Type        string `yaml:"type" json:"type"`
	Description string `yaml:"description" json:"description"`
	Items       *Items `yaml:"items,omitempty" json:"items,omitempty"`
}

type Remote

type Remote struct {
	URL       string            `yaml:"url,omitempty" json:"url,omitempty"`
	Transport string            `yaml:"transport_type,omitempty" json:"transport_type,omitempty"`
	Headers   map[string]string `yaml:"headers,omitempty" json:"headers,omitempty"`
}

type Run

type Run struct {
	Command []string          `yaml:"command,omitempty" json:"command,omitempty"`
	Volumes []string          `yaml:"volumes,omitempty" json:"volumes,omitempty"`
	Env     map[string]string `yaml:"env,omitempty" json:"env,omitempty"`
}

type Secret

type Secret struct {
	Name string `yaml:"name" json:"name"`
	Env  string `yaml:"env" json:"env"`
}

type Server

type Server struct {
	Name           string    `yaml:"name,omitempty" json:"name,omitempty"`
	Type           string    `yaml:"type" json:"type"`
	Image          string    `yaml:"image" json:"image"`
	Description    string    `yaml:"description,omitempty" json:"description,omitempty"`
	Title          string    `yaml:"title,omitempty" json:"title,omitempty"`
	Icon           string    `yaml:"icon,omitempty" json:"icon,omitempty"`
	LongLived      bool      `yaml:"longLived,omitempty" json:"longLived,omitempty"`
	Remote         Remote    `yaml:"remote" json:"remote"`
	SSEEndpoint    string    `yaml:"sseEndpoint,omitempty" json:"sseEndpoint,omitempty"` // Deprecated: Use Remote instead
	OAuth          *OAuth    `yaml:"oauth,omitempty" json:"oauth,omitempty"`
	Secrets        []Secret  `yaml:"secrets,omitempty" json:"secrets,omitempty"`
	Env            []Env     `yaml:"env,omitempty" json:"env,omitempty"`
	Command        []string  `yaml:"command,omitempty" json:"command,omitempty"`
	Volumes        []string  `yaml:"volumes,omitempty" json:"volumes,omitempty"`
	User           string    `yaml:"user,omitempty" json:"user,omitempty"`
	DisableNetwork bool      `yaml:"disableNetwork,omitempty" json:"disableNetwork,omitempty"`
	AllowHosts     []string  `yaml:"allowHosts,omitempty" json:"allowHosts,omitempty"`
	Tools          []Tool    `yaml:"tools,omitempty" json:"tools,omitempty"`
	Config         []any     `yaml:"config,omitempty" json:"config,omitempty"`
	Prefix         string    `yaml:"prefix,omitempty" json:"prefix,omitempty"`
	Metadata       *Metadata `yaml:"metadata,omitempty" json:"metadata,omitempty"`
}

func (*Server) IsOAuthServer added in v0.27.0

func (s *Server) IsOAuthServer() bool

func (*Server) IsRemoteOAuthServer

func (s *Server) IsRemoteOAuthServer() bool

type ServerConfig

type ServerConfig struct {
	Name    string
	Spec    Server
	Config  map[string]any
	Secrets map[string]string
}

type Tool

type Tool struct {
	Name        string     `yaml:"name" json:"name"`
	Description string     `yaml:"description" json:"description"`
	Container   Container  `yaml:"container" json:"container"`
	Parameters  Parameters `yaml:"parameters" json:"parameters"`
}

type ToolGroup

type ToolGroup struct {
	Name  string `yaml:"name" json:"name"`
	Tools []Tool `yaml:"tools" json:"tools"`
}

Jump to

Keyboard shortcuts

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