Medplum is an open-source, API-first, headless EHR built around HL7 FHIR R4 (Apache 2.0). We self-hosted it on the client's own AWS account and built a custom React patient portal and clinician workflows on top of its FHIR REST and GraphQL surface.
A telehealth startup needed a HIPAA/SOC 2-ready patient portal — charts, scheduling, and lab results — in eight weeks, and refused to keep paying a legacy EHR's per-provider fees. Their incumbent system was a closed database with no safe way to attach custom intake forms or ingest outside lab feeds.
- Self-hosting a full FHIR stack inside the client's own AWS account so no PHI ever left their boundary, while staying HIPAA/SOC 2 defensible.
- Ingesting HL7v2 ADT and lab messages from a reference lab and mapping them cleanly onto FHIR Patient, Encounter, and Observation resources.
- Enforcing SMART-on-FHIR OAuth 2.0 PKCE consent so patients and guardians only ever saw records they were authorized to see.
We deployed Medplum via its official AWS CDK construct (ECS Fargate, RDS Aurora Postgres, ElastiCache Redis, CloudFront), then built a custom patient portal with the @medplum/react component library and wrote Medplum Bots to ingest lab data and summarize visit notes back into FHIR.
- One-command deploy on the client's AWS via `npx medplum aws init` then `cdk deploy`, fronted by CloudFront with Secrets Manager-held OAuth credentials.
- An HL7v2 → FHIR translator built on the @medplum/hl7 package, mapping ADT^A01 messages to FHIR Patient/Encounter with automated validation tests.
- A Medplum Bot (serverless TypeScript) that calls an LLM to summarize visit notes and writes them back as structured FHIR Observation resources.
A customized view of the system we shipped for this engagement — the components and how requests and data flow between them.
Before — manual bottleneck flow
Staff re-key patient details into a closed EHR terminal with no way to attach custom intake data.
Lab HL7v2 messages are printed, read, and typed into the EHR by hand, delaying results.
Every new clinician triggers a vendor seat purchase and a fresh onboarding ticket.
After — automated optimized flow
Patient completes SMART-on-FHIR-secured intake; consent and access scopes resolve instantly.
HL7v2 lab feeds auto-map to FHIR Observation/Encounter resources on arrival.
Clinicians open a complete FHIR-native chart with labs and notes already in place.
“Honestly, I expected the self-hosting to be the painful part, but they had it running in our own AWS inside a couple of sprints. The thing that actually mattered to us — that no patient data sits with a vendor — was handled properly, and the HL7 ingestion saved us from a lot of manual re-keying.”

