{
  "name": "AI Agent-in-a-Box — Follow-Up",
  "nodes": [
    {
      "parameters": {},
      "type": "n8n-nodes-base.manualTrigger",
      "typeVersion": 1,
      "position": [0, 0],
      "id": "trigger-3",
      "name": "Lead needs follow-up"
    },
    {
      "parameters": {
        "values": {
          "string": [
            {"name": "name", "value": "Jordan"},
            {"name": "lastMessage", "value": "Sounds interesting. Can you send me more info?"},
            {"name": "daysSinceReply", "value": "2"}
          ]
        }
      },
      "type": "n8n-nodes-base.set",
      "typeVersion": 3,
      "position": [220, 0],
      "id": "set-followup-1",
      "name": "Set Lead Context"
    },
    {
      "parameters": {
        "jsCode": "const { name, lastMessage, daysSinceReply } = $input.first().json;\nconst followUp = `Hey ${name}, wanted to follow up on this. Here's a 2-min Loom showing exactly how it works: [link]. Worth a look?`;\nreturn [{ json: { name, lastMessage, daysSinceReply, followUp, sendInHours: 24 } }];"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [440, 0],
      "id": "ai-followup-1",
      "name": "AI Follow-Up Drafter"
    },
    {
      "parameters": {
        "jsCode": "// Add a Wait node + Send Email / DM node here\n// If no reply after 3 touches, create a task for you to manually close or move on.\nreturn $input.all();"
      },
      "type": "n8n-nodes-base.code",
      "typeVersion": 2,
      "position": [660, 0],
      "id": "schedule-1",
      "name": "Schedule + Escalate"
    }
  ],
  "connections": {
    "Lead needs follow-up": {
      "main": [[{"node": "Set Lead Context", "type": "main", "index": 0}]]
    },
    "Set Lead Context": {
      "main": [[{"node": "AI Follow-Up Drafter", "type": "main", "index": 0}]]
    },
    "AI Follow-Up Drafter": {
      "main": [[{"node": "Schedule + Escalate", "type": "main", "index": 0}]]
    }
  },
  "settings": {"executionOrder": "v1"},
  "staticData": null,
  "tags": ["ai-agent-in-a-box", "follow-up"]
}
