1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "locations": [
10 {
11 "locationId": "S001",
12 "name": "Acme Coffee Downtown",
13 "city": "Springfield",
14 "websiteUrl": "https://www.acmecoffee.example/locations/downtown",
15 },
16 {
17 "locationId": "S002",
18 "name": "Acme Coffee Riverside",
19 "city": "Springfield",
20 "websiteUrl": "acmecoffee.example/locations/riverside?utm_source=maps",
21 },
22 {
23 "locationId": "S003",
24 "name": "Acme Coffee Airport",
25 "city": "Shelbyville",
26 "websiteUrl": "http://acme-coffee-airport.example",
27 },
28 {
29 "locationId": "S004",
30 "name": "Acme Coffee Mall",
31 "city": "Shelbyville",
32 "websiteUrl": "",
33 },
34 {
35 "locationId": "S005",
36 "name": "Acme Coffee Harbor",
37 "city": "Capital City",
38 "websiteUrl": "https://acmecoffee.example/locations/downtown/",
39 },
40 {
41 "locationId": "S006",
42 "name": "Acme Coffee Station",
43 "city": "Capital City",
44 "websiteUrl": "https//acmecoffee.example/station",
45 },
46 ],
47 "brandDomains": ["acmecoffee.example"],
48}
49
50
51run = client.actor("practical_ai_lab_jp/pal-maps-location-website-health-audit").call(run_input=run_input)
52
53
54print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
55for item in client.dataset(run.default_dataset_id).iterate_items():
56 print(item)
57
58