{
  "name": "Zambo - Lead Enrichment",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "lead-enrich",
        "responseMode": "onReceived",
        "options": {}
      },
      "id": "c4058904-c030-4811-96d4-4d313e19c5ae",
      "name": "Lead Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        240,
        300
      ],
      "webhookId": "27205f84-790f-4c2a-a678-1a5246d59a14"
    },
    {
      "parameters": {
        "operation": "universal",
        "goal": "={{ \"Enrich this inbound sales lead. Research the person and company from the details below and return structured findings: full name, role, company, company size and industry, public signals (funding, hiring, launches), and a suggested next step. Lead details: \" + JSON.stringify($json.body) }}",
        "sessionId": "lead-enrichment"
      },
      "id": "f75698a6-8874-4275-92a1-3bf6489a5884",
      "name": "Zambo Enrich Lead",
      "type": "n8n-nodes-zambo.zambo",
      "typeVersion": 1,
      "position": [
        460,
        300
      ]
    },
    {
      "parameters": {
        "mode": "runOnceForAllItems",
        "jsCode": "const items = $input.all();\nconst out = [];\nfor (const item of items) {\n  const j = item.json || {};\n  let data = j.result ? j.result : j;\n  let parsed = data;\n  if (data && data.content && Array.isArray(data.content) && data.content[0] && data.content[0].text) {\n    try { parsed = JSON.parse(data.content[0].text); }\n    catch (e) { parsed = { raw_text: data.content[0].text }; }\n  } else if (typeof data === 'string') {\n    try { parsed = JSON.parse(data); }\n    catch (e) { parsed = { raw_text: data }; }\n  }\n  const p = parsed || {};\n  out.push({ json: {\n    findings: p.findings ?? p.result ?? p.enrichment ?? p.raw_text ?? JSON.stringify(p).slice(0, 3000),\n    receipt_url: p.receipt_url ?? p.receipt ?? j.receipt_url ?? null,\n    raw: p,\n  }});\n}\nreturn out;"
      },
      "id": "687b5c85-d3aa-4b28-bd17-13c0e9c1bed5",
      "name": "Extract Findings",
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [
        680,
        300
      ]
    },
    {
      "parameters": {
        "content": "## Lead enrichment (Zambo)\n\n1. Install the community node: n8n **Settings \u2192 Community Nodes \u2192 Install** \u2192 `n8n-nodes-zambo`. No API key needed (free: 20 calls/tool/day).\n2. Activate the workflow, copy the **Production URL** from *Lead Webhook*, and POST leads to it:\n\n```\ncurl -X POST <production-url> -H 'Content-Type: application/json' \\\n  -d '{\"name\":\"Jane Doe\",\"email\":\"jane@acme.com\",\"company\":\"Acme\"}'\n```\n\n3. *Zambo Enrich Lead* routes the goal through 100+ tools (research, company data, signals) with one shared session id, so follow-up calls keep context.\n4. *Extract Findings* surfaces the structured findings plus the verifiable receipt URL. Send it to your CRM, Slack, or a sheet from here.",
        "height": 260,
        "width": 880,
        "color": 4
      },
      "id": "bd5f7710-b209-48c9-8f55-0f98a3414df5",
      "name": "README",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        240,
        60
      ]
    }
  ],
  "connections": {
    "Lead Webhook": {
      "main": [
        [
          {
            "node": "Zambo Enrich Lead",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Zambo Enrich Lead": {
      "main": [
        [
          {
            "node": "Extract Findings",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "pinData": {},
  "meta": {
    "templateCredsSetupCompleted": false
  }
}