1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "mode": "search",
12 "searchTerm": "akku ventilator",
13 "urls": [
14 "https://www.obi.de/search/akku%20ventilator/",
15 "https://www.obi.de/search/werkzeuge/?page=3",
16 "https://www.obi.de/search/werkzeuge/",
17 "https://www.obi.de/search/aktion/",
18 "https://www.obi.de/search/akku%20ventilator/?sort=price_asc",
19 "https://www.obi.de/p/6929863/einhell-werkzeugkoffer-universal-80tlg-e-case",
20 "https://www.obi.de/p/6929863",
21 "https://www.obi.de/search/akku%20ventilator",
22 "https://obi.de/search/akku%20ventilator/",
23 "https://www.obi.de/marken/eufy"
24 ],
25 "brands": [],
26 "proxy": {
27 "useApifyProxy": true
28 },
29 "incrementalMode": false,
30 "emitUnchanged": false,
31 "emitExpired": false,
32 "compactUpdates": false
33};
34
35
36const run = await client.actor("abotapi/obi-de-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