Prompt
I'm building a consulting platform with deposits and cancellations
Latest observation
Oct 15, 2026
OpenAI APIWeb search: off
Great use case. For a consulting platform with deposits and cancellations, the main thing is to design the money flow and refund rules clearly before you code.
Core concepts to define
1. Booking states
A simple lifecycle helps a lot:
- Draft — user is filling out the booking
- Pending deposit — booking created, payment not completed
- Confirmed — deposit paid, session reserved
- Completed — consulting session happened
- Cancelled — booking canceled
- Refunded — money returned, fully or partially
- No-show — client didn’t attend, if you enforce that
2. Payment model
Decide whether you want:
- Full payment upfront
- Deposit only
- Deposit + remaining balance later
- Subscription / retainer model
For deposits, common patterns are:
- Fixed deposit, e.g.
$50 - Percentage deposit, e.g.
20% - Non-refundable deposit
- Refundable deposit under certain conditions
3. Cancellation policy
You should define:
- How long before the session a client can cancel for a full refund
- Whether deposit is refundable
- What happens if the consultant cancels
- Whether rescheduling is allowed instead of refunding
- Cutoff times, e.g.:
- More than 48h before: full refund
- 24–48h before: 50% refund
- Less than 24h: no refund
Recommended workflow
Booking flow
- Client selects consultant and time slot
- Platform creates booking in
pending_deposit - Client pays deposit
- Booking becomes
confirmed - Before session, client may cancel or reschedule based on policy
- After session, client pays remaining balance if applicable
Cancellation flow
When cancellation is requested:
- Check booking state
- Check time until session start
- Apply cancellation policy
- Calculate refund amount
- Trigger payment refund if needed
- Update booking status
Data model suggestion
Bookings table
idclient_idconsultant_idscheduled_startscheduled_endstatusdeposit_amounttotal_amountremaining_balancecurrencycancellation_policy_idcancelled_atrefund_amount
Payments table
idbooking_idtype(deposit,balance,refund)amountproviderprovider_payment_idstatuscreated_at
Cancellation policies table
idnamerefund_before_48hrefund_before_24hnon_refundable_afterconsultant_cancel_rule
Important edge cases
- Consultant cancels: usually full refund + maybe credit
- Client cancels right before session
- Session starts but client no-shows
- Partial refunds after dispute
- Chargebacks
- Timezone handling
- Double booking / slot locking
- Idempotency for payment/refund events
Payment provider considerations
If you’re using Stripe, Paddle, etc.:
- Use payment intents for deposits
- Store webhooks for payment confirmation/refunds
- Never trust frontend payment success alone
- Handle asynchronous payment events carefully
Legal / policy note
You should make the cancellation and refund policy visible before checkout and require user agreement. Depending on jurisdiction, deposits and cancellation terms may have consumer protection requirements.
If you want, I can help you next with one of these:
- a database schema
- a state machine
- a Stripe payment flow
- a cancellation policy design
- a full API design