ConsoleChat
chat.ConsoleChat
A simple, console-based Chat wrapper for testing and debugging applications. Only available in Node.js.
Hierarchy
↳ ConsoleChat
Constructors
constructor
+ new ConsoleChat(account
: Account, conversation?
: Conversation<Record<string, unknown>, Record<string, unknown>>, syncMode?
: boolean): ConsoleChat
Parameters:
Name | Type |
---|---|
account | Account |
conversation? | Conversation<Record<string, unknown>, Record<string, unknown>> |
syncMode? | boolean |
Returns: ConsoleChat
Overrides: Chat
Properties
account
• Protected
account: Account
Methods
close
▸ close(): Promise<void>
Close the chat, notifying the application.
Returns: Promise<void>
Inherited from: Chat
sendText
▸ sendText(text
: string): Promise<void>
Send some text to the application.
Parameters:
Name | Type |
---|---|
text | string |
Returns: Promise<void>
Inherited from: Chat
sendTextAndReceiveResponse
▸ sendTextAndReceiveResponse(text
: string): Promise<string>
Send some text and wait for response
Parameters:
Name | Type |
---|---|
text | string |
Returns: Promise<string>
Inherited from: Chat