Facebook通知API:"必须使用app access_token调用此方法"

Art*_*uro 4 php notifications facebook facebook-graph-api

我正在尝试使用Graph API Explorer从我的应用程序发送Facebook通知.所以我选择了我的应用程序POST,然后输入了这个字符串/

11093774316/notifications?access_token=430xxxxxx156|HU0ygMtxxxxxxxxxxxxikVKg&template=Hello&href=index.php
Run Code Online (Sandbox Code Playgroud)

访问字符串是我在"访问令牌调试器"上得到的,我检查它是否正常.

但是,我收到此错误消息:

{
  "error": {
    "message": "(#15) This method must be called with an app access_token.", 
    "type": "OAuthException", 
    "code": 15
  }
}
Run Code Online (Sandbox Code Playgroud)

我会说它在一个月前工作了......有什么想法吗?

谢谢

Igy*_*Igy 5

  • 尽快更改您的应用程序密码,您不应在这些问题中包含私人信息
  • 然后,检查应用程序的高级设置,并将应用程序类型设置为"Web",而不是"本机/桌面" - 如果设置为本机/桌面,则应用程序机密不受信任且需要应用程序访问令牌的调用将失败.


Low*_*ory 5

尝试使用这里的访问令牌:

https://developers.facebook.com/tools/access_token/

我有同样的问题,我已经解决了这样的问题。