Skip to main content

Module mcp

Module mcp 

Source
Expand description

MCP server implementation.

Provides Model Context Protocol server for AI agent interoperability.

§Features

  • Tools: subcog_capture, subcog_recall, subcog_status, subcog_namespaces
  • Resources: Help documentation via subcog://help/{category}
  • Prompts: Tutorial, capture assistant, decision documentation

§Usage

§Stdio Transport (Claude Desktop)

subcog serve

§Claude Desktop Configuration

{
  "mcpServers": {
    "subcog": {
      "command": "subcog",
      "args": ["serve"]
    }
  }
}

Modules§

auth 🔒
JWT authentication for MCP HTTP transport (SEC-H1).
dispatch 🔒
MCP method dispatch using command pattern.
help_content 🔒
Help content for MCP resources.
prompt_understanding 🔒
Guidance content for the prompt_understanding tool.
prompts 🔒
MCP pre-defined prompts.
resources 🔒
MCP resource handlers.
server 🔒
MCP server setup and lifecycle.
session 🔒
Session state tracking for MCP clients.
tool_types 🔒
Argument types and helper functions for MCP tools.
tools 🔒
MCP tool implementations.

Structs§

Claims
JWT claims structure.
HelpCategory
Help category definition.
JwtAuthenticator
JWT authenticator for validating bearer tokens.
JwtConfig
JWT authentication configuration.
McpServer
MCP server for subcog.
PromptArgument
Argument for a prompt.
PromptDefinition
Definition of an MCP prompt.
PromptMessage
A message in a prompt.
PromptRegistry
Registry of pre-defined prompts.
ResourceContent
Content of an MCP resource.
ResourceDefinition
Definition of an MCP resource.
ResourceHandler
Handler for MCP resources (URN scheme).
ToolDefinition
Definition of an MCP tool.
ToolRegistry
Registry of MCP tools.
ToolResult
Result of a tool execution.

Enums§

PromptContent
Content of a prompt message.
ToolContent
Content types that can be returned by tools.
Transport
Transport type for the MCP server.