Skip to main content

Automated B2B lead generation: Google Places, Scrape.do & AI enrichment

Workflow preview

Workflow preview
100%
Automated B2B lead generation: Google Places, Scrape.do & AI enrichment preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Automated B2B Lead Generation: Google Places, Scrape.do & AI Enrichment This workflow is a powerful, fully automated B2B lead generation engine. It starts by finding businesses on Google Maps based...

Best for

  • Lead Generation automation workflows
  • AI Summarization automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.function, @n8n/n8n-nodes-langchain.lmchatopenai, @n8n/n8n-nodes-langchain.outputparserstructured, n8n-nodes-base.manualtrigger, n8n-nodes-base.set, n8n-nodes-base.httprequest, n8n-nodes-base.if, n8n-nodes-base.splitinbatches

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Onur.

Original n8n.io source

1.1 Workflow description

Title
Automated B2B lead generation: Google Places, Scrape.do & AI enrichment
Workflow name
Automated B2B lead generation: Google Places, Scrape.do & AI enrichment

Automated B2B Lead Generation: Google Places, Scrape.do & AI Enrichment

This workflow is a powerful, fully automated B2B lead generation engine. It starts by finding businesses on Google Maps based on your criteria (e.g., "dentists" in "Istanbul"), assigns a quality score to each, and then uses Scrape.do to reliably access their websites. Finally, it leverages an AI agent to extract valuable contact information like emails and social media profiles. The final, enriched data is then neatly organized and saved directly into a Google Sheet.

This template is built for reliability, using Scrape.do to handle the complexities of web scraping, ensuring you can consistently gather data without getting blocked.


🚀 What does this workflow do?

  • Automatically finds businesses using the Google Places API based on a category and location you define.
  • Calculates a leadScore for each business based on its rating, website presence, and operational status to prioritize high-quality leads.
  • Filters out low-quality leads to ensure you only focus on the most promising prospects.
  • Reliably scrapes the website of each high-quality lead using Scrape.do to bypass common blocking issues and retrieve the raw HTML.
  • Uses an AI Agent (OpenAI) to intelligently parse the website's HTML and extract hard-to-find contact details (emails, social media links, phone numbers).
  • Saves all enriched lead data to a Google Sheet, creating a clean, actionable list for your sales or marketing team.
  • Runs on a schedule, continuously finding new leads without any manual effort.

🎯 Who is this for?

  • Sales & Business Development Teams: Automate prospecting and build targeted lead lists.
  • Marketing Agencies: Generate leads for clients in specific industries and locations.
  • Freelancers & Consultants: Quickly find potential clients for your services.
  • Startups & Small Businesses: Build a customer database without spending hours on manual research.

✨ Benefits

  • Full Automation: Set it up once and let it run on a schedule to continuously fill your pipeline.
  • AI-Powered Enrichment: Go beyond basic business info. Get actual emails and social profiles that aren't available on Google Maps.
  • Reliable Website Access: Leverages Scrape.do to handle proxies and prevent IP blocks, ensuring consistent data gathering from target websites.
  • High-Quality Leads: The built-in scoring and filtering system ensures you don't waste time on irrelevant or incomplete listings.
  • Centralized Database: All your leads are automatically organized in a single, easy-to-access Google Sheet.

⚙️ How it Works

  1. Schedule Trigger: The workflow starts automatically at your chosen interval (e.g., daily).
  2. Set Parameters: You define the business type (searchCategory) and location (locationName) in a central Set node.
  3. Find Businesses: It calls the Google Places API to get a list of businesses matching your criteria.
  4. Score & Filter: A custom Function node scores each lead. An IF node then separates high-quality leads from low-quality ones.
  5. Loop & Enrich: The workflow processes each high-quality lead one by one.
    • It uses a scraping service (Scrape.do) to reliably fetch the lead's website content.
    • An AI Agent (OpenAI) analyzes the website's footer to find contact and social media links.
  6. Save Data: The final, enriched lead information is appended as a new row in your Google Sheet.

