1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "currentItems": [
10 {
11 "id": "h1",
12 "company": "Acme",
13 "eventType": "hiring",
14 "role": "Engineer",
15 "openings": 45,
16 "netHiringSignal": 45,
17 },
18 {
19 "id": "h2",
20 "company": "Acme",
21 "eventType": "hiring",
22 "role": "Sales",
23 "openings": 20,
24 "netHiringSignal": 20,
25 },
26 ],
27 "previousItems": [{
28 "id": "l1",
29 "company": "Acme",
30 "eventType": "layoff",
31 "affectedWorkers": 300,
32 "netHiringSignal": -300,
33 }],
34}
35
36
37run = client.actor("quanmatrix/layoff-hiring-reversal-intelligence").call(run_input=run_input)
38
39
40print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
41for item in client.dataset(run.default_dataset_id).iterate_items():
42 print(item)
43
44