开发者

Finding which user's friends also use my facebook application

开发者 https://www.devze.com 2023-03-01 10:30 出处:网络
I\'ve seen the other answers about this but have a few different questions. I\'m new to Fb Development so bear with me but I am creating an Android app and want to use Fb. I want to find out which of

I've seen the other answers about this but have a few different questions.

I'm new to Fb Development so bear with me but I am creating an Android app and want to use Fb. I want to find out which of the current user's friends also uses my app, I have implemented a way to do this but I don't think it is the most efficient or even allowed by Fb ToS.

So far, everytime a user interacts with my app, their uid is sent to my own db which either adds the uid or just checks that it's already in there. When the user wants to find other friends that use the app, a nested loop works through the user's friends' uids comparing with the uids in my db and finds them that way. This takes a few seconds with quite a few users and friends so I dread to think how long it would take if my app was successful.

I am now wanting to have another db table that stores uids of friends that use the app, so when the above looping occurs, the user's uid and all their app-using friends' uids are stored in a table together, this would make it much quicker when the user performs the "friend search" again, as many of their friends will already be known to be users.

My question with this is that I don't know if this is allowed by Fb ToS? Am I allowed to retain uids? And if so, am I allowed to retain relationships between uids as I propose?

I know that you can do FQL queries to c开发者_运维问答ompare friends with users that use the app but the Android Facebook SDK I am using called Easy Facebook Android SDK for some reason returns FQL queries as XML rather than JSON (even though the query has "&format=json" on the end :-/) and I'm not really a fan of XML and don't want to be messing around with SAX if I don't need to, as I am using JSON for my method because I already have JSON implemented in my app for other things.

I also know about the REST API method getAppUsers() but don't want to use this for the simple reason that it is legacy and could be deprecated anytime.

Thanks for reading all this drudge :-)

Hope you can help,

Infinitifizz


Regarding to FB policies, I do not think you are breaking them. At most, you will need to add it to your privacy policies:

3 . You will have a privacy policy that tells users what user data you are going to use and how you will use, display, share, or transfer that data and you will include your privacy policy URL in the Developer Application.

4 . A user's friends' data can only be used in the context of the user's experience on your application.

(...)

7 . You will not use Facebook User IDs for any purpose outside your application (e.g., your infrastructure, code, or services necessary to build and run your application). Facebook User IDs may be used with external services that you use to build and run your application, such as a web infrastructure service or a distributed computing platform, but only if those services are necessary to running your application and the service has a contractual obligation with you to keep Facebook User IDs confidential.

But, looking at that library, it seems that they're using the old REST API that is being deprecated, (i.e.., URL https://api.facebook.com/restserver.php?method=fql.query... instead of https://api.facebook.com/method/fql.query?...)

I would either (1) contact them to see if they will update the library soon or (2) use another library (such as the android-facebook-sdk).

0

精彩评论

暂无评论...
验证码 换一张
取 消