Sample case study · Clinic · 6 min read

WA Concierge: designing a booking agent for clinics

A sample case study designing a WhatsApp agent that understands prospective patient intent, checks therapist calendar slots, creates bookings, and hands off out-of-rule cases to clinic staff.

Sample project designed to show our workflow. Not a client project.

Problem

Small clinics receive WhatsApp messages all day, including at night, and a single admin has to answer the same questions while managing the schedule.

What we built

An agent that understands message intent, checks the therapist calendar, creates bookings, sends confirmations and reminders, and hands off out-of-rule cases to staff.

01. Business context

For many small skincare, dental, and physiotherapy clinics in South Tangerang and South Jakarta, WhatsApp is not a secondary inquiry channel—it is the main front desk. Prospective patients rarely fill out multi-step web forms to book an appointment. Instead, they send short messages asking for basic treatment price ranges, checking whether Saturday afternoon still has an open slot, or asking to move their session because of traffic.

We built WA Concierge as a CHESTAADOTCOM sample project to test firsthand how a conversational agent behaves when connected to a real therapist calendar and CRM table. Rather than building a slide-deck demo that only handles tidy one-line prompts, we wanted to test everyday chat patterns filled with abbreviations, mid-conversation changes of mind, and strict boundaries between tasks that may be completed automatically and tasks that must be handed over to a human admin.

02. Problem

Small clinics receive WhatsApp messages all day, including at night, and a single admin has to answer the same questions while managing the schedule. During daytime clinic hours, that same admin is also greeting walk-in patients at the front desk, preparing registration forms, and processing payments. As a result, incoming WhatsApp messages often pile up for thirty to sixty minutes before receiving a reply.

When messages arrive after eight in the evening—right when many prospective patients finish work and start planning weekend treatments—they sit unread until the next morning. By the time the admin replies the following day, some prospective patients have already booked elsewhere or moved on. Meanwhile, rigid menu-tree auto-replies often frustrate callers because they force people to type numbers repeatedly without telling them whether their preferred hour is actually open.

03. Approach

Our approach starts from one strict rule: the language model is only responsible for understanding message intent and drafting a polite reply, while all pricing, treatment duration, and slot availability data must be fetched from written records via structured tool calls. The agent is never allowed to guess open hours or invent treatment details outside the approved catalog table.

We also designed human handover from day one rather than bolting it on later. Before writing prompts or connecting calendar APIs, we separated incoming messages into two clear categories: routine scheduling inquiries that the agent may complete on its own, and sensitive questions that must immediately pause automated replies and notify the clinic admin.

04. System flow

Every incoming WhatsApp message passes through six ordered steps from intent understanding to CRM logging. If during the intent-reading stage the system detects a medical question, a post-treatment complaint, or a custom request outside standard catalog rules, the flow immediately branches to Staff handover together with a concise conversation summary.

05. Implementation

At the messaging layer, WA Concierge receives webhooks from the WhatsApp Business Platform and maintains per-phone conversation state with a clear session window. When a prospective patient sends three short chat bubbles within five seconds—a very common habit on WhatsApp—a short debounce buffer combines those messages first so the agent responds to the full context instead of firing three separate replies.

For schedule verification, we built three structured tools: a treatment catalog reader (`get_treatment_catalog`), an open-slot checker (`check_available_slots`), and a reservation writer (`create_booking_slot`). Each tool validates parameters against a strict schema before touching the calendar. For example, if a treatment requires 60 minutes plus a 15-minute room preparation buffer, the slot checker automatically calculates a 75-minute window before reporting that a time slot is open.

06. Design targets

Because WA Concierge is a sample project we built to test workflow reliability before deploying for clients, all indicators below are engineering design targets, not measured results from a client clinic.

Design target, not client results
  • Initial response time: < 10 seconds (Target for busy hours and evening messages)
  • Human handover: Automatic with summary (When a question falls outside defined rules)
  • Schedule reminder: H-1 via WhatsApp (Reduces missed appointments)

07. Design notes

The most important part of designing an agent for a clinic is not making the agent sound clever—it is defining strictly what the agent must never do. In WA Concierge, we enforced three hard boundaries: the agent never gives medical advice or diagnoses skin/health conditions, the agent never promises discounts or alters prices outside the official catalog table, and the agent never cancels appointments unilaterally less than 12 hours before a session without admin approval.

Restricting the agent in this way comes with a deliberate trade-off. Roughly twenty to thirty percent of conversations that involve specific clinical consultations still require a human reply. Yet that trade-off is exactly what keeps clinic operations safe: human admins can focus their full attention on patients who need personal consultation, while repetitive questions about open hours and routine slot bookings are handled cleanly.