1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "mode": "projectSearch",
12 "searchQuery": "python",
13 "category": "",
14 "remoteType": "",
15 "contractType": "",
16 "sortBy": "newest",
17 "technologySlug": "",
18 "city": "",
19 "industry": "",
20 "country": "",
21 "endClientOnly": false,
22 "includeDachRegion": false,
23 "language": "",
24 "requireDisplayedName": false,
25 "hasAttachmentsOnly": false,
26 "openToPermanentJobs": false,
27 "openToAgencyContract": false,
28 "excludeUnavailable": false,
29 "recentlyActiveOnly": false,
30 "projectSlugsOrUrls": [],
31 "profileSlugsOrUrls": [],
32 "availableOnly": false,
33 "maxItems": 20
34};
35
36
37const run = await client.actor("crawlerbros/freelancermap-scraper").call(input);
38
39
40console.log('Results from dataset');
41console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
42const { items } = await client.dataset(run.defaultDatasetId).listItems();
43items.forEach((item) => {
44 console.dir(item);
45});
46
47