1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "documents": ["""[package]
10name = \"my-app\"
11version = \"1.0.0\"
12edition = \"2021\"
13
14[dependencies]
15serde = { version = \"1.0\", features = [\"derive\"] }
16tokio = { version = \"1\", features = [\"full\"] }
17
18[profile.release]
19opt-level = 3"""],
20 "urls": [],
21 "operation": "validate",
22 "inputFormat": "auto",
23 "outputFormat": "json",
24 "jsonIndent": 2,
25 "stopOnError": False,
26 "includeOriginal": False,
27}
28
29
30run = client.actor("automation-lab/toml-validator").call(run_input=run_input)
31
32
33print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
34for item in client.dataset(run["defaultDatasetId"]).iterate_items():
35 print(item)
36
37