Reputation: 1857
I'm trying to get all gender from all my friends on facebook using OpenGraph Api and Facebook SDK.
Step 1 : OpenGraph
https://developers.facebook.com/tools/explorer/?method=GET&path=me%3Ffields%3Did%2Cname&version=v2.0
and query: xxxxxxid/friends?fields=gender
but with or without Limit field I get only few result.
What do I wrong?
Upvotes: 0
Views: 734
Reputation: 336
As per Facebook API v2.0, /{user}/friends
will only return friends who already use your application.
friends
endpoint will only return id
and name
(in v1.0 it also returned installed
field, but not anymore as it's now restricted to app users only).
If still useful for you, you can get friends gender by calling /{user}
on friend's IDs.
Cheers!
Edit: Removed user_birthday reference
Upvotes: 1
Reputation: 38046
Only id and name is available via /me/friends on v2 of the platform, and then only for other users of your app. But if they use the app, then you can ask them using user_birthday
.
Upvotes: 0