Quantcast
Channel: Active questions tagged youtube-api - Stack Overflow
Viewing all articles
Browse latest Browse all 3831

How to get livestream chat messages from YouTube? It looks like it's broken

$
0
0

I read the documentation page very attentively, but it won't work.

I'm trying to fetch posts from a stream, but I keep getting an error that the pageToken is invalid. Although this parameter is optional and can only be obtained after receiving a list of messages.

Documentation page

It is not working even on documentation page. To check - you can use 4xDzrJKXOOY id. Here is query:

curl \'https://youtube.googleapis.com/youtube/v3/liveChat/messages?liveChatId=4xDzrJKXOOY&part=snippet&key=[YOUR_API_KEY]' \  --header 'Authorization: Bearer ACCESS TOKEN' \  --header 'Accept: application/json' \  --compressed

And here's what I get:

{"error": {"code": 400,"message": "page token is not valid.","errors": [      {"message": "page token is not valid.","domain": "youtube.liveChat","reason": "pageTokenInvalid"      }    ]  }}

Video id is absolutely valid, you can check it here.


Viewing all articles
Browse latest Browse all 3831

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>