如何检索 Facebook 帖子的评论和点赞数

发布于 2024-10-06 17:44:03 字数 491 浏览 1 评论 0原文

我尝试执行以下 FQL,结果始终是空 XML

https:// api.facebook.com/method/fql.query?query=SELECT post_id, comments.count FROM Stream where post_id = 167995709886177

<fql_query_response list="true"/>  

这是帖子,有很多评论和喜欢 http://www.facebook.com/ryanleslie/posts/167995709886177

请帮忙

I am trying to execute following FQL and the result is always an empty XML

https://api.facebook.com/method/fql.query?query=SELECT post_id, comments.count FROM stream where post_id = 167995709886177

<fql_query_response list="true"/>  

This is the post and it has lot of comments and LIKEs
http://www.facebook.com/ryanleslie/posts/167995709886177

Please help

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

东风软 2024-10-13 17:44:03

@Anz 只需浏览 Facebook 开发者部分即可。你所有的疑问都可以解决

@Anz just go through facebook developer section. all your doubt solve their

梦里的微风 2024-10-13 17:44:03

您需要使用如下网址:

https://graph.facebook.com/100002725117360_142921995808637< /strong>?access_token=154407880175|16a3d55d6e4be468d6a131bc.1-100002735407608|IhahmvIUsur7GuZ45rxRj3boXtE

粗体 id (100002725117360_142921995808637) 是帖子的 ID。下划线之前的部分是帖子出现在其墙上的人的用户 ID,之后的部分可能是您在示例中使用的 ID。

这将为您提供所需的一切——评论、点赞等。如果您想要更窄的信息,您可以使用如下 URL:

https://graph.facebook.com/100002725117360_142921995808637/likes?access_token=154407880175|16a3d55d6e4be468d6a131bc.1-100002735407608|IhahmvIUsur 7GuZ45rxRj3boXtE

注意:这是一个测试用户帐户,所以我我不会在这里暴露任何人的私人信息。

You need to use a URL like this:

https://graph.facebook.com/100002725117360_142921995808637?access_token=154407880175|16a3d55d6e4be468d6a131bc.1-100002735407608|IhahmvIUsur7GuZ45rxRj3boXtE

The bolded id (100002725117360_142921995808637) is the ID of the post. The part before the underscore is the user id of the person on whose wall the post appears, and the part after is probably the ID you are using in the example.

This will give you everything you need -- comments, likes, etc. If you want even narrower info, you can do that with URLs like this:

https://graph.facebook.com/100002725117360_142921995808637/likes?access_token=154407880175|16a3d55d6e4be468d6a131bc.1-100002735407608|IhahmvIUsur7GuZ45rxRj3boXtE

Note: this is a test user account, so I'm not exposing anyone's private info here.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文