Skip to content

Channel

Represents a Twitch channel.

Extends

Type parameters

Type parameter
T extends EventSubConnection

Constructors

new Channel()

1
new Channel<T>(chatbot: ChatBot<T>, data: Channel): Channel<T>

Creates a new instance of the channel.

Parameters

ParameterTypeDescription
chatbotChatBot<T>The current instance of the chatbot.
dataChannelThe data of the channel returned from the API.

Returns

Channel<T>

Overrides

BaseChannel.constructor

Source

twitchfy/packages/chatbot/src/structures/Channel.ts:43

Properties

PropertyModifierTypeDescriptionInherited from
broadcasterreadonlyBaseUser<T>The broadcaster of the channel.BaseChannel.broadcaster
chatbotreadonlyChatBot<T>The current instance of the chatbot.BaseChannel.chatbot
chatroomreadonlyChatRoom<T>The chatroom of the channel.BaseChannel.chatroom
classificationLabelsreadonlystring[]The classification labels of the channel.-
gamereadonlyGameThe game which was currently set into the channel.-
idreadonlystringThe id of the channel.BaseChannel.id
isBrandedContentreadonlybooleanWhether the channel has branded content.-
tagsreadonlystring[]The tags of the channel.-

Accessors

bans

1
get bans(): BanManager<T>

The chatroom bans manager. See BanManager.

Returns

BanManager<T>

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:51


broadcasterId

1
get broadcasterId(): string

The id of the broadcaster who owns the channel.

Returns

string

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:37


chatroomId

1
get chatroomId(): string

The id of the chatroom of the channel.

Returns

string

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:44


language

1
get language(): string

The language that was set to the channel.

Returns

string

Source

twitchfy/packages/chatbot/src/structures/Channel.ts:63


messages

1
get messages(): MessageManager<T>

The chatroom messages manager. See MessageManager.

Returns

MessageManager<T>

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:65


timeouts

1
get timeouts(): TimeoutManager<T>

The chatroom timeouts manager. See TimeoutManager.

Returns

TimeoutManager<T>

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:58


title

1
get title(): null | string

The title of the channel. If it was never set, it will return a nullish value.

Returns

null | string

Source

twitchfy/packages/chatbot/src/structures/Channel.ts:56


warns

1
get warns(): WarnsManager<T>

The chatroom warns manager. See WarnsManager.

Returns

WarnsManager<T>

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:73

Methods

clips()

1
clips(options?: Omit<GetClipsOptions<true>, "broadcaster_id">): Promise<null | Clip<T>[]>

Fetches the clips of the channel from the API.

Parameters

ParameterTypeDescription
options?Omit<GetClipsOptions<true>, "broadcaster_id">The options to fetch the clips.

Returns

Promise<null | Clip<T>[]>

An array containing the clips of the channel.

Inherited from

BaseChannel.clips

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:98


emotes()

1
emotes(): Promise<Collection<string, ChannelEmote<T>>>

Fetches all the emotes of this channel.

Returns

Promise<Collection<string, ChannelEmote<T>>>

The a Collection containing all the emotes of the channel.

Inherited from

BaseChannel.emotes

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:80


fetch()

1
fetch(): Promise<Channel<T>>

Fetches the current channel from the API.

Returns

Promise<Channel<T>>

The fetched channel from the API.

Inherited from

BaseChannel.fetch

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:111


isModerator()

1
isModerator(): Promise<boolean>

Returns

Promise<boolean>

Inherited from

BaseChannel.isModerator

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:103


stream()

1
stream(): Promise<null | Stream<T>>

Fetches the current stream of the channel from the API.

Returns

Promise<null | Stream<T>>

The current stream or null if the stream is offline.

Inherited from

BaseChannel.stream

Source

twitchfy/packages/chatbot/src/structures/BaseChannel.ts:89