API Reference backplane_mcp_protocol v#0.5.0
Copy MarkdownModules
MCP (Model Context Protocol) client for connecting to MCP servers.
HTTP client authorization helpers for the modern MCP protocol.
Facade for persisted OAuth client credentials bound to an exact issuer.
Compiles a tool list into an immutable snapshot for parameter-header projection.
Represents an operation to be performed by the MCP client.
Cancellable client handle and owner process for one modern subscription.
Validator for the restricted JSON Schema subset allowed in elicitation requests.
Fluent API for building MCP protocol errors.
Handles parsing and validation of MCP (Model Context Protocol) messages using the Peri library.
Represents successful responses in the MCP protocol.
MCP protocol version management.
Behaviour that each MCP protocol version module must implement.
Cache metadata carried by cacheable MCP 2026-07-28 results.
Describes the lifecycle and wire surface of an MCP protocol version.
Registry for MCP protocol version modules.
Protocol implementation for MCP specification version 2024-11-05.
Protocol implementation for MCP specification version 2025-03-26.
Protocol implementation for MCP specification version 2025-06-18.
Protocol implementation for MCP specification version 2025-11-25.
Independent protocol profile for MCP specification version 2026-07-28.
Adapter boundary between JSON Schema wire documents and local validation.
Conservative JSON Schema 2020-12 adapter backed by Peri.
Build MCP servers that extend language model capabilities.
OAuth 2.1 resource server authorization support.
Token validator using RFC 7662 Token Introspection.
JWT validator using JWKS (requires the :jose dependency).
Behaviour for token validators.
Plug serving the RFC 9728 protected resource metadata document.
Defines the behaviour for MCP prompts.
Defines the behaviour for MCP resources.
Defines the behaviour for MCP tools.
RFC 6570 URI Template parser and matcher (Levels 1 and 2).
Raised when required MCP server configuration is missing or invalid.
Read-only session and request context, set by the SDK before each callback.
The Backplane.McpProtocol Frame — pure user state + read-only context.
Builds the raw result for the mandatory modern server/discover method.
Executes one modern MCP request without creating or retaining session state.
Pure validation for the HTTP fields mirrored by modern MCP requests.
Validated, request-local context for the stateless modern server path.
Normalizes callback outcomes for the stateless modern server path.
Immutable data and filtering helpers for one modern MCP subscription.
Monitored, in-process subscription hub for modern MCP notification streams.
Selects the session-oriented legacy path or a stateless modern profile.
Behaviour for pluggable session registries and deterministic naming utilities.
ETS-based session registry for HTTP transports.
No-op registry for STDIO transport.
Distributed session registry backed by Erlang's :pg (process groups) module.
Fluent interface for building MCP component responses.
Per-client MCP session process.
Behaviour for session persistence adapters.
Redis-based session store implementation.
Represents an MCP task — a durable state machine wrapping a long-running request.
Behaviour for pluggable MCP task storage backends.
In-memory Backplane.McpProtocol.Server.TaskStore adapter backed by a single GenServer.
SSE (Server-Sent Events) transport implementation for MCP servers.
A Plug implementation for the SSE (Server-Sent Events) transport.
STDIO transport implementation for MCP servers.
StreamableHTTP transport implementation for MCP servers.
Owns one modern subscriptions/listen POST and its request-scoped SSE stream.
A Plug implementation for the Streamable HTTP transport.
Plug that serves the RFC 9728 OAuth Protected Resource metadata document
at /.well-known/oauth-protected-resource.
Functional behaviour for MCP transport implementations.
Defines the behavior that all transport implementations must follow.
Immutable protocol context captured for one outbound transport send.
A transport implementation that uses Server-Sent Events (SSE) for receiving messages and HTTP POST requests for sending messages back to the server.
A transport implementation that uses standard input/output.
A transport implementation that uses Streamable HTTP as specified in MCP 2025-03-26.
Builds request-local Streamable HTTP headers for legacy and modern MCP sends.
Owns one modern request-scoped POST/SSE exchange.
A transport implementation that uses WebSockets for bidirectional communication with the MCP server.
Mix Tasks
Mix task to test the SSE transport implementation, interactively sending commands.
Mix task to test the STDIO transport implementation, interactively sending commands.
Mix task to test the Streamable HTTP transport implementation, interactively sending commands.
Mix task to test the WebSocket transport implementation, interactively sending commands.