1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "ads": [
10 {
11 "id": "meta-1",
12 "headline": "Free delivery for teams",
13 "text": "Compare annual plans and see included services.",
14 "cta": "Compare plans",
15 },
16 {
17 "id": "meta-2",
18 "headline": " FREE delivery for teams ",
19 "text": "Compare annual plans with included support.",
20 "cta": "Compare plans",
21 },
22 {
23 "id": "search-1",
24 "headline": "Try the workflow demo today",
25 "text": "See the demo before you choose a plan.",
26 "cta": "Book a demo",
27 },
28 {
29 "id": "search-2",
30 "headline": "Try the workflow demo today",
31 "text": "See the demo before you choose a plan.",
32 },
33 ],
34 "limits": { "headlineCharacters": 24 },
35 "maxPhrases": 20,
36 "minPhraseAds": 2,
37 "phraseLength": 2,
38 "maxItems": 1,
39}
40
41
42run = client.actor("danielmichalek/ad-headline-cta-intelligence").call(run_input=run_input)
43
44
45print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
46for item in client.dataset(run.default_dataset_id).iterate_items():
47 print(item)
48
49