Skip to main content

Generate and enrich local business leads with Decodo, OpenAI and Gmail

Workflow preview

Workflow preview
100%
Generate and enrich local business leads with Decodo, OpenAI and Gmail preview
Open on n8n.io

1. Workflow Overview

End to End Local Business Lead Generation, Enrichment and Outreach Pipeline with Decodo This workflow finds local business leads on Google Maps, enriches them with website and AI analysis, and send...

Best for

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

Tools used

n8n-nodes-base.stickynote, n8n-nodes-base.scheduletrigger, n8n-nodes-base.set, @decodo/n8n-nodes-decodo.decodo, n8n-nodes-base.code, n8n-nodes-base.if, n8n-nodes-base.googlesheets, 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 Fahmi Fahreza.

Original n8n.io source

1.1 Workflow description

Title
Generate and enrich local business leads with Decodo, OpenAI and Gmail
Workflow name
Generate and enrich local business leads with Decodo, OpenAI and Gmail

End-to-End Local Business Lead Generation, Enrichment and Outreach Pipeline with Decodo

This workflow finds local business leads on Google Maps, enriches them with website and AI analysis, and sends personalized cold emails to qualified prospects automatically.

Who’s it for?

This template is for agencies, freelancers, B2B growth teams, and sales operators who want a repeatable outbound lead generation system for local business prospecting.

How it works

  1. The workflow starts on a schedule and loads the search, scoring, and sender settings from one configuration node.
  2. Decodo scrapes Google Maps search results for businesses that match your niche and city.
  3. The workflow extracts lead details such as business name, address, phone number, website, and rating, then stores each lead in Google Sheets.
  4. Each discovered lead is checked for a website. If no website is available, the lead is marked and skipped from enrichment.
  5. For leads with a website, Decodo scrapes the site and OpenAI scores the business, summarizes it, and suggests enrichment fields such as business type, pain points, and contact email.
  6. The workflow updates the lead in Google Sheets with the enrichment data.
  7. Enriched leads are filtered by score threshold, website presence, email availability, and contact status.
  8. For each qualified lead, the workflow scrapes more website content and uses OpenAI to write a personalized outreach email.
  9. Gmail sends the email, and the lead is marked as contacted in Google Sheets.

How to set up

Add credentials for Decodo, OpenAI, Google Sheets, and Gmail. Replace the placeholder Google Sheet ID in the configuration node. Create a Leads sheet with all required columns used in the workflow. Update the niche, city, geo, max leads, score threshold, and sender fields. This template uses the Decodo community node, so it is intended for self-hosted n8n only. Replace the placeholder image above with a real workflow screenshot before submission.

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 - đź“‹ WF1 Setup Guide

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

Block 2 - 📍 Stage 1: Discovery

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

Block 3 - Schedule: Daily 10AM

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

Block 4 - Search Config

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

Block 5 - Decodo: Scrape Google Maps

Type / Role
@decodo/n8n-nodes-decodo.decodo - decodo
Config choices
Version 1

Block 6 - Parse Leads from Markdown

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 7 - Is Valid Lead?

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

Block 8 - Save Lead to Google Sheets

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

Block 9 - Split In Batches

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

Block 10 - Has Website?

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

Block 11 - Mark: No Website

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

Block 12 - Decodo: Scrape Business Website

Type / Role
@decodo/n8n-nodes-decodo.decodo - decodo
Config choices
Version 1

Block 13 - Update Lead (No Website)

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

Block 14 - Merge Website Content

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

Block 15 - AI: Score & Enrich Lead

Type / Role
n8n-nodes-base.openAi - openAi
Config choices
Version 1.1

Block 16 - Parse AI Response

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 17 - Update Lead (Enriched)

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

Block 18 - Get Enriched Leads

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

Block 19 - Filter by Score Threshold

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 20 - Qualified Leads Exist?

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

Block 21 - Split In Batches1

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

Block 22 - Decodo: Deep Scrape Website

Type / Role
@decodo/n8n-nodes-decodo.decodo - decodo
Config choices
Version 1

Block 23 - Merge Lead + Content

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

Block 24 - AI: Write Cold Email

Type / Role
n8n-nodes-base.openAi - openAi
Config choices
Version 1.1

Showing the first 24 of 31 workflow blocks. Download the JSON for the full node graph.

3. Summary Table

Workflow Generate and enrich local business leads with Decodo, OpenAI and Gmail
Complexity advanced
Nodes 31
Categories Lead Generation, AI Summarization
Author Fahmi Fahreza
Published 16 Mar 2026

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/14084/14084.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 Generate and enrich local business leads with Decodo, OpenAI and Gmail do?

End to End Local Business Lead Generation, Enrichment and Outreach Pipeline with Decodo This workflow finds local business leads on Google Maps, enriches them with website and AI analysis, and send...

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.