Overview
Properties
Properties
type
Type: HelixUserTypeThe type of a user.
Aliased type: "staff" | "admin" | "global_mod" | ""
The type of a user.
Aliased type: "staff" | "admin" | "global_mod" | ""
The type of the user.
Methods
follows(broadcaster)
asyncChecks whether the user is following the given broadcaster.
This requires user authentication.
For broadcaster authentication, you can use isFollowedBy
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
broadcaster | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The broadcaster to check the user's follow to. |
getChannelFollower(user)
asyncGets the follow data of the given user to the broadcaster, or null
if the user doesn't follow the broadcaster.
This requires broadcaster authentication.
For user authentication, you can use getFollowedChannel
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
user | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The user to check the follow from. |
getChannelFollowers()
asyncGets a list of users that follow the broadcaster.
getFollowedChannel(broadcaster)
asyncGets the follow data of the user to the given broadcaster, or null
if the user doesn't follow the broadcaster.
This requires user authentication.
For broadcaster authentication, you can use getChannelFollower
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
broadcaster | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The broadcaster to check the follow to. |
getFollowedChannels()
asyncGets a list of broadcasters the user follows.
getSubscriber(user)
asyncGets the subscription data for the given user to the broadcaster, or null
if the user is not subscribed.
This requires broadcaster authentication.
For user authentication, you can use getSubscriptionTo
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
user | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The user you want to get the subscription data for. |
getSubscriptionTo(broadcaster)
asyncGets the subscription data for the user to the given broadcaster, or null
if the user is not subscribed.
This requires user authentication.
For broadcaster authentication, you can use getSubscriber
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
broadcaster | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The broadcaster you want to get the subscription data for. |
hasSubscriber(user)
asyncChecks whether the given user is subscribed to the broadcaster.
This requires broadcaster authentication.
For user authentication, you can use isSubscribedTo
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
user | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The user you want to check the subscription for. |
isFollowedBy(user)
asyncChecks whether the given user is following the broadcaster.
This requires broadcaster authentication.
For user authentication, you can use follows
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
user | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The user to check the broadcaster's follow from. |
isSubscribedTo(broadcaster)
asyncChecks whether the user is subscribed to the given broadcaster.
This requires user authentication.
For broadcaster authentication, you can use hasSubscriber
while switching this
and the parameter.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
broadcaster | UserIdResolvable A user ID or a user or channel object. This is not a user name. Please use HelixUserApi#getUserByName to fetch a user object by name. Aliased type: string | number | UserIdResolvableType | none | The broadcaster you want to check the subscription for. |
setDescription(description)
asyncChanges the description of the user.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
description | string | none | The new description. |