Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting YouTube channel profile picture with channelId

So I'm trying to get the channel profile picture for a YouTube channel by using the channelId.

I would like to do it simply by adding the channelId to a URL and get the image that way. Facebook has something similar where you use this URL:

http://graph.facebook.com/user_id/picture?type=square

Google+ has it too, found this question here. Sadly it didn't work for YouTube (I couldn't get it to work)

Hope someone has a solution!

Thanks in advance :)

like image 721
Aleksander Avatar asked Aug 16 '13 19:08

Aleksander


1 Answers

a little bit late, but maybe interesting for others:

just create a comma separated list for the different channelIds and then call

https://www.googleapis.com/youtube/v3/channels?part=snippet&id='+commaSeperatedList+'&fields=items(id%2Csnippet%2Fthumbnails)&key={YOUR_API_KEY}

therefore you don't have to send a request for each item

like image 114
pas13 Avatar answered Oct 01 '22 15:10

pas13