BaseMessage
The base class for a message.
Extends
Base
<T
>
Extended by
Type parameters
Type parameter |
---|
T extends EventSubConnection |
Constructors
new BaseMessage()
Creates a new instance of the base message.
Parameters
Parameter | Type | Description |
---|---|---|
chatbot | ChatBot <T > | The current instance of the chatbot. |
data | BaseMessageData | The base data of the message. |
Returns
BaseMessage
<T
>
Overrides
Base<T>.constructor
Source
twitchfy/packages/chatbot/src/structures/BaseMessage.ts:36
Properties
Property | Modifier | Type | Description | Inherited from |
---|---|---|---|---|
author | readonly | BaseUser <T > | The author of the message. | - |
chatbot | readonly | ChatBot <T > | The current instance of the chatbot. | Base.chatbot |
content | readonly | null | string | The content of the message. | - |
id | readonly | string | The id of the message. | - |
Accessors
chatroomId
The Id of the chatroom where the message was sent.
Returns
string
Source
twitchfy/packages/chatbot/src/structures/BaseMessage.ts:64
self
Whether the message was sent by the chatbot.
Returns
boolean
Source
twitchfy/packages/chatbot/src/structures/BaseMessage.ts:71
Methods
delete()
Deletes the message from the chatroom.
Returns
Promise
<void
>
Source
twitchfy/packages/chatbot/src/structures/BaseMessage.ts:48
reply()
Replies to the message.
Parameters
Parameter | Type | Description |
---|---|---|
message | string | The message to reply with. |
Returns
Promise
<BaseMessage
<T
>>
The message that was sent as a reply.