有没有办法使用来自Facebook的搜索查询/关键字来检索帖子? [英] Is there no way available for retrieving posts using a search query/keyword from facebook?

查看:1088
本文介绍了有没有办法使用来自Facebook的搜索查询/关键字来检索帖子?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用 GraphAPI 通过搜索来检索各种帖子来自Facebook的查询/关键字.

I'm trying to use GraphAPI for retrieving various posts using a search query/keyword from Facebook.

这是我尝试过的:

new GraphRequest(
    AccessToken.getCurrentAccessToken(),
    "/search?q=solareclipse&type=post",
    null,
    HttpMethod.GET,
    new GraphRequest.Callback() {
        public void onCompleted(GraphResponse response) {
            /* handle the result */
        }
    }
).executeAsync();

但是我得到了这个错误:

but I got this error:

{
  "error": {
    "message": "(#11) This method is deprecated",
    "type": "OAuthException",
    "code": 11,
    "fbtrace_id": "AZD1YH0em2M"
  }
}

Facebook是否已完全收回了搜索其公开帖子的特权,或者还有其他可用的方式吗?

Has Facebook completely taken back the privilege of searching through it's public posts or is there some other way available?

推荐答案

自Graph API v2.0起,就不再可能搜索公开帖子.

Since Graph API v2.0 it is no longer possible to search through public posts.

有一个公共供稿API( https://developers.facebook.com/docs/public_feed ),但是访问仅限于某些媒体公司.

There is a public feed API (https://developers.facebook.com/docs/public_feed), however the access is limited to certain media companies only.

这篇关于有没有办法使用来自Facebook的搜索查询/关键字来检索帖子?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