mcpserverv1

package
v0.2.22 Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2026 License: MPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MCPServerKind          = "mcp.server"
	MCPServerSchemaID      = "mcp.server.v1"
	MCPServerSchemaVersion = "v1"
)

Variables

Functions

func MCPServerJSONSchema

func MCPServerJSONSchema() []byte

Types

type MCPServerAuthentication

type MCPServerAuthentication struct {
	Mode                        string `json:"mode,omitempty"`
	ClientCredentialsInput      string `json:"clientCredentialsInput,omitempty"`
	ClientIDMetadataDocumentURL string `json:"clientIDMetadataDocumentURL,omitempty"`
}

type MCPServerConnectionProfile

type MCPServerConnectionProfile struct {
	Platforms []string               `json:"platforms,omitempty"`
	Stdio     *MCPServerStdioProfile `json:"stdio,omitempty"`
	HTTP      *MCPServerHTTPProfile  `json:"http,omitempty"`
}

type MCPServerCoreServer

type MCPServerCoreServer struct {
	Type    string            `json:"type,omitempty"`
	Command string            `json:"command,omitempty"`
	Args    []string          `json:"args,omitempty"`
	Env     map[string]string `json:"env,omitempty"`
	URL     string            `json:"url,omitempty"`
	Headers map[string]string `json:"headers,omitempty"`
}

type MCPServerDocument

type MCPServerDocument struct {
	Digest         *string             `json:"digest,omitempty"`
	Kind           string              `json:"kind"`
	SchemaID       string              `json:"schemaID"`
	SchemaVersion  string              `json:"schemaVersion"`
	LogicalName    string              `json:"logicalName"`
	LogicalVersion string              `json:"logicalVersion,omitempty"`
	DisplayName    string              `json:"displayName,omitempty"`
	Description    string              `json:"description,omitempty"`
	Labels         map[string]string   `json:"labels,omitempty"`
	MCPServer      MCPServerCoreServer `json:"mcpServer"`
	Extension      MCPServerExtension  `json:"extension"`
}

func DecodeMCPServerJSON

func DecodeMCPServerJSON(raw []byte) (MCPServerDocument, error)

func (MCPServerDocument) CalculatedDigest

func (v MCPServerDocument) CalculatedDigest() (
	cryptoutil.Digest,
	error,
)

func (MCPServerDocument) CanonicalJSON

func (v MCPServerDocument) CanonicalJSON() ([]byte, error)

func (MCPServerDocument) Canonicalize

func (v MCPServerDocument) Canonicalize() (MCPServerDocument, error)

func (MCPServerDocument) Clone

func (MCPServerDocument) Validate

func (v MCPServerDocument) Validate() error

type MCPServerExtension

type MCPServerExtension struct {
	LogicalVersion     string                                `json:"logicalVersion,omitempty"`
	DisplayName        string                                `json:"displayName,omitempty"`
	Description        string                                `json:"description,omitempty"`
	TimeoutMS          *int                                  `json:"timeoutMS,omitempty"`
	Labels             map[string]string                     `json:"labels,omitempty"`
	Auth               *MCPServerAuthentication              `json:"auth,omitempty"`
	Install            *MCPServerInstallation                `json:"install,omitempty"`
	ConnectionProfiles map[string]MCPServerConnectionProfile `json:"connectionProfiles,omitempty"`
	Policy             *MCPServerPolicyReference             `json:"policy,omitempty"`
}

type MCPServerHTTPProfile

type MCPServerHTTPProfile struct {
	URL           string            `json:"url,omitempty"`
	Headers       map[string]string `json:"headers,omitempty"`
	RemoveHeaders []string          `json:"removeHeaders,omitempty"`
}

type MCPServerInputDeclaration

type MCPServerInputDeclaration struct {
	Kind                 string `json:"kind"`
	Label                string `json:"label,omitempty"`
	Description          string `json:"description,omitempty"`
	Note                 string `json:"note,omitempty"`
	Placeholder          string `json:"placeholder,omitempty"`
	Required             bool   `json:"required,omitempty"`
	Default              string `json:"default,omitempty"`
	ClientSecretRequired bool   `json:"clientSecretRequired,omitempty"`
}

type MCPServerInstallation

type MCPServerInstallation struct {
	Note             string                               `json:"note,omitempty"`
	Inputs           map[string]MCPServerInputDeclaration `json:"inputs,omitempty"`
	AllowEnvironment []string                             `json:"allowEnvironment,omitempty"`
}

type MCPServerPolicyReference

type MCPServerPolicyReference struct {
	Ref      string `json:"ref"`
	Required bool   `json:"required,omitempty"`
}

type MCPServerStdioProfile

type MCPServerStdioProfile struct {
	Command   string            `json:"command,omitempty"`
	Args      []string          `json:"args,omitempty"`
	Env       map[string]string `json:"env,omitempty"`
	RemoveEnv []string          `json:"removeEnv,omitempty"`
}

Jump to

Keyboard shortcuts

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