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 "categories": [
13 "dresses"
14 ],
15 "sortBy": "recommended",
16 "availabilityScope": "all",
17 "urls": [
18 "https://www.renttherunway.com/c/dresses",
19 "https://www.renttherunway.com/c/dresses/gowns",
20 "https://www.renttherunway.com/products?filters%5BsearchText%5D=black+gown",
21 "https://www.renttherunway.com/shop/designers/amur/reese_cascade_gown"
22 ],
23 "fetchDetails": true,
24 "fetchReviews": false,
25 "maxReviews": 20,
26 "maxItems": 20,
27 "maxPages": 0,
28 "proxy": {
29 "useApifyProxy": true
30 },
31 "incrementalMode": false,
32 "emitUnchanged": false,
33 "emitExpired": false,
34 "ignoreFieldsForChanges": [],
35 "maxNotifyListings": 50
36};
37
38
39const run = await client.actor("abotapi/renttherunway-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