WebSocketChatClient class

Inheritance

Constructors

WebSocketChatClient({required Uri url, String token = '', AccessTokenProvider? tokenProvider, String? participantName, List<String> protocols = const <String>['meshagent-msgpack'], bool reconnect = true, Duration reconnectInitialDelay = const Duration(seconds: 1), Duration reconnectMaxDelay = const Duration(seconds: 10), LlmAuthorizationProvider? llmAuthorizationProvider})
WebSocketChatClient.withAnonymous({Uri? authorizationUrl, bool reconnect = true, Duration reconnectInitialDelay = const Duration(seconds: 1), Duration reconnectMaxDelay = const Duration(seconds: 10), LlmAuthorizationProvider? llmAuthorizationProvider})
factory

Properties

connectionStatus → AgentConnectionStatus?
no setterinherited
deduplicateClientToolRequests → bool
finalinherited
events → Stream<AgentMessageEvent>
no setterinherited
hashCode → int
The hash code for this object.
no setterinherited
isConnected → bool
no setter
llmAuthorizationProvider → LlmAuthorizationProvider?
finalinherited
participantName → String?
final
protocols → List<String>
final
reconnect → bool
final
reconnectInitialDelay → Duration
final
reconnectMaxDelay → Duration
final
requiresAgentParticipant → bool
Whether messages must wait for a room agent participant before sending.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sessions → Iterable<ChatThreadSession>
no setterinherited
threadCreatedPendingStartMatcher → ThreadCreatedPendingStartMatcher?
finalinherited
token → String
no setter
tokenProvider → AccessTokenProvider?
final
url → Uri
final

Methods

addListener(void listener()) → void
inherited
agentParticipant() → RemoteParticipant?
inherited
emitConnectionStatus({required String status, String? message, String? reason, Duration? retryDelay}) → void
inherited
handleAgentMessage(AgentMessage message, {DateTime? createdAt, Uint8List? attachment}) → void
inherited
localParticipantId() → String?
override
localParticipantName() → String?
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
inherited
openThread(String threadPath, {bool load = true, String? sinceTurn, bool reloadIfOpen = false}) → ChatThreadSession
inherited
removeListener(void listener()) → void
inherited
removeThreadSession(String threadPath) → void
inherited
sendAgentMessage(AgentMessage message, {Uint8List? attachment}) → Future<void>
override
start() → Future<void>
override
startThread({String? messageId, required String message, required List<AgentFileContent> attachments, String? name, String? backend, String? provider, String? model, String? voice, List<String>? outputModalities, String? realtimeProtocol, String? senderName, List<ClientToolkitDescription>? clientToolkits, bool omitContent = false}) → Future<ChatThreadStartResult>
inherited
stop() → Future<void>
override
toString() → String
A string representation of this object.
inherited

Operators

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