Loyalty turns one-time visitors into repeat patients. The patient earns cashback on every paid invoice, redeems it on the next, and may also collect points, gift vouchers, or referral credits. The system holds all of this on a patient wallet ledger, the accountant sees it as a liability until redeemed, and the marketing team sees it as a retention lever. This article walks the working flows.

Coming soon. A Platinum tier, tier downgrade, automatic tier-up communications, and a points-vs-cashback toggle are on the roadmap. Today: three tiers (Bronze / Silver / Gold), upgrades only, and a single cashback rate (not a tier multiplier).

Where it lives#

  • Settings → Cashback & loyalty: the rules.
  • Patient profile → Wallet: this patient's balance and ledger.
  • Sales → invoice payment: redeem during checkout.
  • Reports → Loyalty: program-wide stats.

What is stored on the wallet#

  • Cashback balance: AED earned from past paid invoices.
  • Points balance: program-specific points if you run a points program.
  • Gift voucher: amount paid for by someone else as a gift, or issued by the clinic.
  • Refund credit: refunds issued as credit instead of cash.
  • Referral credit: earned for referring a friend who converts.
  • All shown in one wallet, totalled at the top, breakdown by category below.

Of the three buckets, only non-cashable is a live payment method at checkout today. Cashable and points accumulate per the cashback / loyalty policy but are not yet spendable on invoices.

Cashback rules#

The rule shape#

  • "Earn X% of every paid invoice as cashback."
  • X is a single global rate today, not tier-multiplied. Tier perks live as a service-wide discount percentage and a tier-specific points-expiry window (see tiered structure below).
  • Earn happens at Paid status. Refund reverses the earn.

Example tiered structure#

  • Bronze (entry, automatic): the default cashback rate.
  • Silver and Gold: each requires all three of total points, completed referrals, and completed sessions. Falling short on any one means the customer stays in the current tier.
  • Tier perks come as a service-wide discount percentage (default Silver 10%, Gold 20%) and tier-specific points expiry (Bronze 180 days, Silver 365, Gold 540), not as a cashback multiplier. Cashback is a single rate on cashback settings.
  • Tier upgrades are automatic on the next qualifying event. There is no auto-downgrade and no automated tier-up notification yet.

Cashback expiry#

  • Points use the configured tier expiry window. Cashback uses the separate wallet-expiry setting; do not assume it shares the points expiry date.
  • A reminder fires when an item is inside the 7-day warning window so the patient gets one nudge before losing it.
  • Expired balance is released to breakage revenue on the income statement.

How expiry actually runs#

A daily Celery job at 00:00 walks every wallet transaction and every point transaction that has hit its expiry. Expired items are zeroed out and the bucket totals recompute. A second daily lifecycle sweep emits a "points expiring in 7 days" notification for items inside the warning window. Points expiry windows are tier-specific and read live from loyalty settings.

Anniversary and birthday rules#

The daily lifecycle sweep emits two patient-facing events:

  • Anniversary. Once a year on the customer's signup date, the configured anniversary points credit to their wallet and an anniversary notification fires.
  • Birthday. On the customer's birthday, a one-day discount eligibility is opened. The discount percentage comes from loyalty settings (default 50%). It does not auto-apply to a future invoice; reception applies it at checkout.

The same sweep also emits churn-risk signals for Silver and Gold customers without a booking in 90 days, so marketing can re-engage them.

Redemption at checkout#

The flow#

  1. Patient is at the desk with an unpaid invoice.
  2. Reception opens Take payment.
  3. If the patient has wallet balance, "Apply wallet" appears.
  4. Reception enters the redeem amount (up to balance, up to max-redeem-per-invoice cap).
  5. Wallet line subtracts from invoice total. Patient pays the rest by cash, card, etc.
  6. Wallet ledger entry: redeem of AED N against invoice X.

Redemption caps#

  • Tenants typically cap "max % of invoice redeemable by wallet" (e.g. 50%). Prevents patient turning every visit free.
  • Some service categories excluded from redemption (e.g. cannot use cashback on a package, only on individual sessions).
  • Configurable per tenant.

Voucher and gift card redemption#

  • Patient (or gift recipient) enters the voucher code at checkout.
  • Voucher balance applies to the invoice as a payment line, not as a discount.
  • Distinct from cashback because the voucher's underlying funding was cash received earlier (from the gifter or the clinic).

Referral credit#

How it works#

  1. Patient invites a friend via a referral link (per-patient unique code).
  2. Friend signs up as a new patient using the code.
  3. Friend completes their first paid session.
  4. Both patient and friend receive a referral credit (configurable, e.g. AED 100 each).
  5. Credit lands on each wallet, redeemable on next invoice.

Anti-abuse, what we catch and what we don't#

