{
  "name": "Analyze Retell AI call transcripts with OpenAI and sync insights to HubSpot",
  "nodes": [
    {
      "id": "a1000001-0000-0000-0000-000000000001",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -480,
        -340
      ],
      "parameters": {
        "width": 540,
        "height": 480,
        "content": "## Retell AI Call Analyzer → HubSpot\n\nAutomatically analyze voice call transcripts and sync AI-powered insights to your CRM.\n\n### How it works\n1. **Webhook:** Receives the call transcript from Retell "
      }
    },
    {
      "id": "a1000001-0000-0000-0000-000000000002",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        40,
        60
      ],
      "parameters": {
        "width": 460,
        "height": 200,
        "content": "## 1. Trigger & Config\nRetell sends a webhook when a call finishes. The config node holds your editable settings."
      }
    },
    {
      "id": "a1000001-0000-0000-0000-000000000003",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        560,
        60
      ],
      "parameters": {
        "width": 460,
        "height": 200,
        "content": "## 2. AI Analysis\nOpenAI reads the full transcript and returns structured JSON: sentiment, lead score, action items, and a summary."
      }
    },
    {
      "id": "a1000001-0000-0000-0000-000000000004",
      "name": "Sticky Note3",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1100,
        60
      ],
      "parameters": {
        "width": 620,
        "height": 200,
        "content": "## 3. CRM & Routing\nUpdates the HubSpot contact. Qualified leads trigger a Slack alert and a HubSpot follow-up task."
      }
    },
    {
      "id": "a1000001-0000-0000-0000-000000000005",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        1100,
        480
      ],
      "parameters": {
        "width": 320,
        "height": 160,
        "content": "## 4. Logging\nEvery call is appended to Google Sheets for reporting and tracking."
      }
    },
    {
      "id": "a1000001-1000-0000-0000-000000000001",
      "name": "Receive Retell call webhook",
      "type": "n8n-nodes-base.webhook",
      "position": [
        80,
        300
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000002",
      "name": "Set user config variables",
      "type": "n8n-nodes-base.set",
      "position": [
        300,
        300
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000003",
      "name": "Parse call transcript and metadata",
      "type": "n8n-nodes-base.code",
      "position": [
        520,
        300
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000004",
      "name": "Analyze call with OpenAI",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        760,
        300
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000005",
      "name": "Extract and structure AI analysis",
      "type": "n8n-nodes-base.code",
      "position": [
        1000,
        300
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000006",
      "name": "Update HubSpot contact with insights",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        1280,
        200
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000007",
      "name": "Check if lead is qualified",
      "type": "n8n-nodes-base.if",
      "position": [
        1280,
        400
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000008",
      "name": "Alert sales team about hot lead",
      "type": "n8n-nodes-base.slack",
      "position": [
        1540,
        300
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000009",
      "name": "Create follow-up task in HubSpot",
      "type": "n8n-nodes-base.hubspot",
      "position": [
        1540,
        480
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000010",
      "name": "Log call analysis to tracking sheet",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1280,
        600
      ]
    },
    {
      "id": "a1000001-1000-0000-0000-000000000011",
      "name": "Respond to Retell webhook",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1540,
        140
      ]
    }
  ],
  "connections": {
    "Analyze call with OpenAI": {
      "main": [
        [
          {
            "node": "Extract and structure AI analysis",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Set user config variables": {
      "main": [
        [
          {
            "node": "Parse call transcript and metadata",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Check if lead is qualified": {
      "main": [
        [
          {
            "node": "Alert sales team about hot lead",
            "type": "main",
            "index": 0
          },
          {
            "node": "Create follow-up task in HubSpot",
            "type": "main",
            "index": 0
          }
        ],
        []
      ]
    },
    "Receive Retell call webhook": {
      "main": [
        [
          {
            "node": "Set user config variables",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract and structure AI analysis": {
      "main": [
        [
          {
            "node": "Update HubSpot contact with insights",
            "type": "main",
            "index": 0
          },
          {
            "node": "Check if lead is qualified",
            "type": "main",
            "index": 0
          },
          {
            "node": "Log call analysis to tracking sheet",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Parse call transcript and metadata": {
      "main": [
        [
          {
            "node": "Analyze call with OpenAI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Update HubSpot contact with insights": {
      "main": [
        [
          {
            "node": "Respond to Retell webhook",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}