gpt4 book ai didi

facebook-graph-api - 2013 年 7 月重大更改 : Graph API post search with or without access token?

转载 作者:行者123 更新时间:2023-12-04 07:58:02 26 4
gpt4 key购买 nike

Developer Roadmap Graph API search changes 段落中的状态:

User access tokens will be required for all search Graph API calls except Posts, Places and Pages. App access tokens may also be used for Post search Graph API calls. Places and Pages search Graph API calls will still require an App access token. Search for Applications will no longer be supported.

但是这个Developer Blog PostGraph API search changes 段落中说:

App access tokens will be required for all search Graph API calls except Places and Pages. Search for application will no longer be supported.

所以第一个说我不需要用户访问 token 来搜索帖子(但如果我愿意,我可以使用应用程序访问 token )。第二个说我需要使用应用程序访问 token 。我很困惑。哪一个是正确的?

最佳答案

为了消除您的困惑,我想提一些关于搜索 API 的事情。

  1. 您可以使用 User Access Token 进行 Graph API 搜索,搜索所有类型的节点,例如 Post、Places 和 Pages,并检索 User's view结果可能与其他两种情况不同。差异基本上来自其他人对各自用户的权限。基本上我会推荐这个而不是其他人,因为结果可能更适合用户。

  2. 您可以使用应用访问 token 从图谱 API 搜索中获取数据的公共(public) View 。检索到的数据可能与其他情况不同或相同。 如果对要使用的访问 token 有疑问,最好使用此方法。

  3. 更复杂的是,您甚至可以在没有任何访问 token 的情况下使用 Graph API 搜索(Sample request /search?type=post&q=video).虽然这是非常不推荐的做法,因为 Facebook 可能会随时更改 API,从而需要对您的应用进行进一步更改。

因此,简而言之,如果您希望用户查看数据,或者如果您只想使用公共(public)数据进行某些统计等,那么请使用用户访问 token 。您可以使用应用程序访问 token 。

并回答您的问题您将需要在 2013 年 7 月 10 日之后使用应用访问 token

关于facebook-graph-api - 2013 年 7 月重大更改 : Graph API post search with or without access token?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17163532/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com