Hospital OS: Patient Records & OPD, Healthcare · Hospital Operating System

Hospital OS: Patient Records & OPD

CategoryHealthcare · Hospital Operating System
Hospital Operating SystemPart 1 of 4

Overview

Part 1 of a 50+ module Hospital Operating System built for a psychiatric and mental-healthcare hospital. This part is the foundation every other module depends on: a single patient registry keyed on a unique hospital identifier (UHID), and the outpatient department (OPD) workflow that moves a patient from registration to booked slot, queue token, consultation and prescription. Everything downstream (admissions, pharmacy, laboratory and billing) reads from and writes to this one record.

Unified Patient RegistryRegistration & UHID GenerationAppointment & Queue ManagementOPD Consultation WorkflowPrescriptions & Clinical OrdersReferral Management
0

Shared patient record across departments

0+

Modules in the full system

0%

Workflow digitised

0 months

Full build delivered

01

The challenge
we had to solve

Appointments, patient files and consultation notes were kept manually and offline. The same patient could exist as several paper files with slightly different details, front-desk staff had no live view of which doctor was running late, and a psychiatrist's notes, prescriptions and referrals sat in folders that could not follow the patient to the next visit. For long-term mental-health care, where continuity across months of follow-ups matters, a fragmented history was a clinical risk as well as an operational one.

Patient records kept on paper, with duplicate files for the same person
Appointments booked manually, with no shared view of doctor schedules
No queue visibility for front-desk staff or waiting patients
Prescriptions and referrals written by hand and not linked to the patient's history
Paper files, duplicatesPatient recordsBefore
Hospital OS: Patient Records & OPD project showcase
02

How we
approached it

We designed a normalised PostgreSQL schema around a single patient entity with a system-generated UHID, server-side duplicate checks on name, date of birth and phone, and a merge path for records that do collide. On top of it sits a React OPD workspace: doctor-wise slot calendars, walk-in and booked appointments in one queue, token numbers that update in real time as consultations start and close, and a consultation screen where the clinician records history, diagnosis, prescriptions and investigation orders against the same visit. Orders and referrals are written as structured records, not free text, so the pharmacy, laboratory and billing modules pick them up without re-entry.

Hospital OS: Patient Records & OPD, Healthcare · Hospital Operating System
01

One Patient, One Record

Every patient gets a UHID at registration. Visits, notes, orders and documents attach to it, so the full history follows the patient across departments and years of follow-up.

02

Predictable Front Desk

Doctor-wise slot calendars, walk-ins and booked appointments share one queue with token numbers, so staff can see who is waiting, who is in consultation and who is next.

03

Structured Consultations

Clinicians record history, diagnosis, prescriptions and investigation orders in structured fields designed for psychiatric follow-ups, not loose paper notes.

04

Built to Connect

Prescriptions, lab orders and referrals are stored as typed records exposed through REST APIs, ready for pharmacy, laboratory and billing to consume, and for HL7/FHIR-ready exchange later.

03

Four phases
zero shortcuts

Registry & Data Model

Mapped every way a patient enters the hospital and designed the normalised patient, visit and encounter tables around a single UHID, with duplicate detection and controlled record merging.

Appointments & Queue Engine

Built doctor-wise slot templates, walk-in handling and a token queue whose status changes are pushed to front-desk and doctor screens as consultations start and close.

OPD Consultation Workspace

Delivered the React consultation screen (visit history, notes, diagnosis, prescriptions and investigation orders) with server-side validation on every clinical field.

Orders, Referrals & Handover

Exposed prescriptions, orders and referrals as structured records over REST APIs so the pharmacy, lab and billing modules receive them without re-typing.

05

Before vs.
after

"

The system transformed the way we manage appointments and patient workflows while giving us a professional digital presence.

M

Management team

Specialty mental-health hospital

MetricBeforeAfterΔ
Patient recordsPaper files, duplicatesOne UHID-based recordUnified
AppointmentsManual, offlineSlot calendars & live queueDigitised
Consultation notesHandwrittenStructured, searchable historyContinuous
Orders & referralsRe-written per departmentEntered once at sourceNo re-entry
1Shared patient record across departments
Next

Want results like these? Let's talk about what we can build together.

Start a project