Reputation: 23
I'm trying to get (using FB PHP SDK) number of users attending an open event. All good, but seems like Facebook limits number of records in response...
Example: https://graph.facebook.com/169041749835607/attending returns 999 users although more than 1600 users attending the event.
I would really appreciate any solution on this ... how to increase / disable this limit?
Thanks
Upvotes: 1
Views: 1705
Reputation: 165
Although this is a bug with a limit of 999 users, we've found that if you repeatedly query it does return different users. We then query the results every few hours and add any new ones into our list. It tends to get around 50% of the users, which is better than just 999.
However it does require lots of API calls, so you'd think that Facebook would just fix this!
Upvotes: 0
Reputation: 76888
Some googling finds that ... This is a bug.
http://bugs.developers.facebook.net/show_bug.cgi?id=13694
Upvotes: 1
Reputation: 4150
Optionally you can Try Batch http://developers.facebook.com/docs/reference/api/batch/
<?php
curl \
–F 'access_token=…' \
-F 'batch=[ \
{"method": "GET", "relative_url": "169041749835607/attending?limit=500&offset=0"}, \
{"method": "GET", "relative_url": "169041749835607/attending?limit=500&offset=500"}, \
{"method": "GET", "relative_url": "169041749835607/attending?limit=500&offset=1000"}, \
{"method": "GET", "relative_url": "169041749835607/attending?limit=500&offset=1500"} \
]'\
https://graph.facebook.com
?>
Upvotes: 0