TwitchApi.Entitlements.RedeemCode (TwitchApi v0.1.3) View Source

⛔ This module is autogenerated please do not modify manually.

Example request from twitch api docs:

descriptions:

requests:

curl -X POST 'https://api.twitch.tv/helix/entitlements/codes?user_id=12345&code=8CD5P-V3J92-2S6JY&code=PUN4G-HYFVP-MMFET'
-H'Authorization: Bearer cfabdegwdoklmawdzdo98xt2fo512y'
-H'Client-Id: uo6dggojyb8d6soh92zknwmi5ej1q2'

Example response from twitch api docs:

descriptions:

responses:

{"data":[{"code":"8CD5P-V3J92-2S6JY","status":"SUCCESSFULLY_REDEEMED"},{"code":"PUN4G-HYFVP-MMFET","status":"ALREADY_CLAIMED"}]}

Link to this section Summary

Types

The redemption code to redeem. To redeem multiple codes, include this parameter for each redemption code. For example, code=1234&code=5678. You may specify a maximum of 20 codes.

The ID of the user that owns the redemption code to redeem.

Functions

Description:

Redeems one or more redemption codes.

Link to this section Types

Specs

code() :: %{code: String.t()}

The redemption code to redeem. To redeem multiple codes, include this parameter for each redemption code. For example, code=1234&code=5678. You may specify a maximum of 20 codes.

Specs

user_id() :: %{user_id: String.t()}

The ID of the user that owns the redemption code to redeem.

Link to this section Functions

Specs

call(code() | user_id()) :: {:ok, Finch.Response.t()} | {:error, Exception.t()}

Description:

Redeems one or more redemption codes.

Required authentication:

Requires an App access token. Only client IDs approved by Twitch may redeem codes on behalf of any Twitch user account.

Required authorization: