This question already has an answer here:
-
How do I fetch comments in version 3 of the YouTube API?
2 answers
"Getting comments with Youtube Data API V3 is on Trusted Tester stage". Can anyone give me some update info for this?
I don't want to use API V2 for getting comments, maybe there is a better way?
Can anyone give me an advice how to use jsoup html parser in Android for retrieving comments if there is no way to use Youtube Data API V3 (With example, please)?
The YouTube Team added support for comments in v3 recently.
Have a look here:
- http://youtube-eng.blogspot.co.at/2015/04/manage-comments-with-youtube-data-api-v3.html
- https://developers.google.com/youtube/v3/docs/commentThreads
Update: Comments feature is now available in Data API v3. http://youtube-eng.blogspot.com/2015/04/manage-comments-with-youtube-data-api-v3.html
Comments feature for the v3 API will hopefully be released on early Q1.
You can track the issue and ask for the trusted tester, so you can already start developing against.
https://code.google.com/p/gdata-issues/issues/detail?id=5046
I don't know if this may help a bit, but there is a little code example page from Google to use their Youtube API: YouTube Data API (v3) Code Samples
The samples are available at github as you can see at the page.
I don't think it really think JSOUP is an option. If you have a video (let's take PewDiePie for example) it has litterly thousands of comments (maybe more), and not all the comments are displayed when you open the video, so you'll first need to find a way to load all comments before you can start reading them.
The reading part is the most difficult, because it has thousands of comments, the system takes a while to read the comments and do whatever you want to do with it.
But what I did find is this:
How to get comments of youtube Video from VideoId android in youtubeApi v3?
Take a look at the link in the comment on the first post and compare it to the video itself:
With this link you get the comments using JSON:
Getting comments of a video: http://gdata.youtube.com/feeds/api/videos/DBNYwxDZ_pA/comments?orderby=published&alt=json&max-results=30&start-index=1
The video itself: https://www.youtube.com/watch?v=DBNYwxDZ_pA
I hope this helps you a bit with your project!