1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "query": "software engineer",
12 "location": "",
13 "startUrls": [],
14 "minSalary": 0,
15 "language": "",
16 "fromDate": "",
17 "toDate": "",
18 "maxResults": 25,
19 "maxPages": 5,
20 "outputFields": [],
21 "datasetName": "",
22 "stateKey": "",
23 "dedupStoreName": "",
24 "dedupKey": "jobId",
25 "proxyConfiguration": {
26 "useApifyProxy": true,
27 "apifyProxyGroups": [
28 "RESIDENTIAL"
29 ],
30 "apifyProxyCountry": "IE"
31 }
32};
33
34
35const run = await client.actor("parsebird/irishjobs-scraper").call(input);
36
37
38console.log('Results from dataset');
39console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
40const { items } = await client.dataset(run.defaultDatasetId).listItems();
41items.forEach((item) => {
42 console.dir(item);
43});
44
45