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

HelixUser

A Twitch user.

Overview

Properties

broadcasterType

Type: string

The type of the user.

creationDate

Type: Date

The date when the user was created, i.e. when they registered on Twitch.

description

Type: string

The description of the user.

displayName

Type: string

The display name of the user.

id

Type: string

The ID of the user.

name

Type: string

The name of the user.

offlinePlaceholderUrl

Type: string

The URL to the offline video placeholder of the user.

profilePictureUrl

Type: string

The URL to the profile picture of the user.

type

Type: HelixUserType

The type of the user.

views

Type: number

The total number of views of the user's channel.

Methods

follow()

async

Follows the broadcaster.

Return type: UserFollow

follows(broadcaster)

async

Checks whether the user is following the given broadcaster.

ParameterTypeDescription
broadcasterUserIdResolvable

The broadcaster to check the user's follow to.

Return type: boolean

getFollowFrom(user)

async

Retrieves the follow data of the given user to the broadcaster.

ParameterTypeDescription
userUserIdResolvable

The user to check the follow from.

Return type: HelixFollow | null

getFollows()

async

Retrieves a list of broadcasters the user follows.

getFollowTo(broadcaster)

async

Retrieves the follow data of the user to the given broadcaster.

ParameterTypeDescription
broadcasterUserIdResolvable

The broadcaster to check the follow to.

Return type: HelixFollow | null

getStream()

async

Retrieves the channel's stream data.

Return type: HelixStream | null

getSubscriptionTo(broadcaster)

async

Retrieves the subscription data for the user to the given broadcaster, or `null` if the user is not subscribed.

ParameterTypeDescription
broadcasterUserIdResolvable

The broadcaster you want to get the subscription data for.

Return type: HelixSubscription | null

isFollowedBy(user)

async

Checks whether the given user is following the broadcaster.

ParameterTypeDescription
userUserIdResolvable

The user to check the broadcaster's follow from.

Return type: boolean

isSubscribedTo(broadcaster)

async

Checks whether the user is subscribed to the given broadcaster.

ParameterTypeDescription
broadcasterUserIdResolvable

The broadcaster you want to check the subscription for.

Return type: boolean

unfollow()

async

Unfollows the broadcaster.

Return type: void