Introduction to HL7 FHIR
What it is · How it works · Why it matters for health interoperability
What is FHIR?
FHIR (Fast Healthcare Interoperability Resources, pronounced "fire") is a standard developed by HL7 International for exchanging health information electronically. It defines how health data should be structured and shared between different systems — hospitals, labs, health apps, and national health platforms.
Fast
Built on modern web standards — RESTful APIs, JSON, XML. Easy to implement with standard developer tools.
Healthcare-focused
Every concept maps to a real clinical entity: patients, observations, medications, appointments.
Interoperable
Designed so systems from different vendors and countries can share data without custom connectors.
Current version: FHIR R4 (Release 4) is the most widely adopted version and the one used in most national digital health programmes today, including those aligned with WHO SMART Guidelines.
Why Does Interoperability Matter?
In most health systems, data lives in silos. A lab system cannot automatically send results to the hospital EMR. The national HMIS cannot pull from facility-level databases. Clinicians re-enter the same patient data into multiple systems. FHIR solves this.
Without Interoperability
- ✗Manual data re-entry between systems
- ✗Duplicate patient records across facilities
- ✗Delayed lab results reaching clinicians
- ✗Fragmented patient history — no single view
- ✗National reporting requires manual aggregation
With FHIR
- ✓Lab results flow automatically to the EMR
- ✓One patient identity across all systems
- ✓Real-time data available at point of care
- ✓Complete longitudinal patient record
- ✓National dashboards fed automatically
FHIR Resources — The Building Blocks
In FHIR, a Resource is the basic unit of data — it represents a single clinical or administrative concept. Everything in FHIR is a resource. There are 150+ resource types in FHIR R4.
Patient
Demographics, identifiers, contact details of a person receiving care.
Observation
A measurement or result — lab test, vital sign, clinical finding.
MedicationRequest
A prescription or order for a medication to be dispensed.
Encounter
An interaction between a patient and a care provider — a visit, admission.
Organization
A health facility, ministry, lab, or other formal group.
DiagnosticReport
The result and findings of a diagnostic service (e.g. GeneXpert TB test).
Key idea: A FHIR resource is just a structured data object — like a JSON file — that represents one piece of health information. Systems exchange these objects over the web.
What a FHIR Resource Looks Like
FHIR resources are exchanged as JSON (most common) or XML. Here is a simplified example of a Patient resource:
{
"resourceType": "Patient",
"id": "patient-001",
"name": [
{
"family": "Shrestha",
"given": ["Ram"]
}
],
"gender": "male",
"birthDate": "1985-06-12",
"identifier": [
{
"system": "https://hmis.gov.np/patient-id",
"value": "NP-84721"
}
]
}resourceTypeAlways present — tells the receiver what kind of data this is.
idUnique identifier for this specific resource on the server.
identifierReal-world IDs (e.g. national health ID) with a system URL as namespace.
The FHIR RESTful API
FHIR uses standard HTTP methods — the same ones your browser uses every day. A FHIR server exposes a base URL, and resources are accessed by type and ID.
| HTTP Method | FHIR Operation | Example URL | What it does |
|---|---|---|---|
| GET | Read | /Patient/patient-001 | Retrieve a specific patient by ID |
| GET | Search | /Patient?name=Shrestha | Search patients by name |
| POST | Create | /Patient | Add a new patient record |
| PUT | Update | /Patient/patient-001 | Replace an existing patient record |
| DELETE | Delete | /Patient/patient-001 | Remove a patient record |
Base URL example: A FHIR server might be at https://fhir.hmis.gov.np/. A full request to get a patient would be GET https://fhir.hmis.gov.np/Patient/patient-001.
Bundles — Sending Multiple Resources Together
A Bundle is a container that holds multiple FHIR resources in a single HTTP request. This is used when you need to send related data together — for example, a patient record plus their lab results in one transaction.
transactionAll-or-nothing: all resources succeed or the whole bundle fails. Used for atomic operations.
batchEach resource is processed independently. Some may succeed, some may fail.
searchsetReturned by FHIR servers as the result of a search query — a list of matching resources.
FHIR in Practice — Real Use Cases
A GeneXpert machine generates a TB test result. Using FHIR DiagnosticReport, the result is automatically sent to the patient's EMR and flagged for the clinician — no manual entry needed.
A patient visits a district hospital and a national lab. Using FHIR Patient resources with a shared national health ID, both systems recognise it is the same person and merge their records.
A facility's EMR bundles monthly TB notifications as FHIR MeasureReport resources and posts them to the national HMIS endpoint — replacing manual aggregate data entry.
A community health worker app built on FHIR can post new patient registrations and observations directly to the national FHIR server, which are then visible in facility dashboards.
FHIR, DHIS2 & OpenHIM — How They Work Together
FHIR, DHIS2, and OpenHIM play different but complementary roles in a national health architecture. Understanding how they fit together is key for anyone working in health informatics.
Defines how data is structured and exchanged. A standard, not a system. Any system can speak FHIR.
Routes, audits, and transforms messages between systems. Translates FHIR messages to formats DHIS2 understands.
Stores aggregate and tracker data. Receives transformed data via OpenHIM mediators. Powers reports and dashboards.
Typical data flow: EMR / Lab System → FHIR message → OpenHIM (route + transform) → DHIS2 (store + visualise) → National Dashboard
Key Concepts Summary
Resources & Further Reading
Slide 22
FHIR R4 Specification
The official FHIR R4 specification — resource definitions, API reference, and implementation guides.
hl7.org/fhir →Firely FHIR School
Free self-paced FHIR courses from Firely — covering FHIR basics, profiling, and implementation guides.
fire.ly/fhir-school →FHIR Test Server
HAPI FHIR — a free public FHIR test server to try API calls and explore the standard hands-on.
hapi.fhir.org →Hello World Nepal · Health Informatics Training Series