Olery Developer Portal logo Olery Developer Portal

Method Path
GET https://agora.olery.com/v3/companies/:id/sentiment

Returns sentiment opinions stats (as times series and/or grouped by traveler segment)

About Sentiment

All reviews with written content in English, German, French, Dutch, Italian and Spanish get analyzed for the reviewer’s sentiment towards certain topics (see page “Sentiment Topics”).

Each review can contain multiple opinions for the same or different topics. “The room was nice. It was also very large.” might count as 2 positive opinions for “room”.

You are limited to 1 request per second. Please use this endpoint responsibly. Requests with long time periods and multiple groupings are resource-intensive.

Output Format

The meta field contains general information about the property.

The aggregated data is returned as an Array of JSON objects in the data field. Each object has the following fields:

Field Data Types Description
topic String Topic of the rating
positive_opinions Integer Count of times the topic was mentioned in a positive context
negative_opinions Integer Count of times the topic was mentioned in a negative context
review_count Integer Count of reviews the opinions are from
opinions_count Integer Total count of opinions
sentiment_score Float Sentiment on a scale from -1 to 1
positive_percentage Float Simple percentage of positive opinions
date Date Start date of each time period, if per parameter is used
segment String Segment, if segment parameter is used

In case of grouping by per or segment the data is found in the opinions object for each group.

The sentiment score is a float on a scale from -1.0 to 1.0. A value of -1.0 indicates a completely negative opinion while 1.0 indicates a completely positive opinion. The calculation is (positive count - negative count) / (positive count + negative count).


Parameter Parameter Type Data Types Required Description
id path Integer true ID of the company
start_date query Date true Start date in ISO 8601 format
end_date query Date true End date in ISO 8601 format
subratings query Boolean false Toggle subratings array
per query String false Date grouping (day, month, quarter, year)
segment query String false Segment grouping (origin-country, composition, language, source)
topic query String false Filter the output by a list of comma-separated topics

Example Call


Example Output

         "name":"Hotel Casa"

Response Statuses

Status Code Reason
200 OK
404 Company not found
403 No access, no authentication token
400 Missing or incorrect dates