Scrape LinkedIn B2B leads with Apify and GPT-4 and approve emails in Sheets
Ready for 3.0What this workflow does
This AI workflow has 23 nodes and runs when someone submits an n8n form (“LinkedIn Leads Scraping Setup”) (plus 2 other triggers). Along the way it connects Gmail, HubSpot, Google Sheets and OpenAI Chat Model. It also calls api.apify.com over HTTP.
How it runs
Trigger: When someone submits an n8n form (“LinkedIn Leads Scraping Setup”) (plus 2 other triggers).
- make separate json of each keyword (Code): runs custom JavaScript code
- 🔧 Normalize Lead Data (Code): runs custom JavaScript code
- Webhook Data Normalizer (Code): runs custom JavaScript code
- Data Batcher (Loop Over Items (Split in Batches)): loops over the items in batches
- ✂️ Split Email Content (Code): runs custom JavaScript code
- Rejection Data Stringifier (Code): runs custom JavaScript code
- post Apify data scrap (HTTP Request): calls api.apify.com (POST)
- 📤 Send Approved Email (Gmail): uses Gmail
- Rejection Email Rewriter (AI Agent): runs an AI agent, with model: OpenAI Chat Model
- Get Apify recent run data (HTTP Request): calls api.apify.com
…plus 8 more steps. See the full node list below.
Services it uses
HTTP calls to: api.apify.com
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
Nodes used (11)
- HTTP Request
n8n-nodes-base.httpRequest - AI Agent
@n8n/n8n-nodes-langchain.agent - Code
n8n-nodes-base.code - If
n8n-nodes-base.if - Webhook
n8n-nodes-base.webhook - Gmail
n8n-nodes-base.gmail - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches - HubSpot
n8n-nodes-base.hubspot - Google Sheets
n8n-nodes-base.googleSheets - n8n Form Trigger
n8n-nodes-base.formTrigger - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi
From the author
What this workflow does Fully production-ready B2B lead outreach pipeline that: 1. Takes industry keywords from a form trigger (or you can manually add rows to Google Sheets) 2. Scrapes targeted LinkedIn leads using Apify (peakydev~leads-scraper-ppe actor) 3.…