Automation library · Lead generation

Extract Google Maps business leads with Apify and OpenAI

Started by an event in a connected app, and works across Google Sheets, Slack and Telegram. It hands the judgement calls to OpenAI. 26 steps, 2 branches, 5 loops or waits: large, and worth reading before you trust it with anything live.

LargeCalls a model: OpenAI

26 stepsLarge: read it before trusting it with anything live
2Branches: places the flow splits
5Loops or waits
3Services it connects to

The flow

Starts it 1Model 2Logic 12Service 11

The steps in the order they run, from what starts it.

  1. 1Start by clickingManual triggerStarts it
  2. 2Get list of actorsApifyService
  3. 3Split OutSplit OutLogic
  4. 4Loop Over Items (actor)Split In BatchesLogic
  5. 5If (Check specific actor)IfLogic
  6. 6Get list of tasksApifyService
  7. 7Split Out1Split OutLogic
  8. 8Loop Over Items (task)Split In BatchesLogic
  9. 9If (Check specific task)IfLogic
  10. 10HTTP (Run Scraper Task)Http RequestService
  11. 11Wait 20s for run successfully and get dataWaitLogic
  12. 12HTTP (Get Specific Task Result)Http RequestService
  13. 13Remove DuplicatesRemove DuplicatesLogic
  14. 14Loop Over Items (lead)Split In BatchesLogic
  15. 15Code (Count Toral Incoming Data)CodeLogic
  16. 16AI Company Description GeneratorOpen AiModel
  17. 17Notification messageTelegramService
  18. 18RapiwaRapiwaService
  19. 19Create messageMicrosoft TeamsService
  20. 20Send a messageSlackService
  21. 21Sheet (Store google maps/lead data)Google SheetsService
  22. 22Get Website URLsSetLogic
  23. 23Https (Get Raw HTML Content from Business Website)Http RequestService
  24. 24Extract Business Email from Website HTML (GPT-4)Open AiModel
  25. 25Sheet (Update Email form website)Google SheetsService
  26. 26Wait 5sWaitLogic

How it's built

Starts on
An event in a connected app
Steps
26, with 2 branches, 5 loops or waits
Size
Large: read it before trusting it with anything live
Connects to
Google Sheets, Slack, Telegram
Model
OpenAI

Questions

What does it need to run?

An n8n account, plus your own Google Sheets, Slack and Telegram accounts, and a key for OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on an event in a connected app.

Does it use AI?

Yes. It calls OpenAI. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 26 steps it is large: read it before trusting it with anything live.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

Before you run it

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 26 steps before you point it at anything that matters.