How getwaitwise/waitwise works
WaitWise is a hospital queue and appointment platform: patients find a service, book or claim a token, pay when required, then track queue progress; staff and administrators manage counters, doctors, services, and payments. The mobile and web apps provide patient and operational interfaces, backed by a FastAPI API and Supabase. The API also supports prediction, AI-assisted help, queue notifications, and daily summaries. Sampled code confirms API startup wiring, payment processing, and several admin database interactions; other links reflect documented route and feature structure in the tree.
Main entry points: main.py FastAPI app · (app) Mobile app · routes.py Payment routes · admin Admin console
Components 23
Patient apps
- Mobile app
apps/mobile/src/app/(app) - Public web
apps/web/src/app - Token booking
apps/mobile/src/app/(app)/take-token.tsx - Payment checkout
apps/mobile/src/app/(app)/checkout/[holdId].tsx - Token status
apps/web/src/app/t/[id] - Help and FAQ
apps/mobile/src/app/(app)/help
Queue operations
- Staff tools
apps/web/src/app/counter - Doctor desk
apps/web/src/app/doctor - Queue display
apps/web/src/app/display/[service] - Admin console
apps/web/src/app/admin - Staff management API
apps/web/src/app/api/admin/staff/route.ts
API services
- FastAPI app
apps/api/app/main.py - API routes
apps/api/app/routes - Payment routes
apps/api/app/payments/routes.py - Wait prediction
apps/api/app/routes/predict.py - AI help
apps/api/app/ai_ask.py - Queue notifications
apps/api/app/notifications.py - Daily summaries
apps/api/app/summary.py - ML runtime
apps/api/app/ml_runtime.py
External services
- Supabase
- Razorpay
- DeepSeek
Other components
- Patient
Connections 23
- Patient → Mobile app: uses
- Patient → Public web: uses
- Mobile app → Token booking: books token
- Token booking → Payment checkout: continues payment
- Patient → Token status: checks status
- Mobile app → Help and FAQ: opens help
- FastAPI app → API routes: dispatches
- FastAPI app → Payment routes: mounts routes
- FastAPI app → ML runtime: loads model
- FastAPI app → Queue notifications: starts tasks
- FastAPI app → Daily summaries: starts loop
- Payment routes → Supabase: reads and writes
- Payment routes → Razorpay: handles payments
- Admin console → Supabase: manages records
- Admin console → Staff management API: requests staff changes
- Staff management API → Supabase: manages accounts
- Staff tools → Supabase: operates queue
- Doctor desk → Supabase: manages visits
- Queue display → Supabase: reads queue
- Wait prediction → ML runtime: uses model
- AI help → DeepSeek: asks model
- Queue notifications → Supabase: listens and polls
- Daily summaries → Supabase: reads queue data