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

HelixChannelPointsApi

Overview

Methods

createCustomReward(broadcaster, data)

async

Creates a new custom reward.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to create the reward for.

data HelixCreateCustomRewardData none

The reward data.

data.autoFulfill boolean none

Whether the redemption should automatically set its status to fulfilled.

data.backgroundColor string none

The hex code of the background color of the reward.

data.cost number none

The channel points cost of the reward.

data.globalCooldown number | null none

The cooldown between two redemptions of the reward, in seconds. 0 or null means no cooldown.

data.isEnabled boolean none

Whether the reward is enabled (shown to users).

data.maxRedemptionsPerStream number | null none

The maximum number of redemptions of the reward per stream. 0 or null means no limit.

data.maxRedemptionsPerUserPerStream number | null none

The maximum number of redemptions of the reward per stream for each user. 0 or null means no limit.

data.prompt string none

The prompt shown to users when redeeming the reward.

data.title string none

The title of the reward.

data.userInputRequired boolean none

Whether the reward requires user input to be redeemed.

Return type: HelixCustomReward

deleteCustomReward(broadcaster, rewardId)

async

Deletes a custom reward.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to delete the reward for.

rewardId string none

The ID of the reward.

Return type: void

getCustomRewardById(broadcaster, rewardId)

async

Retrieves a custom reward by ID.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the reward for.

rewardId string none

The ID of the reward.

Return type: HelixCustomReward | null

getCustomRewards(broadcaster, onlyManageable)

async

Retrieves all custom rewards for the given broadcaster.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the rewards for.

onlyManageable boolean none

Whether to only retrieve rewards that can be managed by the API.

Return type: Array<HelixCustomReward>

getCustomRewardsByIds(broadcaster, rewardIds)

async

Retrieves custom rewards by IDs.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the rewards for.

rewardIds Array<string> none

The IDs of the rewards.

Return type: Array<HelixCustomReward>

getRedemptionById(broadcaster, rewardId, redemptionId)

async

Retrieves a custom reward redemption by ID.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the redemption for.

rewardId string none

The ID of the reward.

redemptionId string none

The ID of the redemption.

Return type: HelixCustomRewardRedemption | null

getRedemptionsByIds(broadcaster, rewardId, redemptionIds)

async

Retrieves custom reward redemptions by IDs.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the redemptions for.

rewardId string none

The ID of the reward.

redemptionIds Array<string> none

The IDs of the redemptions.

Return type: Array<HelixCustomRewardRedemption>

getRedemptionsForBroadcaster(broadcaster, rewardId, status, filter)

async

Retrieves custom reward redemptions for the given broadcaster.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the redemptions for.

rewardId string none

The ID of the reward.

status
HelixCustomRewardRedemptionStatus

The possible statuses of a custom Channel Points reward redemption.

Aliased type: "UNFULFILLED" |

HelixCustomRewardRedemptionTargetStatus

The possible statuses of a custom Channel Points reward redemption you can set.

Aliased type: "FULFILLED" | "CANCELED"

none

The status of the redemptions to retrieve.

filter HelixPaginatedCustomRewardRedemptionFilter none
filter.after string none

A cursor to get the following page of.

filter.limit string none

The number of results per page.

filter.newestFirst boolean none

Whether to put the newest redemptions first.

Oldest redemptions are shown first by default.

getRedemptionsForBroadcasterPaginated(broadcaster, rewardId, status, filter)

Creates a paginator for custom reward redemptions for the given broadcaster.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the redemptions for.

rewardId string none

The ID of the reward.

status
HelixCustomRewardRedemptionStatus

The possible statuses of a custom Channel Points reward redemption.

Aliased type: "UNFULFILLED" |

HelixCustomRewardRedemptionTargetStatus

The possible statuses of a custom Channel Points reward redemption you can set.

Aliased type: "FULFILLED" | "CANCELED"

none

The status of the redemptions to retrieve.

filter HelixCustomRewardRedemptionFilter none
filter.newestFirst boolean none

Whether to put the newest redemptions first.

Oldest redemptions are shown first by default.

Return type: HelixPaginatedRequest<HelixCustomRewardRedemptionData, HelixCustomRewardRedemption>

updateCustomReward(broadcaster, rewardId, data)

async

Updates a custom reward.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to update the reward for.

rewardId string none

The ID of the reward.

data HelixUpdateCustomRewardData none

The reward data.

Return type: HelixCustomReward

updateRedemptionStatusByIds(broadcaster, rewardId, redemptionIds, status)

async

Updates the status of the given redemptions by IDs.

Parameter Type Required Default Description
broadcaster UserIdResolvable none

The broadcaster to retrieve the redemptions for.

rewardId string none

The ID of the reward.

redemptionIds Array<string> none

The IDs of the redemptions to update.

status
HelixCustomRewardRedemptionTargetStatus

The possible statuses of a custom Channel Points reward redemption you can set.

Aliased type: "FULFILLED" | "CANCELED"

none

The status to set for the redemptions.

Return type: Array<HelixCustomRewardRedemption>