views:

41

answers:

1

I am trying to get the photos in user profile, I tried this

https://graph.facebook.com/me/photos

but it returns tagged photos only, can I get all the photos in all albums??

Thanks in advance

+1  A: 

You are using the wrong api endpoint, you want the albums endpoint.

https://graph.facebook.com/me/albums

From the api page:

Photo Tags: https://graph.facebook.com/me/photos
Photo Albums: https://graph.facebook.com/me/albums

From that you can then call: https://graph.facebook.com/ALBUM_ID/photos

Gazler
that only return the album not the photos inside it
omar
See my edits...
Gazler
that worked perfectly, thanks, but how did that "rest request" know that it was me, /me/ or my id is not included in the url. let's ask the question in different way, how to get my friends photos??
omar
From your access token, it uses facebook privileges to see if you are allowed.
Gazler