Facebook graph api friend list not complete - facebook-graph-api

I am using graph api to retrieve my friend list.
https://graph.facebook.com/me/friends?access_token=
I noticed it is not returning all friends, e.g. I have 194 friends according to facebook.com, but the api call is only returning 189.
Additional Information. I just checked XBox 360's facebook implementation too, it shows only 189 friends for me, even though facebook.com is showing 194 friends. It looks like graph api is not exposing the full friend list.
Anybody has any ideas to fix this ?

A user can "turn off all platform apps" and hide himself from all applications. It looks like 5 of your friends chose to turn that off.
The setting is under:
Privacy Settings > Apps and Websites > Apps you use > "Turn off all apps"

Related

getting list of friends from facebook

Facebook API does not provide friends list of people using our fb app, according to their developer faq page. But still, websites like nimble and the live example of socialauth are able to get the names of people on our friend list, even those who do not use their app. Please, can any one help me with how this work?
The read_friendlist permission gives only name of lists like 'close friends', 'aquaintance' etc. the user_friends permission gives only the list of people in our friendlist who use our app.
What all api permssions do we need to get the full friend list?
I am trying to make an address book by importing contacts from google, facebook etc. using socialauth. Had success with google.
Those websites are probably using older Apps with v1.0 - it will stop working for them after end of April 2015. You can only use v1.0 with an App created before end of April 2014.
All 'friends_*' permissions have been removed from new version 2.1
You can use 'user_friends'
https://developers.facebook.com/docs/apps/upgrading
https://developers.facebook.com/docs/apps/changelog
For fetching app users user 'me/friends'
For more friends use 'me/taggable_friends' .
Remember it will still not return whole friends.
In new facebook api version there is no way to fetch whole friend list at one time

Friends list request from Corona SDK on Facebook API returns nothing

I've copied I code I used in an older game into my new game (it worked and still does in the old game) that I use to get the users friends list so I could publish (send) a message to which ever friends I want, inviting to play against me in my game, simple enough, no?
But it seems this does not work anymore, is that true? Does Facebook only allows an app to request just the list of your friends who also use the same app? I can't see how this helps the gaming industry get the word out on new games using the Facebook API to message about it from one user to his friend/s...
Am a complete fool and miss something? can the normal friends list be loaded into my Corona built game using the Facebook graph API?
Thanks.
Yes, Facebook has changed the rules and the me/friends will only return friends who have the app installed. You have to use various showDialog() features with friend pickers to see all your friends.

Facebook API get friend albums not working for some friends

I'm using the following FQL query
'select src,src_big from photo where aid in(select aid from album where owner=' + contactId + ' and type="profile")'
But it works for about 50% of my friends, and the rest - it doesn't.
Its not a permissions problem because the behavior persists per friend, if it works for a friend - it always works for him.
Is this a Facebook thing, where a user can choose to prevent apps from getting his photos?
(like what happens when some friends are missing from /me/friends )
It will be odd, because it doesn't work for too many friends..
I tried the same with the graph API, and the same happens (some users ok, rest are not)
What is this?
Thanks in advance
Take a look at the Profile settings of your account. Do you see the Apps link on the left?
There's on portion there that says "Apps others use"
People on Facebook who can see your info can bring it with them when they use apps. This makes their experience better and more social. Use the settings below to control the categories of information that people can bring with them when they use apps, games and websites.
Bio
My videos
Birthday
My links
Family and relationships
My notes
Interested in
Hometown
Religious and political views
Current city
My website
Education and work
If I'm online
Activities, interests, things I like
My status updates
My app activity
My photos
If you don't want apps and websites to access other categories of information (like your friend list, gender or info you've made public), you can turn off all Platform apps. But remember, you will not be able to use any games or apps yourself.
If your friends have that checked. I believe apps won't be able to get your friends' images through your access_tokens even if you have allowed the "friends_photos" permission enabled for the app that you're using.
I did an experiment and apparently I found that I must get my friend to also access the app to allow the app to access their photos under the "user_photos" permission. only then can I get their photos using my access token with the "friends_photos" permission.
Not sure if this makes sense to you.

Some friends on the Facebook website do not appear in the Graph API

I was playing with the Graph API recently and I made the following simple call:
https://graph.facebook.com/me/friends
For me, this returns 461 entries. On my profile page on the Facebook website, I have 465 friends. On the following page, I have 477 friends:
https://www.facebook.com/me/friends
I've discovered that 12 of my friends has deactivated their profiles, which would account for the difference between the 477 and the 465. However, that still does not explain the difference between the Graph API call and the number that appears on my profile.
This leads me to my questions:
Is there a way to retrieve a list of inactive friends via Facebook API?
What other reasons are there aside from user inactivity that a friend connection would not appear on the Graph API? Is there a user's privacy setting for such control?
Thanks!
This is absolutely normal behavior. There is an option in Facebook that let's you disable all apps. Reference: Facebook: Disable all apps If they have that turned on, your app to not be able to reach them.
As of finding inactive friends, the answer is NO, you can't not. They are not a part of the Facebook public platform and therefore you don't have access to them.

Multiple friend selector in Facebook App

I just started with Facebook APIs a couple of hours ago. I am trying to build a app for a page (which will be used on the page only, and not on FB side) where the users will select some of the friends in their friend list and I need to save which users did they selected.
I see FB does provide something like this (Legacy FBML) but I am unsure of how to use it or its exactly what I want. Other than that, I have the option to just display the friends list in a similar interface on page and then get it done (I already have them in an array). But the Facebook like multiple friend selector would be great! Won't have to deal with searching and styling that much.
So what would be the best option to achieve this (I am using PHP SDK).
I am describing my requirements as follows:
User must be login into FB to do anything on the page
Login + Permissions Dialog box for App
Select friends among the friend list (lets say good friends), this is what I need to save.
Then an option to share the page with your friends (status/message?) so that they can do the same too.
Pardon me if I am missing something very obvious as I just started with it.
I found this jQuery to plugin do what I want - http://mike.brevoort.com/2010/08/10/introducing-the-jquery-facebook-multi-friend-selector-plugin/index.html
I am starting with JS SDK as of now, not using PHP SDK anymore!