Project · Digital health
ClinIA: electronic health record
The same patient can be seen by several doctors in different institutions, and their record follows them without anyone having to ask for it over the phone. The record belongs to the patient, not to the clinic.

The problem
In Peru, a patient's medical record is split across as many systems as clinics they have visited. At a new clinic the doctor starts from scratch, asking again about allergies and ordering tests that already exist.
ClinIA starts from a single patient record. A doctor sees what the patient has authorised, and that authorisation is explicit and revocable.
Design decisions
- Permissions are checked on the server with a
require_role()decorator on every route. Hiding a button is not access control. - From Supabase to plain PostgreSQL. Supabase made authentication quick but tied the schema and policies to a vendor. For clinical data that dependency was a bigger risk than the convenience.
- All enums in one module, so "pending", "PENDING" and "waiting" never end up meaning the same thing.
Roles
- Super admin: platform, institutions, doctors and metrics
- Doctor: their patients' history, visits, tests, appointments and prescriptions
- Nurse: triage and vital signs
- Patient: their own record, appointments and results
Known limitations
- Voice transcription and the clinical assistant are in the UI but have no engine behind them yet.
- No regulatory certification for real clinical use.
- Record sharing works at permission level, not interoperability: it does not speak HL7 or FHIR yet.