mcpr parses every JSON-RPC 2.0 message and classifies it against the MCP specification (2025-03-26). This page lists every supported method, what mcpr does with it, and what fields are logged.
| Method | Proxy Behavior | Logged Fields |
|---|
initialize | Extracts clientInfo (name, version, platform), tracks session state, captures server metadata and capabilities | session_id, client_name, client_version, client_platform |
notifications/initialized | Transitions session to Active state | session_id |
ping | Forwarded as-is | — |
| Method | Proxy Behavior | Logged Fields |
|---|
tools/list | CSP rewriting + schema capture with change tracking | mcp_method |
tools/call | CSP rewriting, extracts tool name, per-tool metrics | mcp_method, tool, latency_ms, error_code, error_msg |
notifications/tools/list_changed | Marks schema as stale | — |
| Method | Proxy Behavior | Logged Fields |
|---|
resources/list | CSP rewriting + schema capture | mcp_method |
resources/templates/list | CSP rewriting + schema capture | mcp_method |
resources/read | CSP rewriting, extracts resource URI | mcp_method |
resources/subscribe | Forwarded as-is | mcp_method |
resources/unsubscribe | Forwarded as-is | mcp_method |
| Method | Proxy Behavior | Logged Fields |
|---|
prompts/list | Schema capture (names, descriptions, arguments) | mcp_method |
prompts/get | Extracts prompt name for logging | mcp_method |
| Method | Proxy Behavior | Logged Fields |
|---|
logging/setLevel | Forwarded as-is, classified for logging | mcp_method |
completion/complete | Forwarded as-is, classified for logging | mcp_method |
notifications/cancelled | Extracts requestId | mcp_method |
notifications/progress | Extracts progressToken | mcp_method |
These methods are forwarded as passthrough (not actively classified):
| Method | Direction | Notes |
|---|
sampling/createMessage | Server → Client | Sampling request |
roots/list | Server → Client | Root listing request |
notifications/resources/list_changed | Server → Client | Resource change notification |
notifications/resources/updated | Server → Client | Resource update notification |
notifications/prompts/list_changed | Server → Client | Prompt change notification |
notifications/roots/list_changed | Client → Server | Root change notification |
notifications/message | Server → Client | Log message notification |
Unknown methods are forwarded as-is and appear as Unknown in observability output.
mcpr produces an McpMethod enum value for each recognized method. This value appears in:
- Terminal output (the MCP method column)
- SQLite storage (
mcp_method field)
- Cloud sync events
- Event bus
ProxyEvent::Request events
The classification happens at the JSON-RPC parsing layer (mcpr-protocol crate) before any routing or CSP logic runs.