1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "listings": [
10 {
11 "title": "2 pokoje, Kazimierz",
12 "price": 1050000,
13 "area": 52,
14 "rooms": 2,
15 "floor": 2,
16 "market": "SECONDARY",
17 "latitude": 50.051,
18 "longitude": 19.9447,
19 "city": "Kraków",
20 "district": "Kazimierz",
21 "street": "Józefa",
22 "url": "https://example.com/listing-1",
23 },
24 {
25 "title": "3 pokoje, Mokotów",
26 "price": 1150000,
27 "area": 65,
28 "rooms": 3,
29 "floor": 4,
30 "market": "SECONDARY",
31 "latitude": 52.1935,
32 "longitude": 21.0235,
33 "city": "Warszawa",
34 "district": "Mokotów",
35 "street": "Puławska",
36 "url": "https://example.com/listing-2",
37 },
38 {
39 "title": "2 pokoje, Wrzeszcz",
40 "price": 720000,
41 "area": 48,
42 "rooms": 2,
43 "floor": 1,
44 "market": "SECONDARY",
45 "latitude": 54.38,
46 "longitude": 18.604,
47 "city": "Gdańsk",
48 "district": "Wrzeszcz",
49 "url": "https://example.com/listing-3",
50 },
51 ],
52 "fieldMapping": {},
53}
54
55
56run = client.actor("kris_fili/otodom-listing-deal-checker").call(run_input=run_input)
57
58
59print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
60for item in client.dataset(run.default_dataset_id).iterate_items():
61 print(item)
62
63