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 "queries": [
13 "Fender Stratocaster"
14 ],
15 "urls": [
16 "https://api.reverb.com/api/listings?query=stratocaster&condition=used&per_page=1",
17 "https://api.reverb.com/api/listings?query=stratocaster&per_page=2&page=2",
18 "https://reverb.com/brand/fender",
19 "https://reverb.com/shop/lavonta-rashawns-boutique",
20 "https://reverb.com/item/103425668",
21 "https://api.reverb.com/api/csps?query=stratocaster&per_page=1",
22 "https://api.reverb.com/api/comparison_shopping_pages/126164",
23 "https://reverb.com/marketplace?query=Gibson%20Les%20Paul&condition=used",
24 "https://reverb.com/price-guide/fender-american-professional-ii-stratocaster"
25 ],
26 "proxy": {
27 "useApifyProxy": true
28 },
29 "incrementalMode": false,
30 "emitUnchanged": false,
31 "emitExpired": false,
32 "changeScope": "all",
33 "compactUpdates": false,
34 "expireAfterMissedScans": 1,
35 "ignoreFieldsForChanges": []
36};
37
38
39const run = await client.actor("abotapi/reverb-scraper").call(input);
40
41
42console.log('Results from dataset');
43console.log(`๐พ Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
44const { items } = await client.dataset(run.defaultDatasetId).listItems();
45items.forEach((item) => {
46 console.dir(item);
47});
48
49