I was searching but couldn't find anywhere how to retrieve random video which is most viewed or trending this day or this week. How could I do that?
-
2http://gdata.youtube.com/feeds/api/standardfeeds/most_viewed – diegueus9 Oct 30 '11 at 05:24
5 Answers
No document hint a radom way. In fact, youtube use google search engine, as I know, there is no opinion set in all the google search api.
So if you want do a random show. You can catch all the standard result to database, then make them random show.

- 1,323
- 4
- 17
- 31
The YouTube Data API will allow you to do that.
You can find out more about it here: http://gdata.youtube.com/demo/index.html

- 4,073
- 5
- 31
- 35
Dude you just need to consult the You Tube API
For Example you can use following urls to send requests to get most recent
http://gdata.youtube.com/feeds/api/standardfeeds/most_recent
most viewed
http://gdata.youtube.com/feeds/api/standardfeeds/most_viewed
Top rated
http://gdata.youtube.com/feeds/api/standardfeeds/top_rated
etc. Consult the API, you will get the more information from there

- 17,492
- 24
- 75
- 137
I think this is possible, You can use YouTube authenticated Zend API
Read API methods from below link http://framework.zend.com/manual/en/zend.gdata.youtube.html
All the available methods are defined, so you be reading methods name you can guess what they are doing.

- 98
- 8
these are the methods in the youtube php api that gives you the opportunity to get a list of videos based on different criteria, then its easy to pick for example a random video from the top rated feeds.

- 490
- 5
- 18