Amazon Product Scraper - Prices, ASIN, BSR & Reviews avatar

Amazon Product Scraper - Prices, ASIN, BSR & Reviews

Pricing

from $3.00 / 1,000 products scraped

Go to Apify Store
Amazon Product Scraper - Prices, ASIN, BSR & Reviews

Amazon Product Scraper - Prices, ASIN, BSR & Reviews

Get Amazon prices by ASIN from searches or product URLs. Export prices, currency, ratings and stock signals. Detail pages can include technical specifications such as model number or dimensions. Optional BSR tracks category ranks. Fees apply to run starts, products, dataset rows and optional events.

Pricing

from $3.00 / 1,000 products scraped

Rating

0.0

(0)

Developer

harvestlab

harvestlab

Maintained by Community

Actor stats

1

Bookmarked

484

Total users

18

Monthly active users

2 days ago

Last modified

Categories

Features

Limited permissions

Share

Amazon product and BSR data for sellers and pricing teams. Returns ASINs, prices, ratings and optional rank history, with per-product pricing and separate optional events.

Who it's for

  • Sellers comparing their products with competing offers.
  • Pricing teams exporting recurring ASIN price observations to CSV or JSON.
  • Brand analysts monitoring Best Sellers Rank separately from keyword search position.

Start with ten products

The Console starter searches for iPhone 15 Pro on amazon.com, caps output at ten products and leaves details, BSR tracking and AI off. This exact starter returned ten priced products in 32 seconds on November 13, 2026, at the default 256 MB. Access and timing can change; inspect the output before increasing limits.

{
"searchQuery": "iPhone 15 Pro",
"amazonDomain": "amazon.com",
"maxProducts": 10,
"fetchDetails": false,
"trackBestsellerRank": false,
"enableAiAnalysis": false,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"]
}
}

Cost example: 100 returned products on Starter/Bronze cost $0.40104 in Actor events at 256 MB: 100 × $0.004 product events + 100 × $0.00001 saved rows + $0.00004 startup. This assumes exactly 100 dataset rows, with BSR, AI and alerts off. More saved rows or optional features add fees; this is an event estimate, not a guaranteed all-in quote. See the live pricing.

Check the price of one known ASIN

The saved example checks one product on Amazon Germany. On December 2, 2026 it returned a one-time price of €26.99 from Mighty Elements. Copy the one-product ASIN example.

To check your own product, paste this input into the Console's Input tab in JSON mode. Replace the ASIN and set the marketplace and residential proxy country together. For Amazon US, use amazon.com and US. A full product URL can preserve seller or offer parameters.

{
"productUrls": ["B09JGFTTRX"],
"amazonDomain": "amazon.de",
"maxProducts": 1,
"fetchDetails": true,
"trackBestsellerRank": false,
"enableAiAnalysis": false,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"],
"apifyProxyCountry": "DE"
}
}

One priced product and one saved row cost $0.00405 in Actor events on Starter/Bronze at 256 MB. This assumes BSR tracking, AI and alerts are off. Apify platform usage during the run is included under current Store pricing. The public example selects build 2.2.107. For a previously saved copy, check the build in Run options and select latest to use the current price checks. In the completed run’s Output tab, open Direct price and stock. Match the ASIN and marketplace and check the observation time. If the price is blank, check Availability and Price reason. Keep the stock observation and omit the row from price comparisons. For earlier builds, download full dataset JSON for the available fields. See scheduled product-only export.

Real output preview

Two product records from the November 13, 2026 starter, with selected fields shown. These are historical observations, not current offers or guaranteed future values.

[
{
"asin": "B0CMZ8ZBVN",
"title": "iPhone 15 Pro, 128GB, Blue Titanium - Unlocked (Renewed)",
"price": 457.75,
"currency": "USD",
"rating": 3.8,
"reviews_count": 54,
"url": "https://www.amazon.com/dp/B0CMZ8ZBVN",
"scraped_at": "2026-11-13T13:40:13.358622+00:00"
},
{
"asin": "B0CMZ5LT14",
"title": "iPhone 15 Pro, 256GB, Black Titanium - Unlocked (Renewed)",
"price": 526.22,
"currency": "USD",
"rating": 3.8,
"reviews_count": 54,
"url": "https://www.amazon.com/dp/B0CMZ5LT14",
"scraped_at": "2026-11-13T13:40:13.723641+00:00"
}
]

Export product rows to CSV, JSON or Excel. Keep currency and scraped_at, and preserve missing values rather than treating them as zero. For direct URL checks, scraped_at records when the product page arrived. Compare prices by that timestamp, even when a larger run finishes later. The dataset can also contain summaries or diagnostics; filter those before importing a price feed.

Prepare and review a dated repeat check. The offline reviewer below prepares one input for 3–5 known products in the same marketplace. Choose a marketplace for bare ASINs, and use the exact full product URL to retain offer parameters. Keep the same URLs and settings on both check dates. If a product URL contains a comma, use a link that already encodes it as %2C and verify that the offer still matches. In Dated repeat refresh, review the full original dataset and add one eligible missing-price retry from the same UTC window. Keep the generated retry JSON and attach it with that run’s dataset. With BSR explicitly off and no webhook target, connector target or selected connector, the reviewer accepts the numeric default alertRankThreshold of 50 in either saved input. The coverage summary keeps the original product count and counts fresh qualified prices, including prices recovered in the retry. Verify both completed file pairs and their actual costs in Apify.

Already have a completed direct-URL run? Download the offline price reviewer and open the HTML file in your browser. Choose the original run input and full default dataset JSON to see which requested products returned usable prices. Add your accepted baseline or full previous dataset to compare eligible prices and export changes to CSV. Prices with an offer-source or range marker stay held. For a version 1 baseline, the first eligible newer price without those markers becomes the version 2 starting price without a reported change. For immediate comparisons, use a full previous dataset only if it matches every accepted ASIN, offer, currency, price, seller and observation time and the compared prices have no source or range markers. Keep the accepted baseline when it carries prices from other runs or a retry. Check product condition and offer basis in Apify before applying later changes. Conflicting prices or offer details at the newest timestamp require review. After reviewing a comparison, download the candidate baseline and use it as the previous file on the next refresh. The baseline retains the last accepted observation when the current price is missing, stale or held for review. Confirm the input and current dataset came from the same run and check its diagnostics before using any retry offered. Files stay in your browser. The reviewer needs no API token and starts no Actor. For a recurring integration, review an existing run in n8n.

Review a fixed list of 6–100 known products. Download the offline Amazon batch price reviewer and open the HTML file in your browser. Paste one ASIN per line and select a marketplace, or use exact product URLs to keep offer details. The browser tool splits your list into groups of 3–5 and prepares each run's input. Keep the same plan on each refresh. In Apify, save the input and export the full default dataset from every completed original. Add at most one eligible missing-price retry for each original from the same UTC observation window. Use the exact saved input and dataset from the same run for each file pair. Choose Download observations CSV for one row per planned URL in order. Fresh columns show qualified observations. Held prices, missing products and unreviewed batches keep their rows with blank fresh values. Previous columns show the supplied baseline price and date when available.

For each batch’s optional retry, select the eligible missing products you want to check. The estimate covers Starter/Bronze Actor events at 256 MB assuming one billable product and one dataset row per selected URL. A saved product without a price can still incur events.

The batch reviewer flags unreviewed batches and withholds the candidate baseline until all batches are reviewed. It lists fresh prices and comparable changes and preserves earlier accepted observations when a fresh price is missing or held. The batch reviewer holds prices with an offer-source or range marker. For a version 1 baseline, the first eligible newer single price without those markers becomes the version 2 starting price without reporting a change. Check product condition and offer basis in the completed runs before accepting a new seller or applying later price changes. Review the results and the actual charges in Apify before using the candidate on your next check. Files stay in your browser.

Collect completed batch files in one private package

For the same 6–100 product plan, use Download the offline batch package reviewer and Download the completed-run collector for Node.js. The same reviewer also accepts files one batch at a time. The collector runs locally with Node.js 22 or newer. When BSR is explicitly off and no alert dispatch is configured, both tools accept Apify’s saved numeric default alertRankThreshold: 50 in an original or retry.

Save the plan as plan.json and use each generated batch input unchanged. In a private completed-runs.json, record the UTC date range and the exact completed original run ID for every batch in the plan. An optional retryRunId belongs to its original batch. Replace the run ID below and include every planned batch.

{
"version": 1,
"window": { "startDate": "2026-11-20", "endDate": "2026-11-20" },
"batches": [{ "batchId": "batch-01", "originalRunId": "YOUR_COMPLETED_RUN_ID" }]
}

Set your authorized APIFY_TOKEN privately in the process environment. Keep the manifest and output in a private folder. Run the downloaded collector using a fresh output filename.

node amazon-collect-batch-package-2026-11-20-v2.mjs plan.json completed-runs.json private-package.json

The collector reads only completed-run metadata, saved inputs and full datasets on api.apify.com. Reads can incur storage or transfer usage. It starts no Actors and sends no data to a destination. The package contains your run input and product data. Keep it private.

In the downloaded offline reviewer, load the plan, use the same UTC dates and attach your last accepted baseline if available. Choose Open a completed batch package (optional), then Review batches. Check original and retry associations, held prices and the actual charges before acknowledging and saving a candidate. If a run cannot be read by the collector, attach its saved input and full dataset manually in the same reviewer.

For a six-product check at 256 MB, two original runs with three priced products and three saved rows each have an estimated event subtotal of $0.02414 at Starter/Bronze. That example assumes no optional features or extra rows. Retries can add events. Review your plan's included usage, separately metered usage and charge caps before starting.

For category rank history, see Amazon BSR monitor. For where a product appears in a keyword search, use Amazon Keyword Rank Tracker.

No API key is needed for scraping public pages. Hosted AI providers require a key only when enabled; self-hosted Ollama does not.

Amazon Product Scraper

Search Amazon by keyword or provide direct product URLs to extract product titles, ASINs, prices, star ratings, rating or review counts, availability, seller names, images, badges, delivery data, and marketplace currency. Use it for competitor monitoring, price checks, catalog research, affiliate research, and product intelligence.

Amazon ASIN Scraper

Use direct product URLs or /dp/ASIN links when you already know the products to track. Detail runs can return brand, seller, availability, category breadcrumbs, feature bullets, image galleries, Best Sellers Rank, and BSR movement fields.

For a ready-made one-ASIN BSR check, use Track Amazon BSR for one ASIN. It is prefilled for one product URL with detail extraction and rank tracking enabled.

Amazon BSR monitor

Monitor Best Sellers Rank for known ASINs with productUrls, fetchDetails: true and trackBestsellerRank: true. BSR is a product's rank within its Amazon category; it is not keyword search position or an estimate of units sold. Use Amazon Keyword Rank Tracker for search visibility.

  1. Open Track Amazon BSR for one ASIN and replace the product URL with your own ASIN in the matching marketplace.
  2. Leave AI and outbound alerts off for the first run. In the completed run’s Output tab, open BSR comparison. Check the ASIN, marketplace, category, observation time and positive current rank. Rows without a matching ASIN and a positive rank in a known category cannot establish a baseline. Check the run status for history-read or save failures.
  3. Save your working input as a private task. Schedule it only after confirming useful output. The first valid observation establishes history; a later comparable observation can report rank_previous, rank_change, rank_peak and rank_movement.
  4. Export rank observations from the completed run. Keep asin, amazon_domain, bestseller_category, scraped_at, rank_now, rank_previous and rank_previous_scraped_at together. For older runs, select these fields from the full dataset. Compare matching ASINs, marketplaces and categories. A positive rank_change means the numerical rank improved. Add a webhook only when you want the optional paid notification and control its destination.

On Starter/Bronze, one product event is $0.004 and one ASIN saved with a known BSR category is another $0.008. Startup and saved-dataset events also apply. Each delivered webhook adds $0.0016. A change to another category starts a new BSR baseline and triggers no movement alert. If saving the history fails, the run keeps the product rows and skips the tracking event and movement alerts.

Scheduled product-only export

Start with 3–5 known product URLs from one marketplace and set maxProducts to the list size. Direct URL runs have up to 180 seconds to fetch the batch and can finish before checking every URL. Compare the requested ASINs with the returned rows that have usable prices before scheduling and when reviewing later runs. Use short batches as you expand.

Save a successful known-product input as a private task, schedule it daily, and configure a run-succeeded webhook/integration in Apify. Your authorized runner should fetch the exact completed run's default dataset as a JSON item array, not a moving latest dataset, then filter products before loading a price feed.

Compare keyword runs in your browser

Download the offline keyword price reviewer and open the HTML file in your browser. Start from the keyword example. For each completed card-only run, save the INPUT record from that run's key-value store. Open the same run's Output Dataset link and save the full JSON item array. If you use the dataset export dialog, select JSON, leave the view, filters and field selection unset, and keep clean output off. The reviewer needs the original scraped_at and search_query fields.

If the link is unavailable, get the same completed run's defaultDatasetId from GET /v2/actor-runs/{runId} on api.apify.com. With a private Apify bearer credential, request GET /v2/datasets/{defaultDatasetId}/items?format=json&clean=false&limit=1000&offset=0. Save the JSON array when its row count matches X-Apify-Pagination-Total and the total is at most 1,000. With an authorized Python client, list(client.dataset(default_dataset_id).iterate_items(clean=False, limit=1001)) also reads the raw rows. Save them as a JSON array if there are at most 1,000. The reviewer works locally and needs no API token.

For another refresh, keep the same keyword, marketplace, result cap, sort and proxy settings. If you use an ASIN list, keep the same ASINs and page limit. Add your last accepted baseline to see newer comparable cards with changed prices and download their CSV. Review the candidate baseline before using it on a later refresh. It keeps prior prices for absent cards and holds conflicting observations for review. The keyword reviewers hold secondary offers, price ranges and unknown price sources for review. Keep the last accepted price when a refresh brings no comparable observation. If an earlier baseline lacks price-source evidence, review the next qualified price as a new starting point before comparing later refreshes. An n8n result of candidate_baseline: null means keep your last accepted snapshot. Leave the baseline field empty only when starting a new snapshot. Confirm the product model, storage and condition before acting on a price difference.

Limit a keyword refresh to selected ASINs

Open the selected-ASIN example to copy the saved four-product task. To follow your own products, open a completed broad keyword run in the browser reviewer above. Under Choose ASINs for a repeat search, select up to ten cards after checking model, storage and condition. Download the selected-ASIN input for Console and set the displayed run cap before starting. Use the first completed selected-ASIN run to start a new baseline.

To save a private task through the API, open Prepare a private Apify task in the reviewer. Choose Starter/Bronze or base rates and download the task request. Its input holds the selected ASINs and its options carry the rounded-up charge cap, build 2.2.90, 256 MB and a 180-second timeout. For other tiers, the base estimate gives a conservative cap at current rates. Verify your saved task's input and options before starting it. Create task API

Four priced cards and four saved rows model $0.01608 on Starter/Bronze or $0.02009 at base rates, with caps of $0.02 or $0.03, respectively. Ten priced cards and ten saved rows model $0.04014 on Starter/Bronze or $0.05015 at base rates, with caps of $0.05 or $0.06, respectively. Each model includes one start at 256 MB with details, BSR, AI and alerts off. The matching search-card prices are observations from that run. Confirm the current offer before acting.

To check the same products in each keyword run, add keywordAsins with 1–100 distinct uppercase ASINs. Set maxProducts high enough to include the list. The Actor saves only matching search cards and reports how many requested ASINs it saved. Omit keywordScanPages to check at most one search page, or set it to 2 or 3 if you want to look further. A wider scan can use more proxy and compute resources. Leave these options out when using direct product URLs.

At 256 MB on Starter/Bronze, seven saved matching cards and seven dataset items total $0.02811 in Actor events with details, BSR, AI and alerts off. Eight cost $0.03212 under the same assumptions. An eligible saved card can incur product and dataset events even if its price is unavailable. A missing target is not a price observation. The reviewer reports which targets have a qualified price in the supplied run.

