How to get notified on Facebook page via Graph API

There was a problem with the Facebook Graph API. I want to read page notifications through the Graph API. But the Facebook documentation only indicates the user's notification.

Only after that returns a notification to the user (the user who provided the access token for this.)

http://graph.facebook.com/me/notifications

I used the following methods. But no luck.

01. But I tried using different URLs with the access token provided by this page. (with my stupid guessing game, replacing the page id for me)

http://graph.facebook.com/page-id/notifications

02. Tested using the Insights API. But Insights does not provide direct solutions. This is more like statistics. But I just need a list of recent user / fan / message actions on the page.

https://graph.facebook.com/page-id/insights/field

A little about my application (I hope that there are no problems with this, how the other API works),

The Facebook documentation is not very helpful. I spent several days on this to find a solution for this. It’s just interesting that one of you guys ran into this problem and solved it. Hopefully I did not ask a duplicate question here, since I searched for a few days on Stackoverflow too.

Thanks.

+4
source share
2 answers

There are no page notification APIs. I do not believe that it is possible to directly request this data.

You can be notified of changes on your Facebook page using the real-time API. https://developers.facebook.com/docs/reference/api/realtime/

+5
source

Facebook now allows you to read unread page posts by requesting an edge: {page-id}/notifications .

See https://developers.facebook.com/docs/graph-api/reference/v2.7/page/notifications

+4
source

Source: https://habr.com/ru/post/1396082/


All Articles