UNPKG

@twurple/eventsub-base

Version:

Base for the other Twurple EventSub packages

38 lines (37 loc) 1.47 kB
import { __decorate } from "tslib"; import { rawDataSymbol, rtfm } from '@twurple/common'; import { EventSubChannelBaseModerationEvent } from './EventSubChannelBaseModerationEvent.js'; /** * An EventSub event representing a moderator untimming out a user in another channel during a shared chat session. */ let EventSubChannelSharedChatUntimeoutModerationEvent = class EventSubChannelSharedChatUntimeoutModerationEvent extends EventSubChannelBaseModerationEvent { moderationAction = 'shared_chat_untimeout'; /** * The ID of the user being untimed out. */ get userId() { return this[rawDataSymbol].shared_chat_untimeout.user_id; } /** * The name of the user being untimed out. */ get userName() { return this[rawDataSymbol].shared_chat_untimeout.user_login; } /** * The display name of the user being untimed out. */ get userDisplayName() { return this[rawDataSymbol].shared_chat_untimeout.user_name; } /** * Gets more information about the user. */ async getUser() { return await this._client.users.getUserById(this[rawDataSymbol].shared_chat_untimeout.user_id); } }; EventSubChannelSharedChatUntimeoutModerationEvent = __decorate([ rtfm('eventsub-base', 'EventSubChannelSharedChatUntimeoutModerationEvent', 'broadcasterId') ], EventSubChannelSharedChatUntimeoutModerationEvent); export { EventSubChannelSharedChatUntimeoutModerationEvent };