I am creating website to search places using graph API. I got the places details from graph API. Is there any way to get the page rating and reviews of the places via graph API?
You can access Page Insights by typing /insights after the name of your page in the URL field. This command will retrieve all of the Insights associated with your Page. Type "/insights" after your company name. Click the Submit button.
The Facebook API returns 5 reviews per request. The order in which reviews are returned is by date from newest to oldest. You can get all reviews from a single place by using the cursor parameter. Unlike other integrations, the facebook api doesn't support the offset parameter to paginate the results.
Open the Graph Explorer in a new browser window. This allows you to execute the examples as you read this tutorial. The explorer loads with a default query with the GET method, the lastest version of the Graph API, the /me node and the id and name fields in the Query String Field, and your Facebook App.
I had the same problem and I answered my own question here:
you need to call {page-id}/ratings?field=open_graph_story, but you need the access token of your page for that (use /me/accounts in the Graph API Explorer to get the token). You find further information in the facebook documentation.
This is an old post, but I wanted to give some extra info to others that might be looking for a solution to this problem still. As stated in the Facebook Open Graph documentation, you definitely need a page access token to get the page's individual ratings/reviews. If you are looking for the overall rating and the count of reviews, however, you are in luck. By simply making a call to /{page-id}?fields=overall_star_rating,rating_count
, you will be able to access that data.
Here's an example response:
{
"overall_star_rating": 4.7,
"rating_count": 31,
"id": "{page-id}"
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With