Review an existing run in n8n

  1. Download the Amazon price-review workflow and import it into n8n. Keep it inactive. If you imported an earlier copy, import this download again. It holds price rows when the ASIN in a mobile source link disagrees with the row. Re-import this download if you use an earlier copy. For fixed-product reviews, it holds unavailable or contradictory price rows and keeps the last accepted value. Review any older baseline entry that came from an unavailable row before importing it.

    Before adding your Apify credential, saved input or baseline, open Settings. Set Save manual executions, Save execution progress, Save successful production executions, and Save failed production executions to Do not save. Enable Timeout Workflow and set it to 5 minutes. The n8n editor can keep the new workflow’s settings when it imports the nodes.

  2. In Configure existing run, enter the ID of a successful Amazon Product Scraper run. Keep the 1,000-row limit for your first review. On each HTTP Request node, select a private HTTP Header Auth credential with header name Authorization and value Bearer <your Apify token>.

  3. Choose the review mode in amazonReviewMode:

    • single_run reviews one completed run with an empty previous snapshot.
    • fixed_products compares the same known products across refreshes. Use one full product URL or bare ASIN per product, specify its supported Amazon marketplace in amazonDomain, and set a cap that covers the list. Keep full URLs to retain offer parameters. Match the residential proxy country to the marketplace and leave rank tracking, AI and alerts off. Copy the first completed run's saved direct INPUT JSON from its key-value store into expectedDirectInput. Keep that input for later reviews and keep credentials in n8n's credential store. The workflow checks the saved input before reading dataset items and stops if the marketplace, ordered product inputs, offer queries, product cap or detail setting changes.
    • pinned_keyword reviews completed runs with the same card-only keyword settings. Start with the keyword example. Paste the exact saved INPUT into expectedKeywordInput, with expectedDirectInput empty. Reuse the accepted snapshot with its keyword_scope. A changed keyword or saved search setting stops before the dataset read. For scoped runs, keyword_target_coverage lists targets with and without a qualified price. Match model, condition and configuration before comparing card prices. Search rank and seller comparability remain unknown.
    • discovery compares changing search results and allows the products to change.
  4. Run it manually and inspect the proposed observations and candidate feed. For a refresh, provide your last accepted full snapshot and its revision in previousSnapshot and baselineReference. In fixed-product mode, check the planned, qualified and pending counts before accepting a refresh. In pinned keyword mode, check observed_card_price_changes for newer accepted cards whose price changed. Each entry includes both amounts and source times. delta.products still carries all accepted observations, including rows with the same price.

Single-run and discovery reviews hold secondary offers, price ranges and other marked prices. Keep the last accepted snapshot if the review reports no qualified prices.

When a complete ASIN-scoped keyword review finds no qualified prices, HELD_NO_QUALIFIED_PRICES lists missing targets. Keep the accepted snapshot. The review returns no candidate baseline.

This workflow reads completed Apify runs and does not start Actors, write to a destination, or advance the accepted baseline. The API reads may incur storage or transfer costs. A changed offer query, changed reported seller or missing previously recorded seller requires review. The current observation stays visible and the last accepted price is retained. If the newest source rows disagree at the same instant, the reviewer flags the product and holds its last accepted price. Independent qualified updates remain eligible. For a newer reported seller on a generic product URL, fixed-product review can show seller_rebaseline_options. Check condition and configuration. Copy one packet into sellerRebaseline and repeat the review with the same run ID and accepted revision. The separate seller_rebaseline proposal can start a new baseline for that ASIN. It stays outside comparable price changes and ordinary destination deltas. Review the proposal before accepting the candidate, then clear the packet. If you sync to a destination, confirm the seller replacement as well as the ordinary changes. Test your destination separately before connecting it.

Export a local CSV

Here is a small offline CSV mapper for a full Output Dataset JSON saved as dataset.json without a view or filters:

import csv
import json
import re
import sys
from datetime import datetime
from decimal import Decimal, InvalidOperation
from urllib.parse import urlsplit
include_seller = True # Set to False if an existing import requires the old header.
with open("dataset.json", encoding="utf-8") as source:
items = json.load(source)
if not isinstance(items, list) or len(items) > 10000:
raise ValueError("Expected at most 10,000 exported items")
products = {}
for item in items:
if not isinstance(item, dict) or item.get("diagnostic_item") or item.get("block_detected"):
continue
if item.get("result_type") not in (None, "product_data") or item.get("error"):
continue
timestamp = item.get("scraped_at")
if not isinstance(timestamp, str):
continue
asin, currency = str(item.get("asin") or "").upper(), str(item.get("currency") or "").upper()
# Keep marked rows in time order, even when there is no scalar price.
price_markers = ("price_source", "price_min", "price_max")
marked_price = any(item.get(field) is not None for field in price_markers)
try:
observed_at = datetime.fromisoformat(timestamp.replace("Z", "+00:00"))
price = None if marked_price else Decimal(str(item.get("price")))
if (price is not None and price.is_finite() and price > 0
and item.get("search_query") == ""
and (item.get("in_stock") is False or item.get("price_reason") is not None)):
marked_price, price = True, None
url = item.get("url") or item.get("product_url") or ""
if not isinstance(url, str):
continue
selected_url = urlsplit(url)
market = (selected_url.hostname or "").removeprefix("www.")
source_conflict = False
for field in ("url", "product_url"):
if not item.get(field):
continue
if not isinstance(item[field], str):
source_conflict = True
break
parsed = urlsplit(item[field])
path_asins = re.findall(
r"/(?:dp|gp/product|product)/([A-Z0-9]{10})(?=/|$)",
parsed.path, flags=re.IGNORECASE,
)
if ((parsed.hostname or "").removeprefix("www.") != market
or any(value.upper() != asin for value in path_asins)):
source_conflict = True
break
except (InvalidOperation, ValueError, TypeError):
continue
if source_conflict:
continue
if not ((marked_price or (price.is_finite() and price > 0)) and len(asin) == 10 and asin.isalnum()
and len(currency) == 3 and currency.isalpha()
and market in ("amazon.com", "amazon.ca", "amazon.com.mx", "amazon.com.br",
"amazon.co.uk", "amazon.de", "amazon.fr", "amazon.es", "amazon.it",
"amazon.nl", "amazon.pl", "amazon.se", "amazon.co.jp", "amazon.in",
"amazon.com.au", "amazon.ae", "amazon.sa", "amazon.sg", "amazon.com.tr")
and item.get("title") and observed_at.utcoffset() is not None):
continue
key = market + ":" + asin
# Keep query parts that may select a specific offer. Ignore the Associates tag.
offer_query = tuple(
part for part in selected_url.query.split("&") if part and part.split("=", 1)[0] != "tag"
)
seller = item.get("seller")
seller = " ".join(seller.split()) if isinstance(seller, str) else ""
offer = price, currency, offer_query, seller.lower()
previous = products.get(key)
row = None if marked_price else dict(item, product_key=key, seller=seller)
if previous is not None:
previous_at, previous_offer, previous_row = previous
if observed_at < previous_at:
continue
if observed_at == previous_at and (previous_row is None or offer != previous_offer):
row = None
products[key] = observed_at, offer, row
held = sum(item is None for _, _, item in products.values())
if held:
print(f"Held {held} product(s) with marked, unavailable or conflicting newest price or offer observations.", file=sys.stderr)
if len(products) == held:
raise ValueError("No price-bearing products; preserve the previous good feed")
fields = ["product_key", "asin", "title", "price", "currency", "availability",
"rating", "reviews_count", "url", "scraped_at"]
if include_seller:
fields.append("seller")
with open("products.csv", "x", newline="", encoding="utf-8") as target:
writer = csv.DictWriter(target, fieldnames=fields)
writer.writeheader()
for _, _, item in products.values():
if item is None:
continue
row = {key: item.get(key, "") for key in fields}
row["url"] = item.get("url") or item.get("product_url")
for key, value in row.items():
if isinstance(value, str) and value.lstrip().startswith(("=", "+", "-", "@")):
row[key] = "'" + value
writer.writerow(row)

