Overview
Here is the list of the different parameters you can use with ScrapingBee's Amazon API.
You can also discover this API using our Postman collection covering every ScrapingBee's features.
Our Amazon API allows you to scrape Amazon search results and product details in realtime.
We provide two endpoints:
- Search endpoint (
/api/v1/amazon/search
) - Fetch Amazon search results - Product endpoint (
/api/v1/amazon/product
) - Fetch structured Amazon product details
Amazon Product API
Quick start
To scrape Amazon product details, you only need two things:
- your API key, available here
- a product ASIN (learn more about ASIN)
Then, simply do this.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Here is a breakdown of all the parameters you can use with the Amazon Product API:
type
]
(default
)Response Example
The API will then respond with formatted JSON data:
{
"ads": null,
"answered_questions_count": 0,
"asin": "B0DPDRNSXV",
"asin_in_url": "B0DPDRNSXV",
"brand": "Apple",
"bullet_points": "This pre-owned product is not Apple certified, but has been professionally inspected, tested and cleaned by Amazon-qualified suppliers.\nThere will be no visible cosmetic imperfections when held at an arm’s length. There will be no visible cosmetic imperfections when held at an arm’s length.\nThis product will have a battery which exceeds 80% capacity relative to new.\nAccessories will not be original, but will be compatible and fully functional. Product may come in generic Box.\nThis product is eligible for a replacement or refund within 90 days of receipt if you are not satisfied.",
"buybox": null,
"category": [
{
"ladder": [
{
"name": "Cell Phones & Accessories",
"url": "/cell-phones-service-plans-accessories/b/ref=dp_bc_1?ie=UTF8&node=2335752011"
},
{
"name": "Cell Phones",
"url": "/cell-phone-devices/b/ref=dp_bc_2?ie=UTF8&node=7072561011"
}
]
}
],
"coupon": "",
"coupon_discount_percentage": null,
"currency": "USD",
"deal_type": null,
"delivery": [
{
"date": {
"by": "Tomorrow, September 13"
},
"type": "FREE delivery"
}
],
"description": "Apple iPhone 16, US Version, 128GB, Pink - Unlocked (Renewed Premium)",
"developer_info": [],
"discount_end": null,
"discount_percentage": 11,
"featured_merchant": {
"is_amazon_fulfilled": false,
"link": "/gp/help/seller/at-a-glance.html/ref=dp_merchant_link?ie=UTF8&seller=A230ZFNKXE1WUD&asin=B0DPDRNSXV&ref_=dp_merchant_link",
"name": "ELECTRONIC DEALS",
"seller_id": "A230ZFNKXE1WUD",
"shipped_from": "ELECTRONIC DEALS"
},
"has_videos": false,
"highest_price": 675,
"html": null,
"images": [
"https://m.media-amazon.com/images/I/31-6u85wcSL._AC_.jpg"
],
"important_information": null,
"is_addon_item": null,
"is_prime": false,
"item_form": null,
"lightning_deal": null,
"manufacturer": "Amazon Renewed",
"max_quantity": 9,
"other_sellers": null,
"page": 1,
"page_type": "Product",
"parent_asin": "B0DPTG2HKV",
"price": 675,
"price_buybox": 675,
"price_shipping": 0,
"price_sns": 0,
"price_strikethrough": 0,
"pricing_count": 1,
"pricing_str": "Renewed (7) from $675.00$675.00 & FREE Shipping",
"pricing_url": "https://www.amazon.com/gp/offer-listing/B0DPDRNSXV/ref=dp_olp_NEW_mbc?ie=UTF8&condition=NEW",
"product_details": {
"asin": "B0DPDRNSXV",
"batteries": "1 Lithium Ion batteries required. (included)",
"battery_capacity": "3491 Milliamp Hours",
"battery_power_rating": "3561 Milliamp Hours",
"best_sellers_rank": "#5,163 in Cell Phones & Accessories (See Top 100 in Cell Phones & Accessories) #68 in Renewed Smartphones #100 in Cell Phones",
"color": "Pink",
"connectivity_technologies": "Infrared, USB, Wi-Fi, Wireless",
"customer_reviews": "4.6 4.6 out of 5 stars 114 ratings 4.6 out of 5 stars",
"date_first_available": "October 20, 2024",
"form_factor": "Bar",
"human_interface_input": "Touchscreen",
"item_model_number": "A3081",
"item_weight": "5.9 ounces",
"manufacturer": "Apple",
"memory_storage_capacity": "128 GB",
"os": "iOS 18",
"other_display_features": "Wireless",
"product_dimensions": "5.81 x 2.82 x 0.31 inches",
"ram_memory_installed_size": "8 GB",
"scanner_resolution": "2556 x 1179",
"standing_screen_display_size": "6.1 Inches",
"weight": "0.37 Pounds",
"whats_in_the_box": "Apple iPhone 16, USB Cable"
},
"product_dimensions": "5.81 x 2.82 x 0.31 inches",
"product_name": "Apple iPhone 16, US Version, 128GB, Pink - Unlocked (Renewed Premium)",
"product_overview": [
{
"description": "Apple",
"title": "Brand"
},
{
"description": "iOS 18",
"title": "Operating System"
},
{
"description": "8 GB",
"title": "Ram Memory Installed Size"
},
{
"description": "Apple A18",
"title": "CPU Model"
},
{
"description": "3.2 GHz",
"title": "CPU Speed"
},
{
"description": "128 GB",
"title": "Memory Storage Capacity"
},
{
"description": "6.1 Inches",
"title": "Screen Size"
},
{
"description": "2556 x 1179",
"title": "Resolution"
},
{
"description": "60 Hz",
"title": "Refresh Rate"
},
{
"description": "iPhone 16",
"title": "Model Name"
}
],
"rating": 4.6,
"rating_stars_distribution": null,
"reviews": [],
"reviews_count": 114,
"sales_rank": [
{
"ladder": [
{
"name": "Cell Phones & Accessories ",
"url": "/gp/bestsellers/wireless/ref=pd_zg_ts_wireless"
}
],
"rank": 5163
},
{
"ladder": [
{
"name": "Renewed Smartphones",
"url": "/gp/bestsellers/amazon-renewed/17871142011/ref=pd_zg_hrsr_amazon-renewed"
}
],
"rank": 68
},
{
"ladder": [
{
"name": "Cell Phones",
"url": "/gp/bestsellers/wireless/7072561011/ref=pd_zg_hrsr_wireless"
}
],
"rank": 100
}
],
"sns_discounts": [],
"stock": "Only 9 left in stock - order soon.",
"store_url": "/Amazon-Renewed/b/ref=bl_dp_s_web_12653393011?ie=UTF8&node=12653393011&field-lbr_brands_browse-bin=Amazon+Renewed",
"technical_details": null,
"title": "Apple iPhone 16, US Version, 128GB, Pink - Unlocked (Renewed Premium)",
"url": "https://www.amazon.com/dp/B0DPDRNSXV?language=en_US",
"variations": [
{
"asin": "B0DPCYVF47",
"dimensions": {
"Color": "Black",
"Size": "128GB",
"Wireless Provider": "T-Mobile"
},
"selected": false
},
...
{
"asin": "B0DPDSD11Q",
"dimensions": {
"Color": "Teal",
"Size": "128GB",
"Wireless Provider": "Unlocked for All Carriers"
},
"selected": false
}
],
"warranty_and_support": null
}
Keep in mind that each successful API call will cost you 5 api credits, unless you disable light requests by setting light_request=false
, in which case it will cost you 15 api credits.
Every request that failed will be tried as many times as possible for 30 seconds.
So please be aware of this maximum timeout when writing your own code.
API key
api_key
[string
]
(default= ""
)
required
All requests are authenticated by using your private API key.
To get access to your API key, just create an account here and confirm your email.
Light Request
light_request
[boolean
]
(default= true
)Light requests are a way to get a quick response from the API without JavaScript rendering. They are also cheaper than regular requests, costing only 5 credits per request instead of 15.
However, since those requests do not use a web browser, they might not return all the data that a regular request would return.
This can be useful for simple pages or when you want to save credits, but we suggest you disable it if you're looking to get reviews or other dynamic content.
To disable light requests and force JavaScript rendering, you can add the light_request=false
parameter to your request.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&light_request=False&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'light_request': 'False',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'light_request': False,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Product ASIN
query
[string
]
(default= ""
)
required
The query
parameter is the Amazon Standard Identification Number (ASIN) of the product. This is a unique 10-character alphanumeric identifier assigned by Amazon and is required for the product endpoint.
You can find the ASIN in the URL of any Amazon product page. For example, in the URL:
https://www.amazon.com/dp/B0DPDRNSXV/
The ASIN is B0DPDRNSXV
.
You can also find the ASIN in the product details section of any Amazon product page.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Device
device
[string
]
(default= desktop
)device
controls the device type for the request. You can use desktop
, mobile
or tablet
.
By default, the API uses desktop
. Mobile results may differ in layout and available product information.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&device=mobile&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'device': 'mobile',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'device': mobile,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Domain
domain
[string
]
(default= com
)The domain
parameter allows you to specify an Amazon domain for localization purposes.
Available domains include:
com
(United States) Defaultae
(United Arab Emirates)ca
(Canada)cn
(China)co.jp
(Japan)co.uk
(United Kingdom)com.au
(Australia)com.be
(Belgium)com.br
(Brazil)com.mx
(Mexico)com.tr
(Turkey)de
(Germany)eg
(Egypt)es
(Spain)fr
(France)in
(India)it
(Italy)nl
(Netherlands)pl
(Poland)sa
(Saudi Arabia)se
(Sweden)sg
(Singapore)
This parameter helps you get localized product information, prices, and availability.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&domain=co.uk&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'domain': 'co.uk',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'domain': co.uk,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Country
country
[string
]
(default= ""
)The country
parameter sets the geolocation from which the request appears to originate. This can affect product availability, shipping options, and regional pricing.
Use ISO country codes like:
us
- United Statesgb
- United Kingdomde
- Germanyfr
- France
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&country=us&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'country': 'us',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'country': us,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
ZIP Code
zip_code
[string
]
(default= ""
)Use zip_code
to get results for a specific postal code area. This affects shipping costs, delivery times, and local availability:
zip_code=10001
This parameter works in conjunction with the country parameter to provide accurate local information.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&query=B0DPDRNSXV&zip_code=10001"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'query': 'B0DPDRNSXV',
'zip_code': '10001',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': B0DPDRNSXV,
'zip_code': 10001,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV&zip_code=10001")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV&zip_code=10001')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV&zip_code=10001');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&query=B0DPDRNSXV&zip_code=10001", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Language
language
[string
]
(default= ""
)The language
parameter controls the language in which product information is displayed. Use ISO language codes:
en
- Englishes
- Spanishfr
- Frenchde
- Germanit
- Italianja
- Japanese
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&language=en&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'language': 'en',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'language': en,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Currency
currency
[string
]
(default= ""
)The currency
parameter allows you to specify the currency for price display using ISO 4217 currency codes:
USD
- US DollarEUR
- EuroGBP
- British PoundJPY
- Japanese YenCAD
- Canadian Dollar
Note that currency conversion may not always be available depending on the domain and product.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY¤cy=USD&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'currency': 'USD',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'currency': USD,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Full HTML
add_html
[boolean
]
(default= false
)The add_html
parameter allows you to include the full HTML of the product page in the response. By default, this is set to false
, if you want to include the HTML, pass add_html=true
to your API call.
curl "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&add_html=true&query=B0DPDRNSXV"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/product',
params={
'api_key': 'YOUR-API-KEY',
'add_html': 'true',
'query': 'B0DPDRNSXV',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/product', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'add_html': true,
'query': B0DPDRNSXV,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=B0DPDRNSXV")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=B0DPDRNSXV')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=B0DPDRNSXV');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/product?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=B0DPDRNSXV", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Amazon Search API
Quick start
To scrape Amazon search results, you only need two things:
- your API key, available here
- a search query (learn more about search query)
Then, simply do this.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&query=iphone+16"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'query': 'iphone 16',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': iphone 16,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=iphone+16")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=iphone+16')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=iphone+16');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=iphone+16", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Here is a breakdown of all the parameters you can use with the Amazon Search API:
type
]
(default
)"most_recent" | "price_low_to_high" | "price_high_to_low" | "featured" | "average_review" | "bestsellers"
]
(""
)Response Example
The API will then respond with formatted JSON data:
{
"html": "", # Use add_html=true to get the full HTML response
"url": "https://www.amazon.com/s?k=iphone+16&page=1&language=en_US"
"page": 1,
"products": [
{
"asin": "B0DGHH9WMX",
"best_seller": false,
"currency": "USD",
"highest_price": 39.99,
"is_amazons_choice": false,
"is_prime": false,
"is_sponsored": true,
"is_video": null,
"manufacturer": "",
"organic_position": 1,
"price": 39.99,
"price_strikethrough": 49,
"pricing_count": 1,
"rating": 4.5,
"reviews_count": 1934,
"sales_volume": "500+ bought in past month",
"shipping_information": "FREE delivery Mon, Sep 22",
"sponsored_position": null,
"title": "iPhone 16 Clear Case with MagSafe and Camera Control: Lightweight Phone Case, Wireless Charging Compatible, Smooth Glossy Finish",
"url": "/sspa/click?ie=UTF8&spc=MTo3OTg1MzI2MDA1MzM3Nzg0OjE3NTc2NjM2OTY6c3BfYXRmOjMwMDQwNzcxMzk2NTkwMjo6MDo6&url=/Apple-iPhone-MagSafe-Camera-Control/dp/B0DGHH9WMX/ref=sr_1_1_sspa?dib=eyJ2IjoiMSJ9.MUo4aqcokGTenXfAL4iZAn2MnWqsNIC9tCokWLgO5AG-PvJmF4Bn99Cp1OhJKoivOrII9El6_dDsYNU8-RFZmmxabOG-1v_2V1tsPCtpbNuHFGM1devOF_7Gn_tuRu0LnuLfg3QkRpMXXkeqpSucS6aa7Ba6g4mPG08f16opjwwtJ-zZHY0FvHq480uhXBfcfpaqEkUQKHvroWqvyTGicwn74QvOahjq1f-xBjhBl3I.fcm270pzFN4A4U4QIiIkzvqIgXtkAmIeFL243g-kEC4&dib_tag=se&keywords=iphone+16&qid=1757663696&sr=8-1-spons&sp_csd=d2lkZ2V0TmFtZT1zcF9hdGY&psc=1",
"url_image": "https://m.media-amazon.com/images/I/71K2g1AgnLL._AC_UY218_.jpg",
"variations": []
},
...
{
"asin": "B0DMYRZJ69",
"best_seller": false,
"currency": "USD",
"highest_price": 569.56,
"is_amazons_choice": false,
"is_prime": false,
"is_sponsored": false,
"is_video": null,
"manufacturer": "",
"organic_position": 18,
"price": 569.56,
"price_strikethrough": 598.82,
"pricing_count": 1,
"rating": 4.5,
"reviews_count": 55,
"sales_volume": "50+ bought in past month",
"shipping_information": "FREE delivery Mon, Sep 22Or fastest delivery Tomorrow, Sep 13",
"sponsored_position": null,
"title": "Apple iPhone 16 Plus, 128GB, Pink - T-Mobile (Renewed)",
"url": "/Apple-iPhone-Plus-128GB-Pink/dp/B0DMYRZJ69/ref=sr_1_18?dib=eyJ2IjoiMSJ9.MUo4aqcokGTenXfAL4iZAn2MnWqsNIC9tCokWLgO5AG-PvJmF4Bn99Cp1OhJKoivOrII9El6_dDsYNU8-RFZmmxabOG-1v_2V1tsPCtpbNuHFGM1devOF_7Gn_tuRu0LnuLfg3QkRpMXXkeqpSucS6aa7Ba6g4mPG08f16opjwwtJ-zZHY0FvHq480uhXBfcfpaqEkUQKHvroWqvyTGicwn74QvOahjq1f-xBjhBl3I.fcm270pzFN4A4U4QIiIkzvqIgXtkAmIeFL243g-kEC4&dib_tag=se&keywords=iphone+16&qid=1757663696&sr=8-18",
"url_image": "https://m.media-amazon.com/images/I/31BVQroLBUL._AC_UY218_.jpg",
"variations": []
}
],
"products_count": 22,
"refinements": {
"battery_capacity": [
{
"link": "/s?k=iphone+16&rh=n%3A21514055011%2Cp_n_g-101015098008111%3A120185115011&dc&language=en_US&qid=1757663696&rnid=120185111011&ref=sr_nr_p_n_g-101015098008111_1&ds=v1%3AU%2FHfUzaCpWwZoHXb43Xf7R2Ab58ACAbasU9LsBEcUE4",
"name": "Up to 2,999 mAh",
"refinement_display_name": "Battery Capacity",
"value": "n:21514055011,p_n_g-101015098008111/120185115011"
},
{
"link": "/s?k=iphone+16&rh=n%3A21514055011%2Cp_n_g-101015098008111%3A120185114011&dc&language=en_US&qid=1757663696&rnid=120185111011&ref=sr_nr_p_n_g-101015098008111_2&ds=v1%3AFFyukaU7Fws1%2FAjuxyDrYQRn7b06vm8UZQmW%2B3T8i8I",
"name": "3,000 to 3,999 mAh",
"refinement_display_name": "Battery Capacity",
"value": "n:21514055011,p_n_g-101015098008111/120185114011"
},
{
"link": "/s?k=iphone+16&rh=n%3A21514055011%2Cp_n_g-101015098008111%3A120185112011&dc&language=en_US&qid=1757663696&rnid=120185111011&ref=sr_nr_p_n_g-101015098008111_3&ds=v1%3AHheQ1XxVNf%2F%2BI8vagmRZ1ttGGO1%2BpIWVXJU%2FsJPtTZU",
"name": "4,000 to 4,999 mAh",
"refinement_display_name": "Battery Capacity",
"value": "n:21514055011,p_n_g-101015098008111/120185112011"
},
{
"link": "/s?k=iphone+16&rh=n%3A21514055011%2Cp_n_g-101015098008111%3A120185113011&dc&language=en_US&qid=1757663696&rnid=120185111011&ref=sr_nr_p_n_g-101015098008111_4&ds=v1%3AHTRHkdpT6I8We0JPHIFIqYgXquS8c7GITCEvTzC%2BzUg",
"name": "5,000 to 5,999 mAh",
"refinement_display_name": "Battery Capacity",
"value": "n:21514055011,p_n_g-101015098008111/120185113011"
},
{
"link": "/s?k=iphone+16&rh=n%3A21514055011%2Cp_n_g-101015098008111%3A120224515011&dc&language=en_US&qid=1757663696&rnid=120185111011&ref=sr_nr_p_n_g-101015098008111_5&ds=v1%3AxfVFtKOkVhKiCGB9KqXIEmwoNj2UJhwBc5z5t1CYA9Y",
"name": "6,000 mAh & Above",
"refinement_display_name": "Battery Capacity",
"value": "n:21514055011,p_n_g-101015098008111/120224515011"
}
],
...
},
}
Keep in mind that each successful API call will cost you 5 api credits per page, unless you disable light requests by setting light_request=false
, in which case it will cost you 15 api credits per page.
Every search that failed will be tried as many times as possible for 30 seconds.
So please be aware of this maximum timeout when writing your own code.
API key
api_key
All requests are authenticated by using your private API key.
To get access to your API key, just create an account here and confirm your email.
Light Request
light_request
[boolean
]
(default= true
)Light requests are a way to get a quick response from the API without JavaScript rendering. They are also cheaper than regular requests, costing only 10 credits per request instead of 15.
However, since those requests do not use a web browser, they might not return all the data that a regular request would return.
To disable light requests and force JavaScript rendering, you can add the light_request=false
parameter to your request.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&light_request=False&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'light_request': 'False',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'light_request': False,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&light_request=False&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Search Query
query
[string
]
(default= ""
)
required
The query
parameter is the text you would search for on Amazon.com. This is required for the search endpoint.
Never forget to correctly encode this parameter before calling the API, especially if you are using special characters.
If you need help encoding your parameter you can find more information below:
sudo apt-get install gridsite-clients
urlencode "YOUR SEARCH"
import urllib.parse
encoded_url = urllib.parse.quote("YOUR SEARCH")
encoded_url = encodeURIComponent("YOUR SEARCH")
String encoded_url = URLEncoder.encode("YOUR SEARCH", "UTF-8");
require 'uri'
encoded_url = URI::encode("YOUR SEARCH")
<?php
$url_encoded = urlencode("YOUR SEARCH");
?>
package main
import (
"net/url"
)
func main() {
encoded_url := url.QueryEscape("YOUR SEARCH")
}
Start Page
start_page
[integer
]
(default= 1
)The start_page
parameter specifies which page of results to start fetching from. Default is 1.
For example:
start_page=1
- Start from the first page (default)start_page=5
- Start from the fifth page
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&query=laptop&start_page=2"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'query': 'laptop',
'start_page': '2',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': laptop,
'start_page': 2,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&start_page=2")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&start_page=2')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&start_page=2');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&start_page=2", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Number of Pages
pages
[integer
]
(default= 1
)The pages
parameter controls how many pages of results to fetch. Default is 1.
For example:
pages=1
- Fetch only one page (default)pages=3
- Fetch three consecutive pagespages=5
- Fetch five consecutive pages
When combined with start_page
, you can fetch a range of pages:
start_page=2&pages=3
- Fetch pages 2, 3, and 4
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&pages=3&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'pages': '3',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'pages': 3,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&pages=3&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&pages=3&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&pages=3&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&pages=3&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Sort By
sort_by
["most_recent" | "price_low_to_high" | "price_high_to_low" | "featured" | "average_review" | "bestsellers"
]
(default= ""
)The sort_by
parameter allows you to sort search results. Available sorting options depend on the search category but commonly include:
most_recent
: Sort by most recent listings.price_low_to_high
: Sort by price, low to high.price_high_to_low
: Sort by price, high to low.average_review
: Sort by average customer review.bestsellers
: Sort by best-selling items.featured
: Sort by Amazon's featured items.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&query=laptop&sort_by=price-asc"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'query': 'laptop',
'sort_by': 'price-asc',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': laptop,
'sort_by': price-asc,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&sort_by=price-asc")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&sort_by=price-asc')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&sort_by=price-asc');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&sort_by=price-asc", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Device
device
[string
]
(default= desktop
)device
controls the device type for the request. You can use desktop
, mobile
or tablet
.
By default, the API uses desktop
. Mobile results may differ in layout and available products.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&device=mobile&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'device': 'mobile',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'device': mobile,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&device=mobile&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Domain
domain
[string
]
(default= com
)The domain
parameter allows you to specify an Amazon domain for localization purposes.
Available domains include:
com
(United States) Defaultae
(United Arab Emirates)ca
(Canada)cn
(China)co.jp
(Japan)co.uk
(United Kingdom)com.au
(Australia)com.be
(Belgium)com.br
(Brazil)com.mx
(Mexico)com.tr
(Turkey)de
(Germany)eg
(Egypt)es
(Spain)fr
(France)in
(India)it
(Italy)nl
(Netherlands)pl
(Poland)sa
(Saudi Arabia)se
(Sweden)sg
(Singapore)
This parameter helps you get localized search results, prices, and availability.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&domain=co.uk&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'domain': 'co.uk',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'domain': co.uk,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&domain=co.uk&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Country
country
[string
]
(default= ""
)The country
parameter sets the geolocation from which the request appears to originate. This can affect product availability, shipping options, and regional pricing.
Use ISO country codes like:
us
- United Statesgb
- United Kingdomde
- Germanyfr
- France
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&country=us&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'country': 'us',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'country': us,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&country=us&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
ZIP Code
zip_code
[string
]
(default= ""
)Use zip_code
to get results for a specific postal code area. This affects shipping costs, delivery times, and local availability:
zip_code=10001
This parameter works in conjunction with the country parameter to provide accurate local information.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&query=laptop&zip_code=10001"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'query': 'laptop',
'zip_code': '10001',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'query': laptop,
'zip_code': 10001,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&zip_code=10001")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&zip_code=10001')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&zip_code=10001');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&query=laptop&zip_code=10001", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Language
language
[string
]
(default= ""
)The language
parameter controls the language in which search results are displayed. Use ISO language codes:
en
- Englishes
- Spanishfr
- Frenchde
- Germanit
- Italianja
- Japanese and more
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&language=en&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'language': 'en',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'language': en,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&language=en&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Currency
currency
[string
]
(default= ""
)The currency
parameter allows you to specify the currency for price display using ISO 4217 currency codes:
USD
- US DollarEUR
- EuroGBP
- British PoundJPY
- Japanese YenCAD
- Canadian Dollar
Note that currency conversion may not always be available depending on the domain and products.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY¤cy=USD&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'currency': 'USD',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'currency': USD,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL¤cy=USD&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Category ID
category_id
[string
]
(default= ""
)Use category_id
to filter search results to a specific Amazon category. Category IDs can be found in Amazon URLs or through the category tree.
Example category IDs:
565108
- Computers & Accessories172282
- Electronics16310101
- Laptop Computers
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&category_id=565108&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'category_id': '565108',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'category_id': 565108,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&category_id=565108&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&category_id=565108&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&category_id=565108&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&category_id=565108&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Merchant ID
merchant_id
[string
]
(default= ""
)Use merchant_id
to filter search results by a specific seller or merchant. This is useful when you want products from a particular seller only.
You can find merchant IDs on seller profile pages or in product listings.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&merchant_id=A2EUQ1WTGCTBG2&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'merchant_id': 'A2EUQ1WTGCTBG2',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'merchant_id': A2EUQ1WTGCTBG2,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&merchant_id=A2EUQ1WTGCTBG2&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&merchant_id=A2EUQ1WTGCTBG2&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&merchant_id=A2EUQ1WTGCTBG2&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&merchant_id=A2EUQ1WTGCTBG2&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Autoselect Variant
autoselect_variant
The autoselect_variant
parameter automatically selects product variants when multiple options are available in search results (e.g., different colors or sizes).
When set to true
, the API will automatically select the default or most popular variant for each product. When set to false
(default), the API returns the base product information.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&autoselect_variant=true&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'autoselect_variant': 'true',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'autoselect_variant': true,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&autoselect_variant=true&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&autoselect_variant=true&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&autoselect_variant=true&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&autoselect_variant=true&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Full HTML
add_html
[boolean
]
(default= false
)The add_html
parameter allows you to include the full HTML of the search page in the response. By default, this is set to false
, if you want to include the HTML, pass add_html=true
to your API call.
curl "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&add_html=true&query=laptop"
# Install the Python Requests library:
# pip install requests
import requests
def send_request():
response = requests.get(
url='https://app.scrapingbee.com/api/v1/amazon/search',
params={
'api_key': 'YOUR-API-KEY',
'add_html': 'true',
'query': 'laptop',
},
)
print('Response HTTP Status Code: ', response.status_code)
print('Response HTTP Response Body: ', response.content)
send_request()
// Install the Node Axios package
// npm install axios
const axios = require('axios');
axios.get('https://app.scrapingbee.com/api/v1/amazon/search', {
params: {
'api_key': 'YOUR-API-KEY',
'url': 'YOUR-URL',
'add_html': true,
'query': laptop,
}
}).then(function (response) {
// handle success
console.log(response);
})
import java.io.IOException;
import org.apache.http.client.fluent.*;
public class SendRequest
{
public static void main(String[] args) {
sendRequest();
}
private static void sendRequest() {
// Classic (GET )
try {
// Create request
Content content = Request.Get("https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=laptop")
// Fetch request and return content
.execute().returnContent();
// Print content
System.out.println(content);
}
catch (IOException e) { System.out.println(e); }
}
}
require 'net/http'
require 'net/https'
# Classic (GET )
def send_request
uri = URI('https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=laptop')
# Create client
http = Net::HTTP.new(uri.host, uri.port)
http.use_ssl = true
http.verify_mode = OpenSSL::SSL::VERIFY_PEER
# Create Request
req = Net::HTTP::Get.new(uri)
# Fetch Request
res = http.request(req)
puts "Response HTTP Status Code: #{ res.code }"
puts "Response HTTP Response Body: #{ res.body }"
rescue StandardError => e
puts "HTTP Request failed (#{ e.message })"
end
send_request()
<?php
// get cURL resource
$ch = curl_init();
// set url
curl_setopt($ch, CURLOPT_URL, 'https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=laptop');
// set method
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
// return the transfer as a string
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
// send the request and save response to $response
$response = curl_exec($ch);
// stop if fails
if (!$response) {
die('Error: "' . curl_error($ch) . '" - Code: ' . curl_errno($ch));
}
echo 'HTTP Status Code: ' . curl_getinfo($ch, CURLINFO_HTTP_CODE) . PHP_EOL;
echo 'Response Body: ' . $response . PHP_EOL;
// close curl resource to free up system resources
curl_close($ch);
>
package main
import (
"fmt"
"io/ioutil"
"net/http"
)
func sendClassic() {
// Create client
client := &http.Client{}
// Create request
req, err := http.NewRequest("GET", "https://app.scrapingbee.com/api/v1/amazon/search?api_key=YOUR-API-KEY&url=YOUR-URL&add_html=true&query=laptop", nil)
parseFormErr := req.ParseForm()
if parseFormErr != nil {
fmt.Println(parseFormErr)
}
// Fetch Request
resp, err := client.Do(req)
if err != nil {
fmt.Println("Failure : ", err)
}
// Read Response Body
respBody, _ := ioutil.ReadAll(resp.Body)
// Display Results
fmt.Println("response Status : ", resp.Status)
fmt.Println("response Headers : ", resp.Header)
fmt.Println("response Body : ", string(respBody))
}
func main() {
sendClassic()
}
Credit cost for your requests
Each ScrapingBee plan provides a certain amount of API credits per month.
It costs 5 or 15 credits per Amazon Product API request, depending on the type of request you make.
Here is a breakdown of ScrapingBee API credit costs:
Feature used | API credit cost |
---|---|
Light Requests learn more (default) | 5 |
Regular requests (with JavaScript rendering) | 15 |