Referrals only count once the friend has a paid invoice, not just a signup. The platform blocks a customer from referring themselves. It does not yet block:

  • The same person creating a second account on a different phone number and self-referring.
  • A referrer claiming the reward on a referred friend whose first paid invoice is suspiciously low.
  • Multiple devices or shared IPs.

If you suspect abuse, review the referral list under the patient drawer and revoke the reward manually. The wallet audit log captures the revocation.

Gift vouchers#

Selling#

  • Sales → + New sale → "Gift voucher".
  • Pick amount, recipient (existing patient or "to be assigned").
  • Buyer pays. Invoice issues as normal, payment to bank or cash.
  • Voucher code emails to recipient (or printed for in-person handover).
  • Accounting: cash to bank, deferred revenue liability for the voucher value.

Redemption#

  • Recipient (already a patient or registers as new) enters the code at checkout.
  • Voucher balance applies as a payment line.
  • Revenue recognises on redemption (since service was rendered).
  • Voucher liability reduces by the redeemed amount.
  • Voucher expires per the validity rule (default 12 months from purchase).

Points programs (optional, advanced)#

  • Some clinics prefer "points" abstraction: earn 1 point per AED spent, 100 points = AED 10 credit.
  • Points are mathematically equivalent to cashback, the marketing value is the framing.
  • Configure conversion rate, tier earn multipliers, redemption thresholds.
  • Cannot run cashback and points simultaneously, pick one.

Accounting treatment#

Cashback#

  • At earn: debit "cashback expense" (or a contra-revenue line), credit "cashback liability".
  • At redeem: debit "cashback liability", credit the invoice receipt (effectively the patient is paying with their own prepaid credit).
  • At expiry: debit "cashback liability", credit "breakage revenue".

Vouchers and gift cards#

  • At sale: debit cash, credit "gift voucher liability".
  • At redeem: debit "gift voucher liability", credit revenue (sale recognised).
  • At expiry / breakage: debit "gift voucher liability", credit "breakage revenue" (account 415000).

The breakage sweep runs after gift_card_breakage_months from the gift card's issuance (default 24 months). After that, the unredeemed balance is no longer redeemable and posts as breakage revenue. Set the breakage period to 0 in loyalty settings to disable the sweep.

Why this matters#

The wallet balance is a real liability on the balance sheet. Patients can demand redemption. Accountant has to know what is owed at month-end. Misclassifying cashback as a discount understates revenue, misclassifying voucher sale as revenue overstates it. The system gets this right by default, never override.

Communication and engagement#

  • Earn notification: optional message after each paid invoice ("You earned AED N").
  • Balance reminder: monthly summary message ("You have AED X waiting").
  • Expiry warning: T-30 and T-7 nudges.
  • Tier upgrade: congratulatory message at threshold crossing.
  • Referral invite: in-app prompt after a satisfied visit.
  • All gated on marketing consent. Quiet-hours enforcement is on the roadmap; schedule upstream triggers during business hours as a workaround.

Reports#

  • Total liability: balance sheet number.
  • Earn vs redeem rate: per period, by tier.
  • Breakage rate: % of earned balance that expires.
  • Tier mix: how many patients in each tier.
  • Referral conversion: invites sent, redemptions, revenue from referred patients.
  • Voucher sell-through: sold this month, redeemed this month.
  • LTV by tier: lifetime spend of gold vs silver vs bronze patients, the ROI of running the program.

KPIs that matter#

  • Repeat-visit rate of cashback redeemers vs non-redeemers. Big multiplier is the program working.
  • Breakage rate: too high means patients are not engaging, too low means you are paying out too generously.
  • Redemption rate: % of earned that gets used. 60-80% is healthy.
  • Net contribution: revenue from redeemers minus cashback cost minus expired-not-released. Positive means the program funds itself.

Who can do what#

  • Reception / sales: see balance, apply at checkout within cap, view ledger.
  • Manager: adjust balance for gestures within an authorised band, with reason.
  • Owner: change rules, override caps, write off liability.
  • Accountant: view liability, ledger, reports, cannot adjust balances.

Common mistakes#

  • Applying cashback as a discount line: breaks revenue recognition. The system treats it as a payment-side line, do not work around.
  • No expiry: liability grows forever, balance sheet bloat, no urgency to redeem.
  • Too-generous earn + no cap on redemption: patient comes in once, free forever.
  • Forgetting tier upgrade comms: patients do not know they earned a higher rate, do not feel the loyalty.
  • Mixing voucher and cashback ledger: separate categories. Vouchers were paid for, cashback was earned. Different accounting.
  • Manual balance edits without reason: audit is blind. Always reason-required.

How loyalty connects to the rest of the system#

  • Patients: wallet hangs off patient.
  • Invoices and payments: earn at Paid, redeem at checkout.
  • Refunds: reverse earn.
  • Marketing / automations: reminders, tier upgrade, referral invites.
  • Accounting: liability on balance sheet, breakage on income statement.
  • Reports: program effectiveness.
  • Patient portal: patient sees their own balance.