JSONRPCErrorBuilder

DSL builder for constructing JSONRPCError instances.

Type Parameters

D

The type of the error's optional data field.

Example:

val error = jsonRPCError {
code = -32600
message = "Invalid Request"
data = "Missing 'method' field"
}

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
var code: Int?

The integer error code. See JSONRPCError.ErrorCodes for standard values.

Link copied to clipboard
var data: D?

Optional structured data with additional error information.

Link copied to clipboard

A short human-readable description of the error.

Functions

Link copied to clipboard

Builds a JSONRPCError from the configured properties.