{
  "id": "hhCx6IGatRzAbFZ4",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "Multi-Channel Lead Nurturing Engine",
  "tags": [],
  "nodes": [
    {
      "id": "0abe3f0d-a83d-421e-bd01-d6a498da3863",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        3472,
        -832
      ],
      "parameters": {
        "width": 980,
        "height": 680,
        "content": "## Multi-Channel Lead Nurturing Engine\n\nThis workflow captures leads from web forms, nurtures them through personalized email sequences, sends timely WhatsApp follow-ups, and keeps CRM records updated automatically.\n\n### Who\u2019s it for\n\u2022 Marketing teams running high-volume lead gen campaigns\n\u2022 Sales teams managing inbound inquiries\n\u2022 Businesses with multi-channel customer acquisition\n\n### How it works\n1. Captures new leads via form webhook\n2. Qualifies and segments leads\n3. Sends personalized email sequence\n4. Triggers WhatsApp messages at key intervals\n5. Logs all interactions and updates CRM\n\n### Setup\n1. Import workflow\n2. Configure credentials (Email, WhatsApp/Twilio, CRM)\n3. Update lead preferences and templates\n4. Activate\n\n### Requirements\n\u2022 Form webhook or Typeform/Zapier\n\u2022 Email service (SendGrid/Gmail)\n\u2022 WhatsApp Business API or Twilio\n\u2022 CRM (Google Sheets/Airtable/HubSpot)"
      },
      "typeVersion": 1
    },
    {
      "id": "929c51ba-e421-49f2-b7cb-959eb54f2c45",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        4576,
        -720
      ],
      "parameters": {
        "color": 4,
        "width": 820,
        "height": 520,
        "content": "## 1. Lead Intake & Qualification"
      },
      "typeVersion": 1
    },
    {
      "id": "035feed8-1a81-4211-a448-654027825f4c",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        5440,
        -768
      ],
      "parameters": {
        "color": 3,
        "width": 860,
        "height": 680,
        "content": "## 2. Email Nurturing Sequence"
      },
      "typeVersion": 1
    },
    {
      "id": "24e3e3ac-f74e-4f44-94af-33b6db7101d0",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        6336,
        -816
      ],
      "parameters": {
        "color": 6,
        "width": 780,
        "height": 640,
        "content": "## 3. WhatsApp & CRM Sync"
      },
      "typeVersion": 1
    },
    {
      "id": "4d668f90-35a9-4af0-a443-f78ac16479b1",
      "name": "Webhook - New Lead Form",
      "type": "n8n-nodes-base.webhook",
      "position": [
        4640,
        -592
      ],
      "parameters": {
        "path": "new-lead-form",
        "options": {},
        "httpMethod": "POST",
        "responseMode": "responseNode"
      },
      "typeVersion": 1.1
    },
    {
      "id": "cead896a-6e8e-4fb7-9925-17553f80296d",
      "name": "Schedule - Check Pending Leads",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        4624,
        -384
      ],
      "parameters": {
        "rule": {
          "interval": [
            {
              "field": "cronExpression",
              "expression": "*/15 * * * *"
            }
          ]
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "d506e6a4-2378-4026-a53b-ff0431ea848f",
      "name": "Prepare Lead Data",
      "type": "n8n-nodes-base.set",
      "position": [
        4880,
        -528
      ],
      "parameters": {
        "options": {},
        "assignments": {
          "assignments": [
            {
              "name": "leadName",
              "type": "string",
              "value": "={{ $json.name || $json.fullName || $json.body?.name }}"
            },
            {
              "name": "leadEmail",
              "type": "string",
              "value": "={{ $json.email || $json.body?.email }}"
            },
            {
              "name": "leadPhone",
              "type": "string",
              "value": "={{ $json.phone || $json.body?.phone }}"
            },
            {
              "name": "leadSource",
              "type": "string",
              "value": "={{ $json.source || $json.body?.source || 'Web Form' }}"
            },
            {
              "name": "message",
              "type": "string",
              "value": "={{ $json.message || $json.body?.message || '' }}"
            },
            {
              "name": "leadId",
              "type": "string",
              "value": "={{ $json.id || 'lead-' + Date.now().toString() }}"
            }
          ]
        }
      },
      "typeVersion": 3.4
    },
    {
      "id": "ced4c7b2-e79e-4ca5-8293-98aa91aea808",
      "name": "Python - Qualify Lead",
      "type": "n8n-nodes-base.code",
      "position": [
        5088,
        -528
      ],
      "parameters": {
        "mode": "runOnceForEachItem",
        "language": "python"
      },
      "typeVersion": 2
    },
    {
      "id": "cfae1d93-bf66-492a-9533-2764546e5a74",
      "name": "Filter Qualified Leads",
      "type": "n8n-nodes-base.filter",
      "position": [
        5472,
        -528
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "conditions": [
            {
              "operator": {
                "type": "boolean",
                "operation": "true"
              },
              "leftValue": "={{ $json.isQualified }}"
            }
          ]
        }
      },
      "typeVersion": 2.2
    },
    {
      "id": "c2177609-59e0-420a-bceb-760c37268110",
      "name": "Wait 1 - Initial Delay",
      "type": "n8n-nodes-base.wait",
      "position": [
        5632,
        -576
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "83d0a01d-fce1-4939-ba24-16e9a90b8bd5",
      "name": "AI - Generate Email 1",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        5792,
        -592
      ],
      "parameters": {
        "text": "=Act as an expert sales copywriter. Create a warm, personalized nurturing email for this new lead.\n\nLead Info:\nName: {{ $json.leadName }}\nSource: {{ $json.leadSource }}\nMessage: {{ $json.message }}\n\nProduct Context: High-value SaaS solution for workflow automation.\n\nWrite an engaging first email under 150 words that builds rapport and offers value.",
        "options": {},
        "promptType": "define"
      },
      "typeVersion": 1.6
    },
    {
      "id": "d204b706-a7df-4f8c-b848-d21364795219",
      "name": "JS - Format Email",
      "type": "n8n-nodes-base.code",
      "position": [
        6144,
        -592
      ],
      "parameters": {
        "mode": "runOnceForEachItem",
        "jsCode": "const item = $input.item.json;\nreturn {\n  json: {\n    ...item,\n    emailSubject: 'Welcome! Let\\'s get you started with automation',\n    emailBody: item.response || item.text || 'Thank you for your interest...',\n    status: 'Email Sent - Day 1',\n    lastInteraction: new Date().toISOString()\n  }\n};"
      },
      "typeVersion": 2
    },
    {
      "id": "e5246522-406b-4ad1-886d-0aed5fd76c87",
      "name": "Wait 2 - 3 Days Nurture",
      "type": "n8n-nodes-base.wait",
      "position": [
        6400,
        -592
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "414f3bac-47a5-424b-b9f5-2e964ce9b124",
      "name": "Send Nurture Email",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        6640,
        -688
      ],
      "parameters": {
        "url": "https://api.sendgrid.com/v3/mail/send",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"personalizations\": [{\"to\": [{\"email\": \"{{ $json.leadEmail }}\"}]}],\n  \"from\": {\"email\": \"noreply@yourcompany.com\", \"name\": \"Your Company Sales\"},\n  \"subject\": \"{{ $json.emailSubject }}\",\n  \"content\": [{\"type\": \"text/plain\", \"value\": \"{{ $json.emailBody }}\"}]\n}",
        "sendBody": true,
        "specifyBody": "json"
      },
      "typeVersion": 4.2
    },
    {
      "id": "5ee9edf9-5e17-4b0b-a332-8782fa3c230a",
      "name": "Send WhatsApp Follow-up",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        6608,
        -432
      ],
      "parameters": {
        "url": "https://api.twilio.com/2010-04-01/Accounts/{{ $credentials.twilioAccountSid }}/Messages.json",
        "method": "POST",
        "options": {},
        "sendBody": true,
        "specifyBody": "form",
        "authentication": "headerAuth"
      },
      "typeVersion": 4.2
    },
    {
      "id": "e71e74f6-7211-46f0-8432-4b9f2e1cb694",
      "name": "Update CRM - Google Sheets",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        6912,
        -560
      ],
      "parameters": {
        "url": "https://sheets.googleapis.com/v4/spreadsheets/YOUR_CRM_SHEET_ID/values/Leads!A1:append?valueInputOption=USER_ENTERED",
        "method": "POST",
        "options": {},
        "jsonBody": "={\n  \"values\": [[\"{{ $json.leadId }}\", \"{{ $json.leadName }}\", \"{{ $json.leadEmail }}\", \"{{ $json.leadPhone }}\", \"{{ $json.leadSource }}\", \"{{ $json.status }}\", \"{{ $json.lastInteraction }}\"]]\n}",
        "sendBody": true,
        "specifyBody": "json"
      },
      "typeVersion": 4.2
    },
    {
      "id": "9ab249e1-4c0c-4c19-929c-e1362edfaa4b",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        5744,
        -368
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini"
        },
        "options": {},
        "builtInTools": {}
      },
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1.3
    },
    {
      "id": "cf9e98f8-3412-429b-95ec-2e4f10c4e448",
      "name": "Wait For Result",
      "type": "n8n-nodes-base.wait",
      "position": [
        5264,
        -528
      ],
      "parameters": {},
      "typeVersion": 1.1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "941d89e0-9b37-425d-bfc5-f2a927422c1f",
  "connections": {
    "Wait For Result": {
      "main": [
        [
          {
            "node": "Filter Qualified Leads",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "JS - Format Email": {
      "main": [
        [
          {
            "node": "Wait 2 - 3 Days Nurture",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI - Generate Email 1",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Prepare Lead Data": {
      "main": [
        [
          {
            "node": "Python - Qualify Lead",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI - Generate Email 1": {
      "main": [
        [
          {
            "node": "JS - Format Email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Python - Qualify Lead": {
      "main": [
        [
          {
            "node": "Wait For Result",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Filter Qualified Leads": {
      "main": [
        [
          {
            "node": "Wait 1 - Initial Delay",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait 1 - Initial Delay": {
      "main": [
        [
          {
            "node": "AI - Generate Email 1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait 2 - 3 Days Nurture": {
      "main": [
        [
          {
            "node": "Send Nurture Email",
            "type": "main",
            "index": 0
          },
          {
            "node": "Send WhatsApp Follow-up",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update CRM - Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Webhook - New Lead Form": {
      "main": [
        [
          {
            "node": "Prepare Lead Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule - Check Pending Leads": {
      "main": [
        [
          {
            "node": "Prepare Lead Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}