📋 n8n Nodes Used

  • Schedule Trigger
  • Set
  • HTTP Request (for Google Places & Scrape.do)
  • Function
  • If
  • Split in Batches (Loop Over Items)
  • HTML
  • Langchain Agent (with OpenAI Chat Model & Structured Output Parser)
  • Google Sheets

🔑 Prerequisites

  • An active n8n instance.
  • Google Cloud Project with the Places API enabled.
  • Google Places API Key, stored in n8n's Header Auth credentials.
  • A Scrape.do Account and API Token. This is essential for reliably scraping websites without your n8n server's IP getting blocked.
  • OpenAI Account & API Key for the AI-powered data extraction.
  • Google Account with access to Google Sheets.
  • Google Sheets API Credentials (OAuth2) configured in n8n.
  • A Google Sheet prepared with columns to store the lead data (e.g., BusinessName, Address, Phone, Website, Email, Facebook, etc.).

🛠️ Setup

  1. Import the workflow into your n8n instance.
  2. Configure Credentials: Create and/or select your credentials for:
    • Google Places API: In the 2. Find Businesses (Google Places) node, select your Header Auth credential containing your API key.
    • Scrape.do: In the 6a. Scrape Website HTML node, configure credentials for your Scrape.do account.
    • OpenAI: In the OpenAI Chat Model node, select your OpenAI credentials.
    • Google Sheets: In the 7. Save to Google Sheets node, select your Google Sheets OAuth2 credentials.
  3. Define Your Search: In the 1. Set Search Parameters node, update the searchCategory and locationName values to match your target market.
  4. Link Your Google Sheet: In the 7. Save to Google Sheets node, select your Spreadsheet and Sheet Name from the dropdown lists. Map the incoming data to the correct columns in your sheet.
  5. Set Your Schedule: Adjust the Schedule Trigger to run as often as you like (e.g., once a day).
  6. Activate the workflow! Your automated lead generation will begin on the next scheduled run.

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Generate Report

Type / Role
n8n-nodes-base.function - function
Config choices
Version 1

Block 2 - Error Logging

Type / Role
n8n-nodes-base.function - function
Config choices
Version 1

Block 3 - OpenAI Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 4 - Structured Output Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 5 - When clicking ‘Execute workflow’

Type / Role
n8n-nodes-base.manualTrigger - manualTrigger
Config choices
Version 1

Block 6 - 1. Set Search Parameters

Type / Role
n8n-nodes-base.set - set
Config choices
Version 1

Block 7 - 2. Find Businesses (Google Places)

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 3

Block 8 - 3. Parse & Score Leads

Type / Role
n8n-nodes-base.function - function
Config choices
Version 1

Block 9 - 4. Filter High-Quality Leads

Type / Role
n8n-nodes-base.if - if
Config choices
Version 1

Block 10 - 5. Loop Through Each Lead

Type / Role
n8n-nodes-base.splitInBatches - splitInBatches
Config choices
Version 3

Block 11 - 6a. Scrape Website with Scrape.do

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.2

Block 12 - 6b. Check if Scrape Was Successful

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 13 - 6c. Extract Footer from HTML

Type / Role
n8n-nodes-base.html - html
Config choices
Version 1.2

Block 14 - 6d. Extract Contact Info with AI

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.2

Block 15 - 7. Save Enriched Lead to Google Sheets

Type / Role
n8n-nodes-base.googleSheets - googleSheets
Config choices
Version 3

Block 16 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 17 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 18 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 19 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Automated B2B lead generation: Google Places, Scrape.do & AI enrichment
Complexity advanced
Nodes 19
Categories Lead Generation, AI Summarization
Author Onur
Published 10 Sept 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/8448/8448.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Automated B2B lead generation: Google Places, Scrape.do & AI enrichment do?

Automated B2B Lead Generation: Google Places, Scrape.do & AI Enrichment This workflow is a powerful, fully automated B2B lead generation engine. It starts by finding businesses on Google Maps based...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Lead Generation, AI Summarization use case.