Scrape & Enrich Google Maps Leads with Decodo API and Gemini 2.5 Flash
This workflow scrapes Google Maps via Decodo API, analyzes each business using Google Gemini 2.5 Flash, scores lead quality, and generates ready to send outreach emails.
Why Use This Workflow?
Time Savings:** Reduces manual lead research from 20 minutes per lead to 30 seconds processing 100 leads in under an hour Cost Reduction:** Eliminates $300-500/month spent on lead databases and enrichment tools like Apollo or ZoomInfo
Scalability:** Process 500+ leads daily without additional staff or subscription costs
Ideal For
Sales Teams & BDRs:** Building targeted prospect lists for local businesses (restaurants, retail, service providers) with verified contact data and personalized outreach hooks Digital Marketing Agencies:** Identifying high-value clients in specific niches (e.g., "restaurants without websites in Chicago") and automating first-touch campaigns B2B SaaS Companies:** Finding businesses matching ideal customer profiles based on ratings, reviews, and digital maturity indicators Local Service Providers:** Generating qualified leads for web design, SEO, POS systems, or booking software tailored to underserved markets
How It Works
Trigger: Manually start the workflow or schedule it to run on specific intervals (e.g., daily/weekly) Data Collection: Scrapes Google Maps search results using Decodo API based on your query (e.g., "coffee shops in Austin"), country, and language settings Processing: Parses raw HTML responses into structured lead objects with business name, address, phone, website, ratings, reviews, and coordinates Intelligence Layer: Google Gemini 2.5 Flash analyzes each lead to generate value propositions, identify pain points, create outreach hooks, and assign a 1-10 quality score Output & Delivery: Filters leads scoring ≥7, generates personalized email templates, and saves all data to Google Sheets with enrichment timestamps Storage & Logging: Maintains complete lead database with outreach status tracking; error handler sends Telegram notifications for failed executions
Setup Guide
Prerequisites
| Requirement | Type | Purpose | |-------------|------|---------| | n8n instance | Essential | Workflow execution platform | | Decodo Scraper API | Essential | Google Maps data extraction (get key at dashboard.decodo.com) | | Google Gemini API | Essential | AI-powered lead analysis and scoring | | Google Sheets | Essential | Lead database and outreach tracking | | Telegram Bot (optional) | Optional | Real-time error notifications |
Installation Steps
Import the JSON file to your n8n instance
Configure credentials: Decodo API: Create HTTP Header Auth credential with header name Authorization and value Basic [YOUR_API_KEY] get from Decodo dashboard Google Gemini API: Add your Google AI API key in the "2.5 Flash" node credentials Google Sheets OAuth2: Authenticate with your Google account (both "Save to Google Sheets" and "Save Outreach To Sheets" nodes) Telegram (optional): Add bot token and replace YOUR-CHAT-ID in "Send Error Notification" node
Update environment-specific values: In "Set Search Parameters" node: Update searchQuery (e.g., "Italian restaurants in Miami"), country, targetLanguage, and resultsLimit In both Google Sheets nodes: Select your destination spreadsheet and sheet name
Customize settings: Adjust lead score threshold in "Filter Hot Leads" (default: ≥7) Modify AI prompt in "Lead Enrichment" node to match your value proposition Customize outreach email template in "Prepare Outreach Message" node
Test execution: Start with resultsLimit: 5 to verify all connections work Check Google Sheets for properly formatted data Verify AI enrichment produces actionable insights
Technical Details
Core Nodes
| Node | Purpose | Key Configuration | |------|---------|-------------------| | Decodo Maps Scraper | Fetches Google Maps listings via API | Set target: google_maps, adjust page_to based on resultsLimit | | Parse & Normalize Data | Extracts business data from HTML | Custom JavaScript handles multiple response formats | | Lead Enrichment (AI Chain) | Analyzes leads with Gemini 2.5 Flash | Structured output parser ensures JSON compliance | | Filter Hot Leads | Isolates high-quality prospects | Combines lead score ≥7 + contact info validation | | Save to Google Sheets | Stores all enriched leads | Uses appendOrUpdate with id as matching column | | Save Outreach To Sheets | Updates hot leads with messages | Marks leads as "HOT" category for prioritization |
Customization Options
Basic Adjustments
Search Parameters:** Modify searchQuery, country, targetLanguage in "Set Search Parameters" to target different markets (supports all Google Maps locales) Lead Scoring Threshold:** Change filter condition from ≥7 to ≥6 for broader lead pool or ≥8 for ultra-qualified prospects Batch Size:** Adjust "Split Into Batches" to process 10-50 items per cycle (lower = more reliable, higher = faster execution)
Advanced Enhancements
Email Automation:** Connect "Prepare Outreach Message" to Gmail/SendGrid nodes for automatic campaign sends (medium complexity) CRM Integration:** Add HubSpot/Salesforce nodes after enrichment to sync leads directly (requires CRM API credentials) Multi-Channel Outreach:** Branch hot leads to LinkedIn automation tools or SMS providers (high complexity, needs additional services) Custom Scoring Models:** Modify AI prompt to prioritize industry-specific signals (e.g., verified badges for healthcare, delivery options for restaurants)
Troubleshooting
Common Issues
| Problem | Cause | Solution | |---------|-------|----------| | "No valid leads extracted" error | Decodo response format changed or empty results | Check Decodo API response in "Parse & Normalize Data" execution logs; verify search query returns results in Google Maps manually | | AI enrichment produces invalid JSON | Gemini output doesn't match schema | Review "Result Parser" schema; add retry logic or simplify AI prompt to reduce complexity | | Google Sheets "matching column not found" | Spreadsheet missing "id" column header | Ensure Sheet1 has headers: id, businessName, category, address, phone, website, rating, reviewCount, valueProposition, painPoints, outreachHook, leadScore, engagementStrategy, googleMapsUrl, scrapedAt, enrichedAt, outreachMessage, status | | Timeout on large batches | Processing 100+ leads exceeds execution limits | Reduce resultsLimit to 25-50; run workflow multiple times with different queries |
Use Case Examples
Scenario 1: Digital Marketing Agency Prospecting
Challenge: Agency needs 200 qualified restaurant leads monthly for web design services, spending 40 hours on manual research
Solution: Configure workflow with query "restaurants in [city]" filtered by ratings ≥4.0 and missing professional websites (AI scoring detects this)
Result: Generated 312 leads in 8 hours across 3 cities; 89 scored ≥8 (hot prospects); closed 14 clients in first month at $2,500 average contract value
Scenario 2: SaaS Company Market Entry
Challenge: Booking software startup targeting salons/spas in new geographic market with zero existing contacts
Solution: Ran workflow with "beauty salons in Denver" + "day spas in Denver"; AI identified pain points like "manual appointment booking" and "no online presence"
Result: 156 leads enriched in 2 days; personalized outreach hooks increased demo booking rate from 2% (cold template) to 11%; secured 8 pilot customers in 3 weeks
Scenario 3: Local Service Provider Lead Generation
Challenge: POS system reseller needs to identify retail stores still using cash registers, wasting days driving to scout locations
Solution: Configured workflow for "retail stores in [neighborhood]" with AI analyzing reviews for mentions of "cash only" or payment friction
Result: Identified 47 high-probability prospects in 90 minutes; field sales team prioritized top 15 leads (score ≥9), closed 6 deals worth $32K total revenue
Credits & Links
Created by: Khaisa Studio
Category: Sales & CRM | Tags: lead-generation, google-maps, ai-enrichment, sales-automation, prospecting
Need custom workflows? Contact us
Connect with the creator:
Portfolio • Workflows • LinkedIn • Medium • Threads
Related Templates
Instagram Full Profile Scraper with Apify and Google Sheets
📸 Instagram Full Profile Scraper with Apify and Google Sheets This n8n workflow automates the process of scraping ful...
Auto-classify Gmail emails with AI and apply labels for inbox organization
Who is this for? Professionals and individuals who receive high volumes of emails, those who want to automatically organ...
Compare Lists and Identify Common Items & Differences Using Custom Keys
This workflow compares two lists of objects (List A and List B) using a user-specified key (e.g. email, id, domain) and ...
🔒 Please log in to import templates to n8n and favorite templates
Workflow Visualization
Loading...
Preparing workflow renderer
Comments (0)
Login to post comments