How kanvyhealth/dheergayush-backend works
This is a telemedicine and health-commerce backend serving patient, doctor, and admin workflows. Patients authenticate, book paid consultations, share reports, consult by video, and receive prescriptions; they can also browse a medicine store, pay for orders, and track fulfillment. Doctors manage profiles and availability and conduct consultations; admins manage doctors, payments, prescriptions, and orders. The graph emphasizes domain routes and their evidenced integrations. Source excerpts are partial and the README is empty, so some subsystem wiring is intentionally omitted.
Main entry points: index.js Firestore data · store/routes.js Storefront and orders · consultations/routes.js Consultation workflow · server.js HTTP server
Components 19
Platform
- HTTP server
src/server.js - Application routes
src/application.js - Firestore data
src/core/data/index.js - Firebase Storage
src/core/firebase/storage.js
Identity
- Authentication
src/modules/auth/routes.js - Patient services
src/modules/patients/routes.js - Firebase Auth
Clinical care
- Doctor services
src/modules/doctors/routes.js - Consultation workflow
src/modules/consultations/routes.js - Prescriptions
src/modules/prescriptions/routes.js - Consultation payments
src/modules/payments/routes.js - Razorpay
Health commerce
- Storefront and orders
src/modules/store/routes.js - Store catalog
src/modules/store/storeCatalog.js
Operations
- Admin services
src/modules/admin/routes.js - Site analytics
src/modules/analytics/routes.js
Other components
- Patient
- Doctor
- Admin
Connections 27
- Patient → HTTP server: requests
- Doctor → HTTP server: requests
- Admin → HTTP server: requests
- HTTP server → Application routes: starts
- Patient → Authentication: signs in
- Authentication → Firebase Auth: authenticates
- Authentication → Firestore data: loads profile
- Patient → Patient services: views history
- Patient services → Firestore data: reads records
- Doctor → Doctor services: manages profile
- Doctor services → Firestore data: reads and writes
- Patient → Consultation payments: pays to book
- Consultation payments → Razorpay: creates and verifies
- Consultation payments → Firestore data: records payment
- Patient → Consultation workflow: joins consultation
- Doctor → Consultation workflow: conducts consultation
- Consultation workflow → Firestore data: loads room records
- Patient → Prescriptions: views prescription
- Prescriptions → Firestore data: reads and writes
- Patient → Storefront and orders: places order
- Storefront and orders → Store catalog: loads catalog
- Storefront and orders → Razorpay: verifies payment
- Storefront and orders → Firestore data: reads and writes orders
- Admin → Admin services: manages records
- Admin → Site analytics: views statistics
- Admin → Storefront and orders: manages fulfillment
- Consultation workflow → Firebase Storage: stores reports