I am trying to read the privacy settings of a Facebook photo posted by a user using my app.
On the documentation for the privacy node, it says photos return a field with the privacy information, but on the documentation for the photo node, privacy
isn't on the list of fields so when I try adding it to my list of fields, I get the following:
{
"error": {
"message": "(#100) Tried accessing nonexisting field (privacy) on node type (Photo)",
"type": "OAuthException",
"code": 100
}
}
Any ideas? Here's my code:
$fbSession = new FacebookSession(ACCESS_TOKEN);
// Request photo info
$photoRequest = (new FacebookRequest(
$fbSession,
'GET',
'/' . ID_PHOTO_FACEBOOK,
['fields' => 'from.name(1),link,source,likes.summary(1),comments.summary(1)']
))->execute();
$photoGraphObject = $photoRequest->getGraphObject();
Thanks!