Amazon Autocomplete Scraper
This API can be used for scraping suggestions from any product page from Amazon. All you need is the query for the search.
You have to send a GET request to https://api.scrapingdog.com/amazon/autocomplete with the below-given parameters.
Scrapingdog Parameters
api_key
required
Your personal API key. Available on your dashboard
Type: String
Search Query
prefix
prefix represent the partial search term that Amazon uses to generate keyword suggestions.
Type: String
last_prefix
This indicate that the user first typed "i" and then continued typing "phone" (leading to "iphone"). Type: String
mid
In Amazon URLs, mid often refers to the Merchant IDrting, which identifies a specific seller on the platform.
Type: String
suffix
The suffix parameter in the Amazon Suggestions API plays a key role in handling search query completion and predictions.
Type: String
Language
language
Language of the results. Possible Values - en, es, fr, de, etc.
Default Value - en
Type - String
curl "https://api.scrapingdog.com/amazon/autocomplete?api_key=5eaa61a6e562fc52fe763tr516e4653&domain=com&prefix=spoon"import requests
# API URL and key
api_url = "https://api.scrapingdog.com/amazon/autocomplete"
api_key = "5eaa61a6e562fc52fe763tr516e4653"
# Search parameters
domain = "com"
prefix = "spoon"
# Create a dictionary with the query parameters
params = {
"api_key": api_key,
"prefix": prefix
}
# Send the GET request with the specified parameters
response = requests.get(api_url, params=params)
# Check if the request was successful (status code 200)
if response.status_code == 200:
data = response.json()
print(data)
else:
print(f"HTTP Request Error: {response.status_code}")
Response
[
{
"type": "KEYWORD",
"keyword": "cricket noise maker prank"
},
{
"type": "KEYWORD",
"keyword": "cricket printer"
},
{
"type": "KEYWORD",
"keyword": "cricket"
},
{
"type": "KEYWORD",
"keyword": "cricket bat"
},
{
"type": "KEYWORD",
"keyword": "live crickets"
},
{
"type": "KEYWORD",
"keyword": "cricket phones"
},
{
"type": "KEYWORD",
"keyword": "cricket keeper"
},
{
"type": "KEYWORD",
"keyword": "live crickets for reptiles"
},
{
"type": "KEYWORD",
"keyword": "cricket ball"
},
{
"type": "KEYWORD",
"keyword": "cricket shoes men"
}
]Last updated