1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = { "payload": {
9 "expectedLocales": [
10 "en-US",
11 "nl-NL",
12 ],
13 "videoDurationMs": 5500,
14 "maxCharactersPerSecond": 20,
15 "tracks": [
16 {
17 "locale": "en-US",
18 "name": "en-US.srt",
19 "content": """1
2000:00:01,000 --> 00:00:03,000
21Hello world.
22
232
2400:00:03,200 --> 00:00:05,000
25Welcome.
26""",
27 },
28 {
29 "locale": "nl-NL",
30 "name": "nl-NL.vtt",
31 "content": """WEBVTT
32
33opening
3400:01.000 --> 00:03.000 align:start
35Hallo wereld.
36
3700:03.200 --> 00:05.000
38Welkom.
39""",
40 },
41 ],
42 } }
43
44
45run = client.actor("manzaritech/multilingual-subtitle-checker").call(run_input=run_input)
46
47
48print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
49for item in client.dataset(run.default_dataset_id).iterate_items():
50 print(item)
51
52