How yavanash/healthezy works
Healthezy is a healthcare operations API for identity, facilities, staff, patients, labs, schedules, and appointments. The principal workflow is an API request routed to a domain handler, processed by its service, and persisted through database managers and SQLAlchemy models; authentication and authorization guard relevant operations. The README documents additional endpoint capabilities such as schedule exceptions and hospital searches. Relationships are limited to routing, imports, and calls supported by the SOURCE INDEX or README; unsampled implementation details are not inferred.
Main entry points: api.py API router · managers Domain managers · users.py User manager · service.py Auth service
Components 26
API entry
- API router
src/api.py
Identity and access
- Auth routes
src/auth/routes.py - Auth service
src/auth/service.py - Auth dependencies
src/auth/dependencies.py - Auth schemas
src/auth/models.py - User routes
src/handlers/users/routes.py - User service
src/handlers/users/service.py
Care operations
- Doctor routes
src/handlers/doctors/routes.py - Doctor service
src/handlers/doctors/service.py - Schedules and exceptions
src/handlers/doctors/doctor_schedules - Appointment routes
src/handlers/appointments/routes.py - Appointment service
src/handlers/appointments/service.py - Patient operations
src/handlers/patients
Facilities and administration
- Hospital operations
src/handlers/hospitals - Lab operations
src/handlers/labs - Tenant operations
src/handlers/tenants - Administration
src/handlers/admin
Persistence
- Database manager base
src/database/managers/manager.py - Doctor manager
src/database/managers/doctors.py - User manager
src/database/managers/users.py - Domain managers
src/database/managers - Healthcare data models
src/database/models/tenants.py - User data models
src/database/models/users.py - Response schemas
src/database/models/response_models.py - Database sessions
src/database/sessions.py
Other components
- API client
Connections 40
- API client → API router: sends request
- API router → Auth routes: routes to
src/api.py - API router → Administration: routes to
src/api.py - API router → User routes: routes to
src/api.py - API router → Doctor routes: routes to
src/api.py - API router → Schedules and exceptions: routes to
src/api.py - API router → Hospital operations: routes to
src/api.py - API router → Tenant operations: routes to
src/api.py - API router → Appointment routes: routes to
src/api.py - API router → Patient operations: routes to
src/api.py - API router → Lab operations: routes to
src/api.py - Auth routes → Auth service: calls
src/auth/routes.py - Auth routes → Auth schemas: uses schemas
src/auth/routes.py - Auth service → User manager: uses
src/auth/service.py - Auth service → Doctor manager: uses
src/auth/service.py - Auth dependencies → Auth service: validates token
src/auth/dependencies.py - User routes → User service: calls
src/handlers/users/routes.py - User routes → Auth dependencies: depends on
src/handlers/users/routes.py - User service → User manager: uses
src/handlers/users/service.py - Doctor routes → Doctor service: calls
src/handlers/doctors/routes.py - Doctor routes → Auth dependencies: depends on
src/handlers/doctors/routes.py - Doctor service → Doctor manager: uses
src/handlers/doctors/service.py - Doctor service → Domain managers: uses schedules
src/handlers/doctors/service.py - Schedules and exceptions → Doctor service: calls
src/handlers/doctors/doctor_schedules/routes.py - Appointment routes → Appointment service: calls
src/handlers/appointments/routes.py - Appointment service → Domain managers: uses appointment and schedule managers
src/handlers/appointments/service.py - Patient operations → User manager: uses
src/handlers/patients/service.py - Patient operations → Domain managers: uses patient manager
src/handlers/patients/service.py - Hospital operations → Domain managers: uses domain managers
src/handlers/hospitals/service.py - Lab operations → Domain managers: uses lab and user managers
src/handlers/labs/service.py - Tenant operations → Domain managers: uses tenant manager
src/handlers/tenants/service.py - Administration → Domain managers: uses managers
src/handlers/admin/service.py - Doctor manager → Database manager base: inherits database operations
src/database/managers/doctors.py - User manager → Database manager base: inherits database operations
src/database/managers/users.py - Domain managers → Database manager base: uses shared base
src/database/managers/schedules.py - Database manager base → Database sessions: operates on session
- Doctor manager → Healthcare data models: queries healthcare data
src/database/managers/doctors.py - User manager → User data models: queries user data
src/database/managers/users.py - Healthcare data models → Response schemas: converts to responses
src/database/models/tenants.py - User data models → Response schemas: converts to responses
src/database/models/users.py