{
  "name": "Send Automated Patient Appointment Reminders via Email & SMS with Multi-Database Support",
  "nodes": [
    {
      "id": "a9d91614-af71-4fb2-8d70-31f924d25f1c",
      "name": "Webhook: New Appointment",
      "type": "n8n-nodes-base.webhook",
      "position": [
        -2656,
        112
      ]
    },
    {
      "id": "68db087c-8c0c-4d07-b7d4-ab11e130273b",
      "name": "Extract Appointment Data",
      "type": "n8n-nodes-base.set",
      "position": [
        -2432,
        112
      ]
    },
    {
      "id": "c092578d-1c3b-46cf-be2b-798ab3204fcd",
      "name": "Format & Validate Data",
      "type": "n8n-nodes-base.code",
      "position": [
        -2208,
        112
      ]
    },
    {
      "id": "8045beb6-3991-4be1-b4bb-dd9639180a48",
      "name": "Store in Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -1984,
        16
      ]
    },
    {
      "id": "b91c8dfa-f6be-49e9-84ab-7dfc477d7876",
      "name": "Store in Airtable",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -1984,
        208
      ]
    },
    {
      "id": "58623e20-a443-494c-ae69-3e7bc2741527",
      "name": "Wait: 3 Days Before",
      "type": "n8n-nodes-base.wait",
      "position": [
        -1760,
        16
      ]
    },
    {
      "id": "cb96b8a0-e5dd-40d9-b5e6-d21857c3305e",
      "name": "Send 3-Day Email Reminder",
      "type": "n8n-nodes-base.emailSend",
      "position": [
        -1536,
        -192
      ]
    },
    {
      "id": "1029daf8-22f4-45dc-9249-23bb3368521b",
      "name": "Send 3-Day SMS Reminder",
      "type": "n8n-nodes-base.twilio",
      "position": [
        -1536,
        304
      ]
    },
    {
      "id": "2792acef-a716-42ba-b401-e1b84408ef5f",
      "name": "Update Google Sheets: 3-Day Sent",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -1312,
        -96
      ]
    },
    {
      "id": "8b5748ed-a62e-4725-a2ad-6412d1468b18",
      "name": "Update Airtable: 3-Day Sent",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -1232,
        176
      ]
    },
    {
      "id": "4caf96ed-2006-41fa-9c4f-ede96ea654e0",
      "name": "Wait: 1 Day Before",
      "type": "n8n-nodes-base.wait",
      "position": [
        -1088,
        16
      ]
    },
    {
      "id": "e1ca4c2d-bcb4-48b1-bed9-9c74a77901e4",
      "name": "Send 1-Day Email Reminder",
      "type": "n8n-nodes-base.emailSend",
      "position": [
        -864,
        -96
      ]
    },
    {
      "id": "88834f46-bcca-4d49-bc56-24b2b26065a6",
      "name": "Send 1-Day SMS Reminder",
      "type": "n8n-nodes-base.twilio",
      "position": [
        -864,
        112
      ]
    },
    {
      "id": "586716de-9d48-468a-8f97-a7e8f87dd1e4",
      "name": "Update Google Sheets: 1-Day Sent",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        -640,
        -96
      ]
    },
    {
      "id": "2398d8d2-7255-4306-806a-aaac78aeaecd",
      "name": "Update Airtable: 1-Day Sent",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -640,
        112
      ]
    },
    {
      "id": "00e32802-9651-4aa9-9143-81a90b7fe00d",
      "name": "System Overview",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2704,
        -560
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "4a1619df-aed7-4527-9d00-0a571d3cec83",
      "name": "Database Selection Guide",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -2352,
        -560
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "e8b7763b-3fcf-4956-9fde-5ee17a084a8d",
      "name": "Google Sheets Setup",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -464,
        -432
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "c3e818dc-46d6-4f83-a195-05eee8a1c5ee",
      "name": "Airtable Setup",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -464,
        48
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "e4db5054-ad97-4d4d-a2e7-8c6288e22a63",
      "name": "Client Setup Checklist",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -1120,
        -528
      ],
      "parameters": {
        "width": null,
        "height": null,
        "content": ""
      }
    },
    {
      "id": "e1c7410d-a009-48ce-a348-367e2f4b285b",
      "name": "Store in PostgreSQL",
      "type": "n8n-nodes-base.postgres",
      "position": [
        -1984,
        -192
      ]
    },
    {
      "id": "3701ff81-7ed4-4961-bac9-6ffa149d5b53",
      "name": "Update PostgreSQL: 3-Day Sent",
      "type": "n8n-nodes-base.postgres",
      "position": [
        -1312,
        -288
      ]
    },
    {
      "id": "b58b6cdb-c01f-426d-a1af-9ad37c1b4cce",
      "name": "Update PostgreSQL: 1-Day Sent",
      "type": "n8n-nodes-base.postgres",
      "position": [
        -640,
        -288
      ]
    }
  ],
  "connections": {
    "Store in Airtable": {
      "main": [
        [
          {
            "node": "Wait: 3 Days Before",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait: 1 Day Before": {
      "main": [
        [
          {
            "node": "Send 1-Day Email Reminder",
            "type": "main",
            "index": 0
          },
          {
            "node": "Send 1-Day SMS Reminder",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Store in PostgreSQL": {
      "main": [
        [
          {
            "node": "Wait: 3 Days Before",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait: 3 Days Before": {
      "main": [
        [
          {
            "node": "Send 3-Day Email Reminder",
            "type": "main",
            "index": 0
          },
          {
            "node": "Send 3-Day SMS Reminder",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Format & Validate Data": {
      "main": [
        [
          {
            "node": "Store in Google Sheets",
            "type": "main",
            "index": 0
          },
          {
            "node": "Store in Airtable",
            "type": "main",
            "index": 0
          },
          {
            "node": "Store in PostgreSQL",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Store in Google Sheets": {
      "main": [
        [
          {
            "node": "Wait: 3 Days Before",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send 1-Day SMS Reminder": {
      "main": [
        [
          {
            "node": "Update Google Sheets: 1-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update Airtable: 1-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update PostgreSQL: 1-Day Sent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send 3-Day SMS Reminder": {
      "main": [
        [
          {
            "node": "Update Google Sheets: 3-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update Airtable: 3-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update PostgreSQL: 3-Day Sent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Appointment Data": {
      "main": [
        [
          {
            "node": "Format & Validate Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Webhook: New Appointment": {
      "main": [
        [
          {
            "node": "Extract Appointment Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send 1-Day Email Reminder": {
      "main": [
        [
          {
            "node": "Update Google Sheets: 1-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update Airtable: 1-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update PostgreSQL: 1-Day Sent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Send 3-Day Email Reminder": {
      "main": [
        [
          {
            "node": "Update Google Sheets: 3-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update Airtable: 3-Day Sent",
            "type": "main",
            "index": 0
          },
          {
            "node": "Update PostgreSQL: 3-Day Sent",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Update Airtable: 3-Day Sent": {
      "main": [
        [
          {
            "node": "Wait: 1 Day Before",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Update PostgreSQL: 3-Day Sent": {
      "main": [
        [
          {
            "node": "Wait: 1 Day Before",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Update Google Sheets: 3-Day Sent": {
      "main": [
        [
          {
            "node": "Wait: 1 Day Before",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}