1from apify_client import ApifyClient
2
3
4
5client = ApifyClient("<YOUR_API_TOKEN>")
6
7
8run_input = {
9 "cities": [
10 "albuquerque-nm",
11 "anaheim-ca",
12 "anchorage-ak",
13 "arlington-tx",
14 "atlanta-ga",
15 "aurora-co",
16 "austin-tx",
17 "bakersfield-ca",
18 "baltimore-md",
19 "baton-rouge-la",
20 "boise-id",
21 "boston-ma",
22 "buffalo-ny",
23 "chandler-az",
24 "charlotte-nc",
25 "chesapeake-va",
26 "chicago-il",
27 "chula-vista-ca",
28 "cincinnati-oh",
29 "cleveland-oh",
30 "colorado-springs-co",
31 "columbus-oh",
32 "corpus-christi-tx",
33 "dallas-tx",
34 "denver-co",
35 "detroit-mi",
36 "durham-nc",
37 "el-paso-tx",
38 "fort-wayne-in",
39 "fort-worth-tx",
40 "fremont-ca",
41 "fresno-ca",
42 "garland-tx",
43 "gilbert-az",
44 "glendale-az",
45 "greensboro-nc",
46 "henderson-nv",
47 "hialeah-fl",
48 "honolulu-hi",
49 "houston-tx",
50 "indianapolis-in",
51 "irvine-ca",
52 "irving-tx",
53 "jacksonville-fl",
54 "jersey-city-nj",
55 "kansas-city-mo",
56 "laredo-tx",
57 "las-vegas-nv",
58 "lexington-ky",
59 "lincoln-ne",
60 "long-beach-ca",
61 "los-angeles-ca",
62 "louisville-ky",
63 "lubbock-tx",
64 "madison-wi",
65 "memphis-tn",
66 "mesa-az",
67 "miami-fl",
68 "milwaukee-wi",
69 "minneapolis-mn",
70 "nashville-tn",
71 "new-orleans-la",
72 "new-york-ny",
73 "newark-nj",
74 "norfolk-va",
75 "north-las-vegas-nv",
76 "oakland-ca",
77 "oklahoma-city-ok",
78 "omaha-ne",
79 "orlando-fl",
80 "philadelphia-pa",
81 "phoenix-az",
82 "pittsburgh-pa",
83 "plano-tx",
84 "portland-or",
85 "raleigh-nc",
86 "reno-nv",
87 "richmond-va",
88 "riverside-ca",
89 "sacramento-ca",
90 "san-antonio-tx",
91 "san-diego-ca",
92 "san-francisco-ca",
93 "san-jose-ca",
94 "santa-ana-ca",
95 "scottsdale-az",
96 "seattle-wa",
97 "spokane-wa",
98 "st-louis-mo",
99 "st-paul-mn",
100 "st-petersburg-fl",
101 "stockton-ca",
102 "tampa-fl",
103 "toledo-oh",
104 "tucson-az",
105 "tulsa-ok",
106 "virginia-beach-va",
107 "washington-dc",
108 "wichita-ks",
109 "winston-salem-nc",
110 ],
111 "proxyConfiguration": {
112 "useApifyProxy": True,
113 "apifyProxyGroups": ["RESIDENTIAL"],
114 },
115}
116
117
118run = client.actor("moving_beacon-owner1/apartments-com-scraper").call(run_input=run_input)
119
120
121print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
122for item in client.dataset(run["defaultDatasetId"]).iterate_items():
123 print(item)
124
125