Skip to content

ChannelFollowMessage

The message received by the ChannelFollow event.

Extends

Type parameters

Type parameterValue
K extends ConnectionTypesConnectionTypes

Constructors

new ChannelFollowMessage()

1
new ChannelFollowMessage<K>(
2
connection: K,
3
subscription: SubscriptionType<ChannelFollow, K>,
4
data: ChannelFollowEvent): ChannelFollowMessage<K>

Builds up a ChannelFollow message.

Parameters

ParameterTypeDescription
connectionKThe EventSub connection used.
subscriptionSubscriptionType<ChannelFollow, K>The subscription which trigger this message.
dataChannelFollowEventThe event data received with the subscription.

Returns

ChannelFollowMessage<K>

Overrides

BaseSubscriptionMessage.constructor

Source

twitchfy/packages/eventsub/src/structures/messages/ChannelFollow/ChannelFollowMessage.ts:33

Properties

PropertyModifierTypeDescriptionInherited from
broadcasterreadonlyBaseUser<ChannelFollow, K>The broadcaster of the channel who was followed.-
connectionreadonlyKThe EventSub connection used.BaseSubscriptionMessage.connection
followedAtreadonlyDateThe Date object when the follow occurred.-
followerreadonlyBaseUser<ChannelFollow, K>The follower who followed the channel.-
subscriptionreadonlySubscriptionType<ChannelFollow, K>The subscription which trigger this message.BaseSubscriptionMessage.subscription

Methods

checkMessageType()

1
checkMessageType<U>(type: U): this is SubscriptionMessages<K>[U]

Checks whether the message is of a certain type.

Type parameters

Type parameterValue
U extends SubscriptionTypesSubscriptionTypes

Parameters

ParameterTypeDescription
typeUThe type to check.

Returns

this is SubscriptionMessages<K>[U]

Whether the message is of the type.

Inherited from

BaseSubscriptionMessage.checkMessageType

Source

twitchfy/packages/eventsub/src/structures/messages/BaseSubscriptionMessage.ts:24