1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "mode": "productUrl",
12 "productUrls": [
13 "https://www.flipkart.com/triggr-arcus-one-60h-battery-4-mic-enc-dual-pairing-rubber-grip-13mm-drivers-v6-0-bluetooth/p/itmc75b69ddbd3df?pid=ACCHKBKZXE5FSZVH&lid=LSTACCHKBKZXE5FSZVHJAEZSJ",
14 "https://www.flipkart.com/aroma-nb119b-badshah-40-hours-playtime-neckband-bluetooth/p/itm45cdcb3a95f2f?pid=ACCG2TC8SURNPZAA&lid=LSTACCG2TC8SURNPZAAEIAOTI",
15 "https://www.flipkart.com/footloose-p47-wireless-bluetooth-headphones-mic-fm-sd-card-hands-foldable-design-gaming/p/itm167c9b8d474b1?pid=ACCHQCHHNUJYSGU4&lid=LSTACCHQCHHNUJYSGU4NL8UQN",
16 "https://www.flipkart.com/worricow-wireless-bluetooth-headphone-over-ear-headset-microphone-stereo-3-5mm-audio/p/itmf22d6268b54bf?pid=ACCGM2BFXNKTD3FG&lid=LSTACCGM2BFXNKTD3FGPITV3Y",
17 "https://www.flipkart.com/vaslas-p47-foldable-bluetooth-headphone/p/itm7c737af6de449?pid=ACCHPQFRD6HU88ZG&lid=LSTACCHPQFRD6HU88ZG5J8BN7",
18 "https://www.flipkart.com/noise-buds-vs102-elite-50hr-playtime-enc-quad-mic-chrome-finish-flybird-design-bluetooth/p/itmd21bac81f0954?pid=ACCHFCF2G2NAQU8V&lid=LSTACCHFCF2G2NAQU8VMO1SCO",
19 "https://www.flipkart.com/shreevistaar-headphones-soft-protein-leather-ear-pads-bluetooth/p/itmeebda10432c9f?pid=ACCHR59M8QY6SDRT&lid=LSTACCHR59M8QY6SDRTEQIVEA",
20 "https://www.flipkart.com/footloose-branded-new-wireless-headphones-hd-bass-sound-foldable-design-built-in-mic-bluetooth-gaming/p/itm3c125fc7f2bd0?pid=ACCHZMBT9WYEK5RS&lid=LSTACCHZMBT9WYEK5RSJXIFHN",
21 "https://www.flipkart.com/boat-rockerz-411-40h-battery-40ms-latency-stream-ad-free-music-via-app-bt-v5-4-bluetooth/p/itmf824790d6dde3?pid=ACCHCJW33SSHZY9H&lid=LSTACCHCJW33SSHZY9HXPKHWI",
22 "https://www.flipkart.com/worricow-best-buy-bluetooth-headphones-mic-volume-control-stereo-fm-sd-card-support/p/itm26b5bdd5af80d?pid=ACCHP9HC2WC86RCF&lid=LSTACCHP9HC2WC86RCFQ6X67T"
23 ],
24 "maxItems": 10,
25 "sellersPageUrls": [
26 "https://www.flipkart.com/sellers?pid=ACCHKBKZXE5FSZVH"
27 ],
28 "maxConcurrency": 1,
29 "proxyConfiguration": {
30 "useApifyProxy": false,
31 "apifyProxyCountry": "IN"
32 }
33};
34
35
36const run = await client.actor("gitlab/flipkart-seller-scraper").call(input);
37
38
39console.log('Results from dataset');
40console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
41const { items } = await client.dataset(run.defaultDatasetId).listItems();
42items.forEach((item) => {
43 console.dir(item);
44});
45
46