I am using the latest Parse SDK 1.7.1 and Facebook SDK 4.0.1 on my iOS application. My users can only log in using their facebook account.
A very important feature I need, is showing the number of facebook friends user1
has in common with another user2
(who is probably not friends with user1
on facebook). Let us assume for the following that I do get the user_friends
permission from both users.
My first question concerns the following quote from the Graph API docs:
Additionally, the response will only include any mutual friends who have granted user_friends to the app.
Does this mean that user1
will only see mutual friends that also use my app? Is it possible to just retrieve the number of mutual friends, without the actual list of friends?
My next question concerns the following statement in the Graph API docs:
If you want to call this endpoint on behalf two app-users who are not friends, then you must provide the appsecret_proof parameter along with the user access token when making the request. This means you must call this endpoint from your server.
How does this work together with Parse? Would I need to do this in Cloud-Code? If so, does anyone happen to have some example code for me of how to do a Graph API request from Cloud-Code? I am not familiar with Cloud-Code yet.
Thank you very much in advance for your help, it is very much appreciated!