Ratings

This API returns the rating details of the mapped products for a given brand and date.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Sample Response

{
    "success": true,
    "message": "",
    "errorCode": "",
    "result": {
        "data": [
            {
                "codeType": "EAN",
                "merchant": "shopee",
                "brand": "anmum",
                "skuId": "B079ZC7KKN",
                "title": "Anmum Essential Step 3 Plain (1.5kg)",
                "code": "6902395642602",
                "coc": false,
                "ratingsCount": 185,
                "avgRating": 4.962162,
                "ratingsDistribution": {
                    "4_star": 2,
                    "3_star": 1,
                    "2_star": 1,
                    "5_star": 181,
                    "1_star": 0
                }
            }
        ],
        "total": 1,
        "type": "rating",
        "date": "2021-05-02"
    }
}

Response Fields

FieldDescriptionData Type
successIndicates if API response is success or not.bool
messageResponse message. Typically populated in error scenarios.string
errorCodeError code.string
codeTypeProduct code type.string
merchantMerchant name.string
brandBrand name.string
skuIdProduct id at merchant site.string
ratingCountNumber of ratings.number
avgRatingAverage rating.number
ratingsDistributionRatings Split.object
titleTitle as seen at merchant site.string
codeProduct code.string
cocCore of the core.bool
totalTotal product count.number
dateDate.string

Exceptions and Error Conditions

The Rating API will look for matching data based on the filters applied. However, there are a few scenarios where the API may not be able to return a valid response. For example

  • Data request for a future date
  • Data requested for invalid merchant/brand combination
  • Invalid access token (API response status code 401)
  • Missing authentication token (API response status code 401)

In all the above scenarios, the Rating API would return with an error response.
Example:

{
  "success": false,
  "message": "You can not request for future date",
  "errorCode": "INVALID_DATE",
  "result": ""
}
Query Params
string
required

Country code (e.g. us (USA), in (India), my (Malaysia)).

string

Merchant names separated by comma (e.g. amazon,shopee).

string
required
Defaults to anmum

Brand name.

string

Competitor brand name.

date
required
Defaults to 2021-05-02

Date in yyyy-mm-dd format.

Headers
string
required
Response

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here!