Atagus Sood
Atagus Sood

Reputation: 61

Why am I unable to see a friend's albums via Facebook/Graph API?

  1. I requested an Access Token with user_photos and friend_photos permissions
  2. I did graph.facebook.com/[friend's id]/albums?access_token=[access token]
  3. For some of my friends, I got results and for other friends, I get an empty JSON data set { "data": [ ] }

If I do the same thing using the Access Token Facebook generates for me for use with their examples on the Core Concepts > Graph API page at developers.facebook.com/docs/reference/api/.
I am able to access all my friend's albums without any problems. So obviously the token and the permission is the problem.

So what am I doing wrong? The documentation seems to indicate that friends_photos should be a sufficient permission.

Upvotes: 2

Views: 1638

Answers (2)

Jeshua Lacock
Jeshua Lacock

Reputation: 6668

CBroe appears to be correct.

Since I could not find it, the setting that will exclude all user photos and albums from apps can be found by going to Privacy Settings > Apps, Games and Websites > How people bring your info to the apps they use > De-check My photos.

Here is a screen shot:

enter image description here

Upvotes: 0

C3roe
C3roe

Reputation: 96316

Every user can state in their privacy settings what kind of information they want to share with apps if a friend of them gives the app a friends-permission.

So if some user said, „Don’t let apps access my albums/photos/whatever just because a friend thinks I might be willing to share them” – then of course you get no data for that person.

Upvotes: 2

Related Questions