{
  "name": "WhatsApp Appointment Booking Engine",
  "nodes": [
    {
      "parameters": {
        "calendar": {
          "__rl": true,
          "value": "hello@autonoma.agency",
          "mode": "list",
          "cachedResultName": "hello@autonoma.agency"
        },
        "start": "={{ $fromAI(\"start\",\"date and time for when the event should start\") }}",
        "end": "={{ $fromAI(\"end\",\"date and time for when the event should end\") }}",
        "additionalFields": {
          "summary": "={{ $fromAI(\"title\",\"title of the event\") }}"
        }
      },
      "type": "n8n-nodes-base.googleCalendarTool",
      "typeVersion": 1.3,
      "position": [
        840,
        140
      ],
      "id": "07f270d6-d18c-498b-941a-aac1c5a6c7a7",
      "name": "Calendar Create"
    },
    {
      "parameters": {
        "operation": "getAll",
        "calendar": {
          "__rl": true,
          "value": "hello@autonoma.agency",
          "mode": "list",
          "cachedResultName": "hello@autonoma.agency"
        },
        "limit": 20,
        "options": {}
      },
      "type": "n8n-nodes-base.googleCalendarTool",
      "typeVersion": 1.3,
      "position": [
        720,
        120
      ],
      "id": "ab5e902a-f5dc-4a9f-a285-686ec4d307b4",
      "name": "Calendar Read",
      "credentials": {
        "googleCalendarOAuth2Api": {
          "id": "m3LNMBgnnoVsLqQT",
          "name": "Google Calendar account 4"
        }
      }
    },
    {
      "parameters": {
        "operation": "delete",
        "calendar": {
          "__rl": true,
          "value": "=hello@autonoma.agency",
          "mode": "id"
        },
        "eventId": "={{ $fromAI(\"id\",\"the id of the event\") }}",
        "options": {}
      },
      "type": "n8n-nodes-base.googleCalendarTool",
      "typeVersion": 1.3,
      "position": [
        960,
        200
      ],
      "id": "41bef9c7-4b09-4526-b91c-6374aa365a00",
      "name": "Google Calendar"
    },
    {
      "parameters": {
        "updates": [
          "messages"
        ]
      },
      "type": "n8n-nodes-base.whatsAppTrigger",
      "typeVersion": 1,
      "position": [
        -40,
        -140
      ],
      "id": "33e87a44-d937-49f3-a0b6-53ac47ff3769",
      "name": "WhatsApp Trigger",
      "webhookId": "28844a97-eefe-4575-8514-40334181c85f"
    },
    {
      "parameters": {
        "documentId": {
          "__rl": true,
          "value": "1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4",
          "mode": "list",
          "cachedResultName": "WhatsApp Ai Agent Appointment Setter - AI Agent WhatsApp Voice and Vision - autonoma.agency",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4/edit?usp=drivesdk"
        },
        "sheetName": {
          "__rl": true,
          "value": 689245338,
          "mode": "list",
          "cachedResultName": "Appointments",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4/edit#gid=689245338"
        },
        "options": {
          "dataLocationOnSheet": {
            "values": {
              "rangeDefinition": "detectAutomatically",
              "readRowsUntil": "firstEmptyRow"
            }
          }
        }
      },
      "type": "n8n-nodes-base.googleSheetsTool",
      "typeVersion": 4.5,
      "position": [
        1080,
        220
      ],
      "id": "0c8d8a9b-d258-4d1b-b060-4baf55a6e24b",
      "name": "Google Sheets - Read"
    },
    {
      "parameters": {
        "operation": "append",
        "documentId": {
          "__rl": true,
          "value": "1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4",
          "mode": "list",
          "cachedResultName": "WhatsApp Ai Agent Appointment Setter - AI Agent WhatsApp Voice and Vision - autonoma.agency",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4/edit?usp=drivesdk"
        },
        "sheetName": {
          "__rl": true,
          "value": 689245338,
          "mode": "list",
          "cachedResultName": "Appointments",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4/edit#gid=689245338"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "Email": "={{ $fromAI(\"email\",\"the email address that the user tells you\") }}"
          },
          "matchingColumns": [],
          "schema": [
            {
              "id": "Appointment Date",
              "displayName": "Appointment Date",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Booking Status",
              "displayName": "Booking Status",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Time Zone",
              "displayName": "Time Zone",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Name",
              "displayName": "Name",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Phone",
              "displayName": "Phone",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Email",
              "displayName": "Email",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "Intake Form",
              "displayName": "Intake Form",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Reminder Sent",
              "displayName": "Reminder Sent",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Email Consent",
              "displayName": "Email Consent",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "Added to Contacts",
              "displayName": "Added to Contacts",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheetsTool",
      "typeVersion": 4.5,
      "position": [
        1200,
        180
      ],
      "id": "01be281e-e0fe-4879-a232-f395100d472e",
      "name": "Google Sheets - Add Row"
    },
    {
      "parameters": {
        "operation": "update",
        "documentId": {
          "__rl": true,
          "value": "1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4",
          "mode": "list",
          "cachedResultName": "WhatsApp Ai Agent Appointment Setter - AI Agent WhatsApp Voice and Vision - autonoma.agency",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4/edit?usp=drivesdk"
        },
        "sheetName": {
          "__rl": true,
          "value": 689245338,
          "mode": "list",
          "cachedResultName": "Appointments",
          "cachedResultUrl": "https://docs.google.com/spreadsheets/d/1KrcTkhpSvGmtrefCIs3pdOtSJr9H8JQqFzrikFkDsM4/edit#gid=689245338"
        },
        "columns": {
          "mappingMode": "defineBelow",
          "value": {
            "Email": "={{ $fromAI(\"email\",\"the email address of the user gave you earlier\") }}",
            "Appointment Date": "={{ $fromAI(\"date\",\"the appointment date and time converted to Germany Timezone that the user comfirmed as his appointment\") }}",
            "Booking Status": "={{ $fromAI(\"status\",\"the status of the appointment which is either conformed or cancelled\") }}",
            "Time Zone": "={{ $fromAI(\"time_zone\",\"the time zone and location that the user tells you\") }}",
            "Name": "={{ $fromAI(\"name\",\"the name of the user\") }}",
            "Phone": "={{ $fromAI(\"phone\",\"the phone number that the user tells you. Always save the phone number with the country code that is associated with the time zone the user mentioned. But do not use a \"+\" sign and no space between the county code and the actual number.\") }}",
            "Intake Form": "={{ $fromAI(\"intake_form\",\"specific topics or issues the user likes to discuss during the appointment\") }}"
          },
          "matchingColumns": [
            "Email"
          ],
          "schema": [
            {
              "id": "Appointment Date",
              "displayName": "Appointment Date",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "Booking Status",
              "displayName": "Booking Status",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "Time Zone",
              "displayName": "Time Zone",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "Name",
              "displayName": "Name",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "Phone",
              "displayName": "Phone",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true
            },
            {
              "id": "Email",
              "displayName": "Email",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "Intake Form",
              "displayName": "Intake Form",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": false
            },
            {
              "id": "Newsletter Optin",
              "displayName": "Newsletter Optin",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "removed": true
            },
            {
              "id": "row_number",
              "displayName": "row_number",
              "required": false,
              "defaultMatch": false,
              "display": true,
              "type": "string",
              "canBeUsedToMatch": true,
              "readOnly": true,
              "removed": true
            }
          ],
          "attemptToConvertTypes": false,
          "convertFieldsToString": false
        },
        "options": {}
      },
      "type": "n8n-nodes-base.googleSheetsTool",
      "typeVersion": 4.5,
      "position": [
        1300,
        100
      ],
      "id": "b89ba368-2fa7-4080-925a-96ddb724a553",
      "name": "Google Sheets - Update Row"
    },
    {
      "parameters": {
        "sessionIdType": "customKey",
        "sessionKey": "={{ $('WhatsApp Trigger').item.json.contacts[0].wa_id }}",
        "contextWindowLength": 20
      },
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "typeVersion": 1.3,
      "position": [
        600,
        100
      ],
      "id": "d8106a27-6904-4ef0-8287-40e3d39380c3",
      "name": "Window Buffer Memory1"
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            {
              "id": "36f2a5d1-8889-40d5-b9bd-f4a374e5a97b",
              "name": "text",
              "value": "={{ $json.messages[0].text.body }}",
              "type": "string"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [
        640,
        -120
      ],
      "id": "65924dd9-70c7-4707-9a59-6c21aa81cfb5",
      "name": "Edit Fields"
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "gpt-4o"
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        460,
        100
      ],
      "id": "261223b7-6bd4-41c7-94aa-1b813d2c30c8",
      "name": "OpenAI Chat Model"
    },
    {
      "parameters": {
        "sendTo": "={{ $fromAI(\"email\",\"the email address of the user gave you earlier\") }}",
        "subject": "={{ $fromAI(\"subject\",\"the email subjectline that just is [New Booking] + Booking date and time converted to the user timezone that he mentioned earlier'\") }}",
        "message": "={{ $fromAI(\"body\",\"the email body that contains the message that the booking of the user was confirmed along with booking date, email, name, timezone, what user wants to discuss during the appointment\") }}",
        "options": {
          "bccList": "INSERT_YOUR_EMAIL"
        }
      },
      "type": "n8n-nodes-base.gmailTool",
      "typeVersion": 2.1,
      "position": [
        1420,
        60
      ],
      "id": "b331e984-f38b-4588-b579-4c119b4f9e05",
      "name": "Gmail - Send Confirmation User",
      "webhookId": "14db8167-92cc-42dd-aed1-22ee9e8e3b1e",
      "credentials": {
        "gmailOAuth2": {
          "id": "i3ib7rCPKDsAZb5u",
          "name": "Gmail account 4"
        }
      }
    },
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "0c5fffa3-c2ac-4fed-b2df-3df4532f9980",
        "options": {}
      },
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2,
      "position": [
        540,
        -560
      ],
      "id": "c88a5c99-6a70-4c2a-a2e2-ccac0818748f",
      "name": "Webhook",
      "webhookId": "0c5fffa3-c2ac-4fed-b2df-3df4532f9980"
    },
    {
      "parameters": {
        "modelId": {
          "__rl": true,
          "value": "gpt-4o",
          "mode": "list",
          "cachedResultName": "GPT-4O"
        },
        "messages": {
          "values": [
            {
              "content": "=Your job is to send a short reminder whatsapp message using the first name of  {{ $json.body.name }}. It should also mention that his appontment regarding \"{{ $json.body.topic }}\" will take place on {{ $json.body.appointmentDate }}. However that appointment time is based on the German time. Please convert the time to this correct timezone {{ $json.body.timezone }}. The current time is {{ $now }}. Sign off \"an\" as this is my name.\n\n#Rules: \n1) Only generate the raw message and never use any introduction like \"Certainly! Here's a short reminder message for Andreas:\"\n2) Do not use line breaks."
            }
          ]
        },
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "typeVersion": 1.8,
      "position": [
        740,
        -560
      ],
      "id": "ab831c21-cc6d-4b80-b306-a1cf4df18cb5",
      "name": "OpenAI"
    },
    {
      "parameters": {
        "rules": {
          "values": [
            {
              "conditions": {
                "options": {
                  "caseSensitive": true,
                  "leftValue": "",
                  "typeValidation": "strict",
                  "version": 2
                },
                "conditions": [
                  {
                    "leftValue": "={{ $json.messages[0].type }}",
                    "rightValue": "audio",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    },
                    "id": "0f591beb-efc8-4df1-9aaa-5146a92df7a0"
                  }
                ],
                "combinator": "and"
              },
              "renameOutput": true,
              "outputKey": "voice"
            },
            {
              "conditions": {
                "options": {
                  "caseSensitive": true,
                  "leftValue": "",
                  "typeValidation": "strict",
                  "version": 2
                },
                "conditions": [
                  {
                    "id": "28e2285d-c325-49ac-b949-540fd48a8bde",
                    "leftValue": "={{ $json.messages[0].type }}",
                    "rightValue": "text",
                    "operator": {
                      "type": "string",
                      "operation": "equals",
                      "name": "filter.operator.equals"
                    }
                  }
                ],
                "combinator": "and"
              },
              "renameOutput": true,
              "outputKey": "text"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.switch",
      "typeVersion": 3.2,
      "position": [
        120,
        -140
      ],
      "id": "9def7380-bf87-48fe-84a4-ec19818948a2",
      "name": "Switch"
    },
    {
      "parameters": {
        "url": "={{ $json.url }}",
        "authentication": "predefinedCredentialType",
        "nodeCredentialType": "whatsAppApi",
        "sendHeaders": true,
        "headerParameters": {
          "parameters": [
            {
              "name": "Authorization",
              "value": "Bearer INSERT_ACCESS_TOKEN"
            }
          ]
        },
        "options": {}
      },
      "type": "n8n-nodes-base.httpRequest",
      "typeVersion": 4.2,
      "position": [
        460,
        -320
      ],
      "id": "626494f7-6798-4ea6-a7de-686cc16389eb",
      "name": "HTTP Request",
      "credentials": {
        "whatsAppApi": {
          "id": "mcDeMettINzOlbYV",
          "name": "WhatsApp account 9 - app setter v3"
        }
      }
    },
    {
      "parameters": {
        "resource": "media",
        "operation": "mediaUrlGet",
        "mediaGetId": "={{ $json.messages[0].audio.id }}",
        "requestOptions": {}
      },
      "type": "n8n-nodes-base.whatsApp",
      "typeVersion": 1,
      "position": [
        300,
        -320
      ],
      "id": "2ed55c05-fc70-411f-a46f-796bddc9e419",
      "name": "WhatsApp Download Audio"
    },
    {
      "parameters": {
        "resource": "audio",
        "operation": "transcribe",
        "options": {}
      },
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "typeVersion": 1.8,
      "position": [
        620,
        -320
      ],
      "id": "5dfc07bd-bdda-4cf8-a38c-bb8630ac737b",
      "name": "Transcribe Audio"
    },
    {
      "parameters": {
        "operation": "send",
        "phoneNumberId": "557712827430663",
        "recipientPhoneNumber": "={{ $('Webhook').item.json.body.phone }}",
        "textBody": "={{ $('OpenAI').item.json.message.content }}",
        "additionalFields": {},
        "requestOptions": {}
      },
      "type": "n8n-nodes-base.whatsApp",
      "typeVersion": 1,
      "position": [
        1120,
        -560
      ],
      "id": "2f82b4c7-2d1c-4a33-8ee2-202f9235448d",
      "name": "WhatsApp Reminder"
    },
    {
      "parameters": {
        "operation": "send",
        "phoneNumberId": "={{ $('WhatsApp Trigger').item.json.metadata.phone_number_id }}",
        "recipientPhoneNumber": "={{ $('WhatsApp Trigger').item.json.messages[0].from }}",
        "textBody": "={{ $json.output }}",
        "additionalFields": {},
        "requestOptions": {}
      },
      "type": "n8n-nodes-base.whatsApp",
      "typeVersion": 1,
      "position": [
        1160,
        -120
      ],
      "id": "c4d08b1d-7198-4ea3-9ce2-ec1b42920320",
      "name": "WhatsApp Response"
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "={{ $json.text }}",
        "options": {
          "systemMessage": "=You are a helpful AI assistant.\n\n# You have access to these tools:\n\n1) A Google Calendar tool that allows you to create, reschedule, and delete events in the calendar.\n\n2) Several Google Sheet tools:\n- \"Google Sheet - Add Row\": allows you to add new rows to a Google Sheet\n- \"Google Sheet - Update Row\": allows you to update rows in a Google Sheet\n- \"Google Sheet - Read\": allows you to read content of the Google Sheet\n\n3) Gmail - Send Confirmation User: allows you to send a confirmation email to the user after the booking is confirmed.\n\nThe current time and date is the following German Time Zone: {{ $now }}.\n\n# Your Task:\n\n1) Start by asking the user:  \n\"Would you like to book an appointment?\"\n\nIf the user responds with yes, begin collecting their contact information.\n\nYou must always collect the contact information in the following strict order:\n\n- First: Email address  \n  → This will be used as the unique identifier to match the row in the Google Sheet.  \n  → After receiving the email address, immediately check if a row with this email already exists using \"Google Sheet - Read\".  \n    - If found, use \"Google Sheet - Update Row\" to update the existing row.  \n    - If not found, use \"Google Sheet - Add Row\" to create a new one with the email.\n\n- Then: Full name  \n- Then: Phone number  \n- Then: Location or time zone\n\n❗ Only ask for one piece of information at a time.  \n❗ Wait for the user's reply before asking the next question.  \n❗ After every response, immediately update the Google Sheet using \"Google Sheet - Update Row\", matched by the email address.\n\n2) You must always store all user information (email address, name, phone number, and location/time zone) in the Google Sheet.\n\n2.5) After collecting the location/time zone, ask the user:  \n\"What would you like to discuss during your appointment?\"\n\n- Wait for the user's response.  \n- Then immediately update the same row in the Google Sheet using \"Google Sheet - Update Row\", matched by the email address.  \n- Save the user’s response as the appointment topic or notes.\n\n3) Once the user's contact information and discussion topic have been collected, you must offer 5 available time slots for booking.\n\n- Use the assistant’s local time zone (German time) to determine availability.\n\n- The available office hours are in German Time zone:\n  - Monday to Friday\n  - Morning block: 09:00–12:00\n  - Afternoon block: 13:00–17:00\n  - (Never offer times between 12:00 and 13:00)\n\n- Do not offer any time slots that fall outside of these hours in German time, even if they appear to be valid in the user’s local time zone.\n\n- When a user requests a time range (e.g., \"afternoon\"), follow this logic:\n  1. Understand the time range based on the user's time zone.\n  2. Convert that time range into German time.\n  3. Only offer time slots that match both the user's intent and fall within the German office hours.\n\n- You must check that a full 60-minute block is available:\n  - The start and end time must not conflict with any existing calendar event.\n  - The time slot must begin at least 24 hours in the future.\n\n- Always offer the next 5 available 60-minute time slots that meet the above criteria.\n\n- Only display the time slots in the user’s time zone.  \n  → Do not mention German time anywhere in your response.  \n  → Do not include time conversions in parentheses.\n\n- Present the time slots in a simple, friendly format like but remember availabnle times you find in my Google Calendar are in German time zone. So you must always only show the user the avialable times converted to his timezoone:  \n  \"Here are the next available time slots in your local time zone:  \n  - Thursday at 10:00 AM  \n  - Friday at 11:30 AM  \n  ...\"\n\n- If no valid slots match the user's requested period (e.g., afternoon), politely inform the user and offer the next closest options.\n\n- Never mention unavailable or already booked time slots. Only show the free ones. Do not include notes, reminders, or explanations about other bookings.\n\n❗ You must not manually calculate or estimate time zone offsets.  \n→ Use the Google Calendar tool to convert and format times.  \n→ Always respect daylight saving time (DST) in both the user's and assistant's time zone.\n\n4) When the user confirms a preferred date and time, you must:\n\n- Create an event in the Google Calendar at the selected time.\n\n- Appointments should always be scheduled for 60 minutes unless the user specifies otherwise.\n\n- Do not create a new row in the Google Sheet.\n\n- Instead, use the tool \"Google Sheet - Update Row\" to update the existing row corresponding to the user (matched by email address) and add the selected date and time as the confirmed appointment.\n\n- The appointment time saved in the Google Sheet must always be in the assistant’s local time (German time) — never in the user's time zone.\n\n- After the booking is confirmed, send a confirmation email to the user using the \"Gmail - Send Confirmation User\" tool.\n\n- The email must include:\n  - The confirmed appointment date and time (in the user's local time zone)\n  - The user's name and topic of discussion\n  - A short, friendly message confirming the booking\n\nOnly send the confirmation email after the calendar event has been created and all data has been stored in the Google Sheet.\n"
        }
      },
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 1.7,
      "position": [
        820,
        -120
      ],
      "id": "605692f8-9d6a-4a45-aeff-05040a74c986",
      "name": "AI Agent - Books Appointments"
    }
  ],
  "connections": {
    "Calendar Create": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Calendar Read": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Google Calendar": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "WhatsApp Trigger": {
      "main": [
        [
          {
            "node": "Switch",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Google Sheets - Read": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Google Sheets - Add Row": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Google Sheets - Update Row": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Window Buffer Memory1": {
      "ai_memory": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "Edit Fields": {
      "main": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Gmail - Send Confirmation User": {
      "ai_tool": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "Webhook": {
      "main": [
        [
          {
            "node": "OpenAI",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI": {
      "main": [
        [
          {
            "node": "WhatsApp Reminder",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Switch": {
      "main": [
        [
          {
            "node": "WhatsApp Download Audio",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Edit Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "HTTP Request": {
      "main": [
        [
          {
            "node": "Transcribe Audio",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "WhatsApp Download Audio": {
      "main": [
        [
          {
            "node": "HTTP Request",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Transcribe Audio": {
      "main": [
        [
          {
            "node": "AI Agent - Books Appointments",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent - Books Appointments": {
      "main": [
        [
          {
            "node": "WhatsApp Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "e44f898e-df60-4066-b7e8-cd6cb9e410ba",
  "meta": {
    "templateCredsSetupCompleted": true,
    "instanceId": "7ff6625f0127f3e9a7865e3493009de1c48f57dc5ed87def3ae3316be7f6b238"
  },
  "id": "37utJbMYN17CDLAE",
  "tags": []
}