为 Facebook 使用“用户通知”图表 API

Using ''User Notifications" Graph API for Facebook

自 Graph API v2.3 起,通知请求已被弃用。我是 API 的新手,我想知道如何使用此处找到的 POST 边缘请求:https://developers.facebook.com/docs/graph-api/reference/user/notifications/

更具体地说,检索用户的未读通知。

这是我目前的代码:

function getInfo() {
  FB.api("/me/notifications", function(response) {
    console.log(response);
  });
}

该端点仅用于发送通知,您无法再收到未读通知。并且您需要为该调用使用带有 App Scoped ID 的 App Token。您不应使用 App Token 客户端,因此应始终在服务器端发送通知。

更多信息:https://developers.facebook.com/docs/games/services/appnotifications