Twitch API endpoint
Returns the top games/categories site-wide, ranked by total current viewers across all live streams under each one.
/twitch/top-gamesReturns the top games/categories site-wide, ranked by total current viewers across all live streams under each one: game name, box art, total viewer count, and tags.
Query parameters:
limit (optional) — number of games to return. Defaults to 20,
clamped to a maximum of 100.Notable response behavior:
games is ordered by viewers_count descending — Twitch's own default
directory sort, matching the unfiltered twitch.tv/directory page.viewers_count is the sum across every live stream currently under
that game, not a single stream's count — use
/twitch/streams for per-stream viewer counts
within a game.| Field | Filled in, of 20 checked | Values in the sample |
|---|---|---|
| id | 20 | |
| slug | 20 | |
| name | 20 | |
| box_art_url | 20 | static-cdn.jtvnw.net |
| viewers_count | 20 | 34,669 to 434,008, median 57,564 |
| tags | 19 | median 4 entries |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| limit | integer | No | Number of games to return (default 20, max 100) | 20 | |
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/twitch/top-games?limit=10" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"count": 20,
"games": [
{
"id": "29595",
"slug": "dota-2",
"name": "Dota 2",
"box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/29595-285x380.jpg",
"viewers_count": 390201,
"tags": [
"Strategy",
"MOBA",
"Action"
]
},
{
"id": "21779",
"slug": "league-of-legends",
"name": "League of Legends",
"box_art_url": "https://static-cdn.jtvnw.net/ttv-boxart/21779-285x380.jpg",
"viewers_count": 206554,
"tags": [
"RPG",
"Strategy",
"MOBA",
"Action"
]
}
]
}
}Request schema
No body schema
Response schema
#/definitions/twitch.topGamesResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | twitch.TopGamesResponse | No | ||||
| data.count | integer | No | 20 | |||
| data.games | array | No | ||||
| data.games[].box_art_url | string | No | ||||
| data.games[].id | string | No | ||||
| data.games[].name | string | No | Dota 2 | |||
| data.games[].slug | string | No | dota-2 | |||
| data.games[].tags | array | No | ||||
| data.games[].viewers_count | integer | No | 390201 | |||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 429 | Too Many Requests | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/twitch/top-games?limit=10" \
-H "x-api-key: $CRAWLORA_API_KEY"