twitcheasy-twitch-bottwitch-authtwitch-auth-tmitwitch-chat-clienttwitch-eventsubtwitch-pubsub-clienttwitch-webhooks

TwitchPrivateMessage

An IRC PRIVMSG, with easy accessors for commonly used data from its tags.

Overview

Properties

bits

Type: number

The number of bits cheered with the message.

channelId

Type: string | null

The ID of the channel the message is in.

emoteOffsets

Type: Map<string, Array<string>>

The offsets of emote usages in the message.

id

Type: string

The ID of the message.

isCheer

Type: boolean

Whether the message is a cheer.

userInfo

Type: ChatUser

Info about the user that send the message, like their user ID and their status in the current channel.

Methods

parseEmotes()

Parses the message, separating text from emote usages.

Return type: Array< >

parseEmotesAndBits(cheermotes)

Parses the message, separating text from emote usages and cheers.

Parameter Type Required Default Description
cheermotes BaseCheermoteList none

A list of cheermotes

Return type: Array< >