facebookfacebook-graph-api

Is there a way to find connection between 2 users in facebook using graph API?


Consider 2 users U1 & U2

Consider a facebook app that is approved by both user to access their personal information and friend list.

Secondly, both the users are not friends and have no common friends but are connected by a chain of 3 users (F1, F2, F3 and these 3 have friend list public) i.e.

U1 <----> F1 <----> F3 <-----> F2 <-----> U2

Then using FQL, is it possible to determine such a connection?


Solution

  • You can't check friends of friends like this, but you can check mutual friends between two users U1 and U2. This will work if there's only one level of abstraction between U1 and U2

    i.e given U1 <--> F1,F2,F3,F4 <--> U2 You can get the list of people in 'F1' by making a Graph API call to

    /U1_USER_ID/mutualfriends/U2_USER_ID