3
votes

I want to get all facebook group post using FB Graph API.
I searched , googled, seen documentation for graph api, asked to so many persons, all are saying it is possible

Also i'm providing link from stackoverflow which i referred and tried
How to get all posts of a group via facebook graph api
But as you can see the post is very much old (from 2013)

When i tried to send request using CURL, at that time i'm not getting any error not any data

When i tried below code
$publish = $facebook-api('https://graph.facebook.com/v2.3/'.$group_id.'/feed/?access_token='.$params['access_token']);

at least i'm getting something in response

Array
(
    [og_object] => Array
        (
            [id] => 859455820800214
            [type] => website
            [updated_time] => 2015-06-04T12:18:15+0000
            [url] => https://graph.facebook.com/v2.3/659988617465253/feed/
        )

[share] => Array
    (
        [comment_count] => 0
        [share_count] => 0
    )

[id] => https://graph.facebook.com/v2.3/659988617465253/feed/

)


So i just wanted to know that is it really possible at this moment?

And one good thing is that when i'm trying it from Graph API Explorer, i'm getting the data properly.

So where i'm wrong ?
Any little help would be greatly accepted

1

1 Answers

7
votes

Why don't you just use the Facebook PHP SDK?

You can get the group's feed via /{group_id}/feed, as described at

Make sure your Access Token is of the right type and contains the right permissions.