u/Big-Ask-7879

Unlimited lead finding n8n engine
▲ 1 r/nocode

Unlimited lead finding n8n engine

I built a 20-node Google Maps data extraction workflow in n8n and wanted to share the full logic behind it.

The Goal: Automatically find leads in a specific area, and pipe them into a database for outreach. 

1 → Edit Fields (Control Center)

This is where all variables are set:

→ Google Maps API key

→ search query

→ location

→ radius

→ max businesses to collect

I built it this way so the workflow becomes reusable without touching multiple nodes every time.

2 → Get Coordinates

Google’s API works best using exact latitude and longitude coordinates.

This node converts the text-based location into precise coordinates before the search begins.

3 → Get Places (Main Operator)

This is the core engine.

It searches businesses using:

→ query

→ location

→ radius

Google only returns the first 20 businesses here.

But the important thing is:

it also returns a NextPageToken.

That token is what allows the workflow to continue pulling more businesses automatically.

4 → Split Out

Google returns all businesses in a single JSON array.

This node splits every business into its own individual item so it can be processed separately.

5 → Append Row in Sheet

Every business found gets immediately saved into Google Sheets.

I wanted the data stored instantly instead of waiting until the workflow fully finishes.

6 → Aggregate

After splitting the data, I recombine the business objects again.

This helps reduce unnecessary operations and keeps the flow more token-efficient.

7 → Insert Row

This node stores the NextPageToken.

Without storing it somewhere, the workflow would forget where the next batch starts.

8 → If (Token Check)

This is the logic gate.

It checks:

→ Does another page token exist?

If yes:

→ continue looping

If no:

→ workflow stops

9 → Wait

Google doesn’t activate the next page token immediately.

If you try using it instantly, the API fails.

So I added a 5-second delay before requesting the next batch.

10 → Get Row(s)

Fetches the stored token back into the workflow.

11 → Get Places 1

Uses the stored NextPageToken to fetch the next set of businesses from Google Maps.

12 → Split Out 1

Splits the second batch into separate business rows again.

13 → Append Row in Sheet 1

Adds the new businesses into the same spreadsheet.

14 → Aggregate 1

Recombines the new business batch to keep processing efficient.

15 → Update Row(s)

Updates the old page token with the newest one returned by Google.

This allows the workflow to continue looping through:

→ page 3

→ page 4

→ page 5

→ etc

16 → If 1 (New Token Check)

Checks whether Google returned another token.

If yes:

→ continue looping

If no:

→ stop

17 → Get Row(s) in Sheet

At this point the workflow checks how many total businesses have already been collected.

18 → Aggregate 2

Aggregates all collected lead data for counting.

19 → Edit Fields 1 (Counter)

Counts the total number of businesses successfully collected from Google Maps.

20 → If 2 (Kill Switch)

This is the final control logic.

It compares:

→ total businesses collected

vs

→ max limit set in Node 1

If the limit hasn’t been reached:

→ workflow loops again

If the target is reached:

→ workflow shuts down automatically

That's it.

u/Big-Ask-7879 — 3 days ago

Unlimited lead finding n8n engine

If you are running an agency or a B2B business, you know that lead flow is the biggest bottleneck.

I decided to build my own engine in n8n that pulls directly from the source: Google Maps.

This workflow allows you to get unlimited, fresh leads for your business in just one click, forever.

I wanted to share exactly how the logic works so you can build it yourself.

The Goal: Automatically find leads in a specific area, and pipe them into a database for outreach.

Here is the exact work each node does in this 20-node setup:

1 → Edit Fields (Control Center)

This is where all variables are set:

→ Google Maps API key

→ search query

→ location

→ radius

→ max businesses to collect

I built it this way so the workflow becomes reusable without touching multiple nodes every time.

2 → Get Coordinates

Google’s API works best using exact latitude and longitude coordinates.

This node converts the text-based location into precise coordinates before the search begins.

3 → Get Places (Main Operator)

This is the core engine.

It searches businesses using:

→ query

→ location

→ radius

Google only returns the first 20 businesses here.

But the important thing is:

it also returns a NextPageToken.

That token is what allows the workflow to continue pulling more businesses automatically.

4 → Split Out

Google returns all businesses in a single JSON array.

This node splits every business into its own individual item so it can be processed separately.

5 → Append Row in Sheet

Every business found gets immediately saved into Google Sheets.

I wanted the data stored instantly instead of waiting until the workflow fully finishes.

6 → Aggregate

After splitting the data, I recombine the business objects again.

This helps reduce unnecessary operations and keeps the flow more token-efficient.

7 → Insert Row

This node stores the NextPageToken.

Without storing it somewhere, the workflow would forget where the next batch starts.

8 → If (Token Check)

This is the logic gate.

It checks:

→ Does another page token exist?

If yes:

→ continue looping

If no:

→ workflow stops

9 → Wait

Google doesn’t activate the next page token immediately.

If you try using it instantly, the API fails.

So I added a 5-second delay before requesting the next batch.

10 → Get Row(s)

Fetches the stored token back into the workflow.

11 → Get Places 1

Uses the stored NextPageToken to fetch the next set of businesses from Google Maps.

12 → Split Out 1

Splits the second batch into separate business rows again.

13 → Append Row in Sheet 1

Adds the new businesses into the same spreadsheet.

14 → Aggregate 1

Recombines the new business batch to keep processing efficient.

15 → Update Row(s)

Updates the old page token with the newest one returned by Google.

This allows the workflow to continue looping through:

→ page 3

→ page 4

→ page 5

→ etc

16 → If 1 (New Token Check)

Checks whether Google returned another token.

If yes:

→ continue looping

If no:

→ stop

17 → Get Row(s) in Sheet

At this point the workflow checks how many total businesses have already been collected.

18 → Aggregate 2

Aggregates all collected lead data for counting.

19 → Edit Fields 1 (Counter)

Counts the total number of businesses successfully collected from Google Maps.

20 → If 2 (Kill Switch)

This is the final control logic.

It compares:

→ total businesses collected

vs

→ max limit set in Node 1

If the limit hasn’t been reached:

→ workflow loops again

If the target is reached:

→ workflow shuts down automatically

That's it.

reddit.com
u/Big-Ask-7879 — 3 days ago