1

The title basically says it all.

Can I retrieve a list of videos with more than 1B views, using YouTube API?

I couldn't find anything like that in the official docs.

The same story for likes/dislikes. Sorta making a collection of most viewed/liked/disliked videos.

Mike K.
  • 637
  • 1
  • 5
  • 18
  • 1
    maybe this will help https://stackoverflow.com/questions/13331795/find-videos-with-a-minimum-number-of-views-with-youtube-api – Furious Mountain Dec 08 '21 at 09:02
  • It seems that this case implies a query. I need my query to be somewhat like `?viewsCount=gt1bil` I am not looking for a particular topic of the video and filtering it by views. I am looking for let's call it `most popular videos ever`. Regardless of a topic. I want to create a couple of playlists with music. Kinda like `songs what everyone already heard`. – Mike K. Dec 08 '21 at 12:08

1 Answers1

2

You cant specifflicly state that you want videos with over 1 billion views. However search.list does offer you the option to sort by view count.

curl \
  'https://youtube.googleapis.com/youtube/v3/search?part=snippet&order=viewCount&type=video&fields=*&key=[YOUR_API_KEY]' \
  --header 'Accept: application/json' \
  --compressed

This should return to you the videos with the highest count.

You can also sort by rating which should be the likes. YouTube removed public dislikes so i doubt this is something you would be able to sort on.

Unfortunately the YouTube Data api is very limited. This is going to be the best you can do.

Linda Lawton - DaImTo
  • 106,405
  • 32
  • 180
  • 449
  • i did run this exact request and the very first video in the response I had was a video with 50m views. And as you said YT API doesn't even offer this thing... eh – Mike K. Dec 10 '21 at 16:53