0

I am trying to use YouTube apis to collect chat messages from public live videos. I am able to get regular comments but unable to get live comments. Let me know if there is an api for this.

I have tried LiveStreams: list (https://developers.google.com/youtube/v3/live/docs/liveChatMessages/list#try-it); however, it requires liveChatId which I could not get for a YouTube live video.

Thanks, Vivek

Vivek
  • 357
  • 1
  • 18

1 Answers1

0

You can use this reference page from the Live Streaming API.

theauzman
  • 11
  • 4
  • The list api requires liveChatId. How can you get liveChatId for a youTube live video? Here is an example youTube video: https://www.youtube.com/watch?v=nk7IngWdcI4 – Vivek Mar 21 '21 at 09:40
  • Try following the answer on this question: https://stackoverflow.com/questions/36683878/youtube-api-how-do-i-get-the-livechatid – theauzman Mar 21 '21 at 13:34
  • 1
    @Vivek did that answer your question? – theauzman Mar 24 '21 at 04:15
  • Is there an equivalent API to retrieve the same chat after the livestream has completed and archived? As stated in the referenced page: “after the event ends, live chat is no longer available for that event.”. But I know there’s a Python solution (chat-replay-downloader) that does this for completed livestreams. That won’t work with private videos since it doesn’t allow sign-in. I would like to retrieve my own channel’s livestream chats after-the-fact if possible, even if they’ve been marked Private. – Dennis Jul 01 '21 at 23:15