RPCError

data class RPCError(val code: Int, val message: String, val data: JsonElement? = null)(source)

Error information for a failed JSON-RPC request.

Constructors

Link copied to clipboard
constructor(code: Int, message: String, data: JsonElement? = null)

Types

Link copied to clipboard
object ErrorCode

Standard JSON-RPC 2.0 and MCP SDK error codes.

Properties

Link copied to clipboard
val code: Int

The error type that occurred. A number indicating the error category. See standard JSON-RPC 2.0 error codes:

Link copied to clipboard

Additional information about the error. The value of this member is defined by the sender (e.g., detailed error information, nested errors, etc.).

Link copied to clipboard

A short description of the error. The message SHOULD be limited to a concise single sentence.