L
Leaphealth - OSDocs

Booking an Appointment

Complete booking flow — draft holds, payment types, approval workflow, status lifecycle, and config snapshots.

Booking an Appointment

This page explains the complete appointment booking flow — from searching for a slot to getting a confirmed appointment. The flow depends on your hospital's configuration: some appointments confirm instantly, others go through a hold-and-pay or approval step.

Appointment Statuses

Every appointment moves through a defined set of statuses. Understanding these helps you know where an appointment is in the process.

Status

What It Means

Draft

Slot is held temporarily. Patient must confirm or pay within the hold window, or it expires automatically.

Pending Approval

Patient has confirmed, but the appointment requires staff/doctor approval before it's final.

Confirmed

Appointment is locked in. The slot is reserved and the patient can check in on the day.

Rejected

A staff member or doctor rejected the pending appointment. The patient is notified.

Expired

The draft was not confirmed within the hold window. The slot is released back to the pool.

Cancelled

The appointment was cancelled by the patient, staff, or system.

Checked In

The patient has arrived and checked in at the centre.

Completed

The consultation or service is finished.

No-Show

The patient did not show up and the grace period has passed.

Rescheduled

This appointment was replaced by a new one at a different time. This is a terminal status on the old appointment.

Status Flow

Not every status can transition to every other status. Here are the allowed paths:

From

Can Move To

Draft

Confirmed, Pending Approval, Expired, Cancelled

Pending Approval

Confirmed, Rejected, Cancelled

Confirmed

Cancelled, Checked In, Rescheduled, No-Show

Checked In

Completed, No-Show

Rejected, Expired, Cancelled, Completed, No-Show, and Rescheduled are terminal statuses — no further transitions are possible.


The Hold System (Draft Appointments)

When a patient selects a slot, the system creates a draft appointment and holds the slot for a configurable time window. During this hold:

  • The slot is reserved — other patients cannot book it
  • The patient must confirm (and optionally pay) within the hold window
  • If the hold expires, the appointment is automatically marked as Expired and the slot is released

Setting

What It Controls

Example

Hold Duration

How long the slot is held before expiry

15 minutes, 30 minutes, 1 hour

Max Active Bookings

How many active appointments a patient can have at once

3 (counts Draft, Pending Approval, Confirmed, Checked In)

Automatic Expiry

A background job periodically checks for expired drafts and releases their slots. You don't need to manually clean up expired appointments.

Payment Types

Your hospital can configure what payment is required before an appointment is confirmed:

Payment Type

What's Required

When to Use

None

No payment needed. Appointment confirms immediately after booking.

Free clinics, internal staff appointments, walk-in conversions

Token

A small fixed deposit (token amount) is collected upfront.

Low commitment — e.g. Rs 100 token to hold the slot

Advance

A percentage of the consultation fee is collected upfront.

Moderate commitment — e.g. 25% advance payment

Full

The entire consultation fee must be paid before confirmation.

Premium services, specialist consultations

The payment type is configurable at the tenant, centre, or service level. If set to None, the hold-and-pay step is skipped entirely.


Approval Workflow

Some appointments require manual approval before they are confirmed. When approval is required:

  1. Patient books and pays (if required) → status becomes Pending Approval
  2. Staff or doctor reviews the appointment
  3. If approved → status moves to Confirmed and patient is notified
  4. If rejected → status moves to Rejected with a reason, and refund is initiated if payment was made

Approval Timeout

If nobody approves or rejects within the configured timeout window, the system takes an automatic action:

Timeout Action

What Happens

Auto-Approve

The appointment is automatically confirmed after the timeout. Useful for low-risk appointments.

Cancel with Refund

The appointment is automatically cancelled and any payment is refunded. Protects patients from being stuck waiting.

Setting

Example

Approval Required

Yes or No (per service or centre)

Timeout Hours

24 hours, 48 hours

Timeout Action

Auto-Approve or Cancel with Refund


Booking Flow Summary

The complete flow depends on configuration:

Flow 1: No Payment, No Approval (Simplest)

  1. Patient selects slot → Draft created
  2. Patient confirms → Confirmed immediately
  3. Done — patient receives confirmation notification

Flow 2: Payment Required, No Approval

  1. Patient selects slot → Draft created (slot held)
  2. Patient pays (token/advance/full amount)
  3. Payment confirmed → Appointment moves to Confirmed
  4. If hold expires before payment → Expired, slot released

Flow 3: Payment + Approval Required

  1. Patient selects slot → Draft created (slot held)
  2. Patient pays → Appointment moves to Pending Approval
  3. Staff/doctor reviews → Approved or Rejected
  4. If approved → Confirmed. If rejected → Rejected + refund initiated
  5. If timeout reached → Auto-Approve or Cancel with Refund (per config)

Config Snapshot

When an appointment is created, the system takes a snapshot of the current booking configuration (cancellation policy, refund rules, approval settings). Even if the config changes later, the appointment uses the rules that were active at the time of booking. This protects patients from retroactive policy changes.

What's Next?

Learn about changing or cancelling appointments in Rescheduling & Cancellation, or see how check-in works in Check-in & Completion.

bookingappointmentdraftpaymentconfirmation

Last updated on

On this page