Use a new private output folder per completed run. This mapper never invokes an Actor, overwrites a prior CSV, or writes to a third-party destination. In your sheet/database, deduplicate webhook replays by product_key + scraped_at; marketplace/currency differences must remain explicit. For each marketplace and ASIN, the mapper keeps the newest observation with a timezone-qualified scraped_at. If a row at that instant has a secondary-offer, range or unknown price marker, the mapper holds that product even if an older price is available. A direct-URL row with a positive amount is also held if it explicitly marks the product out of stock or reports a missing-price reason. It also holds products when newest rows disagree on price, currency, reported seller or offer query, and reports the number held. Equivalent price amounts and seller names with different spacing or capitalization can share an instant. Associates tag parameters and URL fragments are ignored when comparing offers. Independent products still export. When merging this CSV into a prior snapshot, keep the previous accepted prices for omitted products and mark them stale. Check the reported seller, currency and offer query before comparing prices across runs. A changed or missing seller needs review before you replace a comparable baseline. A blank seller means the run did not report one. If an older CSV lacks the seller column, regenerate it from the original JSON or leave that comparison unresolved. Set include_seller to False to retain the original CSV header for an existing importer. If no qualified rows remain, the mapper creates no CSV. Test the destination mapping with your own credentials before production.

Rows are also excluded when a recognized /dp/, /gp/product/, or /product/ URL identifies a different ASIN, or populated url and product_url fields disagree on marketplace. Matching source URLs retain their original spelling, tracking parameters and fragments. Legacy links without a recognized ASIN path remain usable; this consistency check does not prove price accuracy or freshness.

Amazon Price Tracker

Schedule product-only runs for the same ASINs and export each observed price and currency, or use the LangGraph percentage comparison below with your accepted prior observations. Enable trackBestsellerRank only for optional BSR history; alertWebhookUrl sends rank-movement alerts, while the graph returns price-alert flags for your own notification workflow.

Why buyers use this Amazon scraper

  • Search keywords or supply known ASIN product URLs.
  • Export observed prices, currencies, star ratings and displayed rating or review counts.
  • Add detail-page extraction when you need BSR, seller or availability fields.
  • Keep optional BSR history, notifications and AI off until your workflow needs them.

What it does

Search and direct-product modes return public product observations across the supported marketplaces below. Detail fields depend on what the source page exposes. Optional BSR tracking retains rank history; optional alerts send rank-movement notifications to your configured endpoint. Neither a successful run nor a nonempty row guarantees a usable price or rank.

Supported Amazon domains:

DomainCountryCurrency
amazon.comUnited StatesUSD
amazon.caCanadaCAD
amazon.com.mxMexicoMXN
amazon.com.brBrazilBRL
amazon.co.ukUnited KingdomGBP
amazon.deGermanyEUR
amazon.frFranceEUR
amazon.esSpainEUR
amazon.itItalyEUR
amazon.nlNetherlandsEUR
amazon.plPolandPLN
amazon.seSwedenSEK
amazon.co.jpJapanJPY
amazon.inIndiaINR
amazon.com.auAustraliaAUD
amazon.aeUnited Arab EmiratesAED
amazon.saSaudi ArabiaSAR
amazon.sgSingaporeSGD
amazon.com.trTurkeyTRY

Each domain returns results in local currency. The currency field in each output item reflects the currency actually rendered on the page - if your proxy's geo doesn't match the domain, Amazon may localize prices to the proxy's currency.

Features

  • Keyword searches and direct ASIN URLs with bounded product limits.
  • Marketplace currency, product identity, price, rating and review fields.
  • Optional detail fields, images and Best Sellers Rank when present on the page.
  • Optional BSR history and threshold alerts, billed separately.
  • CSV, JSON and Excel exports, with a product-only mapping recipe above.
  • Optional AI reports using your chosen provider; provider charges are separate.

Use Cases

  • E-commerce sellers - Review listed prices for a fixed set of ASINs in one marketplace per run. Start with 3–5 products, keep the same offer URLs, and check qualified coverage before expanding.
  • Brand & rank monitoring - Track changes in an ASIN's Best Sellers Rank. The optional webhook sends an event when the rank changes by at least your threshold. At base rates, 25 products with 25 successful BSR annotations daily total $11.25 over 30 days before webhook, start and saved-dataset events.
  • Dropshippers & arbitrage - Find profitable products by cross-domain price-arbitrage scans (e.g. amazon.com vs amazon.de). The discount_percentage and bestseller_rank fields surface high-margin candidates fast.
  • Market & category research - Sample keyword results and compare the observed brands, prices and displayed rating or review counts. The product cap is 100 per run. Source access and the run budget determine how many results are available.
  • Affiliate marketers - Discover highly rated products with many ratings or reviews by category for "best of 2026" listicles. Sort by avg_review or newest to surface fresh-but-validated picks.
  • Price-floor review - In your spreadsheet, compare each observed offer price with the floor for that ASIN and currency. Leave missing prices for review. The optional webhook alerts on changes in Best Sellers Rank (BSR).
  • Procurement teams - Benchmark supplier quotes against live Amazon list prices at scale; the currency + availability fields make cross-border procurement decisions defensible.
  • AI / ML training data - Pull thousands of product titles, bullet features, and descriptions for embedding fine-tunes or product-categorization models - no API quotas, just pay-per-row.
  • BI / dashboard pipelines - Push CSV / JSON straight into Google Sheets, Snowflake, or BigQuery via Apify's 2,000+ integrations. The scraped_at ISO timestamp makes time-series joins trivial.

Input

Search Parameters

  • Search Query (searchQuery): Keywords to search for (e.g., "wireless headphones", "laptop stand", "organic coffee")
  • Product URLs (productUrls): Direct Amazon product URLs - provide specific ASINs or product pages for detailed extraction. Overrides search query when provided
  • Amazon Domain (amazonDomain): Which Amazon marketplace to scrape. Options: amazon.com (default), amazon.ca, amazon.com.mx, amazon.com.br, amazon.co.uk, amazon.de, amazon.fr, amazon.es, amazon.it, amazon.nl, amazon.pl, amazon.se, amazon.co.jp, amazon.in, amazon.com.au, amazon.ae, amazon.sa, amazon.sg, amazon.com.tr
  • Max Products (maxProducts): Maximum number of products to scrape (1-100, default: 10). Higher values paginate through multiple search result pages
  • Sort By (sortBy): Sort order for search results - relevance (default), price-asc, price-desc, avg-rating, newest
  • Fetch Product Details (fetchDetails): Visit individual product detail pages to enrich results with brand, availability, description, features, and seller info (default: false for faster first runs)

BSR Time-Series & Alerts

  • Track Best Sellers Rank (trackBestsellerRank): Persist each product's BSR across runs and emit rank delta fields (rank_now, rank_previous, rank_change, rank_peak, rank_movement). Forces fetchDetails: true. Default: false
  • BSR Alert Webhook URL (alertWebhookUrl): POST a JSON payload to this URL whenever a tracked ASIN's absolute rank_change crosses the threshold. Use a receiver that accepts custom JSON. To post to Slack or Discord, map the event to a message in your workflow. Auto-enables trackBestsellerRank
  • MCP Output Connectors (outputConnectors): Send the same qualifying BSR alerts to authorized Slack, Notion, GitHub, Sheets, CRM, or other MCP connector tools. Auto-enables trackBestsellerRank
  • Connector Target (connectorAlertTarget): Optional destination such as a Slack channel, Notion database ID, sheet name, table, or CRM list
  • BSR Alert Threshold (alertRankThreshold): Minimum absolute rank_change required to fire a webhook (default: 50). Lower = more alerts

AI Analysis Settings

  • Enable AI Analysis (enableAiAnalysis): Toggle AI-powered competitive analysis on or off (default: off). Requires an LLM API key when enabled
  • LLM Provider (llmProvider): Choose between OpenRouter (recommended - 300+ models), Anthropic (Claude), Google AI (Gemini), OpenAI (GPT), or Ollama (self-hosted)
  • OpenRouter API Key (openrouterApiKey): Your API key from openrouter.ai
  • Anthropic API Key (anthropicApiKey): Your API key from console.anthropic.com
  • Google AI API Key (googleApiKey): Your API key from aistudio.google.com
  • OpenAI API Key (openaiApiKey): Your API key from platform.openai.com
  • Model Override (llmModel): Optional custom model selection. Leave empty for defaults (google/gemini-3.8-flash for OpenRouter, claude-sonnet-5-5 for Anthropic, gemini-3.8-flash for Google AI, gpt-4o-mini for OpenAI, llama3.1 for Ollama)

Proxy Settings

Residential proxy is strongly recommended - Amazon's AWS WAF frequently blocks datacenter IPs, especially on non-US marketplaces.

The actor combines per-request access rotation with automatic WAF-aware retries on search result pages, but residential IPs substantially improve success rates across all domains.

Key proxy tip: Set apifyProxyCountry to match your target domain. Amazon localizes prices and content based on the requesting IP's geography - a US proxy on amazon.co.jp will return USD prices instead of JPY.

Target domainRecommended apifyProxyCountry
amazon.comUS
amazon.caCA
amazon.com.mxMX
amazon.com.brBR
amazon.co.ukGB
amazon.deDE
amazon.frFR
amazon.esES
amazon.itIT
amazon.nlNL
amazon.plPL
amazon.seSE
amazon.co.jpJP
amazon.inIN
amazon.com.auAU
amazon.aeAE
amazon.saSA
amazon.sgSG
amazon.com.trTR

amazon.fr WAF limitation: amazon.fr enforces a stricter AWS WAF than other EU domains. Prefer direct product URL scraping (/dp/ASIN) over keyword search on this domain. If search fails, fall back to amazon.de or amazon.co.uk - they share most of the EU catalog.

Output

Search Results

Each product from search results includes:

FieldDescription
asinAmazon Standard Identification Number
titleProduct title
priceCurrent selling price
original_priceOriginal/list price (if discounted)
discount_percentageComputed discount percent when both prices are present
currencyCurrency code as displayed on the page (USD, EUR, GBP, JPY, etc.)
ratingAverage customer rating (out of 5)
reviews_countCount displayed by Amazon for ratings or reviews. A global ratings total includes star-only ratings and may be shared across product variations.
is_primeWhether the product is Prime eligible
is_sponsoredWhether the listing is a sponsored ad
in_stocktrue or false when Amazon shows a recognized current stock message. A preorder, a prompt to choose a delivery location or an unclear message returns null. See availability for Amazon's wording.
image_urlMain product image URL
urlDirect link to the product page
brandBrand or manufacturer name
badgeSpecial badges (Best Seller, Amazon's Choice)
delivery_infoDelivery date information
page_numberWhich search result page the product appeared on
amazon_domainThe marketplace domain scraped
search_queryThe search term used
scraped_atISO 8601 timestamp

Product Detail Pages

When scraping direct product URLs or enabling fetchDetails: true on search, additional fields are extracted:

FieldDescription
descriptionFull product description text
featuresBullet-point feature list
specificationsUp to 24 labeled technical attributes from the verified product detail page, with source labels and units. Package dimensions and product dimensions retain separate labels. ASINs, canonical /dp/ product URLs and keyword runs with Fetch Product Details enabled can include this object. The parser recognizes selected English and German labels. Missing or conflicting attributes are omitted.
availabilityStock availability status
sellerThird-party seller name (if not Amazon)
categoryProduct category breadcrumb path
imagesList of hi-res gallery image URLs (up to 12)
bestseller_rankAmazon's "Best Sellers Rank" position in its category
bestseller_categoryCategory label associated with bestseller_rank

For a catalog check, choose the Technical specifications dataset view and export JSON, or read GET https://api.apify.com/v2/datasets/DATASET_ID/items?view=specifications&format=json. Each row includes the available ASIN, marketplace, observation time, product URL and specification map. A blank cell means no supported attribute was observed. Use the explicitly labeled measure, such as product dimensions or package dimensions.

BSR Time-Series Fields

When trackBestsellerRank: true, these fields are added to every product:

FieldDescription
rank_nowCurrent BSR (same as bestseller_rank)
rank_previousPrevious BSR for the same ASIN and category. Null without comparable history
rank_changerank_previous - rank_now. Positive = climbed, negative = fell
rank_peakBest (lowest) rank in the current comparable category history
rank_movementnew, rising, falling, steady or unknown
rank_previous_scraped_atISO timestamp of the previous snapshot
hours_since_last_snapshotHours between previous snapshot and this run

Sample Output

{
"asin": "B0CHX3QBCH",
"title": "Apple iPhone 15 Pro, 128GB, Natural Titanium",
"price": 999.00,
"original_price": 1099.00,
"discount_percentage": 9.1,
"currency": "USD",
"rating": 4.6,
"reviews_count": 2431,
"is_prime": true,
"is_sponsored": false,
"in_stock": true,
"image_url": "https://m.media-amazon.com/images/I/81Os1SBkFpL._AC_SL1500_.jpg",
"url": "https://www.amazon.com/dp/B0CHX3QBCH",
"brand": "Apple",
"badge": "Amazon's Choice",
"delivery_info": "FREE delivery Tomorrow",
"availability": "In Stock",
"seller": "Amazon.com",
"features": ["6.1-inch Super Retina XDR display", "A17 Pro chip", "48MP Main camera", "Titanium design"],
"category": "Electronics > Cell Phones & Accessories > Unlocked Cell Phones",
"bestseller_rank": 4,
"bestseller_category": "Unlocked Cell Phones",
"description": "The iPhone 15 Pro features a titanium design with the A17 Pro chip...",
"amazon_domain": "amazon.com",
"search_query": "iphone 15 pro",
"scraped_at": "2026-04-18T10:15:00Z"
}

BSR Rank Movement Summary

A rank_movement_summary rollup item is pushed at the end of each run when a prior snapshot exists:

{
"type": "rank_movement_summary",
"amazon_domain": "amazon.com",
"search_query": "air fryer",
"snapshot_at": "2026-04-23T12:00:00+00:00",
"previous_snapshot_at": "2026-04-22T12:00:00+00:00",
"climbers_count": 3,
"fallers_count": 2,
"top_climbers": [{"asin": "B0C...", "rank_previous": 812, "rank_now": 417, "rank_change": 395, "title": "...", "bestseller_category": "..."}],
"top_fallers": [{"asin": "B0D...", "rank_previous": 42, "rank_now": 210, "rank_change": -168, "title": "...", "bestseller_category": "..."}]
}

Screenshots / Sample Output

What you'll see in Apify Console -> Storage -> Default dataset -> JSON after a daily-scheduled run:

Sample BSR rank-movement output (one row per tracked ASIN):

{
"asin": "B0CHX3QBCH",
"title": "Keychron Q1 Pro QMK/VIA Wireless Mechanical Keyboard",
"rank_now": 417,
"rank_previous": 812,
"rank_change": 395,
"rank_change_pct": 48.65,
"rank_movement": "rising",
"rank_peak": 390,
"bestseller_category": "Electronics > Computer Keyboards",
"scraped_at": "2026-04-23T12:00:00+00:00"
}

Sample BSR webhook payload (POSTed to alertWebhookUrl when |rank_change| >= alertRankThreshold):

{
"asin": "B0CHX3QBCH",
"title": "Keychron Q1 Pro QMK/VIA Wireless Mechanical Keyboard",
"url": "https://www.amazon.com/dp/B0CHX3QBCH",
"marketplace": "amazon.com",
"rank_previous": 812,
"rank_now": 417,
"rank_change": 395,
"rank_change_pct": 48.65,
"rank_movement": "rising",
"price": 199.00,
"currency": "USD",
"scraped_at": "2026-04-23T12:00:00+00:00"
}

Run a single ASIN to see this output live.

Pricing

This actor uses pay-per-event pricing. Starter (Bronze), Scale (Silver) and Business (Gold) receive 20%, 30% and 40% off the ordinary events below. Platinum and Diamond use the Business/Gold amounts. Discounts depend on your Apify subscription plan, not a per-run quantity threshold. The live Pricing tab shows your applicable prices.

All amounts are USD per event. The default-dataset fee and legacy $5 bundle stay flat across plans.

EventFree / baseStarter / BronzeScale / SilverBusiness / GoldWhen it applies
product-scraped$0.005$0.004$0.0035$0.003Each product row saved with search-result or product-page data, including rows whose optional detail enrichment was incomplete
rank-tracked$0.01$0.008$0.007$0.006Each distinct ASIN with a positive, categorized BSR observation saved when trackBestsellerRank: true
alert-dispatched$0.002$0.0016$0.0014$0.0012Each BSR-alert webhook successfully POSTed with a 2xx response
connector-alert-dispatched$0.002$0.0016$0.0014$0.0012Each qualifying BSR alert successfully delivered through an MCP output connector
ai-analysis-completed$0.05$0.04$0.035$0.03One-time charge when AI competitive analysis is generated
apify-actor-start$0.00005$0.00004$0.000035$0.00003Once when the Actor starts
apify-default-dataset-item$0.00001$0.00001$0.00001$0.00001Each item saved to the default dataset
skyfire-bundle-1000-products$5$5$5$5Legacy listed event; see the qualification below

Some saved product rows have no usable price and are excluded from the CSV above. A failed scrape requests no product event, and a failed webhook or connector attempt requests no corresponding alert event. Start and saved-dataset events can still apply to a run without useful products. Optional external AI-provider charges are separate.

Skyfire payment note

The legacy skyfire-bundle-1000-products event remains listed at $5 on every plan. A prepaid workflow that replaces ordinary product, rank or AI events with this bundle has not been verified; do not use its name as a quote for included output. Ordinary runs use the event table above. Apify's Skyfire integration requires at least $5 of available PAY-token balance, not a $5 minimum charge per invocation.

Base-rate event subtotal examples: These exclude start and default-dataset events and any external-provider charges. Multiply the listed product, rank, alert and AI subtotals by 0.8 on Starter, 0.7 on Scale or 0.6 on Business; add the applicable start and dataset fees separately.

  • 100 products = $0.50
  • 100 products + AI analysis = $0.55
  • 100 products + BSR tracking (60 have BSR) + AI rank report = $0.005 x 100 + $0.01 x 60 + $0.05 = $1.15
  • 25-product daily watchlist with 3 webhook alerts/day = $0.005 x 25 + $0.01 x 25 + $0.002 x 3 = $0.381/day ~ $11.43/month

Export formats: JSON, CSV, Excel - plus 2,000+ app integrations via Apify (Google Sheets, Slack, Zapier, Make, Amazon S3).

There is no separate Actor rental fee. The base product event is $0.005; paid Apify plans qualify for the discounts above. Enabled rank tracking, successful alert delivery, completed AI analysis, startup and saved-dataset events are separately chargeable as listed.

Quick Start

Minimum working input - scrape 10 products from amazon.com with residential proxy:

{
"searchQuery": "wireless headphones",
"amazonDomain": "amazon.com",
"maxProducts": 10,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"],
"apifyProxyCountry": "US"
}
}

