How to get who and when a user shared a Facebook post

为君一笑 提交于 2019-12-05 00:20:19

问题


For my Facebook posts my friends share (not likes) I would like get who shared it and when. Using the graph api I can get the like or comment information and the number of times a post has been shared. What I am looking for is a graph api call or Facebook fql query for shares which returns a result set similar to this:

data": [
      {
         "id": "user_id_1",
         "name": "Username 1",
         "created": "some date"
      },
      {
         "id": "user_id_2",
         "name": "Username 2",
         "created": "some other date"
      }
   ]

回答1:


I am also looking for the exact thing for long time now. Since Facebook shows the list of users who shared the post, I was expecting that the same will be available in Graph API. But unfortunately nothing such exists till date.

The best workaround I could find for this problem is scraping the Facebook page for the list of users who shared the given post. I haven't yet tried this solution but this should solve the problem for now. The only issue here is, if Facebook changes the HTML structure of that page, the scrapper will have to modified.



来源:https://stackoverflow.com/questions/12504179/how-to-get-who-and-when-a-user-shared-a-facebook-post

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