5
People I need to return to facebook friends list using facebook API 4 for PHP. I can log in, get the account information but the list only comes the following result for me:
Array
(
[data] => Array
(
)
[summary] => stdClass Object
(
[total_count] => 124
)
)
I’m using the following command:
$friends = (new FacebookRequest($session, 'GET', '/me/friends'))
->execute()
->getGraphObject()
->asArray();
echo '<pre>' . print_r( $friends, 1 ) . '</pre>';
And I have the following permissions:
$permissions = array(
'email',
'public_profile',
'user_friends'
);
echo '<a href="' . $helper->getLoginUrl($permissions) . '">Login</a>';
How should I return friends?
Has your APP ever been through the Facebook Review? Yes, according to documentation, when you request more than one of these permissions (public_profile, email, user_friends), the APP needs to be reviewed by Facebook.
– Jonas WebDev