{
  "id": "{{WORKFLOW_ID}}",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "22 - Multi-Source Lead Routing",
  "tags": [
    {
      "id": "{{TAG_ID}}",
      "name": "Production",
      "createdAt": "2025-01-01T00:00:00.000Z",
      "updatedAt": "2025-01-01T00:00:00.000Z"
    }
  ],
  "nodes": [
    {
      "id": "cd8e0aa7-1991-4ecd-966f-15249c8b7244",
      "name": "\ud83d\udccb Typeform Submission Trigger",
      "type": "n8n-nodes-base.typeformTrigger",
      "position": [
        -1200,
        130
      ],
      "parameters": {
        "formId": "{{YOUR_TYPEFORM_ID}}"
      },
      "credentials": {
        "typeformApi": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "ec35de3e-7722-4445-80ed-c6cc2a3941dc",
      "name": "\ud83d\udcb0 Check High-Budget Lead",
      "type": "n8n-nodes-base.if",
      "position": [
        -980,
        130
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "or",
          "conditions": [
            {
              "id": "high-priority-budget",
              "operator": {
                "type": "number",
                "operation": "gt"
              },
              "leftValue": "={{ $json['What is your Budget'] }}",
              "rightValue": 5000
            }
          ]
        }
      },
      "typeVersion": 2
    },
    {
      "id": "e1271e83-fa1a-4ba1-9c8c-bf7f1f38261c",
      "name": "\ud83d\udcd8 Check if Facebook Lead",
      "type": "n8n-nodes-base.if",
      "position": [
        -320,
        130
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "facebook-source",
              "operator": {
                "type": "string",
                "operation": "contains"
              },
              "leftValue": "={{ $json.lead_source || $json.source }}",
              "rightValue": "Facebook"
            }
          ]
        }
      },
      "typeVersion": 2
    },
    {
      "id": "bc9727ca-0cf7-4d89-b771-ca354537df5c",
      "name": "\ud83d\udcca Check if SurveyMonkey Lead",
      "type": "n8n-nodes-base.if",
      "position": [
        -100,
        205
      ],
      "parameters": {
        "options": {},
        "conditions": {
          "options": {
            "version": 1,
            "leftValue": "",
            "caseSensitive": true,
            "typeValidation": "strict"
          },
          "combinator": "and",
          "conditions": [
            {
              "id": "surveymonkey-source",
              "operator": {
                "type": "string",
                "operation": "contains"
              },
              "leftValue": "={{ $json.lead_source || $json.source }}",
              "rightValue": "SurveyMonkey"
            }
          ]
        }
      },
      "typeVersion": 2
    },
    {
      "id": "22344a6e-e585-44f9-a896-a48720d9da6b",
      "name": "\ud83d\udc64 HubSpot \u2014 Create/Update Contact",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        -760,
        130
      ],
      "parameters": {
        "email": "={{ $json.Email }}",
        "options": {},
        "authentication": "appToken",
        "additionalFields": {
          "firstName": "={{ $json.Name }}",
          "phoneNumber": "={{ $json['Phone Number'] }}",
          "customPropertiesUi": {
            "customPropertiesValues": [
              {
                "value": "={{ $json['What is your Budget'] }}",
                "property": "Budget"
              }
            ]
          }
        }
      },
      "credentials": {
        "hubspotAppToken": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "fb3aba79-a82b-4a75-8174-46bcd8b77957",
      "name": "\ud83d\udcdd HubSpot \u2014 Add Priority Task",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        -540,
        130
      ],
      "parameters": {
        "type": "task",
        "metadata": {
          "body": "=Priority - High (Budget - {{ $json['What is your Budget'] }})"
        },
        "resource": "engagement",
        "authentication": "appToken",
        "additionalFields": {}
      },
      "credentials": {
        "hubspotAppToken": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "bc870ccf-8759-40ad-b7f6-5dc9e310fa9e",
      "name": "\ud83d\udcc4 Log Facebook Lead to Google Sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        120,
        40
      ],
      "parameters": {
        "columns": {
          "value": {},
          "schema": [],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "append",
        "sheetName": {
          "__rl": true,
          "mode": "id",
          "value": "{{YOUR_SHEET_NAME}}"
        },
        "documentId": {
          "__rl": true,
          "mode": "id",
          "value": "{{YOUR_GOOGLE_SHEET_ID}}"
        }
      },
      "credentials": {
        "googleSheetsOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 4
    },
    {
      "id": "9690a043-4ad1-4d69-aa34-1429983f864a",
      "name": "\ud83d\udce6 Store SurveyMonkey Lead in Airtable",
      "type": "n8n-nodes-base.airtable",
      "position": [
        120,
        280
      ],
      "parameters": {
        "base": {
          "__rl": true,
          "mode": "id",
          "value": "{{YOUR_AIRTABLE_BASE_ID}}"
        },
        "table": {
          "__rl": true,
          "mode": "id",
          "value": "{{YOUR_AIRTABLE_TABLE_NAME}}"
        },
        "columns": {
          "value": {},
          "schema": [
            {
              "id": "Name",
              "type": "string",
              "display": true,
              "removed": true,
              "readOnly": false,
              "required": false,
              "displayName": "Name",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Email",
              "type": "string",
              "display": true,
              "removed": true,
              "readOnly": false,
              "required": false,
              "displayName": "Email",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Phone Number",
              "type": "number",
              "display": true,
              "removed": true,
              "readOnly": false,
              "required": false,
              "displayName": "Phone Number",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            },
            {
              "id": "Message",
              "type": "string",
              "display": true,
              "removed": true,
              "readOnly": false,
              "required": false,
              "displayName": "Message",
              "defaultMatch": false,
              "canBeUsedToMatch": true
            }
          ],
          "mappingMode": "defineBelow",
          "matchingColumns": [],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {},
        "operation": "create",
        "authentication": "airtableOAuth2Api"
      },
      "credentials": {
        "airtableOAuth2Api": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "6e6d35a3-1c45-43b6-86ee-f99397dfe924",
      "name": "\ud83d\udce7 Send Gmail Auto-Response",
      "type": "n8n-nodes-base.gmail",
      "position": [
        340,
        130
      ],
      "parameters": {
        "sendTo": "={{ $json.email }}",
        "message": "Hi {{ $json.name || $json.first_name }},\n\nThank you for your interest. Our sales team will reach out within 24 hours.\n\nBest regards,\nSales Team",
        "options": {
          "ccList": "",
          "bccList": ""
        },
        "subject": "Thanks for reaching out \u2014 We'll get back soon"
      },
      "credentials": {
        "gmailOAuth2": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2
    },
    {
      "id": "6eea1967-e1ee-4f57-aa68-f0fca9304c00",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1260,
        -200
      ],
      "parameters": {
        "color": 5,
        "width": 440,
        "height": 660,
        "content": "## \ud83d\udccb Form Intake & Lead Qualification\n\n**\ud83d\udccb Typeform Submission Trigger \u2192 \ud83d\udcb0 Check High-Budget Lead**\n\n*This section captures new lead data from the Typeform submission. It immediately evaluates the budget field to determine whether the lead is high priority (budget > $5,000), allowing the workflow to route premium leads for faster follow-up.*"
      },
      "typeVersion": 1
    },
    {
      "id": "59c9b01f-a262-42d4-aa0c-a92f5a874f67",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -800,
        -200
      ],
      "parameters": {
        "width": 400,
        "height": 660,
        "content": "## \ud83d\udc64 CRM Integration & Priority Handling\n\n**\ud83d\udc64 HubSpot \u2014 Create/Update Contact \u2192 \ud83d\udcdd HubSpot \u2014 Add Priority Task**\n\n*For high-priority leads, the workflow automatically creates or updates the corresponding contact in HubSpot, adding their budget and other details. It then logs a priority follow-up task in HubSpot to ensure the sales team responds promptly.*"
      },
      "typeVersion": 1
    },
    {
      "id": "df5fcd72-2882-40f4-a398-4d49b0eb55f8",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -380,
        -200
      ],
      "parameters": {
        "color": 4,
        "width": 420,
        "height": 660,
        "content": "## \ud83d\udcd8/\ud83d\udcca Lead Source Routing & Storage\n\n**\ud83d\udcd8 Check if Facebook Lead \u2192 \ud83d\udcc4 Log Facebook Lead to Google Sheet\n\ud83d\udcca Check if SurveyMonkey Lead \u2192 \ud83d\udce6 Store SurveyMonkey Lead in Airtable**\n\n*This section routes leads based on their source. Facebook leads are logged in Google Sheets for marketing analysis, while SurveyMonkey leads are stored in Airtable for structured data management and campaign tracking.*"
      },
      "typeVersion": 1
    },
    {
      "id": "4e93476a-9dd5-49c5-865f-a8d95d6d2415",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        60,
        -260
      ],
      "parameters": {
        "color": 3,
        "width": 420,
        "height": 720,
        "content": "## \ud83d\udce7 Automated Lead Acknowledgment\n\n**\ud83d\udcc4 Log Facebook Lead to Google Sheet \u2192 \ud83d\udce7 Send Gmail Auto-Response\n\ud83d\udce6 Store SurveyMonkey Lead in Airtable \u2192 \ud83d\udce7 Send Gmail Auto-Response**\n\n*After the lead's data is stored in the appropriate system, the workflow sends an automated acknowledgment email via Gmail, confirming receipt of their inquiry and setting the expectation for a 24-hour follow-up.*"
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "{{WORKFLOW_VERSION_ID}}",
  "connections": {
    "\ud83d\udcb0 Check High-Budget Lead": {
      "main": [
        [
          {
            "node": "\ud83d\udc64 HubSpot \u2014 Create/Update Contact",
            "type": "main",
            "index": 0
          }
        ],
        []
      ]
    },
    "\ud83d\udcd8 Check if Facebook Lead": {
      "main": [
        [
          {
            "node": "\ud83d\udcc4 Log Facebook Lead to Google Sheet",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "\ud83d\udcca Check if SurveyMonkey Lead",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ud83d\udcca Check if SurveyMonkey Lead": {
      "main": [
        [
          {
            "node": "\ud83d\udce6 Store SurveyMonkey Lead in Airtable",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "\ud83d\udce7 Send Gmail Auto-Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ud83d\udccb Typeform Submission Trigger": {
      "main": [
        [
          {
            "node": "\ud83d\udcb0 Check High-Budget Lead",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ud83d\udcdd HubSpot \u2014 Add Priority Task": {
      "main": [
        [
          {
            "node": "\ud83d\udcd8 Check if Facebook Lead",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ud83d\udc64 HubSpot \u2014 Create/Update Contact": {
      "main": [
        [
          {
            "node": "\ud83d\udcdd HubSpot \u2014 Add Priority Task",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ud83d\udcc4 Log Facebook Lead to Google Sheet": {
      "main": [
        [
          {
            "node": "\ud83d\udce7 Send Gmail Auto-Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "\ud83d\udce6 Store SurveyMonkey Lead in Airtable": {
      "main": [
        [
          {
            "node": "\ud83d\udce7 Send Gmail Auto-Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}