TwitchApi.Entitlements.GetCodeStatus (TwitchApi v0.1.2) View Source
⛔ This module is autogenerated please do not modify manually.
Example request from twitch api docs:
descriptions:
requests:
curl -X GET 'https://api.twitch.tv/helix/entitlements/codes?code=KUHXV-4GXYP-AKAKK&code=XZDDZ-5SIQR-RT5M3&user_id=156900877'
-H'Authorization: Bearer cfabdegwdoklmawdzdo98xt2fo512y'
-H'Client-Id: uo6dggojyb8d6soh92zknwmi5ej1q2'
Example response from twitch api docs:
descriptions:
responses:
{"data":[{"code":"KUHXV-4GXYP-AKAKK","status":"UNUSED"},{"code":"XZDDZ-5SIQR-RT5M3","status":"ALREADY_CLAIMED"}]}
Link to this section Summary
Types
The code to get the status of. Repeat this query parameter additional times to get the status of multiple codes.Ex: ?code=code1&code=code21-20 code parameters are allowed.
Represents a numeric Twitch user ID.The user account which is going to receive the entitlement associated with the code.
Link to this section Types
Specs
code() :: %{code: String.t()}
The code to get the status of. Repeat this query parameter additional times to get the status of multiple codes.Ex: ?code=code1&code=code21-20 code parameters are allowed.
Specs
user_id() :: %{user_id: integer()}
Represents a numeric Twitch user ID.The user account which is going to receive the entitlement associated with the code.
Link to this section Functions
Specs
call(code() | user_id()) :: {:ok, Finch.Response.t()} | {:error, Exception.t()}
Description:
Gets the status of one or more provided codes. This API requires that the caller is an authenticated Twitch user. The API is throttled to one request per second per authenticated user.
Required authentication:
Access is controlled via an app access token on the calling service. The client ID associated with the app access token must be approved by Twitch as part of a contracted arrangement.
Required authorization:
Callers with an app access token are authorized to redeem codes on behalf of any Twitch user account.