1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "mode": "items",
12 "items": [
13 {
14 "asin": "B0GOOD123",
15 "title": "Silicone drawer organizer set",
16 "marketplace": "US",
17 "category": "Kitchen",
18 "price": 29.99,
19 "reviewCount": 142,
20 "rating": 4.2,
21 "bestSellerRank": 1850,
22 "sellerCount": 2,
23 "monthlySales": 1200,
24 "marginPercent": 38,
25 "url": "https://www.amazon.com/dp/B0GOOD123",
26 "features": [
27 "silicone",
28 "dishwasher safe",
29 "space saving"
30 ]
31 },
32 {
33 "ASIN": "B0QUAL123",
34 "productTitle": "Stackable pantry organizer bins",
35 "country": "US",
36 "department": "Home",
37 "currentPrice": 24.5,
38 "ratingsCount": 310,
39 "stars": 3.7,
40 "rank": 4200,
41 "sellers": 2,
42 "estimatedMonthlySales": 600,
43 "profitMargin": 31,
44 "complaints": "Customers complain about cracked lids and weak handles.",
45 "productUrl": "https://www.amazon.com/dp/B0QUAL123"
46 },
47 {
48 "asin": "B0RISKY",
49 "title": "Seasonal fragile glass diffuser with patent note",
50 "marketplace": "US",
51 "category": "Home",
52 "price": 32,
53 "reviewCount": 90,
54 "rating": 4.1,
55 "bestSellerRank": 2100,
56 "sellerCount": 1,
57 "monthlySales": 900,
58 "marginPercent": 42,
59 "riskNotes": "Potential patent issue, fragile packaging, seasonal demand.",
60 "url": "https://www.amazon.com/dp/B0RISKY"
61 }
62 ],
63 "sellerProfile": {
64 "targetMarketplace": "US",
65 "targetCategories": [
66 "Kitchen",
67 "Home"
68 ],
69 "avoidCategories": [
70 "Supplements"
71 ],
72 "targetKeywords": [
73 "silicone",
74 "organizer"
75 ],
76 "avoidKeywords": [
77 "medical"
78 ],
79 "minPrice": 15,
80 "maxPrice": 60,
81 "minMarginPercent": 25,
82 "maxReviewCount": 500,
83 "minRatingGap": 0.3,
84 "maxSellers": 5,
85 "maxWeightLb": 3,
86 "riskKeywords": [
87 "patent",
88 "hazmat",
89 "gated",
90 "fragile",
91 "seasonal"
92 ],
93 "capitalBudget": 5000
94 },
95 "scrapedAt": "2026-07-08T00:00:00.000Z"
96};
97
98
99const run = await client.actor("rotvuvo/amazon-product-opportunity-gap-scorer").call(input);
100
101
102console.log('Results from dataset');
103console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
104const { items } = await client.dataset(run.defaultDatasetId).listItems();
105items.forEach((item) => {
106 console.dir(item);
107});
108
109