Skip to main content

LinkedIn scraping, structuring, and messaging using PhantomBuster and GPT-4

Workflow preview

Workflow preview
100%
LinkedIn scraping, structuring, and messaging using PhantomBuster and GPT-4 preview
Open on n8n.io

Important notice

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

1. Workflow Overview

Description This template automates the end to end process of extracting professional data from LinkedIn and converting it into a usable format—ideal for recruiters, SDRs, marketers, and growth tea...

Best for

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

Tools used

@n8n/n8n-nodes-langchain.lmchatazureopenai, @n8n/n8n-nodes-langchain.outputparserstructured, n8n-nodes-base.wait, n8n-nodes-base.scheduletrigger, n8n-nodes-base.googlesheets, n8n-nodes-base.httprequest, @n8n/n8n-nodes-langchain.agent, @n8n/n8n-nodes-langchain.chainllm

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
LinkedIn scraping, structuring, and messaging using PhantomBuster and GPT-4
Workflow name
LinkedIn scraping, structuring, and messaging using PhantomBuster and GPT-4

Description

This template automates the end-to-end process of extracting professional data from LinkedIn and converting it into a usable format—ideal for recruiters, SDRs, marketers, and growth teams. With a few simple configurations, you’ll be able to trigger the flow, scrape profiles, and use AI to extract name, headline, company, role, industry, and more—without writing a single line of code.

Key Features

🔗 Launch PhantomBuster Agent using a profile URL ⏳ Wait 45 seconds for PhantomBuster to complete scraping 📥 Fetch and parse scraped data (download URL to JSON) 🤖 Use GPT-4 (OpenAI/Azure) to extract structured information 📄 Output fields: Name, Headline, Company, Job Title, Industry, Experience, etc. 🧰 Optional: Personalize messages using extracted data 📊 Send structured output to Google Sheets, Airtable, or CRM

Setup Instructions

PhantomBuster Configuration

  • Sign up for PhantomBuster
  • Use the LinkedIn Profile Scraper Phantom
  • Obtain your API Key and Agent ID
  • Provide a valid LinkedIn session cookie (from browser dev tools)

OpenAI or Azure Setup

  • Add your GPT-4 or GPT-4o API credentials
  • Can be from either OpenAI or Azure OpenAI

Google Sheet (Optional) Add a sheet with LinkedIn profile URLs to process in batch mode

Environment Cleanup

  • This version uses n8n credentials manager
  • All hardcoded tokens and API keys are removed for security compliance

Customization Tips

  • You can adjust the wait duration depending on PhantomBuster execution time
  • Replace or extend the AI parsing prompt to include more fields (e.g., education, location, skills)
  • Add additional automations: Slack notifications, CRM sync, or enrichment tools like Clearbit or Hunter.io

Perfect For

🚀 Growth hackers and SDRs automating lead generation 🧠 Recruiters scraping profiles for outreach 📊 Marketing teams enriching data for campaigns 🛠️ SaaS builders building LinkedIn intelligence tools

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 - Azure OpenAI Chat Model

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

Block 2 - Structured Output Parser

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

Block 3 - Wait

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

Block 4 - Azure OpenAI Chat Model1

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

Block 5 - Structured Output Parser1

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

Block 6 - Schedule Trigger

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

Block 7 - Fetch URL from Spreadsheet

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

Block 8 - Temp URL Storage

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

Block 9 - POST to Phantombuster API

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

Block 10 - GET from Phantombuster API

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

Block 11 - Extract URL from Output using GPT-4

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

Block 12 - GET LinkedIn Data from URL

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

Block 13 - Create Personalised Messages using a Template

Type / Role
@n8n/n8n-nodes-langchain.chainLlm - chainLlm
Config choices
Version 1.6

Block 14 - Update Personalised Messages to Spreadsheet

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

Block 15 - Delete Temp URL Storage

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

Block 16 - Sticky Note

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

3. Summary Table

Workflow LinkedIn scraping, structuring, and messaging using PhantomBuster and GPT-4
Complexity advanced
Nodes 16
Categories Lead Generation, AI Summarization
Author Rahul Joshi
Published 20 Jun 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/5070/5070.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 LinkedIn scraping, structuring, and messaging using PhantomBuster and GPT-4 do?

Description This template automates the end to end process of extracting professional data from LinkedIn and converting it into a usable format—ideal for recruiters, SDRs, marketers, and growth tea...

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.