Expand description
Error types for tower-mcp
§JSON-RPC Error Codes
Standard JSON-RPC 2.0 error codes are defined in the specification: https://www.jsonrpc.org/specification#error_object
| Code | Message | Meaning |
|---|---|---|
| -32700 | Parse error | Invalid JSON was received |
| -32600 | Invalid Request | The JSON sent is not a valid Request |
| -32601 | Method not found | The method does not exist / is not available |
| -32602 | Invalid params | Invalid method parameter(s) |
| -32603 | Internal error | Internal JSON-RPC error |
§MCP-Specific Error Codes
MCP uses the server error range (-32000 to -32099) for protocol-specific errors:
| Code | Name | Meaning |
|---|---|---|
| -32000 | ConnectionClosed | Transport connection was closed |
| -32001 | RequestTimeout | Request exceeded timeout |
| -32002 | ResourceNotFound | Resource not found |
| -32003 | AlreadySubscribed | Resource already subscribed |
| -32004 | NotSubscribed | Resource not subscribed (for unsubscribe) |
| -32005 | SessionNotFound | Session not found or expired |
| -32006 | SessionRequired | MCP-Session-Id header is required |
| -32007 | Forbidden | Access forbidden (insufficient scope) |
Structs§
- Json
RpcError - JSON-RPC error object
- Tool
Error - Tool execution error with context
Enums§
- Error
- tower-mcp error type
- Error
Code - Standard JSON-RPC error codes
- McpError
Code - MCP-specific error codes (in the -32000 to -32099 range)