SessionsMessage class

A message received or sent over the sessions WebSocket.

This is a thin JSON wrapper; the downstream RemoteSessionManager and convertSDKMessage decide how to interpret each type.

Constructors

SessionsMessage({required String type, required Map<String, dynamic> raw})
Create a SessionsMessage from a decoded JSON map.
const

Properties

hashCode int
The hash code for this object.
no setterinherited
message Map<String, dynamic>?
Returns the nested message object for assistant/user messages.
no setter
raw Map<String, dynamic>
The full decoded JSON payload.
final
request Map<String, dynamic>?
Returns the nested request object for control_request messages.
no setter
requestId String?
Convenience accessors for common fields.
no setter
response Map<String, dynamic>?
Returns the nested response object for control_response messages.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
type String
The message type discriminator (e.g. assistant, control_request).
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJsonString() String
Serialize back to JSON string.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited