npm - TypeScript / JavaScript
Node.js SDK
First-class TypeScript types for every product field, Promise-based async API, retry middleware. Works in Node, Bun, Deno, Cloudflare Workers, and any modern runtime.
Quick start
1. Install
npm install amazon-scraper-api-sdk 2. Scrape your first ASIN
import { Client } from "amazon-scraper-api-sdk";
const asa = new Client({ apiKey: "asa_live_..." });
const product = await asa.products.get("B08N5KWBKK", { domain: "com" });
console.log(product.title, product.price, product.rating); 3. TypeScript autocomplete works out of the box
// product is typed as Product
// product.price is typed as number | null
// product.images is typed as string[]
// IDE shows every field How-to
Search Amazon
const results = await asa.search.run({
query: "wireless earbuds",
domain: "com",
pages: 3,
sortBy: "best_match",
});
for (const r of results) {
console.log(r.position, r.asin, r.title, r.price);
} Async batch with webhooks
const batch = await asa.batch.create({
asins: ["B08N5KWBKK", "B0DZ7871B8" /* up to 1000 */],
domain: "com",
webhookUrl: "https://your.app/webhook",
});
// Or wait inline
const results = await asa.batch.wait(batch.id, { timeoutMs: 600000 });
console.log(`got ${results.length} products`); Verify a webhook callback
// Express handler
app.post("/webhook", express.raw({ type: "application/json" }), (req, res) => {
const valid = asa.verifyWebhook(req.headers, req.body);
if (!valid) return res.status(400).send("invalid signature");
const payload = JSON.parse(req.body.toString());
// ... process payload
res.sendStatus(200);
}); Run on Cloudflare Workers
// worker.ts
import { Client } from "amazon-scraper-api-sdk";
export default {
async fetch(req: Request, env: Env) {
const asa = new Client({ apiKey: env.ASA_KEY });
const url = new URL(req.url);
const asin = url.searchParams.get("asin");
if (!asin) return new Response("missing asin", { status: 400 });
const product = await asa.products.get(asin);
return Response.json(product);
}
}; SDK uses fetch() under the hood, no Node-only APIs. Works on every modern edge runtime.
Why use the SDK over raw fetch?
First-class TypeScript
Generated from the OpenAPI spec. Every product field is typed; refactors and renames stay safe across your codebase.
Retry middleware
Configurable backoff on 429 + 5xx. Never charged for retries since only 2xx responses bill.
Universal runtime
Works in Node 18+, Bun, Deno, Cloudflare Workers, Vercel Edge, and the browser. No Node-only dependencies.
Webhook signature verification
Built-in HMAC verifier so a forged callback cannot trigger your business logic.
Streaming batch results
`for await (const r of asa.batch.stream(id))` yields results as they complete instead of waiting for the whole batch.
Tree-shakeable
Import only what you use. Bundle-size impact is <15kb gzipped on the search-only client.
Official resources
- npm package - install via npm / yarn / pnpm
- GitHub repo - source + issues + changelog
- Product API reference
- Search API reference
- Async batch API reference
- How to scrape Amazon product listings
Pricing
Same rate across every integration. Monthly plans from $19 or pay-as-you-go at $0.90 per 1,000 successful requests. 1,000 free on signup.
Free
Forever free on signup
- check_circle1,000 requests / month
- check_circle10 concurrent requests
- check_circleAll 20 marketplaces
- check_circleFull dashboard + analytics
- check_circleTop-up at $0.90 / 1k
- check_circleCommunity support
Vibe
$0.70 / 1k effective
- check_circle27,000 requests / month
- check_circle30 concurrent requests
- check_circleAll endpoints + content-language
- check_circleCountry-matched residential IPs
- check_circlePer-API-key usage tracking
- check_circleTop-up at $0.90 / 1k
- check_circleEmail support (1 business day)
Pro
$0.60 / 1k effective
- check_circle82,000 requests / month
- check_circle50 concurrent requests
- check_circlePriority routing queue
- check_circleCountry-matched residential IPs
- check_circleTeam seats (up to 5)
- check_circleTop-up at $0.90 / 1k
- check_circleEmail + chat support
Custom
Flat $0.50 / 1k effective at every level
- check_circle200k - 4M+ requests / month
- check_circle100-500+ concurrent requests
- check_circlePriority queue (highest)
- check_circlePremium proxy pool + SLA on request
- check_circleUnlimited team seats
- check_circleWire / invoice / annual PO
- check_circleDedicated Slack channel
Pay-as-you-go top-up
$0.90 / 1,000 successful requests
Available on every plan including Free. Top up any time when included credits run out. Only 2xx responses charged. Balance never expires.
Ship with Node today
1,000 free requests on signup. No credit card required.