1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "searchUrls": ["https://www.homegate.ch/mieten/immobilien/ort-zuerich/trefferliste"],
10 "city": "Zürich",
11 "canton": "",
12 "priceMin": 0,
13 "priceMax": 0,
14 "roomsMin": 0,
15 "roomsMax": 0,
16 "maxResults": 20,
17 "maxPagesPerTask": 20,
18 "proxyConfiguration": {
19 "useApifyProxy": True,
20 "apifyProxyGroups": ["UNBLOCKER"],
21 },
22}
23
24
25run = client.actor("parsebird/homegate-ch-scraper").call(run_input=run_input)
26
27
28print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
29for item in client.dataset(run.default_dataset_id).iterate_items():
30 print(item)
31
32