A website chat that books calls on my own calendar

The problem
My booking page is Fantastical Openings. It works well for anyone who clicks through and picks a time. But it has no API, meaning no way for another program to check my openings or create a booking. So a chatbot can’t book through it.
Off-the-shelf website chat tools can book a call right inside the chat. I wanted the same thing, under my own control. It also doubles as a working demo of the FAQ and booking chatbot I set up for businesses.
What I built
A chat assistant on my website named Sage. It introduces itself as Sage and says plainly that it’s an AI, not me. It talks about me in the third person.
You open it from a tab on the right edge of the screen labeled “Ask Sage”, a little above the middle rather than in the usual bottom-right corner. The tab gives a small nudge until someone opens it. The chat itself only loads when a visitor opens it, so it doesn’t slow down the rest of the page.
Sage answers from my own website. Every night at 3:00 AM it re-reads the About, Services, How it works and FAQ pages, plus the case studies and blog indexes. When I change something on the site, Sage knows it the next day, and new case studies and blog posts become something it can link to without me doing anything. If the answer isn’t on the site, it says so and offers a call, email or my phone number instead of guessing.
Replies are kept short, one to three sentences, and usually end with one link to the page that fits best: a service, a case study or a blog post.
When someone wants to talk, it:
- Offers open times for a free 20-minute call.
- Asks whether they want phone or Zoom. Phone is my preference and the default, so it asks for a phone number.
- Reads the details back and books only after the visitor confirms.
- Puts the call on my work calendar and sends a push notification to my phone with the time, name, contact info and topic.
It never tells someone they’re booked unless the booking step confirms it. If the notification fails, the booking still stands.
The rules live in code
The AI runs the conversation. Code handles the calendar and the rules, so the AI can’t offer a time the code didn’t approve. Calls are 20 minutes on weekdays, between 24 hours and 14 days out, with one upcoming booking per email address.
It checks three of my calendars, one for work and two personal ones, for conflicts. Events marked Busy block a time. Events marked Free, like all-day reminders, don’t. Repeating events count too. If any of the three can’t be read, it shows no openings at all rather than risk a double booking. Right before it writes the event, it checks once more that the slot is still open.
Fantastical reads the same calendars, so a call booked in the chat shows up there right away, and my Openings page won’t offer that time to anyone else.
How it fits together
- n8n, an automation tool, runs on a small server I rent from Hostinger. The screen where I build and edit the automation is private, reachable only from my own devices over Tailscale, a private network.
- The chat address sits behind nginx, a web server that passes only the chat itself through to the internet.
- iCloud Calendar. n8n has no built-in connection for iCloud, so the automation talks to the calendar directly over CalDAV, the standard way calendar apps read and write events.
- Claude, Anthropic’s AI model, in its smaller and faster Haiku version, handles the conversation.
- Pushover sends notifications to my phone.
Keeping cost and abuse in check
A public chat box running on a paid AI model can run up a bill if nobody puts limits on it. So it has some, and it only accepts requests that come from my own website.
The daily summary arrives at 8 PM: messages, conversations, bookings and anything that was blocked. I looked at adding a captcha (Cloudflare Turnstile, the “prove you’re human” check) and held it back on purpose. If the alerts show abuse, it goes in.
What I tested
I tested it against my real calendars:
- A real meeting on my calendar blocked the time slot that overlapped it.
- A test booking showed up in Fantastical.
- A second booking with the same email address was refused.
- The push notification arrived on my phone with the app closed.
I deleted the test events afterward.
A later test caught a gap with cancellations, and it’s now fixed and tested: if I delete a booking in Fantastical, that email address can book again, and if iCloud can’t be reached during that check, it refuses rather than guess.
The honest limits
- Holidays. It doesn’t know about them. I block those by hand with a Busy event.
- Zoom links. For now, I send them myself.
- The AI can still misread a question. That’s why the booking rules live in code instead of in the AI’s instructions. A misread question can mean an unhelpful answer. It can’t put a call outside my hours or on top of another meeting.
Where it stands
Sage is live on my site. It did go down briefly once, because the server relied on a personal setup of mine to look up web addresses. It now has its own.
The “Ask Sage” tab is the quickest way to see how this would work on a business website, where the rules would be yours: your hours, how long a job takes and how much notice you need. I wrote more about why I built it this way.
Header image created with Grok.