Review API v2
- Renata Rusecka
- David Maicher
- Estelle Lesot (Deactivated)
You will need an API key for authorizing your requests. You can request an API key from our Customer Care team.
The API key must be passed in an HTTP header named X-CA-AUTH when requesting any of the API endpoints.
The default endpoint is https://api.customer-alliance.com, if not stated differently.
Reviews
GET /reviews/v2/ca.json
The new version of the Review API is available here
API allows access to the data that was collected via Customer Alliance review questionnaires. This may include information such as:
Review content;
Average rating;
Information about the guest leaving the review.
Parameters
All parameters are optional.
Name | Default value | Description |
---|
Name | Default value | Description |
---|---|---|
| 1 | Integer greater than or equal to 1. |
| 180 days before the end date | Date in the YYYY-MM-DD format. |
| today | Date in the YYYY-MM-DD format. |
| 'average' | A valid review rating category, also known as a 'criteria'. |
| 0 | Integer between 0 and 100. |
| 100 | Integer between 0 and 100. |
| no value | Must be one of:
Filters reviews as to whether they have been commented, not commented or have had a comment drafted. |
| 0 | Either 1 or 0. |
| 0 | Either 1 or 0. |
| 20 | The number of reviews shown per page. |
Examples
Shell
curl --header "X-CA-AUTH: <YOUR_API_KEY_HERE>" https://api.customer-alliance.com/reviews/v2/ca.json?page=1&start=2021-01-01&end=2021-01-13&fromRating=0&toRating=100&categoryRatings=1&published=0&limit=20
Response
{
"totalCount": 1,
"reviews": [
{
"hotel_name": "Restaurant The Eagle",
"review_id": "careview52326183",
"review_source": "customeralliance",
"average_rating_normalized": "90.0000",
"average_rating": "4.5000",
"reviewer_type": null,
"language": "en",
"published": false,
"reviewer_comment": "It was a nice experience, definitely worth coming again",
"reviewer_comment_positive": "",
"reviewer_comment_negative": "",
"arrival_date": "2021-01-09",
"departure_date": "2021-01-09",
"review_date": "2021-01-12 09:07:46",
"author": "Customer Alliance u.",
"category_ratings": {
"price": {
"rating": 80,
"label": "Price",
"comment": null
},
"service": {
"rating": 100,
"label": "Service",
"comment": null
},
"FoodQuality": {
"rating": 100,
"label": "Quality of Food",
"comment": null
},
"Atmosphere": {
"rating": 80,
"label": "Atmosphere",
"comment": null
}
},
"nps": 9,
"brand_nps": null,
"age": 30,
"hotelier_comment": null
}
]
}
GET /reviews/v2/all.json
Review data collected via Customer Alliance questionnaires and reviews from external portals (for example Booking, Google, Expedia, Tripadvisor, HolidayCheck).
Parameters
All parameters are optional.
Name | Default value | Description |
---|
Name | Default value | Description |
---|---|---|
| 1 | Integer greater than or equal to 1. |
| 180 days before the end date | Date in the YYYY-MM-DD format. |
| today | Date in the YYYY-MM-DD format. |
| 0 | Integer between 0 and 100. |
| 100 | Integer between 0 and 100. |
| no value | Must be one of:
Filters reviews as to whether they have been commented, not commented or have had a comment drafted. |
| 0 | Either 1 or 0. |
| 20 | The number of reviews shown per page. |
Examples
Shell
curl --header "X-CA-AUTH: <YOUR_API_KEY_HERE>" https://api.customer-alliance.com/reviews/v2/all.json?page=1&start=2021-01-01&end=2021-01-12&fromRating=80&toRating=100
Response
Please note that we have the latest version (V3) available here Review API v3
Statistics
GET /statistics/v1/categories.json
Shows the rating categories currently used for aggregation on your API key.
The data refreshes every 2 hours.
Parameters
All parameters are optional.
Name | Default value | Description |
---|
Name | Default value | Description |
---|---|---|
| First created review subject | It refers to Review Config's hash value. By default access key has access to 100 review subjects, by using "review_subject" parameter you can specify for which subject you would like to retrieve data. |
Examples
Shell
Response
GET /statistics/v2/general/recent.json
Shows statistics for rating categories, including the overall category, for all reviews authored in the past 6 months.
Parameters
All parameters are optional.
Name | Default value | Description |
---|
Name | Default value | Description |
---|---|---|
| en | Changes the language used to show the category labels. Must be a valid ISO 3166-1 alpha-2 language code. For example: 'en' for English, 'fr' for French. |
| First created review subject | It refers to Review Config's hash value. By default access key has access to 100 review subjects, by using "review_subject" parameter you can specify for which subject you would like to retrieve data. |
| no value | Possible values: either 0 or 1. If set to 1 will return only data about published reviews (public reviews). |
Examples
Shell
Response
GET /statistics/v2/general/total.json
Shows statistics for rating categories, including the overall category, for all known reviews.
If the parameter 'review_subject' is not set, the statistics will be shown for the first created review subject of the api-key.
Parameters
All parameters are optional.
Name | Default value | Description |
---|
Name | Default value | Description |
---|---|---|
| en | Changes the language used to show the category labels. Must be a valid ISO 3166-1 alpha-2 language code. For example: 'en' for English, 'fr' for French. |
| first created review subject | It refers to Review Config's hash value. By default access key has access to 100 review subjects, by using "review_subject" parameter you can specify for which subject you would like to retrieve data. |
| no value | Possible values: either 0 or 1. If set to 1 will return only data about published reviews (public reviews). |
Examples
Shell
Response
Feedbacks
Monitoring
Guests