Pregunta

Let us assume: Users A and B use my application but they themselves are not Facebook friends and are both huge fans of the band, Cold Play.

User A searches for people who like Cold Play. The application then displays people who also like Cold Play and breaks them up according to the degrees they are separated from User A. User B shows up as a result, being separated from User A by four people. So basically, User A knows someone, who knows someone, who knows someone that knows User B.

Will the Facebook API allow me to find those common links? Or is that all data that I will have to collect on my end and constantly crawl for changes to friends lists of all my users and write my own algorithm to find the shortest distance between two people?

¿Fue útil?

Solución

The Facebook API won't tell you who likes a page, so you would be limited to prompting the user for user_likes extended permission and recording which pages they like, and do this for any future users of your app.

The only thing close to this that Facebook provides is the mutual friends API. This would only get immediate results between 2 users. Thus, you will need to log all the users friends and write your own algorithm for this.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top