Skip to content

ChatBotBanManager

The ban manager of the chatbot.

Extends

  • Base<T>

Type parameters

Type parameter
T extends EventSubConnection

Constructors

new ChatBotBanManager()

1
new ChatBotBanManager<T>(chatbot: ChatBot<T>): ChatBotBanManager<T>

Creates a new instance of the ban manager.

Parameters

ParameterTypeDescription
chatbotChatBot<T>The current instance of the chatbot.

Returns

ChatBotBanManager<T>

Overrides

Base<T>.constructor

Source

twitchfy/packages/chatbot/src/structures/managers/ChatBotBanManager.ts:16

Properties

PropertyModifierTypeDescriptionInherited from
chatbotreadonlyChatBot<T>The current instance of the chatbot.Base.chatbot

Methods

add()

1
add(chatroomId: string, options: BanOptions): Promise<Ban<T>>

Ban a specific user.

Parameters

ParameterTypeDescription
chatroomIdstringThe id of the chatroom where the user will be banned.
optionsBanOptionsThe options required for banning an user. See BanOptions.

Returns

Promise<Ban<T>>

A class representation of the ban. See Ban.

Source

twitchfy/packages/chatbot/src/structures/managers/ChatBotBanManager.ts:26


delete()

1
delete(chatroomId: string, userId: string): Promise<void>

Deletes the ban of a specific user.

Parameters

ParameterTypeDescription
chatroomIdstringThe id of the chatroom where the user will be unbanned.
userIdstringThe id of the user to unban.

Returns

Promise<void>

Source

twitchfy/packages/chatbot/src/structures/managers/ChatBotBanManager.ts:36