Why Scroll Google Maps When You Can Script It?
How I Used the Google Places API to Build Smarter Lead Lists
I recently built a small tool to help generate lead lists at scale using the Google Places API. The goal was simple: automate the manual Google Maps searches that many franchise owners do one-by-one to find apartments, hotels, schools, property managers, and more in their service territories.
The Problem
Another franchise owner shared that they built a lead list by:
- Manually searching Google Maps with queries like "Apartments + [City]"
- Using a paid browser scraper to pull results
- Manually deduplicating and cleaning the data
It worked—but it was time-consuming and tedious. You can't scroll or reposition the map programmatically. Every new area requires a new search. The data's there—it's just not easily accessible at scale.
The Solution: Automating with Google Places API
I've been experimenting with a Raspberry Pi 5 and looking for small automation projects. After getting a basic scraper working, I wondered: could I replicate the Google Maps business search process more cleanly using the official API?
Answer: yes. The Google Places API lets you run structured business searches by keyword and location, and it returns standardized data like name, address, phone, website, and rating.
How It Works
I wrote a Python script that:
- Loops through a list of cities in my territory
- Runs one or more keyword searches (e.g., "Apartments," "Property Managers," etc.)
- Makes API calls to Google Places
- Collects name, address, phone number, website, and rating
- Deduplicates results across cities and categories
- Outputs everything to a clean CSV file
Stack:
- Script Hosting: Render.com (as a cron job or manual run)
- Version Control: GitHub
- API Management: Google Cloud Console
- Debugging & Build Support: ChatGPT
Cost
- Each full run (1 keyword across 20+ cities) costs ~$20 for ~1,000 API calls
- Some terms (like "Retirement Homes") are cheaper
- Google gives $300 in free API credits
- Staying under 5,000 requests/month may qualify for the free tier
Sample Results from My Territory
| Category | Count |
|---|---|
| Apartments | 500 |
| Property Managers | 470 |
| Hotels | 400 |
| Schools | 488 |
| Retirement Homes | 188 |
There's still cleanup involved. Categories overlap, and not every listing is relevant. But this gets you a structured, deduplicated list in a fraction of the time.
Why It's Useful
If you're running a local service business, this helps you:
- Map your territory more quickly
- Identify lead targets without manual search
- Integrate data into a CRM or outreach workflow
- Refresh the data regularly (monthly runs)
It's a low-cost way to take control of lead gen infrastructure without waiting for corporate or relying on expensive third-party data.
Want to Build Your Own?
I'm happy to share:
- The Python script
- Setup instructions for Google API, GitHub, and Render
You can modify it with your own cities, keywords, or data fields. If you drop the code into ChatGPT, it can walk you through how it works step-by-step.