1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "schemaVersion": "1.1",
10 "rows": [
11 {
12 "signalId": "nike-launch-001",
13 "eventType": "product_launch",
14 "severity": "high",
15 "sourceName": "Brand newsroom",
16 "confidenceBps": 9200,
17 "status": "active",
18 },
19 {
20 "signalId": "nike-price-001",
21 "eventType": "price_change",
22 "severity": "medium",
23 "sourceName": "Retail monitor",
24 "confidenceBps": 7600,
25 "status": "resolved",
26 },
27 {
28 "signalId": "nike-review-001",
29 "eventType": "review",
30 "severity": "low",
31 "sourceName": "Retail monitor",
32 "confidenceBps": 4800,
33 "status": "active",
34 },
35 ],
36}
37
38
39run = client.actor("zinin/us-brand-signal-metrics-aggregator").call(run_input=run_input)
40
41
42print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
43for item in client.dataset(run.default_dataset_id).iterate_items():
44 print(item)
45
46