Customer Reviews
Get a list of customer reviews
Note: This endpoint is deprecated. Use the new endpoint listed under Reviews.
This endpoint retrieves your customer reviews by channel ID. The result set can be modified using a set of filters.
The path must contain a channelId
. Note that this must be the channel ID that was assigned by eTrusted and not a user-defined ID.
Query parameters can be added to the request, separated by &
.
Conceptually, there are two types of categories for the query parameters: actual filter parameters on the one hand, rating
, submittedAfter
and submittedBefore
, and pagination parameters on the other, count
, after
and before
.
See our article on paginating response data for more information.
Parameters
Route Parameters
Name | Description |
---|---|
channelId | The ID of the channel for which a list of customer reviews will be returned. Example: |
HTTP Headers
Name | Description |
---|---|
Authorization | An OAuth2 authorization header with an access token, see OAuth2 |
Query Parameters
Name | Description |
---|---|
after |
Example: |
before |
Example: |
submittedAfter |
Example: |
submittedBefore |
Example: |
count | The desired number of customer reviews to be retrieved per page. NB: This can be set to any number from 1 to 1000 with 1000 being the maximum number of records you can get per a page |
rating | A comma-separated list of star rating values to be retrieved. If not set, all customer reviews are listed. Example: |
status | A comma-separated list of statuses to be retrieved. If not set, all customer reviews are listed. The statuses you can filter for are:
Example: See our glossary entry for more information on review statuses. |
type | A comma-separated list of customer review types to be retrieved. If not set, all customer reviews are listed. The customer review types are:
Example: See our glossary entry for more information on review types. |
hasReply | Reduces the list of customer reviews to only match customer reviews that either have been replied to or not. If not set, all customer reviews are listed. Example: |
additionalInformation | A comma-separated list of additional pieces of information to be retrieved with the customer review. If this property is not set, none of the of additional information are included in the customer review. There are the following valid additional information types:
Also see the response object Example: |
ignoreStatements | Filters the list to ignore statements. Default is true. |
query | A full-text search query that is matched against the transaction reference and customer email address properties (see the response schema). Only matching customer reviews will be included in the response. |
orderBy | Specify the date to sort the returned list of reviews by. Possible options:
|
Responses
200 - The list of customer reviews for the `channelId`.
Name | Description |
---|---|
application/json | CustomerReviewListResponseDto |
|
401 - Unauthorized
403 - Forbidden
404 - Not found
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.etrusted.com/channels/{channelId}/customer-reviews?count=95&rating=2,3,4,5",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => "",
CURLOPT_HTTPHEADER => array(
"Authorization: Bearer {access_token}",
"Content-Type: application/json",
"cache-control: no-cache"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.etrusted.com/channels/{channelId}/customer-reviews?count=95&rating=2,3,4,5",
"method": "GET",
"headers": {
"Content-Type": "application/json",
"Authorization": "Bearer {access_token}",
"cache-control": "no-cache",
},
"processData": false,
"data": ""
}
$.ajax(settings).done(function (response) {
console.log(response);
});
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://api.etrusted.com/channels/{channelId}/customer-reviews?count=95&rating=2,3,4,5")
.get()
.addHeader("Content-Type", "application/json")
.addHeader("Authorization", "Bearer {access_token}")
.addHeader("cache-control", "no-cache")
.build();
Response response = client.newCall(request).execute();
Get a customer review by ID
Note: This endpoint is deprecated. Use the new endpoint listed under Reviews.
This endpoint retrieves a customer review by its ID and its channel ID.
The path must contain a channelId
.
Note that this must be the channel ID that was assigned by eTrusted and not a customer-defined ID.
Parameters
Route Parameters
Name | Description |
---|---|
channelId | The ID of the channel for which the customer review will be returned. Example: |
customerReviewId | The customer review ID. Example: |
HTTP Headers
Name | Description |
---|---|
Authorization | An OAuth2 authorization header with an access token, see OAuth2 |
Responses
200 - The customer review with the specified ID.
Name | Description |
---|---|
application/json | CustomerReviewResponseDto |
|
401 - Unauthorized
403 - Forbidden
404 - Not found
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.etrusted.com/channels/{channelId}/customer-reviews/{customerReviewId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => "",
CURLOPT_HTTPHEADER => array(
"Authorization: Bearer {access_token}",
"Content-Type: application/json",
"cache-control: no-cache"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.etrusted.com/channels/{channelId}/customer-reviews/{customerReviewId}",
"method": "GET",
"headers": {
"Content-Type": "application/json",
"Authorization": "Bearer {access_token}",
"cache-control": "no-cache",
},
"processData": false,
"data": ""
}
$.ajax(settings).done(function (response) {
console.log(response);
});
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://api.etrusted.com/channels/{channelId}/customer-reviews/{customerReviewId}")
.get()
.addHeader("Content-Type", "application/json")
.addHeader("Authorization", "Bearer {access_token}")
.addHeader("cache-control", "no-cache")
.build();
Response response = client.newCall(request).execute();
Create a veto for a customer review
Note: This endpoint is deprecated. Use the new endpoint listed under Reviews.
This endpoint creates a veto for the specified customer review. A veto flags a customer review as inappropriate and suggests that the customer review should be removed or investigated. Veto objects consist of a comment, a reason and the associated channel name.
Note that whenever this method is called, eTrusted will create a ticket in Trusted Shops' Review Team board containing the veto data for further investigation.
Parameters
Route Parameters
Name | Description |
---|---|
channelId | The channel UUID. |
customerReviewId | The customer review UUID. |
HTTP Headers
Name | Description |
---|---|
Authorization | A token header containing information such as the account ID. |
Body
Content-Type | Type |
---|---|
application/json | ReviewVetoRequestDto |
|
Responses
200 - The veto has been saved succesfully.
Name | Description |
---|---|
application/json | ReviewVetoResponseDto |
|
400 - Bad Request
401 - Unauthorized
403 - Forbidden
404 - Not Found
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.etrusted.com/channels/{channelId}/customer-reviews/{customerReviewId}/vetos",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS =>
'{
"comment": "My veto comment.",
"reason": "UNTRUTHFUL",
"channelName": "My channel name."
}',
CURLOPT_HTTPHEADER => array(
"Authorization: Bearer {access_token}",
"Content-Type: application/json",
"cache-control: no-cache"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.etrusted.com/channels/{channelId}/customer-reviews/{customerReviewId}/vetos",
"method": "POST",
"headers": {
"Content-Type": "application/json",
"Authorization": "Bearer {access_token}",
"cache-control": "no-cache",
},
"processData": false,
"data": {
"comment": "My veto comment.",
"reason": "UNTRUTHFUL",
"channelName": "My channel name."
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
OkHttpClient client = new OkHttpClient();
MediaType mediaType = MediaType.parse("application/json");
RequestBody body = RequestBody.create(mediaType,
"{" +
"\"comment\": \"My veto comment.\"," +
"\"reason\": \"UNTRUTHFUL\"," +
"\"channelName\": \"My channel name.\"" +
"}"
);
Request request = new Request.Builder()
.url("https://api.etrusted.com/channels/{channelId}/customer-reviews/{customerReviewId}/vetos")
.post(body)
.addHeader("Content-Type", "application/json")
.addHeader("Authorization", "Bearer {access_token}")
.addHeader("cache-control", "no-cache")
.build();
Response response = client.newCall(request).execute();
Models
FeedbackType
The feedback type which is determined by the customer review title, comment and rating.
The type is REVIEW
unless either the comment or the rating are missing. In that case it is STATEMENT
.
Properties
ReviewState
The state of the customer review when the API request was processed. See our glossary entry for more information on review states.
Properties
Type
The customer review type.
A service review is a review for a channel as a whole, e.g. a shop or a store, while a product review is tied to a single product.
Properties
VerificationType
Specifies whether the collection method in combination with the provider/source can be trusted. A Review will be VERIFIED unless it comes from an external import by an account that is not explicitly marked as verified.
Properties
CustomerReviewReplyDto
The reply to the customer review, written by the channel owner.
Properties
createdAt
string
updatedAt
string
comment
string
The text message of the reply.
sendNotification
boolean
Indicates whether the reviewer is notified about the reply by eTrusted or not.
The text message of the reply.
Indicates whether the reviewer is notified about the reply by eTrusted or not.
CustomerReviewResponseProductDto
The product data retrieved with the customer review.
Properties
id
string
The product UUID.
sku
string
The Stock Keeping Unit is a specific article number of the product, most often assigned by a specific retail shop as a scannable bar code.
It lets the shops track movement of inventory.
The SKU must be unique and usually consists of about 8 characters.
mpn
string
The Manufacturer Part Number is an identifier for a product by the manufacturer if applicable.
In some cases it can serve as a substitute for the GTIN.
gtin
string
The GTIN is a unique string that identifies the product globally.
A GTIN can be an ISBN, an EAN, and much more.
Refer to gtin.info.
name
string
The product name contains information about a product that is associated with the customer review.
E.g. Specialbrand T-Shirt White M
.
url
string
The link to the product detail page in your online shop or public catalog (e.g. http://www.specialbrandshop.com/article123-TS-WH-M/).
imageUrl
string
The link to the product image of the product.
eTrusted shows a picture of the product to the customer who wants to write a review.
This makes it easier for customers to remember the purchase and recognize the product.
brand
string
The brand of the product.
A product can only have one brand.
The product UUID.
The Stock Keeping Unit is a specific article number of the product, most often assigned by a specific retail shop as a scannable bar code. It lets the shops track movement of inventory. The SKU must be unique and usually consists of about 8 characters.
The Manufacturer Part Number is an identifier for a product by the manufacturer if applicable. In some cases it can serve as a substitute for the GTIN.
The GTIN is a unique string that identifies the product globally. A GTIN can be an ISBN, an EAN, and much more. Refer to gtin.info.
The product name contains information about a product that is associated with the customer review.
E.g. Specialbrand T-Shirt White M
.
The link to the product detail page in your online shop or public catalog (e.g. http://www.specialbrandshop.com/article123-TS-WH-M/).
The link to the product image of the product. eTrusted shows a picture of the product to the customer who wants to write a review. This makes it easier for customers to remember the purchase and recognize the product.
The brand of the product. A product can only have one brand.
OriginalReview
This is the initial unedited customer review. This object will not change when the review gets edited.
Properties
rating
number
The original core review star rating. The value ranges from 1 to 5.
comment
string
The original review comment. It is a string of up to 4000 characters.
title
string
The original review title.
reply
object
The original reply to the customer review, written by the channel owner.
Properties
replyComment
string
The text message of the reply.
replyCreatedAt
string
replyUpdatedAt
string
The original core review star rating. The value ranges from 1 to 5.
The original review comment. It is a string of up to 4000 characters.
The original review title.
The original reply to the customer review, written by the channel owner.
The text message of the reply.
CustomerReviewResponseDto
A single retrieved customer review.
Properties
_object
string
The object type of this response object, which is CustomerReview
.
id
string
The customer review UUID.
accountRef
string
A UUID as account reference.
channelRef
string
A UUID as channel reference.
inviteRef
string
A UUID as invite reference.
rating
number
The star rating.
The value ranges from 1.0
to 5.0
.
title
string
A title headline for this customer review.
comment
string
The review text for this customer review.
createdAt
string
updatedAt
string
submittedAt
string
feedbackType
verificationType
reply
customer
object
This object holds information about the customer who wrote the review.
Properties
firstName
string
The first name of the customer.
lastName
string
The last name of the customer.
fullName
string
The full name of the customer.
email
string
An email address of the customer.
mobile
string
A mobile phone number of the customer.
transaction
object
The transaction associated with the customer review.
event
object
The event object that is associated with the customer review.
Properties
id
string
The event UUID.
type
string
The event type.
metadata
object
The metadata
object is a collection of user-defined data added to the customer review.
surveyData
object
The surveyData
object holds custom response data from additional questions from eTrusted questionnaires.
questionnaire
object
The questionnaire that was used to collect the customer review.
Properties
id
string
The questionnaire UUID.
locale
string
The questionnaire locale.
templateRef
string
A UUID as questionnaire template reference.
hasAttachments
boolean
This indicates if the whether the customer review has attachments, such as images.
additionalInformation
object
This object containts all of the additional information that is stored with the customer review.
Properties
veto
object
The veto of this customer review.
Properties
createdAt
string
comment
string
The comment in the ticket that was created internally at Trusted Shops for this veto.
reason
string
The reason for this veto.
This string may only have the following values:
UNTRUTHFUL
ABUSIVE
VIOLATES_THE_TERMS_OF_USE
ticketId
string
A reference to the ticket that was created internally at Trusted Shops for this veto.
The ID is a sequence of six digits.
attachments
object
Holds information about the attachments of this customer review.
Properties
images
object[]
This is a list of image objects.
Each image object represents a single image attached to this customer review.
originalReview
object
This object contains the original review, in case the consumer edited their review via our B2C world.
Properties
rating
number
The star rating before the changes.
The value ranges from 1.0
to 5.0
.
title
string
A title headline for this customer review before any changes.
comment
string
The review text for this customer review before any changes.
reply
product
editedAt
string
The date and time when the customer review was last edited by the consumer via our B2C world, in the ISO 8601 and RFC 3339 compliant format yyyy-MM-dd’T’HH:mm:ss.SSSZ
. Check the glossary for examples of valid datetime formats. Will not be present in the response when the review was never edited by the consumer.
originalReview
The object type of this response object, which is CustomerReview
.
The customer review UUID.
A UUID as account reference.
A UUID as channel reference.
A UUID as invite reference.
The star rating.
The value ranges from 1.0
to 5.0
.
A title headline for this customer review.
The review text for this customer review.
This object holds information about the customer who wrote the review.
The first name of the customer.
The last name of the customer.
The full name of the customer.
An email address of the customer.
A mobile phone number of the customer.
The transaction associated with the customer review.
The event object that is associated with the customer review.
The event UUID.
The event type.
The metadata
object is a collection of user-defined data added to the customer review.
The surveyData
object holds custom response data from additional questions from eTrusted questionnaires.
The questionnaire that was used to collect the customer review.
The questionnaire UUID.
The questionnaire locale.
A UUID as questionnaire template reference.
This indicates if the whether the customer review has attachments, such as images.
This object containts all of the additional information that is stored with the customer review.
The veto of this customer review.
The comment in the ticket that was created internally at Trusted Shops for this veto.
The reason for this veto.
This string may only have the following values:
UNTRUTHFUL
ABUSIVE
VIOLATES_THE_TERMS_OF_USE
A reference to the ticket that was created internally at Trusted Shops for this veto. The ID is a sequence of six digits.
Holds information about the attachments of this customer review.
This is a list of image objects.
Each image object represents a single image attached to this customer review.
This object contains the original review, in case the consumer edited their review via our B2C world.
The star rating before the changes.
The value ranges from 1.0
to 5.0
.
A title headline for this customer review before any changes.
The review text for this customer review before any changes.
The date and time when the customer review was last edited by the consumer via our B2C world, in the ISO 8601 and RFC 3339 compliant format yyyy-MM-dd’T’HH:mm:ss.SSSZ
. Check the glossary for examples of valid datetime formats. Will not be present in the response when the review was never edited by the consumer.
CustomerReviewListResponseDto
The list of retrieved reviews.
Properties
totalElements
integer
Deprecated. Use review/count. The value will return 0.
paging
object
The paging object holds pagination information for the reviews retrieved via this API.
Properties
count
integer
This is the number of reviews displayed in one page of the pagination.
Note that this number might be lower than the count
number in the request. This happens when the last page is reached.
For example: A total number of 105 reviews are displayed in chunks of 20 reviews per page. The sixth and last page will only have 5 reviews. The count
property will hold the value 5
.
cursor
object
The cursor object contains information to navigate to the previous and next pages in a subsequent request.
Properties
before
string
This is a review ID to retrieve the previous page in the pagination.
after
string
This is a review ID to retrieve the next page in the pagination. It is empty if it is the last page in the pagination.
links
object
Links to the previous and next pages in the pagination.
Note that the links contain the exact filter parameters that were used in the request (rating
, submittedBefore
, submittedAfter
).
This makes sure that the pagination is always relative to the same filter in subsequent requests.
If developers build URLs themselves using after
, before
, and the matching information inside the cursor
object, they may need to ensure to recreate the same filter as well.
Properties
previous
string
The link to the previous page in the pagination.
next
string
The link to the next page in the pagination. It is empty if it is the last page in the pagination.
This is the list of review objects.
Each item
object represents a single retrieved review.
Deprecated. Use review/count. The value will return 0.
The paging object holds pagination information for the reviews retrieved via this API.
This is the number of reviews displayed in one page of the pagination.
Note that this number might be lower than the count
number in the request. This happens when the last page is reached.
For example: A total number of 105 reviews are displayed in chunks of 20 reviews per page. The sixth and last page will only have 5 reviews. The count
property will hold the value 5
.
The cursor object contains information to navigate to the previous and next pages in a subsequent request.
This is a review ID to retrieve the previous page in the pagination.
This is a review ID to retrieve the next page in the pagination. It is empty if it is the last page in the pagination.
Links to the previous and next pages in the pagination.
Note that the links contain the exact filter parameters that were used in the request (rating
, submittedBefore
, submittedAfter
).
This makes sure that the pagination is always relative to the same filter in subsequent requests.
If developers build URLs themselves using after
, before
, and the matching information inside the cursor
object, they may need to ensure to recreate the same filter as well.
The link to the previous page in the pagination.
The link to the next page in the pagination. It is empty if it is the last page in the pagination.
This is the list of review objects.
Each item
object represents a single retrieved review.
ReviewVetoRequestDto
Properties
comment
string
The veto comment.
Provide additional information on the review or your veto here.
reason
string
The reason for the veto.
This string may only have the following values:
UNTRUTHFUL
ABUSIVE
,
VIOLATES_THE_TERMS_OF_USE
vetoReporterEmail
string
The E-Mail address of the veto reporter.
channelName
string
The name of the channel the review is associated with.
The veto comment. Provide additional information on the review or your veto here.
The reason for the veto.
This string may only have the following values:
UNTRUTHFUL
ABUSIVE
,VIOLATES_THE_TERMS_OF_USE
The E-Mail address of the veto reporter.
The name of the channel the review is associated with.
ReviewVetoResponseDto
The veto has been saved successfully.
Properties
id
string
The veto UUID.
ticketId
string
A reference to the ticket that was created internally at Trusted Shops for this veto.
The ID is a sequence of six digits.
comment
string
The comment in the ticket that was created internally at Trusted Shops for this veto.
reason
string
The reason for this veto.
This string may only have the following values:
UNTRUTHFUL
ABUSIVE
VIOLATES_THE_TERMS_OF_USE
createdAt
string
updatedAt
string
The veto UUID.
A reference to the ticket that was created internally at Trusted Shops for this veto. The ID is a sequence of six digits.
The comment in the ticket that was created internally at Trusted Shops for this veto.
The reason for this veto.
This string may only have the following values:
UNTRUTHFUL
ABUSIVE
VIOLATES_THE_TERMS_OF_USE
Need further support?
Visit the Help Centre for further information, or contact us. Are some words or terms unfamiliar? Then visit the glossary for clarification.