Can't get facebook checkins, data array always empty

半腔热情 提交于 2019-12-11 05:55:59

问题


I have a strange behavior when trying to get the checkins of a place or user: the result is always an empty data array:

{
    "data": [
    ]
}

This happens when I use the Graph Explorer: /4/checkins

or when I use FQL: SELECT checkin_id, author_uid, page_id, timestamp from checkin where page_id = 111856692159256

or when using javascript:

FB.api("/me/checkins", function(response){
    console.log(response);
});

I always use an access_token, even ones with ALL permissions available. Simply no result. I read, that checkins are now post with locations, so I tried /4/posts?with=location, but still no luck. Is there some kind of bug, or restriction (country/app-permissions) I am missing?

EDIT: I now got lucky and can get of SOME of my friends their checkins. It's like a 50/50 chance...


回答1:


There are 2 differences commands, one command is the url to get the user checkins:

  • /me/checkins will return all checkins of the current user (the user that generate the token)
  • /<USERID>/checkins will return all checking from the User ID that the current user can see.
  • /<PLACEID>/checkins will return all friends of the current user that made checkin at this place

So, probably you have no friends that made checkins at the id 111856692159256



来源:https://stackoverflow.com/questions/14718623/cant-get-facebook-checkins-data-array-always-empty

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!