Response to a request.

Fields

type:MessageType

Message type. Values: 'request', 'response', 'event', etc.

success:Bool

Outcome of the request. If true, the request was successful and the 'body' attribute may contain the result of the request. If the value is false, the attribute 'message' contains the error in short form and the 'body' may contain additional information (see 'ErrorResponse.body.error').

seq:Int

Sequence number (also known as message ID). For protocol messages of type 'request' this ID can be used to cancel the request.

request_seq:Int

Sequence number of the corresponding request.

@:optionaloptionalmessage:Null<String>

Contains error message if success == false. This raw error might be interpreted by the frontend and is not shown in the UI. Some predefined values exist. Values: 'cancelled': request was cancelled. etc.

command:String

The command requested.

@:optionaloptionalbody:Null<T>

Contains request result if success is true and optional error details if success is false.