mcpcatalog

package
v0.27.0 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2026 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecodeCatalogFile

func DecodeCatalogFile[T any](path string) ([]T, bool, error)

func DecodeVMCPManifest added in v0.26.2

func DecodeVMCPManifest(data []byte) (types.VMCPManifest, error)

DecodeVMCPManifest maps catalog entry-key references to the resolved-ID field used by the vMCP API and storage model. vMCPs do not support Obot version bounds, so they are rejected rather than ignored.

func NormalizeManifest

func NormalizeManifest(entry *types.MCPServerCatalogEntryManifest)

NormalizeManifest applies the same compatibility normalization used when Obot imports a catalog source.

func NormalizeSystemManifest

func NormalizeSystemManifest(entry *types.SystemMCPServerCatalogEntryManifest)

NormalizeSystemManifest applies the same compatibility normalization used when Obot imports a system catalog source.

func SanitizeName

func SanitizeName(name string) string

SanitizeName converts a catalog entry name to the RFC 1123-compatible form used when catalog entries are persisted.

func VMCPEntryKey added in v0.26.2

func VMCPEntryKey(entryKey, displayName string) string

VMCPEntryKey returns the key that identifies a vMCP within its source, falling back to one derived from the display name.

func VMCPName added in v0.26.2

func VMCPName(catalogName, sourceURL, entryKey, displayName string) string

VMCPName gives catalog sync and composite migration the same resource identity.

func ValidateConfigurationFields added in v0.26.2

func ValidateConfigurationFields(data []byte) error

ValidateConfigurationFields checks removed fields before typed decoding discards them. Other unknown fields remain allowed for forward compatibility.

func ValidateEntryKey added in v0.26.2

func ValidateEntryKey(key string) error

func ValidateSourceFields

func ValidateSourceFields(entry types.MCPServerCatalogEntryManifest) error

func WalkCatalogFiles

func WalkCatalogFiles(root string) (iter.Seq2[string, error], error)

WalkCatalogFiles returns catalog manifest paths selected by .obotcatalogs and .ignoreobotcatalogs, skipping hidden child directories. Traversal errors are yielded in the second value.

Types

type ObotVersionBounds added in v0.27.0

type ObotVersionBounds struct {
	Name           string `json:"name"`
	EntryKey       string `json:"entryKey"`
	MinObotVersion string `json:"minObotVersion"`
	MaxObotVersion string `json:"maxObotVersion"`
}

ObotVersionBounds is the range of Obot versions that a catalog item declares support for.

func DecodeObotVersionBounds added in v0.27.0

func DecodeObotVersionBounds(data []byte) (ObotVersionBounds, error)

DecodeObotVersionBounds decodes and validates only the Obot version bounds of a catalog item, so items for other Obot versions can be excluded before validation that depends on this version's runtimes and configuration fields.

func (ObotVersionBounds) InCurrentRange added in v0.27.0

func (b ObotVersionBounds) InCurrentRange() bool

InCurrentRange reports whether the running Obot version falls within the bounds.

type ValidationOptions

type ValidationOptions struct {
	MCP        mcp.ValidationOptions
	MCPBackend string
	GitManaged bool
}

Jump to

Keyboard shortcuts

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