ChannelAdBreakBeginMessage
The message received by the ChannelAdBreakBegin event.
Extends
BaseSubscriptionMessage
<SubscriptionTypes.ChannelAdBreakBegin
,K
>
Type parameters
Type parameter | Value |
---|---|
K extends ConnectionTypes | ConnectionTypes |
Constructors
new ChannelAdBreakBeginMessage()
Builds up a ChannelAdBreakBegin message.
Parameters
Parameter | Type | Description |
---|---|---|
connection | K | The EventSub connection used. |
subscription | SubscriptionType <ChannelAdBreakBegin , K > | The subscription which trigger this message. |
data | ChannelAdBreakBeginEvent | The event data received with the subscription. |
Returns
Overrides
BaseSubscriptionMessage
.constructor
Source
Properties
Property | Modifier | Type | Description | Inherited from |
---|---|---|---|---|
broadcaster | readonly | BaseUser <ChannelAdBreakBegin , K > | The broadcaster of the channel where the ad was begun. | - |
connection | readonly | K | The EventSub connection used. | BaseSubscriptionMessage .connection |
duration | readonly | number | The duration in seconds of the ad break. | - |
isAutomatic | readonly | boolean | Whether the ad break was automatically triggered or was manually triggered by the broadcaster. | - |
requester | readonly | BaseUser <ChannelAdBreakBegin , K > | The user who requested the ad break. If the ad break was automatically triggered, this field is the broadcaster. | - |
startedAt | readonly | Date | The Date object of when the ad break started. | - |
subscription | readonly | SubscriptionType <ChannelAdBreakBegin , K > | The subscription which trigger this message. | BaseSubscriptionMessage .subscription |
Methods
checkMessageType()
Checks whether the message is of a certain type.
Type parameters
Type parameter | Value |
---|---|
U extends SubscriptionTypes | SubscriptionTypes |
Parameters
Parameter | Type | Description |
---|---|---|
type | U | The 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