Documentation
¶
Index ¶
- Constants
- type Annotations
- type BlobResourceContents
- type CallToolResult
- type ClientCapabilities
- type CompleteArgument
- type CompleteResult
- type Completion
- type Content
- type EmbeddedResource
- type GetPromptResult
- type ImageContent
- type Implementation
- type InitializeResult
- type ListPromptsResult
- type ListResourcesResult
- type ListToolsResult
- type LoggingLevel
- type MetaData
- type Prompt
- type PromptArgument
- type PromptMessage
- type PromptReference
- type ReadResourceResult
- type Resource
- type ResourceContents
- type ResourceReference
- type Role
- type ServerCapabilities
- type TextContent
- type TextResourceContents
- type Tool
- type ToolInputSchema
Constants ¶
View Source
const ( RefTypePrompt = "ref/prompt" RefTypeResource = "ref/resource" )
Constants for reference types
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Annotations ¶
type BlobResourceContents ¶
type CallToolResult ¶
type ClientCapabilities ¶
type CompleteArgument ¶
type CompleteResult ¶
type CompleteResult struct {
Meta *MetaData `json:"_meta,omitempty"`
Completion Completion `json:"completion"`
}
type Completion ¶
type EmbeddedResource ¶
type EmbeddedResource struct {
Annotations *Annotations `json:"annotations,omitempty"`
Resource ResourceContents `json:"resource"`
Type string `json:"type"` // Always "resource"
}
type GetPromptResult ¶
type GetPromptResult struct {
Meta *MetaData `json:"_meta,omitempty"`
Description string `json:"description,omitempty"`
Messages []PromptMessage `json:"messages"`
}
type ImageContent ¶
type ImageContent struct {
Annotations *Annotations `json:"annotations,omitempty"`
Data []byte `json:"data"`
MimeType string `json:"mimeType"`
Type string `json:"type"` // Always "image"
}
type Implementation ¶
Common types used by both client and server
type InitializeResult ¶
type InitializeResult struct {
Meta *MetaData `json:"_meta,omitempty"`
Capabilities ServerCapabilities `json:"capabilities"`
Instructions string `json:"instructions,omitempty"`
ProtocolVersion string `json:"protocolVersion"`
ServerInfo Implementation `json:"serverInfo"`
}
type ListPromptsResult ¶
type ListResourcesResult ¶
type ListToolsResult ¶
type LoggingLevel ¶
type LoggingLevel string
const ( LoggingLevelEmergency LoggingLevel = "emergency" LoggingLevelAlert LoggingLevel = "alert" LoggingLevelCritical LoggingLevel = "critical" LoggingLevelError LoggingLevel = "error" LoggingLevelWarning LoggingLevel = "warning" LoggingLevelNotice LoggingLevel = "notice" LoggingLevelInfo LoggingLevel = "info" LoggingLevelDebug LoggingLevel = "debug" )
type Prompt ¶
type Prompt struct {
Arguments []PromptArgument `json:"arguments,omitempty"`
Description string `json:"description,omitempty"`
Name string `json:"name"`
}
type PromptArgument ¶
type PromptMessage ¶
type PromptReference ¶
type PromptReference struct {
Type string `json:"type"` // const "ref/prompt"
Name string `json:"name"`
}
Reference types
type ReadResourceResult ¶
type ReadResourceResult struct {
Meta *MetaData `json:"_meta,omitempty"`
Contents []ResourceContents `json:"contents"`
}
type Resource ¶
type Resource struct {
Annotations *Annotations `json:"annotations,omitempty"`
Description string `json:"description,omitempty"`
MimeType string `json:"mimeType,omitempty"`
Name string `json:"name"`
URI string `json:"uri"`
}
type ResourceContents ¶
type ResourceContents interface{} // Can be TextResourceContents or BlobResourceContents
type ResourceReference ¶
type ServerCapabilities ¶
type ServerCapabilities struct {
Experimental map[string]map[string]interface{} `json:"experimental,omitempty"`
Logging map[string]interface{} `json:"logging,omitempty"`
Prompts *struct {
ListChanged bool `json:"listChanged"`
} `json:"prompts,omitempty"`
Resources *struct {
ListChanged bool `json:"listChanged"`
Subscribe bool `json:"subscribe"`
} `json:"resources,omitempty"`
Tools *struct {
ListChanged bool `json:"listChanged"`
} `json:"tools,omitempty"`
}
type TextContent ¶
type TextContent struct {
Annotations *Annotations `json:"annotations,omitempty"`
Text string `json:"text"`
Type string `json:"type"` // Always "text"
}
type TextResourceContents ¶
type Tool ¶
type Tool struct {
Description string `json:"description,omitempty"`
InputSchema ToolInputSchema `json:"inputSchema"`
Name string `json:"name"`
}
type ToolInputSchema ¶
Click to show internal directories.
Click to hide internal directories.