> ## Documentation Index
> Fetch the complete documentation index at: https://docs.waverunnerai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Calendar

> Connect Cal.com or Google Calendar so your agent can book appointments during calls and pass booking data to post-call workflows.

Wave Runner supports AI-powered appointment booking during live calls. When you connect a calendar, your agent offers available time slots to callers and confirms bookings without any human involvement. Once a booking is made, the appointment details are available as variables in post-call workflows.

Two calendar providers are supported: **Cal.com** (API key) and **Google Calendar** (OAuth).

## Connecting Cal.com

<Steps>
  <Step title="Generate a Cal.com API key">
    In your Cal.com account, go to **Settings → Developer → API Keys** and create a new API key. Copy the key — it starts with `cal_live_`.
  </Step>

  <Step title="Open the integrations page in Wave Runner">
    Go to **Settings → Integrations** and find the **Calendar** section.
  </Step>

  <Step title="Click Connect Calendar">
    Click **Connect Calendar** on the calendar card. A dialog opens.
  </Step>

  <Step title="Select Cal.com as the provider">
    In the **Calendar Provider** dropdown, select **Cal.com**.
  </Step>

  <Step title="Enter your credentials">
    Fill in the following fields:

    * **Label** — a name for this connection, e.g. `Sales Booking Calendar`
    * **API Key** — paste your `cal_live_...` key
  </Step>

  <Step title="Save the connection">
    Click **Connect Calendar**. The connection appears in the calendar card with an **Active** badge.
  </Step>
</Steps>

<Note>
  The event type is selected when you configure the individual agent, not here. You can connect multiple Cal.com accounts and assign different event types to different agents.
</Note>

## Connecting Google Calendar

<Steps>
  <Step title="Open the integrations page in Wave Runner">
    Go to **Settings → Integrations** and find the **Calendar** section.
  </Step>

  <Step title="Click Connect Calendar">
    Click **Connect Calendar** on the calendar card.
  </Step>

  <Step title="Select Google Calendar as the provider">
    In the **Calendar Provider** dropdown, select **Google Calendar**.
  </Step>

  <Step title="Authorize with Google">
    Click **Connect Calendar** and complete the Google OAuth flow. Grant Wave Runner permission to view and manage your calendar events.
  </Step>

  <Step title="Confirm the connection">
    Google redirects you back to Wave Runner. The calendar card shows the connected Google account with an **Active** badge.
  </Step>
</Steps>

## How agents book appointments

Once a calendar is connected, enable booking on a per-agent basis:

1. Open or create an agent under **Assistants**.
2. In the agent configuration, go to the **Calendar** tab.
3. Select the connected calendar and, for Cal.com, choose the event type.
4. Save the agent.

During a call, when the conversation reaches a booking intent, the agent queries your calendar for available slots in real time and presents options to the caller. When the caller confirms a time, the agent creates the booking and receives confirmation back into the call context.

<Tip>
  Set a reasonable buffer time on your Cal.com event type (e.g. 15 minutes between bookings) so the agent does not offer back-to-back slots.
</Tip>

## Appointment variables

After a call where a booking was made, the appointment data is available in post-call workflows.

| Variable                         | Description                                            |
| -------------------------------- | ------------------------------------------------------ |
| `{appointment.status}`           | Booking status: `confirmed`, `pending`, or `cancelled` |
| `{appointment.start_time}`       | Full ISO 8601 start datetime                           |
| `{appointment.appointment_date}` | Human-readable appointment date                        |
| `{appointment.timezone}`         | Timezone of the booked slot                            |
| `{appointment.calendar}`         | Name of the connected calendar                         |

### Example: send a confirmation SMS after booking

Add an **End of Call** trigger, a **Condition** node checking `{appointment.status} == 'confirmed'`, then a **Send SMS** node:

```text theme={null}
Your appointment is confirmed for {appointment.appointment_date} at {appointment.start_time} ({appointment.timezone}). Reply STOP to cancel.
```

## Testing calendar booking

<Steps>
  <Step title="Start a test call">
    Open your agent and click **Test Call** to start a browser-based call.
  </Step>

  <Step title="Ask the agent to book an appointment">
    Say something like "I'd like to schedule a call." The agent responds with available time slots from your connected calendar.
  </Step>

  <Step title="Confirm a slot">
    Select a time. The agent confirms the booking and a new event appears in your Cal.com or Google Calendar within a few seconds.
  </Step>

  <Step title="Check the workflow variables">
    If you have a post-call workflow connected to this agent, open the **Executions** log and confirm `{appointment.status}` and the other appointment variables are populated correctly.
  </Step>
</Steps>

<Warning>
  Test bookings create real calendar events. Delete the test event after testing, or use a separate Cal.com event type or Google Calendar dedicated to testing.
</Warning>

## Removing a calendar connection

<Steps>
  <Step title="Open the integrations page">
    Go to **Settings → Integrations**.
  </Step>

  <Step title="Click Configure on the calendar card">
    The dialog lists all connected calendar accounts.
  </Step>

  <Step title="Click the trash icon next to the connection">
    Confirm the removal. Wave Runner immediately stops using that connection for booking.
  </Step>
</Steps>

<Note>
  Removing a calendar connection does not cancel existing bookings. Agents that relied on the removed connection will fail to book new appointments until you connect a replacement and update the agent configuration.
</Note>
