1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "start_urls": [
12 {
13 "url": "https://www.zara.com/uk/en/"
14 },
15 {
16 "url": "https://www.zara.com/uk/en/woman-jackets-l1114.html?v1=2536936"
17 },
18 {
19 "url": "https://www.zara.com/uk/en/water-and-wind-protection-short-puffer-anorak-p03046241.html?v1=423159609&v2=2419032"
20 }
21 ],
22 "max_subcategories": 1,
23 "max_results": 5
24};
25
26
27const run = await client.actor("datasaurus/zara").call(input);
28
29
30console.log('Results from dataset');
31console.log(`๐พ Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
32const { items } = await client.dataset(run.defaultDatasetId).listItems();
33items.forEach((item) => {
34 console.dir(item);
35});
36
37