registry

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2025 License: Apache-2.0 Imports: 7 Imported by: 5

Documentation

Overview

Package registry provides access to the MCP server registry

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EnvVar

type EnvVar struct {
	Name        string `json:"name"`
	Description string `json:"description"`
	Required    bool   `json:"required"`
	Default     string `json:"default,omitempty"`
}

EnvVar represents an environment variable for an MCP server

type Metadata

type Metadata struct {
	Stars       int    `json:"stars"`
	Pulls       int    `json:"pulls"`
	LastUpdated string `json:"last_updated"`
}

Metadata represents metadata about an MCP server

func (*Metadata) ParsedTime

func (m *Metadata) ParsedTime() (time.Time, error)

ParsedTime returns the LastUpdated field as a time.Time

type Registry

type Registry struct {
	Version     string             `json:"version"`
	LastUpdated string             `json:"last_updated"`
	Servers     map[string]*Server `json:"servers"`
}

Registry represents the top-level structure of the MCP registry

func GetRegistry

func GetRegistry() (*Registry, error)

GetRegistry returns the MCP server registry

type Server

type Server struct {
	Image         string               `json:"image"`
	Description   string               `json:"description"`
	Transport     string               `json:"transport"`
	Permissions   *permissions.Profile `json:"permissions"`
	Tools         []string             `json:"tools"`
	EnvVars       []*EnvVar            `json:"env_vars"`
	Args          []string             `json:"args"`
	Metadata      *Metadata            `json:"metadata"`
	RepositoryURL string               `json:"repository_url,omitempty"`
	Tags          []string             `json:"tags,omitempty"`
	DockerTags    []string             `json:"docker_tags,omitempty"`
}

Server represents an MCP server in the registry

func GetServer

func GetServer(name string) (*Server, error)

GetServer returns a server from the registry by name

func ListServers

func ListServers() ([]*Server, error)

ListServers returns all servers in the registry

func SearchServers

func SearchServers(query string) ([]*Server, error)

SearchServers searches for servers in the registry It searches in server names, descriptions, and tags

Jump to

Keyboard shortcuts

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