1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "enableCitySearch": True,
10 "cityTasks": [
11 {
12 "category": "steuerberater",
13 "city": "berlin",
14 "maxResults": 10,
15 },
16 {
17 "category": "zahnarzt",
18 "city": "münchen",
19 "maxResults": 10,
20 },
21 ],
22 "enableKeywordSearch": False,
23 "keywordTasks": [{
24 "keyword": "buchhaltung",
25 "maxResults": 10,
26 }],
27 "enableEnrichment": False,
28 "enableListingDetails": False,
29 "enableLeadDetails": False,
30 "enableReviews": False,
31 "concurrency": 2,
32 "proxyConfiguration": {
33 "useApifyProxy": True,
34 "apifyProxyGroups": ["RESIDENTIAL"],
35 "apifyProxyCountry": "US",
36 },
37}
38
39
40run = client.actor("b2b_leads/gelbe-seiten-real-time-data-scraper").call(run_input=run_input)
41
42
43print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
44for item in client.dataset(run.default_dataset_id).iterate_items():
45 print(item)
46
47