Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get channel related data from youtube api

I need to get the video/playlists/show data from youtube.com.

Example :

  • http://www.youtube.com/channel/SWMb9NxQL9I6c
  • http://www.youtube.com/show/mtvroadies9/featured

Is there a way I can get the video details for the above URL using the youtube API?

like image 420
thewhiz01 Avatar asked Oct 15 '12 07:10

thewhiz01


2 Answers

Yes, using:

https://developers.google.com/youtube/v3/docs/channels

e.g.

https://www.googleapis.com/youtube/v3/channels?part=snippet&id=SWMb9NxQL9I6c&key={YOUR_API_KEY}

like image 156
Matias Molinas Avatar answered Nov 17 '22 15:11

Matias Molinas


You need to look at the YouTube Data API. You will find there documentation about how the API can be accessed. You can also find client libraries.

You could also make the requests yourself. Here is an example URL that retrieves the latest videos from a channel :

https://www.googleapis.com/youtube/v3/search?key={your_key_here}&channelId={channel_id_here}&part=snippet,id&order=date&maxResults=20"
like image 22
akshay Avatar answered Nov 17 '22 15:11

akshay