How to get pending group messages from facebook fql

I am the owner of a group from the specified group. I use the user token to access the walls this way:

SELECT post_id, source_id, actor_id, target_id, message, like_info, comment_info, created_time, attachment, timeline_visibility, privacy, is_hidden, is_published FROM stream WHERE type = 308 AND source_id = "482501211816484" ORDER BY created_time DESC 

How can I receive messages pending approval? Am I using the wrong table? Is this possible with FQL or even with a chart?

+4
source share
1 answer

To check if a message (in a group) is approved or not -

  • GET details regarding publishing using the Graph API -

     $result = $facebook->api("/POST_ID"); 
  • If the message has not yet been confirmed, the keys: actions and subscribed will be absent as a result; this is because these messages are not suitable for these keys. Thus, you can create a check using any of the keys. For instance,

     if (array_key_exists("actions",$result)) // the post is approved else // not approved 
+3
source

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


All Articles