Documentation
¶
Index ¶
- type CreateSessionInput
- type CreateSessionOutput
- type DeleteSessionInput
- type DeleteSessionOutput
- type GetMessagesInput
- type GetMessagesOutput
- type GetStatusInput
- type GetStatusOutput
- type ListSessionsInput
- type ListSessionsOutput
- type MCPHandler
- type MCPServer
- type MessageOutput
- type SendMessageInput
- type SendMessageOutput
- type SessionOutput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateSessionInput ¶
type CreateSessionInput struct {
Environment map[string]string `json:"environment,omitempty" jsonschema:"Environment variables for the session"`
Tags map[string]string `json:"tags,omitempty" jsonschema:"Tags for the session"`
}
CreateSessionInput represents input for create_session tool
type CreateSessionOutput ¶
type CreateSessionOutput struct {
SessionID string `json:"session_id" jsonschema:"Created session ID"`
}
CreateSessionOutput represents output for create_session tool
type DeleteSessionInput ¶
type DeleteSessionInput struct {
SessionID string `json:"session_id" jsonschema:"Session ID to delete"`
}
DeleteSessionInput represents input for delete_session tool
type DeleteSessionOutput ¶
type DeleteSessionOutput struct {
Message string `json:"message" jsonschema:"Success message"`
SessionID string `json:"session_id" jsonschema:"Deleted session ID"`
}
DeleteSessionOutput represents output for delete_session tool
type GetMessagesInput ¶
type GetMessagesInput struct {
SessionID string `json:"session_id" jsonschema:"Session ID to get messages from"`
}
GetMessagesInput represents input for get_messages tool
type GetMessagesOutput ¶
type GetMessagesOutput struct {
Messages []MessageOutput `json:"messages" jsonschema:"List of messages"`
}
GetMessagesOutput represents output for get_messages tool
type GetStatusInput ¶
type GetStatusInput struct {
SessionID string `json:"session_id" jsonschema:"Session ID to get status for"`
}
GetStatusInput represents input for get_session_status tool
type GetStatusOutput ¶
type GetStatusOutput struct {
Status string `json:"status" jsonschema:"Session status"`
}
GetStatusOutput represents output for get_session_status tool
type ListSessionsInput ¶
type ListSessionsInput struct {
Status string `json:"status,omitempty" jsonschema:"Filter by session status"`
Tags map[string]string `json:"tags,omitempty" jsonschema:"Filter by tags"`
}
ListSessionsInput represents input for list_sessions tool
type ListSessionsOutput ¶
type ListSessionsOutput struct {
Sessions []SessionOutput `json:"sessions" jsonschema:"List of sessions"`
}
ListSessionsOutput represents output for list_sessions tool
type MCPHandler ¶
type MCPHandler struct {
// contains filtered or unexported fields
}
MCPHandler implements the CustomHandler interface for MCP endpoints
func NewMCPHandler ¶
func NewMCPHandler(server *app.Server) *MCPHandler
NewMCPHandler creates a new MCP handler for the /mcp endpoint
func (*MCPHandler) GetName ¶
func (h *MCPHandler) GetName() string
GetName returns the name of this handler for logging
func (*MCPHandler) RegisterRoutes ¶
RegisterRoutes registers the /mcp endpoint with Echo
type MCPServer ¶
type MCPServer struct {
// contains filtered or unexported fields
}
MCPServer wraps the MCP server and use cases
func NewMCPServer ¶
func NewMCPServer(sessionManager repositories.SessionManager, shareRepo repositories.ShareRepository, authenticatedUserID string, opts *mcp.ServerOptions) *MCPServer
NewMCPServer creates a new MCP server instance
func (*MCPServer) RegisterTools ¶
func (s *MCPServer) RegisterTools()
RegisterTools registers all MCP tools
type MessageOutput ¶
type MessageOutput struct {
Role string `json:"role" jsonschema:"Message role"`
Content string `json:"content" jsonschema:"Message content"`
Timestamp time.Time `json:"timestamp" jsonschema:"Message timestamp"`
}
MessageOutput represents a message in the output
type SendMessageInput ¶
type SendMessageInput struct {
SessionID string `json:"session_id" jsonschema:"Session ID to send message to"`
Message string `json:"message" jsonschema:"Message content to send"`
Type string `json:"type,omitempty" jsonschema:"Message type (user or raw)"`
}
SendMessageInput represents input for send_message tool
type SendMessageOutput ¶
type SendMessageOutput struct {
MessageID string `json:"message_id" jsonschema:"Sent message ID"`
}
SendMessageOutput represents output for send_message tool
type SessionOutput ¶
type SessionOutput struct {
SessionID string `json:"session_id" jsonschema:"Session ID"`
UserID string `json:"user_id" jsonschema:"User ID"`
Status string `json:"status" jsonschema:"Session status"`
StartedAt time.Time `json:"started_at" jsonschema:"When the session was started"`
Port int `json:"port" jsonschema:"Port number"`
Tags map[string]string `json:"tags,omitempty" jsonschema:"Session tags"`
}
SessionOutput represents a session in the output