TwitchApi.Games.GetTopGames (TwitchApi v0.1.2) View Source

⛔ This module is autogenerated please do not modify manually.

Example request from twitch api docs:

descriptions:

This gets the 20 currently most-viewed games.

requests:

curl -X GET 'https://api.twitch.tv/helix/games/top'
-H'Authorization: Bearer cfabdegwdoklmawdzdo98xt2fo512y'
-H'Client-Id: uo6dggojyb8d6soh92zknwmi5ej1q2'

Example response from twitch api docs:

descriptions:

responses:

{"data":[{"id":"493057","name":"PLAYERUNKNOWN'S BATTLEGROUNDS","box_art_url":"https://static-cdn.jtvnw.net/ttv-boxart/PLAYERUNKNOWN'S BATTLEGROUNDS-{width}x{height}.jpg"},...],"pagination":{"cursor":"eyJiIjpudWxsLCJhIjp7Ik9mZnNldCI6MjB9fQ=="}}

Link to this section Summary

Types

Cursor for forward pagination: tells the server where to start fetching the next set of results, in a multi-page response. The cursor value specified here is from the pagination response field of a prior query.

Cursor for backward pagination: tells the server where to start fetching the next set of results, in a multi-page response. The cursor value specified here is from the pagination response field of a prior query.

Maximum number of objects to return. Maximum: 100. Default: 20.

Functions

Description:

Gets games sorted by number of current viewers on Twitch, most popular first.

Link to this section Types

Specs

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

Cursor for forward pagination: tells the server where to start fetching the next set of results, in a multi-page response. The cursor value specified here is from the pagination response field of a prior query.

Specs

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

Cursor for backward pagination: tells the server where to start fetching the next set of results, in a multi-page response. The cursor value specified here is from the pagination response field of a prior query.

Specs

first() :: %{first: integer()}

Maximum number of objects to return. Maximum: 100. Default: 20.

Link to this section Functions

Specs

call(after_query_param() | before() | first()) ::
  {:ok, Finch.Response.t()} | {:error, Exception.t()}

Description:

Gets games sorted by number of current viewers on Twitch, most popular first.

Required authentication:

OAuth or App Access Token required.

Required authorization: