What HL7 Is and Why It Exists
- 5 min
- 6 steps
- 2 questions
- Lesson 1 of 51
In this lesson
- The coordination problem
- What a standard does—and does not—solve
- Four layers to test separately
- The main HL7 families
- Follow one event end to end
- Build an interface contract
Picking up where you left off.
The coordination problem
A modern hospital does not run on one application. Registration, laboratory, pharmacy, radiology, billing, document repositories, devices, and the electronic health record may all come from different vendors and different eras. Yet they must react to the same events: a patient is registered, a bed changes, an order is placed, a specimen is collected, or a result is corrected.
If every pair of systems invents its own format, \(n\) systems can require as many as \(n(n-1)/2\) pairwise connections. Ten systems imply 45 relationships; 30 imply 435. An integration engine can reduce the physical connection pattern, but it does not remove the need for shared structures and meanings.
Health Level Seven (HL7) is the standards-development organization and the family of standards it publishes for exchanging, integrating, sharing, and retrieving electronic health information 1. “Level Seven” refers to the application layer of the OSI model: HL7 is concerned with the meaning and organization of application data, not merely moving bytes.
What a standard does—and does not—solve
An HL7 standard can define message structures, fields, data types, coded elements, documents, resources, and interaction rules. It does not automatically provide:
- a network connection, interface engine, or database;
- one universal patient identifier or one local code set;
- a complete security, privacy, consent, or identity-management program;
- identical workflows across hospitals; or
- proof that two products made compatible implementation choices.
The base standard is a vocabulary of legal possibilities. A real interface also needs an implementation guide or message profile, a local interface specification, test cases, operational ownership, and monitoring. Two products can truthfully say “supports HL7 v2” while disagreeing about which events they send, where an identifier belongs, which fields repeat, and what an error acknowledgment means.
Four layers to test separately
The U.S. Interoperability Standards Platform distinguishes vocabulary and terminology, content and structure, and infrastructure standards because interoperability is layered rather than binary 2. In practice, ask four questions:
- Transport: Did the bytes arrive once, intact, and within the required time?
- Structure: Does the payload conform to the agreed version, message type, profile, cardinality, and data types?
- Meaning: Do identifiers, codes, display text, units, dates, and absent values mean the same thing to both sides?
- Workflow: Did the receiver apply the event to the correct patient, encounter, order, and state transition?
An AA acknowledgment may prove that one application accepted a message under its rules. It does not prove that the correct clinician sees the correct information, that a local code was mapped safely, or that a duplicate did not produce a second action.
The main HL7 families
| Family | Primary unit | Typical representation | Good mental model |
|---|---|---|---|
| HL7 v2 | event message | delimited text | “Something happened; update your state.” |
| HL7 v3 | model-derived interaction | XML | “Construct exchanges from a common information model.” |
| CDA / C-CDA | persistent clinical document | XML with narrative and coded entries | “Store and exchange an attestable note.” |
| FHIR | resource and API interaction | JSON or XML over web conventions | “Address clinical data as linked resources.” |
These are not a simple replacement ladder. A hospital may use v2 for live ADT and laboratory feeds, C-CDA for transitions-of-care documents, and FHIR APIs for app access at the same time. HL7 describes v2 as a long-established, widely implemented messaging family 3. New technology does not erase installed workflows overnight.
Follow one event end to end
Suppose registration admits Jane Doe. The admission system emits an ADT^A01 message. The interface engine validates it, maps local facility codes, and routes copies to the laboratory and pharmacy. Each receiver returns an acknowledgment and creates or updates an encounter.
The interface is not successful merely because both ACKs are positive. A useful acceptance test asks:
- Did the medical-record number retain its assigning authority?
- Did the message select the intended patient and encounter?
- Did inpatient location populate the receiver’s correct field?
- What happens if the same control identifier arrives again?
- What happens if an update arrives before the original admit?
- Can support staff trace the event without exposing unnecessary patient data?
This is the central discipline of interoperability: trace a real-world event through syntax, meaning, application state, and human use.
Build an interface contract
Before implementation, write down at least:
- sending and receiving applications, facilities, environments, and owners;
- transport, endpoint, framing, security, timeout, retry, and acknowledgment rules;
- HL7 version, message structure, trigger events, and profile;
- required, optional, repeating, and unsupported segments and fields;
- identifier authorities, code systems, value sets, units, and time-zone rules;
- duplicate, correction, cancellation, merge, and out-of-order behavior;
- test cases, reconciliation metrics, monitoring, retention, and escalation.
Rule of thumb
Never accept “the interface is HL7” as a complete requirement. Ask: which event, which version, which constrained structure, which meaning, which workflow, and which evidence?
Practice
Choose one event such as admission, medication order, laboratory correction, or discharge summary. Draw the source, transport, payload, code systems, receiver, and human outcome. At each of the four layers, name one plausible failure and one observable signal that would detect it. The result is a first interface test plan—not merely a data-flow drawing.
Practice
Transport and parsing are necessary, but semantic interoperability requires shared meaning for identifiers, codes, units, and context.
Practice
A deployable contract must specify versions, events, fields, identifiers, codes, acknowledgments, and failure behavior.
Lesson complete
Nice work.
Sources for this lesson
- 1
- 2Interoperability. Office of the National Coordinator for Health IT (HealthIT.gov). verified Cited at: interoperability standards structure.
- 3HL7 Standards — Section 1d: Version 2 (V2). HL7 International. verifiedThe HL7 Version 2 messaging standard, first released October 1987 and the most widely implemented healthcare messaging standard worldwide. Cited at: Version 2 product suite.
Further reading
- Tim Benson, Grahame Grieve. Principles of Health Interoperability: FHIR, HL7 and SNOMED CT. 4th ed. Springer. 2021. verified