Module mcp

Module mcp 

Source
Expand description

Model Context Protocol (MCP) implementation for microsandbox server.

This module implements MCP endpoints served at the /mcp endpoint. MCP is essentially JSON-RPC with specific method names and schemas.

The module provides:

  • MCP server initialization and capabilities
  • Tool definitions for sandbox operations
  • Prompt templates for common sandbox tasks
  • Integration with existing sandbox management functions

Functionsยง

handle_mcp_call_tool
Handle MCP call tool request
handle_mcp_get_prompt
Handle MCP get prompt request
handle_mcp_initialize
Handle MCP initialize request
handle_mcp_list_prompts
Handle MCP list prompts request
handle_mcp_list_tools
Handle MCP list tools request
handle_mcp_method
Handle MCP methods
handle_mcp_notifications_initialized
Handle MCP notifications/initialized request