Skip to main content

serve_mcp

Function serve_mcp 

Source
pub fn serve_mcp(state: Arc<State>) -> Result<()>
Expand description

Run the MCP server. Reads JSON-RPC requests from stdin (one per line), writes responses to stdout. Stops cleanly on EOF.

eprintln! is fine for diagnostics — MCP hosts read stdout for the protocol and surface stderr in their UI separately.