{
  "name": "CallHuman · Reconfirm a booking",
  "nodes": [
    {
      "id": "6652e634-4c55-4d03-a3c5-9001ded77b63",
      "name": "New booking",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        0,
        0
      ],
      "webhookId": "cb7976cf-7e8a-49e4-a0d4-da23ea693920",
      "parameters": {
        "httpMethod": "POST",
        "path": "new-booking",
        "options": {}
      }
    },
    {
      "id": "137890c0-1b1d-4194-ae27-42b924a84fc6",
      "name": "Call and wait for answer",
      "type": "n8n-nodes-callhuman.callHuman",
      "typeVersion": 1,
      "position": [
        320,
        0
      ],
      "webhookId": "dba309cc-a9f9-4e72-a8a1-e11be7330941",
      "parameters": {
        "operation": "callAndWait",
        "phone": "={{ $json.body.phone }}",
        "message": "=Hi {{ $json.body.name }}! This is La Plaza about your table tonight at {{ $json.body.time }}.",
        "language": "en",
        "options": {
          "option": [
            {
              "label": "Confirm",
              "id": "confirm",
              "reply": "Perfect, see you tonight!"
            },
            {
              "label": "Cancel",
              "id": "cancel",
              "reply": "Done, your table is cancelled. Thank you for letting us know."
            },
            {
              "label": "Other options",
              "subOptions": {
                "option": [
                  {
                    "label": "Change the time",
                    "id": "change_time",
                    "reply": "We'll call you back to find another time."
                  },
                  {
                    "label": "Change the number of guests",
                    "id": "change_guests",
                    "reply": "We'll call you back to update it."
                  }
                ]
              }
            }
          ]
        },
        "additionalFields": {
          "metadata": "={{ JSON.stringify({ booking_id: $json.body.booking_id }) }}"
        }
      }
    },
    {
      "id": "e617f3c3-6e7d-4a22-aa59-7bf5876059ed",
      "name": "Mark as confirmed",
      "type": "n8n-nodes-base.noOp",
      "typeVersion": 1,
      "position": [
        700,
        -360
      ],
      "parameters": {}
    },
    {
      "id": "abc8390c-3068-46ef-aa5d-cb9fc7994237",
      "name": "Free the table",
      "type": "n8n-nodes-base.noOp",
      "typeVersion": 1,
      "position": [
        700,
        -180
      ],
      "parameters": {}
    },
    {
      "id": "23fc28f1-58f6-428e-a077-055648589dfa",
      "name": "Call back: new time",
      "type": "n8n-nodes-base.noOp",
      "typeVersion": 1,
      "position": [
        700,
        0
      ],
      "parameters": {}
    },
    {
      "id": "1220d3b1-dd9c-47d1-a603-232d75241cda",
      "name": "Call back: guests",
      "type": "n8n-nodes-base.noOp",
      "typeVersion": 1,
      "position": [
        700,
        180
      ],
      "parameters": {}
    },
    {
      "id": "8371c637-ef93-482b-a89d-f3944fdd6812",
      "name": "Send a reminder email",
      "type": "n8n-nodes-base.noOp",
      "typeVersion": 1,
      "position": [
        700,
        360
      ],
      "parameters": {}
    },
    {
      "id": "2d58997b-767c-4cfc-a73a-96f417455eee",
      "name": "How it works",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [
        -40,
        -420
      ],
      "parameters": {
        "width": 520,
        "height": 260,
        "content": "## Reconfirm a booking\nPOST `{ \"phone\": \"+34600111222\", \"name\": \"Ana\", \"time\": \"8:30 pm\" }` to the webhook.\n\nThe guest answers by keypress or in their own words. Each answer continues down its own branch, also the ones inside **Other options**. Needs a plan with at least 4 answers per call. Replace the placeholder nodes with your booking system."
      }
    }
  ],
  "connections": {
    "New booking": {
      "main": [
        [
          {
            "node": "Call and wait for answer",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Call and wait for answer": {
      "main": [
        [
          {
            "node": "Mark as confirmed",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Free the table",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Call back: new time",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Call back: guests",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Send a reminder email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "settings": {
    "executionOrder": "v1"
  },
  "meta": {
    "templateCredsSetupCompleted": false
  }
}
