Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting LinkedIn Profile Picture

Tags:

api

linkedin

Is there an easy way to grab a users LinkedIn profile photo?

Ideally similar to how you would with Facebook - http://graph.facebook.com/userid/picture

like image 308
George Wiscombe Avatar asked Aug 05 '11 11:08

George Wiscombe


People also ask

How can I prevent public from enlarging my profile picture?

Just view your profile picture, drop down the public option at the top corner and then select it to “only me” or you can choose custom settings. That's it now your friends or public can't enlarge your photo, can't like your photo and can't share your photo.


2 Answers

You can retrieve the original photo size with this call:

http://api.linkedin.com/v1/people/~/picture-urls::(original)

Note that this could be any size, so you'll need to do scaling on your side, but the image is the original one uploaded by the user.

like image 183
Rahim Basheer Avatar answered Sep 28 '22 00:09

Rahim Basheer


Not as easy... You need to go through OAuth, then on behalf of the member, you ask for:

http://api.linkedin.com/v1/people/{user-id}/picture-url

like image 28
Adam Trachtenberg Avatar answered Sep 28 '22 02:09

Adam Trachtenberg