Base-rate event subtotal: 10 products x $0.005 = $0.05, before start and saved-dataset events. Add enableAiAnalysis: true for a one-time +$0.05 completed competitive report, plus any external-provider charges. Eligible plan discounts apply as shown above.

Scrape specific products by ASIN

{
"productUrls": [
"https://www.amazon.de/dp/B09JGFTTRX",
"https://www.amazon.de/dp/B0057ED9AM"
],
"amazonDomain": "amazon.de",
"maxProducts": 2,
"fetchDetails": true,
"trackBestsellerRank": false,
"enableAiAnalysis": false,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": [
"RESIDENTIAL"
],
"apifyProxyCountry": "DE"
}
}

Search with AI competitive analysis

{
"searchQuery": "standing desk",
"amazonDomain": "amazon.com",
"maxProducts": 50,
"enableAiAnalysis": true,
"llmProvider": "openrouter",
"openrouterApiKey": "sk-or-...",
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"]
}
}

AI analysis examines all scraped products and generates a structured report including: market overview, price sweet spot ranges, top-5 best-value picks, brand share distribution, and opportunity identification. Output is returned as structured JSON alongside the product data.

Track Best Sellers Rank over time

Save a daily task to compare each ASIN with its previous observation in the same Amazon category.

{
"searchQuery": "air fryer",
"amazonDomain": "amazon.com",
"maxProducts": 50,
"trackBestsellerRank": true,
"enableAiAnalysis": true,
"llmProvider": "openrouter",
"openrouterApiKey": "sk-or-...",
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"],
"apifyProxyCountry": "US"
}
}

A categorized rank starts a baseline when comparable history is unavailable. Unknown categories leave existing history intact. A legacy peak without a recorded category is rebuilt from the comparable raw ranks. Multiple product rows for the same ASIN request one tracking event when their categorized ranks agree. Conflicting categorized ranks are excluded from the snapshot. Optional AI uses saved comparable ranks for movement analysis.

Real-time BSR alerts via webhook

{
"searchQuery": "mechanical keyboard",
"amazonDomain": "amazon.com",
"maxProducts": 25,
"trackBestsellerRank": true,
"alertWebhookUrl": "https://hooks.zapier.com/hooks/catch/12345/abcde",
"alertRankThreshold": 100,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": ["RESIDENTIAL"],
"apifyProxyCountry": "US"
}
}

Webhook payload shape (one POST per qualifying ASIN):

{
"asin": "B0CHX3QBCH",
"title": "Keychron Q1 Pro QMK/VIA Wireless Mechanical Keyboard",
"url": "https://www.amazon.com/dp/B0CHX3QBCH",
"marketplace": "amazon.com",
"rank_previous": 812,
"rank_now": 417,
"rank_change": 395,
"rank_change_pct": 48.65,
"rank_movement": "rising",
"rank_peak": 390,
"bestseller_category": "Electronics > Computer Keyboards",
"price": 199.00,
"currency": "USD",
"hours_since_last_snapshot": 24.03,
"scraped_at": "2026-04-23T12:00:00+00:00"
}

Each webhook includes an X-Actor-Run-Id header for correlating alerts with the run in the Apify Console. Only ASINs whose absolute rank_change is >= alertRankThreshold fire (both climbers and fallers). A per-run cap of 250 webhooks prevents runaway misconfigurations.

MCP Quickstart - call this actor from Claude / Cursor / ChatGPT

Review an existing run. Connect Apify MCP. Use the three read tools below with a run you can access.

https://mcp.apify.com?tools=get-actor-run,get-key-value-store-record,get-dataset-items
  1. Call get-actor-run with your runId. Confirm the response has the same runId, actorId set to JyRjxUswjrRheOdmh, and status set to SUCCEEDED.
  2. Pass storages.keyValueStores.default.id as keyValueStoreId to get-key-value-store-record with recordKey set to INPUT.
  3. Pass storages.datasets.default.id as datasetId to get-dataset-items. Read every page using limit and offset. Match the marketplace and ASIN to the saved input, and check the price, currency and scraped_at. A missing price leaves the earlier accepted observation in place. For a repeat comparison, supply the exact saved input and full default dataset export to the offline price reviewer.

Start one new known-ASIN run. If you choose to start a paid run, connect https://mcp.apify.com?tools=call-actor,get-actor-run,get-key-value-store-record,get-dataset-items and use these call-actor arguments. Replace the URL with your own, keeping the marketplace and residential proxy country aligned.

{
"actor": "harvestlab/amazon-scraper",
"input": {
"productUrls": [
"https://www.amazon.de/dp/B09JGFTTRX"
],
"amazonDomain": "amazon.de",
"maxProducts": 1,
"fetchDetails": true,
"trackBestsellerRank": false,
"enableAiAnalysis": false,
"proxyConfiguration": {
"useApifyProxy": true,
"apifyProxyGroups": [
"RESIDENTIAL"
],
"apifyProxyCountry": "DE"
}
},
"callOptions": {
"memory": 256,
"timeout": 300,
"maxTotalChargeUsd": 0.1
},
"waitSecs": 10
}

In this example, one priced product and one saved row at 256 MB cost $0.00405 in Actor events on Starter/Bronze with BSR, AI and alerts off. An unpriced product row can still incur product and dataset events. The $0.10 Actor-charge cap applies to the run. Separate storage reads can incur standard Apify usage after it completes. call-actor returns run metadata and storage IDs. If the run is still in progress, check the same run ID before reading its dataset.

Apify MCP tool reference · Amazon Product Scraper pricing

Use with AI agents

amazon-scraper output is agent-ready: typed product dicts with BSR rank, time-series deltas, currency, and AI sentiment across 19 marketplaces - wrap it as a single tool and your product-research, arbitrage, or competitive-intel agent gets cross-marketplace BSR + price intelligence that commodity Amazon scrapers don't expose. See Apify's actor-templates - specifically js-langchain and js-langgraph-agent - for end-to-end skeletons.

LangChain tool wrapper

These examples use the typed results in apify-client 3.3/3.4 and your existing LangChain/LangGraph installation. Start with one known ASIN. Each invocation of the start tool submits one paid Actor run for up to ten ASINs in one marketplace. The run is bounded to 180 seconds, 256 MB and a $0.10 event-charge cap. Apify platform usage during the run is included under current Store pricing. BSR, AI and receivers are off.

from datetime import timedelta
from decimal import Decimal
import os
import re
from urllib.parse import urlsplit
from apify_client import ApifyClient
from langchain_core.tools import tool
ACTOR_ID = "JyRjxUswjrRheOdmh"
COUNTRIES = {"amazon." + suffix: country for suffix, country in (
("com", "US"), ("ca", "CA"), ("com.mx", "MX"), ("com.br", "BR"),
("co.uk", "GB"), ("de", "DE"), ("fr", "FR"), ("es", "ES"),
("it", "IT"), ("nl", "NL"), ("pl", "PL"), ("se", "SE"),
("co.jp", "JP"), ("in", "IN"), ("com.au", "AU"), ("ae", "AE"),
("sa", "SA"), ("sg", "SG"), ("com.tr", "TR"),
)}
token = os.environ["APIFY_TOKEN"]
start_client = ApifyClient(token, max_retries=0)
client = ApifyClient(token, max_retries=1)
def valid_id(value: object) -> bool:
return isinstance(value, str) and re.fullmatch(r"[A-Za-z0-9]{17}", value) is not None
def direct_input(asins: list[str], domain: str) -> dict:
if (domain not in COUNTRIES or not isinstance(asins, list) or not 1 <= len(asins) <= 10
or any(not isinstance(asin, str) or not re.fullmatch(r"[A-Z0-9]{10}", asin.upper())
for asin in asins)):
raise ValueError("Use 1–10 known ASINs in one supported marketplace")
requested = list(dict.fromkeys(asin.upper() for asin in asins))
return {
"productUrls": [f"https://www.{domain}/dp/{asin}" for asin in requested],
"amazonDomain": domain, "maxProducts": len(requested), "fetchDetails": True,
"trackBestsellerRank": False, "enableAiAnalysis": False,
"alertWebhookUrl": "", "outputConnectors": [],
"proxyConfiguration": {"useApifyProxy": True, "apifyProxyGroups": ["RESIDENTIAL"],
"apifyProxyCountry": COUNTRIES[domain]},
}
@tool
def start_amazon_price_run(asins: list[str], amazonDomain: str = "amazon.com") -> str:
"""Start one paid product run and return the run ID for later review."""
run = start_client.actor(ACTOR_ID).start(
run_input=direct_input(asins, amazonDomain), wait_for_finish=0,
memory_mbytes=256, run_timeout=timedelta(seconds=180),
max_total_charge_usd=Decimal("0.10"), restart_on_error=False,
)
if run.act_id != ACTOR_ID or not valid_id(run.id):
raise RuntimeError("Start outcome is uncertain. Inspect Apify runs before starting again.")
return run.id

For each scheduled refresh, save a pending entry in your own durable store before calling the start tool. Include a unique refresh key, start time, marketplace, ordered ASINs and accepted baseline revision. Allow one scheduler worker to claim that key. Save the returned run ID to that entry before reading its output. If the start response or your checkpoint write is ambiguous, inspect the Actor's runs in Console using the time and exact saved INPUT. Attach the uniquely matching run ID to the pending entry. Leave the refresh pending when you cannot establish which run started.

LangGraph price-tracking node

Run the wrapper block above first, then supply an exact run ID from your saved refresh entry. This graph reads that run and compares its prices with previous accepted observations for the same marketplace and ASIN. The threshold is a percentage price drop. An unambiguous first observation seeds the candidate baseline without an alert. An explicit, eligible zero stays zero. At the newest observation time, a missing price, a range or offer-source marker, an unavailable item or a recorded price reason keeps the accepted baseline and suppresses the price alert. Check baselines saved with earlier copies against the original dataset before reusing them. The node skips the percentage calculation when the previous price was zero.

from datetime import datetime
from decimal import Decimal, InvalidOperation
import re
from typing import TypedDict
from langgraph.graph import StateGraph, START, END
class PriceState(TypedDict):
run_id: str
review_status: str
asins: list[str]
amazonDomain: str
price_drop_percent: float
baseline: dict[str, dict]
products: list[dict]
alerts: list[dict]
alert: bool
stale: bool
def offer_query(url: str) -> str:
# Associates tags are tracking parameters. Other query components can select an offer.
return "&".join(part for part in urlsplit(url).query.split("&")
if part and part.partition("=")[0] != "tag")
def offer_context(item: dict) -> tuple[str, str, str]:
seller = item.get("seller")
seller = " ".join(seller.split()).lower() if isinstance(seller, str) else ""
return item["currency"], offer_query(item.get("url") or item["product_url"]), seller
def qualified_price(item: dict, currency: str) -> str | None:
if (item.get("in_stock") is False or item.get("price_reason") is not None
or any(item.get(field) is not None for field in ("price_source", "price_min", "price_max"))
or not re.fullmatch(r"[A-Z]{3}", currency)):
return None
try:
price = Decimal(str(item.get("price")))
except InvalidOperation:
return None
return str(price) if price.is_finite() and price >= 0 else None
def price_observation(item: dict, domain: str) -> dict | None:
try:
if (not isinstance(item, dict) or item.get("diagnostic_item") or item.get("block_detected")
or item.get("error") or item.get("result_type") not in (None, "product_data")):
return None
asin, currency = str(item.get("asin", "")).upper(), str(item.get("currency", "")).upper()
observed = datetime.fromisoformat(item["scraped_at"].replace("Z", "+00:00"))
if (item.get("amazon_domain") != domain or not re.fullmatch(r"[A-Z0-9]{10}", asin)
or not str(item.get("title") or "").strip() or observed.utcoffset() is None):
return None
urls = [item[k] for k in ("url", "product_url") if item.get(k)]
if not urls:
return None
for url in urls:
parsed = urlsplit(url)
ids = re.findall(r"/(?:dp|gp/product|product)/([A-Z0-9]{10})(?=/|$)", parsed.path, re.I)
if (parsed.scheme not in {"http", "https"} or (parsed.hostname or "").removeprefix("www.") != domain or parsed.username or parsed.password
or parsed.port or any(value.upper() != asin for value in ids)):
return None
return dict(item, asin=asin, currency=currency, price=qualified_price(item, currency),
product_key=domain + ":" + asin, scraped_at=observed.isoformat())
except (KeyError, ValueError, TypeError, AttributeError, InvalidOperation):
return None
def matching_saved_input(saved: object, expected: dict) -> bool:
if not isinstance(saved, dict):
return False
# Apify can persist default values alongside the submitted input.
allowed_defaults = {
"searchQuery": "", "sortBy": "relevance", "alertRankThreshold": 50,
"alertWebhookUrl": "", "connectorAlertTarget": "", "outputConnectors": [],
"llmProvider": "openrouter",
}
required = {key: value for key, value in expected.items() if key not in allowed_defaults}
for key, value in required.items():
actual = saved.get(key)
if key == "fetchDetails" and type(actual) is bool:
continue # The direct-URL path already reads the detail page.
if key == "proxyConfiguration" and isinstance(actual, dict):
if actual.get("useApifyProxy") is not True:
return False
if "apifyProxyCountry" not in actual:
# The Actor resolves the missing country to the same marketplace.
actual = {**actual, "apifyProxyCountry": value["apifyProxyCountry"]}
if type(actual) is not type(value) or actual != value:
return False
return all(
key in required or key in allowed_defaults and type(value) is type(allowed_defaults[key])
and value == allowed_defaults[key] for key, value in saved.items()
)
def track_node(state: PriceState) -> PriceState:
threshold = Decimal(str(state["price_drop_percent"]))
if not threshold.is_finite() or not 0 < threshold <= 100:
raise ValueError("price_drop_percent must be greater than zero and at most 100")
domain = state["amazonDomain"]
expected = direct_input(state["asins"], domain)
asins = {url.rsplit("/", 1)[-1] for url in expected["productUrls"]}
baseline, products, alerts, accepted = dict(state.get("baseline", {})), [], [], set()
run_id = state.get("run_id")
def held(status: str) -> PriceState:
return {**state, "baseline": baseline, "products": [], "alerts": [],
"alert": False, "stale": True, "review_status": status}
if not valid_id(run_id):
return held("run_id_required")
try:
run = client.run(run_id).get()
if run is None or run.id != run_id or run.act_id != ACTOR_ID:
return held("run_identity_unverified")
if run.status != "SUCCEEDED":
return held("run_not_succeeded")
if not valid_id(run.default_key_value_store_id) or not valid_id(run.default_dataset_id):
return held("run_storage_unverified")
record = client.key_value_store(run.default_key_value_store_id).get_record("INPUT", timeout="medium")
if not record or not matching_saved_input(record.get("value"), expected):
return held("run_input_mismatch")
rows = list(client.dataset(run.default_dataset_id).iterate_items(limit=101, timeout="medium"))
if len(rows) > 100:
return held("dataset_exceeds_review_limit")
except Exception:
return held("run_read_unavailable")
latest = {}
for item in rows:
row = price_observation(item, domain)
if row is None or row["asin"] not in asins:
continue
if row["price"] is not None:
products.append(row)
key = row["product_key"]
observed = datetime.fromisoformat(row["scraped_at"])
previous = latest.get(key)
if previous is None or observed > previous[0]:
latest[key] = observed, [row]
elif observed == previous[0]:
previous[1].append(row)
for key, (observed, observations) in latest.items():
old = price_observation(baseline.get(key, {}), domain)
if old and old["product_key"] != key:
old = None # A mis-keyed baseline is not a previous observation of this ASIN.
# A newer or tied unavailable offer holds this product, even if an older row had a price.
if any(row["price"] is None for row in observations):
continue
row, *duplicates = observations
price, context = Decimal(row["price"]), offer_context(row)
if any(Decimal(other["price"]) != price or offer_context(other) != context for other in duplicates):
continue # Hold the entire product when tied observations disagree.
if old:
previous_context = offer_context(old)
if (observed <= datetime.fromisoformat(old["scraped_at"])
or context[:2] != previous_context[:2]
or (previous_context[2] and context[2] != previous_context[2])):
continue # Keep the accepted time and price until a comparable newer observation.
if old and old["price"] is not None and Decimal(old["price"]) > 0:
drop = (Decimal(old["price"]) - price) * 100 / Decimal(old["price"])
if drop >= threshold:
alerts.append({"product_key": key, "previous_price": old["price"], "price": row["price"],
"currency": row["currency"], "price_drop_percent": str(drop), "scraped_at": row["scraped_at"]})
baseline[key] = row
accepted.add(row["asin"])
complete = len(accepted) == len(asins)
return {**state, "baseline": baseline, "products": products, "alerts": alerts,
"alert": bool(alerts), "stale": not complete,
"review_status": "complete" if complete else "review_required"}
graph = StateGraph(PriceState)
graph.add_node("track", track_node)
graph.add_edge(START, "track")
graph.add_edge("track", END)
price_watch = graph.compile()
# Supply the exact run ID already stored for this refresh.
# result = price_watch.invoke({"run_id": saved_run_id, "asins": ["B0CHX3QBCH"], "amazonDomain": "amazon.com",
# "price_drop_percent": 10, "baseline": {}, "products": [], "alerts": [], "alert": False, "stale": True})

