Amazon Reviews API (Async)

This endpoint will retrieve reviews for a specified product from an Amazon reviews page and transform it into usable JSON.

Single ASIN Request:

<?php
$curl = curl_init();
$data = json_encode(array(
    'apiKey' => 'APIKEY',
    'asin' => 'ASIN',
    'callback' => array(
        'type' => 'webhook',
        'url' => 'CALLBACK'
    )
));
curl_setopt_array($curl, array(
  CURLOPT_URL => 'http://async.scraperapi.com/structured/amazon/review',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => $data,
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json'
  ),
));
$response = curl_exec($curl);
if (curl_errno($curl)) {
    echo 'Error:' . curl_error($curl);
} else {
    echo $response;
}
curl_close($curl);
?>

Multiple ASIN Request:

<?php
$curl = curl_init();
$data = json_encode(array(
    'apiKey' => 'APIKEY',
    'asins' => ['ASIN1','ASIN2','ASIN3'],
    'callback' => array(
        'type' => 'webhook',
        'url' => 'CALLBACK'
    )
));
curl_setopt_array($curl, array(
  CURLOPT_URL => 'http://async.scraperapi.com/structured/amazon/review',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS => $data,
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json'
  ),
));
$response = curl_exec($curl);
if (curl_errno($curl)) {
    echo 'Error:' . curl_error($curl);
} else {
    echo $response;
}
curl_close($curl);
?>

Multiple Parameters can be used with this method:

REQUIRED

APIKEY

User account’s normal API key.

ASIN

Amazon product ASIN.

OPTIONAL

TLD

Valid values include:

com (amazon.com)

co.uk (amazon.co.uk)

ca (amazon.ca)

de (amazon.de)

es (amazon.es)

fr (amazon.fr)

it (amazon.it)

jp (amazon.co.jp)

in (amazon.in)

cn (amazon.cn)

sg (amazon.com.sg)

mx (amazon.com.mx)

ae (amazon.ae)

br (amazon.com.br)

nl (amazon.nl)

au (amazon.com.au)

tr (amazon.com.tr)

sa (amazon.sa)

se (amazon.se)

pl (amazon.pl)

COUNTRY

Valid values are two letter country codes for which we offer Geo Targeting (e.g. “au”, “es”, “it”, etc.).

Where an amazon domain needs to be scraped from another country (e.g. scraping amazon.com from Canada to get Canadian shipping information), both TLD and COUNTRY parameters must be specified.

REFERENCE

A reference string used by amazon. For example: olp_f_usedAcceptable

FILTERBYSTAR

Filter the results by stars. For example: all_stars

REVIEWERTYPE

Filter the results by type. For example: all_reviews

PAGENUMBER

Paginating the result. For example: 1

Sample Response

Single ASIN Request:

{
	"id": "f9c41146-ecd3-415c-ae0a-461de670e2e8",
	"status": "running",
	"statusUrl": "http://async.scraperapi.com/structured/amazon/review/f9c41146-ecd3-415c-ae0a-461de670e2e8",
	"asin": "B079BLHH67"
}

Multiple ASIN Request:

[
	{
		"id": "5b0c838a-d0eb-46c3-ad9a-e82e398d56a5",
		"status": "running",
		"statusUrl": "http://async.scraperapi.com/structured/amazon/review/5b0c838a-d0eb-46c3-ad9a-e82e398d56a5",
		"asin": "B079BLHH67"
	},
	{
		"id": "df83b9e1-be25-40de-8702-4e934f057867",
		"status": "running",
		"statusUrl": "http://async.scraperapi.com/structured/amazon/review/df83b9e1-be25-40de-8702-4e934f057867",
		"asin": "B07G98GG51"
	}
]

After the job(s) finish, you will find the result under the response key in the response JSON object. The structure is the same as in the corresponding SYNC data endpoint.

Last updated