1import { ApifyClient } from 'apify-client';
2
3
4
5const client = new ApifyClient({
6 token: '<YOUR_API_TOKEN>',
7});
8
9
10const input = {
11 "testMode": true,
12 "companies": [
13 {
14 "company_name": "Infosys",
15 "domain": "infosys.com",
16 "ticker_symbol": "INFY",
17 "sector": "Information Technology"
18 },
19 {
20 "company_name": "Tata Consultancy Services",
21 "domain": "tcs.com",
22 "ticker_symbol": "TCS",
23 "sector": "Information Technology"
24 },
25 {
26 "company_name": "Zoho",
27 "domain": "zoho.com",
28 "sector": "Software"
29 }
30 ],
31 "maxCompanies": 25,
32 "validateUrls": false,
33 "requestTimeoutSecs": 20
34};
35
36
37const run = await client.actor("shashghosh/account-source-resolver").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