If a run is still pending or a storage read fails, invoke only the graph again with the same saved run ID and baseline revision. The review uses Apify reads and requires the saved direct INPUT to match the planned batch. Keep the run ID available until review is complete.

Review the returned candidate baseline before saving it in your own authorized store. Pass the accepted map to the next invocation. The node uses the newest qualified source instant for each ASIN. When rows at that instant disagree on price, currency, seller or offer query, the candidate keeps the previous entry or leaves the ASIN absent. Equivalent decimal values, timezone offsets, seller case and spacing and Associates tags can describe the same price observation. A held ASIN has no alert. Other ASINs can still update.

Review products for the validated source rows and alerts for the proposed price drops. stale is true when any requested ASIN lacks an accepted newer observation. A changed offer query, a changed or missing previously known seller, or a different currency at the newest instant keeps the prior entry for review. Configure scheduling, persistence and alert delivery in your own workflow. Keep marketplace and proxy routing consistent. Start with one known ASIN and verify your workload before watching up to ten.

Troubleshooting

Getting 403 / 429 / CAPTCHA errors

Inspect the run log and confirm the marketplace, proxy configuration and requested limits. Residential routing may help, but it does not guarantee access. Keep an existing good export and mark it stale when a run returns no qualifying products. Increasing the product cap or repeatedly rerunning a blocked input does not establish a working access path.

Prices appearing in the wrong currency

The proxy IP's geographic location determines which currency Amazon renders, not the domain. Set apifyProxyCountry to the matching country code (see the table in the Input section above).

No products returned (empty dataset)

  1. Verify the amazonDomain matches the locale of your searchQuery (e.g. German keyword with amazon.de).
  2. Test with a simple English keyword like "laptop" on amazon.com with maxProducts: 5 to isolate the issue.
  3. Retry with fresh proxy IPs - if the first IP batch is flagged, a new run often succeeds.
  4. Check the actor log for WAF / CAPTCHA detection messages. If present, follow the 403/429 steps above.

Webhooks not firing

  • Webhooks require a saved observation and a comparable prior rank in the same category.
  • Ensure trackBestsellerRank: true is set (or provide alertWebhookUrl - it auto-enables BSR tracking).
  • Confirm the URL is reachable and returns a 2xx response. Only successful dispatches are billed.
  • Check the bsr_alert_dispatch_summary item pushed to the dataset for per-webhook results.

BSR fields are null / rank_movement is "new"

A new categorized rank establishes a baseline. A missing rank or category leaves comparable fields unknown. Check the run status if an expected history update failed.

amazon.fr returning no results

amazon.fr runs the strictest AWS WAF of all supported EU domains. Workarounds: (1) retry the run, (2) use direct product URLs (/dp/ASIN) which succeed more reliably than keyword search, or (3) fall back to amazon.de / amazon.co.uk / amazon.it which share much of the EU catalog.

amazon.co.jp prices showing in USD/EUR

Amazon localizes pages based on requesting IP. Set apifyProxyCountry: "JP" to get a Japanese exit IP and genuine JPY results.

Frequently Asked Questions

Is this an Amazon product scraper? Yes. It scrapes Amazon search results and product pages for prices, ASINs, star ratings, rating or review counts, availability, seller data, images, Best Sellers Rank, and marketplace currency.

Can I use it as an Amazon ASIN scraper? Yes. Provide direct product URLs or /dp/ASIN links to extract known products, or search by keyword and use the returned asin field for catalog research and tracking.

Does it scrape Amazon reviews? It returns the displayed star rating and count when available. For a spreadsheet, export the run dataset with all fields as Excel or CSV and keep product rows. Compare rating and reviews_count by amazon_domain, asin and scraped_at, including rows with a blank price. A count change alone cannot identify added or removed written reviews. Individual review text is outside this export.

Can it track Amazon prices over time? Yes. Schedule recurring runs for the same ASINs and export the resulting price, availability, and BSR fields into your own dashboard or spreadsheet.

Can it send BSR alerts? Yes. Set alertWebhookUrl to an endpoint that accepts BSR event JSON. A workflow in Zapier, Make or n8n can format that event for Slack or Discord. Setting the URL enables trackBestsellerRank.

This actor is provided as a technical tool. Users are responsible for ensuring their use complies with:

  • Amazon's Terms of Service and Conditions of Use
  • Applicable data protection laws (GDPR, CCPA, etc.)
  • Local laws regarding web scraping and data collection

Amazon's Terms of Service restrict automated access to their platform. Use this tool responsibly and at your own risk. This actor does not store or process personal data - it only extracts publicly visible product catalog information.

The developer of this actor is not responsible for any misuse or legal consequences arising from its use.