1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "sp_intended_usage": "Describe your intended use...",
12 "sp_improvement_suggestions": "Share your suggestions here...",
13 "sp_contact": "Share your email here...",
14 "countries": [
15 "us"
16 ],
17 "city": "",
18 "specialty": "",
19 "profileUrls": [
20 {
21 "url": "https://www.ratemds.com/doctor-ratings/3540782/Dr-Michael-Robbins-Markham-ON.html/"
22 },
23 {
24 "url": "https://www.ratemds.com/doctor-ratings/dr-angelo-ayar-tamarac-fl-us/"
25 }
26 ],
27 "maxItems": 5,
28 "proxyConfiguration": {
29 "useApifyProxy": true,
30 "apifyProxyGroups": [
31 "RESIDENTIAL"
32 ],
33 "apifyProxyCountry": "US"
34 }
35};
36
37
38const run = await client.actor("jungle_synthesizer/ratemds-scraper").call(input);
39
40
41console.log('Results from dataset');
42console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
43const { items } = await client.dataset(run.defaultDatasetId).listItems();
44items.forEach((item) => {
45 console.dir(item);
46});
47
48