HL7 v2 ADT^A01 Admission Message
An HL7 v2.5 ADT^A01 patient-admission message: pipe/caret-delimited segments (MSH, EVN, PID, PV1, allergies, diagnosis). A fixture for testing healthcare integration engines and HL7 parsers. The patient is fictional.
MSH|^~\&|ADT1|MERIDIAN|LABADT|MERIDIAN|20260115093000||ADT^A01|MSG00001|P|2.5
EVN|A01|20260115093000
PID|1||100001^^^MERIDIAN^MR||Lovelace^Ada^B||19851210|F|||1 Example Street^^London^^SW1A 1AA^GB||(555) 010-0199|||M
NK1|1|Byron^Augusta|SIS|2 Example Road^^London^^SW1A 2BB^GB
PV1|1|I|WARD3^0301^01^MERIDIAN||||1234^Turing^Alan|||MED||||ADM|A0|
AL1|1|DA|^Penicillin|MO|Rash
DG1|1|I10|I10^Essential hypertension^ICD-10|20251120
Specifications
- Standard
- HL7 v2.5
- Message
- ADT^A01 (admit)
- Segments
- MSH, EVN, PID, NK1, PV1, AL1, DG1
- Note
- synthetic patient
Testing contract
Expected to pass- Scenario
- Exercise HL7 v2 ADT^A01 Admission Message in its healthcare workflow. An HL7 v2.5 ADT^A01 patient-admission message: pipe/caret-delimited segments (MSH, EVN, PID, PV1, allergies, diagnosis).
- Expected result
- 7 text lines, decoded as UTF-8; first nonempty line is 'MSH|^~\\&|ADT1|MERIDIAN|LABADT|MERIDIAN|20260115093000||ADT^A01|MSG00001|P|2.5'. Declared feature checks: standard=HL7 v2.5; message=ADT^A01 (admit); segments=MSH, EVN, PID, NK1, PV1, AL1, DG1.
What is a .hl7 file?
HL7 v2 is the dominant messaging standard for exchanging clinical and administrative data between healthcare systems. A message is plain text made of segments (one per line, e.g. MSH, PID, PV1), each split into fields by pipe (|) delimiters, with components separated by carets (^). It drives admissions, lab orders, and results across hospitals.
How to use this file
Use an example HL7 v2 message to test healthcare integration engines, HL7 parsers, and segment/field extraction, or to exercise mapping from HL7 to FHIR or other formats. The data here is synthetic: not a real patient.
How to use this file for testing
“HL7 v2 ADT^A01 Admission Message” is a deterministic Testaroo fixture for Data import, Conversion testing. Realistic faker-generated datasets with documented schemas for testing import and ETL flows.
Documented properties for this file: HL7 · 434 bytes. Compare results against paired or grouped companions on this page when present (clean↔damaged, searchable↔scanned, or format twins) so scores stay reproducible across runs.
Download the file once, keep the path stable in CI or local scripts, and treat the spec table as the contract: dimensions, seeds, field lists, and roles are intentional. Corrupt or invalid samples are labelled as such, expect parsers to fail loudly rather than silently accept them.
Document fixtures list their internal structure (pages, fields, tracked changes, embedded objects) in the spec table. Test extractors, converters, and OCR against that known structure, and compare searchable↔scanned or format-twin companions when present.
Code examples
from hl7apy.parser import parse_message # pip install hl7apy
raw = open("adt-a01.hl7").read().replace("\n", "\r")
msg = parse_message(raw)
for seg in msg.children:
print(seg.name)Generated by generation/docs_realworld.py. Free for any use, no attribution required, license.
Related files
- ediAlder Table Bistro: ANSI X12 810 invoiceANSI X12 810 invoice for Alder Table Bistro. Version 004010 transaction set 810 for invoice INV-BST-5002, control number 810002. 3 IT1 segments, a TXI segment stating GST of 15.69, and a TDS segment of 32953 in implied-decimal cents, which is 329.53 CAD. SE declares 13 segments and 13 are present.

- ediAlder Table Bistro: ANSI X12 810 invoice with a wrong SE segment countANSI X12 810 invoice with a wrong SE segment count for Alder Table Bistro. Identical to edi-810-invoice.edi except for one element: SE declares 11 segments where 13 are present between ST and SE inclusive. The ISA, GS, GE and IEA control numbers, every data segment and the TDS total of 32953 are unchanged, so a parser that checks only syntax accepts the file and only a parser that recounts segments rejects it.

- ediAlder Table Bistro: ANSI X12 850 purchase orderANSI X12 850 purchase order for Alder Table Bistro. Version 004010 transaction set 850 for PO-BST-1002, control number 850002. 3 PO1 segments carry quantity, X12 unit code, unit price, the supplier item code (VP) and the buyer item code (BP); CTT declares 3 line items and SE declares 14 segments, which is the number actually present between ST and SE inclusive.

- ediAlder Table Bistro: ANSI X12 856 despatch adviceANSI X12 856 despatch advice for Alder Table Bistro. Version 004010 transaction set 856 for supplier delivery note DN-BST-3002 against PO-BST-1002, control number 856002. The shipment, order and item hierarchy uses HL segments, and the SN1 quantities are the quantities actually delivered, so line 2 reports 16 where the 850 ordered 20.

- xmlAlder Table Bistro: Factur-X CII invoice XMLFactur-X CII invoice XML for Alder Table Bistro. UN/CEFACT Cross Industry Invoice for INV-BST-5001 at the Factur-X BASIC guideline, with 3 trade line items, a TaxTotalAmount of 10.38 and a DuePayableAmount of 217.98 CAD. These bytes are the exact bytes embedded as factur-x.xml inside invoice-facturx.pdf.

- pdfAlder Table Bistro: Factur-X hybrid invoice PDFFactur-X hybrid invoice PDF for Alder Table Bistro. Invoice INV-BST-5001 rendered for a person and attached as machine-readable XML for a system. The embedded file is named factur-x.xml, is referenced from both the EmbeddedFiles name tree and the document-level AF array with an AFRelationship of Data, and is byte-identical to invoice-facturx-cii.xml. The visible page and the XML agree: net 207.60, GST 10.38, 217.98 CAD due. This is the only file in the set that carries its data twice in one container.
