Beamscope.MCP.Protocol (Beamscope v0.1.2)

Copy Markdown View Source

Minimal MCP (JSON-RPC 2.0 over HTTP) dispatch: initialize, tools/list, tools/call. Built directly on Jason-decoded maps rather than a protocol library — this project only needs a handful of stateless tools, so a full client/server SDK (session tracking, SSE, batching, capability negotiation beyond tools) is more machinery than the problem calls for. Batch requests (a JSON array of messages in one body) aren't supported — each HTTP request is exactly one JSON-RPC message.

Summary

Functions

Handles one decoded JSON-RPC message. Returns {:ok, response_map} to send back, or :no_reply for notifications (no id), which get no response body per the JSON-RPC spec.

Functions

handle(arg1)

@spec handle(map()) :: {:ok, map()} | :no_reply

Handles one decoded JSON-RPC message. Returns {:ok, response_map} to send back, or :no_reply for notifications (no id), which get no response body per the JSON-RPC spec.