Skip to content

@mastondzn/dank-twitch-irc / UsernoticeMessage

Class: UsernoticeMessage

Extends

Constructors

new UsernoticeMessage(message)

new UsernoticeMessage(message): UsernoticeMessage

Parameters

message: IRCMessageData

Returns

UsernoticeMessage

Overrides

ChannelIRCMessage.constructor

Source

src/message/twitch-types/usernotice.ts:318

Properties

badgeInfo

readonly badgeInfo: TwitchBadgesList

Source

src/message/twitch-types/usernotice.ts:267


badgeInfoRaw

readonly badgeInfoRaw: string

Source

src/message/twitch-types/usernotice.ts:268


badges

readonly badges: TwitchBadgesList

Source

src/message/twitch-types/usernotice.ts:270


badgesRaw

readonly badgesRaw: string

Source

src/message/twitch-types/usernotice.ts:271


bits

readonly bits: undefined | number

Source

src/message/twitch-types/usernotice.ts:273


bitsRaw

readonly bitsRaw: undefined | string

Source

src/message/twitch-types/usernotice.ts:274


channelID

readonly channelID: string

Source

src/message/twitch-types/usernotice.ts:256


channelName

readonly channelName: string

Inherited from

ChannelIRCMessage.channelName

Source

src/message/irc/channel-irc-message.ts:35


color

readonly color: undefined | Color

Source

src/message/twitch-types/usernotice.ts:276


colorRaw

readonly colorRaw: string

Source

src/message/twitch-types/usernotice.ts:277


displayName

readonly displayName: string

Source

src/message/twitch-types/usernotice.ts:279


emotes

readonly emotes: TwitchEmoteList

Source

src/message/twitch-types/usernotice.ts:281


emotesRaw

readonly emotesRaw: string

Source

src/message/twitch-types/usernotice.ts:282


eventParams

readonly eventParams: EventParameters

Source

src/message/twitch-types/usernotice.ts:316


flags

readonly flags: undefined | TwitchFlagList

Can be an array of Twitch AutoMod flagged words, for use in moderation and/or filtering purposes.

If the flags tag is missing or of a unparseable format, this will be undefined. This is unlike most other attributes which when missing or malformed will fail the message parsing. However since this attribute is completely undocumented we cannot rely on the flags tag being stable, so this soft fallback is used instead. While it will be a major version release if this attribute changes format in dank-twitch-irc, using this is still at your own risk since it may suddenly contain unexpected data or turn undefined one day as Twitch changes something. In short: Use at your own risk and make sure your implementation can handle the case where this is undefined.

Source

src/message/twitch-types/usernotice.ts:295


flagsRaw

readonly flagsRaw: undefined | string

Twitch AutoMod raw flags string.

If the flags tag is missing or of a unparseable format, this will be undefined. This is unlike most other attributes which when missing or malformed will fail the message parsing. However since this attribute is completely undocumented we cannot rely on the flags tag being stable, so this soft fallback is used instead. In short, ensure your implementation can handle the case where this is undefined or is in a format you don't expect.

Source

src/message/twitch-types/usernotice.ts:306


ircCommand

readonly ircCommand: string

The parser ensures this is always uppercase

Inherited from

ChannelIRCMessage.ircCommand

Source

src/message/irc/irc-message.ts:28


ircParameters

readonly ircParameters: string[]

Inherited from

ChannelIRCMessage.ircParameters

Source

src/message/irc/irc-message.ts:29


ircPrefix

readonly ircPrefix: undefined | IRCMessagePrefix

Inherited from

ChannelIRCMessage.ircPrefix

Source

src/message/irc/irc-message.ts:23


ircPrefixRaw

readonly ircPrefixRaw: undefined | string

Inherited from

ChannelIRCMessage.ircPrefixRaw

Source

src/message/irc/irc-message.ts:22


ircTags

readonly ircTags: IRCMessageTags

Inherited from

ChannelIRCMessage.ircTags

Source

src/message/irc/irc-message.ts:30


isMod

readonly isMod: boolean

Source

src/message/twitch-types/usernotice.ts:310


isModRaw

readonly isModRaw: string

Source

src/message/twitch-types/usernotice.ts:311


messageID

readonly messageID: string

Source

src/message/twitch-types/usernotice.ts:308


messageText

readonly messageText: undefined | string

Source

src/message/twitch-types/usernotice.ts:258


messageTypeID

readonly messageTypeID: string

sub, resub, subgift, etc...

Source

src/message/twitch-types/usernotice.ts:262


rawSource

readonly rawSource: string

Inherited from

ChannelIRCMessage.rawSource

Source

src/message/irc/irc-message.ts:20


senderUserID

readonly senderUserID: string

Source

src/message/twitch-types/usernotice.ts:265


senderUsername

readonly senderUsername: string

Source

src/message/twitch-types/usernotice.ts:264


serverTimestamp

readonly serverTimestamp: Date

Source

src/message/twitch-types/usernotice.ts:313


serverTimestampRaw

readonly serverTimestampRaw: string

Source

src/message/twitch-types/usernotice.ts:314


systemMessage

readonly systemMessage: string

Source

src/message/twitch-types/usernotice.ts:259

Methods

isAnnouncement()

isAnnouncement(): this is AnnouncementUsernoticeMessage

Returns

this is AnnouncementUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:414


isAnonGiftPaidUpgrade()

isAnonGiftPaidUpgrade(): this is AnonGiftPaidUpgradeUsernoticeMessage

Returns

this is AnonGiftPaidUpgradeUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:398


isAnonSubgift()

isAnonSubgift(): this is AnonSubgiftUsernoticeMessage

Returns

this is AnonSubgiftUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:394


isBitsBadgeTier()

isBitsBadgeTier(): this is BitsBadgeTierUsernoticeMessage

Returns

this is BitsBadgeTierUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:410


isCheer()

isCheer(): this is CheerUsernoticeMessage

Returns

this is CheerUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:370


isGiftPaidUpgrade()

isGiftPaidUpgrade(): this is GiftPaidUpgradeUsernoticeMessage

Returns

this is GiftPaidUpgradeUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:402


isMassSubgift()

isMassSubgift(): this is MassSubgiftParameters

Returns

this is MassSubgiftParameters

Source

src/message/twitch-types/usernotice.ts:390


isRaid()

isRaid(): this is RaidUsernoticeMessage

Returns

this is RaidUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:382


isResub()

isResub(): this is ResubUsernoticeMessage

Returns

this is ResubUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:378


isRitual()

isRitual(): this is RitualUsernoticeMessage

Returns

this is RitualUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:406


isSub()

isSub(): this is SubUsernoticeMessage

Returns

this is SubUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:374


isSubgift()

isSubgift(): this is SubgiftUsernoticeMessage

Returns

this is SubgiftUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:386


isViewerMilestone()

isViewerMilestone(): this is ViewerMilestoneUsernoticeMessage

Returns

this is ViewerMilestoneUsernoticeMessage

Source

src/message/twitch-types/usernotice.ts:418