php - Easiest way to get birthday info of all friends through graph api?
163
I am looking for the least resource intensive way of getting all friends' birthday information by a given user object Id. Probably using Event Object since birthdays of friends are visible inside events.
Answer
Solution:
I've done something similar in the following way:
1) Like Awais pointed out - you need to first get the extended permission from the user at the time of login to access their birthday information
<fb:login-button perm="user_birthday, friends_birthday"></fb:login-button>
2) There are different ways of doing this, but if you are not using php sdk, you can get the friends birthday as follows
Just replace the access token in the above code and it should loop through all your friends and print their birthdays
3) Basically the query I have used is
Good luck
Answer
Solution:
quite easy.Just take extended permission of user birthday then just query user table to get birtday
Hope it will work