Open awsr opened 3 years ago
Works fine/as expected here
Calling: https://api.twitch.tv/helix/videos?id=1149015477
And ran in my video watching website/tool
Very strange. The only difference that I can see is that I'm using the Client Credentials OAuth flow rather than the Implicit OAuth flow.
I don't see anything in the Get Videos endpoint that would explain this difference in returned data.
Retested using an App Access Token and confirmed the bug.
For Clarity:
Brief description
Get Videos API doesn't return muted segments when authenticated via App Access Token
How to reproduce
Call https://api.twitch.tv/helix/videos?id=1149015477
with a App Access token
{
"data": [
{
"id": "1149015477",
"stream_id": "43697288365",
"user_id": "16678946",
"user_login": "coestar",
"user_name": "Coestar",
"title": "Starting Ori +merch (#StreamADay 2842)",
"description": "",
"created_at": "2021-09-15T00:57:11Z",
"published_at": "2021-09-15T00:57:11Z",
"url": "https://www.twitch.tv/videos/1149015477",
"thumbnail_url": "https://static-cdn.jtvnw.net/cf_vods/d1m7jfoe9zdc1j/96a37e7c9382cbd229e4_coestar_43697288365_1631667423//thumb/thumb0-%{width}x%{height}.jpg",
"viewable": "public",
"view_count": 903,
"language": "en",
"type": "archive",
"duration": "3h4m44s",
"muted_segments": null
}
],
"pagination": {}
}
Expected behavior
{
"data": [
{
"id": "1149015477",
"stream_id": "43697288365",
"user_id": "16678946",
"user_login": "coestar",
"user_name": "Coestar",
"title": "Starting Ori +merch (#StreamADay 2842)",
"description": "",
"created_at": "2021-09-15T00:57:11Z",
"published_at": "2021-09-15T00:57:11Z",
"url": "https://www.twitch.tv/videos/1149015477",
"thumbnail_url": "https://static-cdn.jtvnw.net/cf_vods/d1m7jfoe9zdc1j/96a37e7c9382cbd229e4_coestar_43697288365_1631667423//thumb/thumb0-%{width}x%{height}.jpg",
"viewable": "public",
"view_count": 903,
"language": "en",
"type": "archive",
"duration": "3h4m44s",
"muted_segments": [
{
"duration": 368,
"offset": 2940
}
]
}
],
"pagination": {}
}
Checked again with a recent video and confirmed that the issue still occurs.
Brief description
The
muted_segments
field for videos does not include any data even if the video does have muted segments. The old v5 API, however, does show this information.How to reproduce
Perform a lookup on a video that has muted segments using the
https://api.twitch.tv/helix/videos
endpoint and compare themuted_segments
field to the one returned by thehttps://api.twitch.tv/kraken/videos/<video ID>
endpoint.Expected behavior
API response should show correct information.
Screenshots
Additional context or questions
Using video ID
1149015477
as an example, the Twitch API returnsnull
for this field but the v5 API returns[{duration: 368, offset: 2940}]
.