{
  "name": "Real Estate Lead Intake and CRM Enrichment",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "real-estate-lead-intake",
        "responseMode": "onReceived",
        "options": {}
      },
      "id": "fe904e13-6bc6-4d01-8a65-9a281300ebe5",
      "name": "Lead Intake",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        0,
        0
      ]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "695ae40c-5afb-41f5-ac34-1eb1f6f4e7ed",
              "name": "lead_name",
              "value": "={{ $json.body.name }}",
              "type": "string"
            },
            {
              "id": "b5f5ce8f-dff5-4e34-8389-49eb8f374c9a",
              "name": "phone",
              "value": "={{ $json.body.phone }}",
              "type": "string"
            },
            {
              "id": "c403f0f6-2a3a-44a9-96b3-8550653ce9e7",
              "name": "budget",
              "value": "={{ $json.body.budget }}",
              "type": "number"
            }
          ]
        },
        "options": {}
      },
      "id": "5022612b-4b9e-4d22-b9dd-569d69a38138",
      "name": "Normalize Lead",
      "type": "n8n-nodes-base.set",
      "typeVersion": 2,
      "position": [
        260,
        0
      ]
    },
    {
      "parameters": {
        "method": "POST",
        "url": "={{ $env.CRM_LEAD_ENDPOINT }}",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer {{$env.CRM_API_TOKEN}}"
            }
          ]
        },
        "sendBody": true,
        "contentType": "raw",
        "rawContentType": "application/json",
        "body": "={{ JSON.stringify($json) }}",
        "options": {}
      },
      "id": "b3c880d9-fddc-45f4-8275-d1c38eeaf4a6",
      "name": "Enrich in CRM",
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 2,
      "position": [
        520,
        0
      ]
    }
  ],
  "pinData": {},
  "connections": {
    "Lead Intake": {
      "main": [
        [
          {
            "node": "Normalize Lead",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Normalize Lead": {
      "main": [
        [
          {
            "node": "Enrich in CRM",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "022fdf62-559b-4a1c-9b1d-0366890c2487",
  "meta": {
    "templateCredsSetupCompleted": false,
    "kumoDraftAsset": true,
    "credentialPlaceholdersRequired": true
  },
  "tags": []
}