Reputation: 21
Sir i have a problem related to graph api with php sdk,i just want to make request from my php code to graph api getting page conversation here is my code
$request2 = new FacebookRequest(
$session,
'GET',
'/8499295645458',//page_id
array(
'fields' => 'conversations'
)
);
Now i have a problem when we request from graph api then there is a page access token who make request,and i get results.but if i want to make request with php code where i put page access token.please help.
Upvotes: 0
Views: 109
Reputation:
You should user page access token session instead redirect access token in session variable like
$facebookSession = new FacebookSession($pageAccessToken);
and then use that in graph api request like,
$request2 = new FacebookRequest(
$facebookSession,
'GET',
'/'.$pageID,
array(
'fields' => 'conversations'
)
);
that's it now make requests chill.
Upvotes: 1