ios facebook get friendlist who play the same app
Asked Answered
S

2

6

I can get the friendlist by

[facebook requestWithGraphPath:@"me/friends" andDelegate:self];

But the list contain all the friends, how could I get the friendlist that only played the app.

Sneakbox answered 31/10, 2011 at 6:53 Comment(0)
C
3

You can query the OpenGraph for the field installed:

[facebook requestWithGraphPath:@"me/friends?fields=installed,name"
                                             andParams:params
                                         andHttpMethod:httpMethod
                                           andDelegate:delegate]; 

That will return you a list of friends, in which some will have the field installed=1

Captivate answered 5/4, 2012 at 15:28 Comment(2)
Hi Angel, I have the same problem but can't understand in this answer that.. for which application "fields=installed" will check. I mean, we are not giving any appId here then how can we be sure that in the response installed=1 is for my application.Please help me.Edraedrea
Well, you are giving the appId when login. The facebook object used is logged within that app.Captivate
L
1

This gives you a list of your friends that have the app installed

friend.getAppUsers()

Legaspi answered 28/11, 2011 at 8:22 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.