Facebook Graph API 是否需要 OAuth?
遇到问题,
https://graph.facebook.com/[page ID]/feed
i get the following response
{
"error": {
"type": "OAuthAccessTokenException",
"message": "An access token is required to request this resource."
}
}
我有一个问题..我想使用不带OAuth的fb graph API从facebook页面获取所有提要,但我在检查另一个页面时
https://graph.facebook.com/[another page ID]/feed
{
"data": [
{
...
它得到正确的响应为什么它要求页面的访问令牌...并且它不会对另一个页面执行此操作?
编辑
我在 2 天前检查了第一页图表调用,它运行 100%
i have a problem .. i want to get all the feeds from a facebook page using fb graph API without OAuth but i have a problem
https://graph.facebook.com/[page ID]/feed
i get the following response
{
"error": {
"type": "OAuthAccessTokenException",
"message": "An access token is required to request this resource."
}
}
while i check another page it gets right response
https://graph.facebook.com/[another page ID]/feed
{
"data": [
{
...
why it's asking for an access token for a page ... and it doesn't do that for another page ?
EDIT
i checked the first page Graph call 2 days ago and it was working 100%
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
您应该始终包含 OAuth 访问令牌(无论是用户的访问令牌(如果您直接代表用户工作)还是您的应用程序的访问令牌(如果您没有在用户上下文中执行某些操作)。否则,您可能无法访问您应该能够访问的所有内容。
You should always be including an OAuth access token (whether it's a user's, if you're working directly on behalf of a user, or your app's, if you're not doing something in a user's context). Otherwise you might not be able to access all of the things that you should be able to access.
我不确定您是否需要 OAuth,但这里是您如何获取访问令牌。
更多资源:
http://developers.facebook.com/docs/api< /a>
I am not sure whether or not you need OAuth but here is how you can get the access token.
More Resources:
http://developers.facebook.com/docs/api
是的,OAuth 是唯一受支持的身份验证形式。但是,某些页面不需要它,例如粉丝页面(例如 https://graph.facebook. com/cocacola/feed)
编辑:Facebook 显然已经改变了他们对此端点的政策。
Yes, OAuth is the only supported form of authentication. However, some pages don't require it, such as fan pages (e.g. https://graph.facebook.com/cocacola/feed)
EDIT: Facebook has apparently changed their policy on this endpoint.