HL7 ACK & error code lookup
Acknowledgment codes (MSA-1), v2 error conditions (ERR-3, Table 0357) and FHIR OperationOutcome issue types, with what to check first.
Acknowledgment codes (Table 0008)
| Code | Meaning | What to check |
|---|
| AA | The receiving application accepted the message for processing. In original mode this is success; in enhanced mode this is the application-level accept. | Check MSA-2 matches your MSH-10. AA is not a promise every downstream system stored the data — only that this app accepted it. |
| AE | The application understood the message but found an error (validation, business rule, missing data). Often paired with ERR. | Read ERR-3 (table 0357) and ERR-8. Fix the field or the feed mapping; do not invent identifiers. |
| AR | The application rejected the message before/without successful application processing — unsupported type, bad encoding, missing control ID, wrong processing ID, etc. | Check MSH-9/10/11/12 and whether this receiver even supports the trigger. |
| CA | Enhanced mode only: the commit (accept) acknowledgment — the receiver safely stored the message for later application processing. | You may still get a later application ACK (AA/AE/AR) depending on MSH-15/16. |
| CE | Enhanced mode: commit-level error — the receiver could not accept responsibility for the message (storage/protocol problem). | Retry policy depends on your interface contract; inspect ERR if present. |
| CR | Enhanced mode: commit-level reject — the receiver will not accept this message at the commit layer. | Usually a protocol/config mismatch, not a soft validation issue. |
Message error conditions (Table 0357)
| Code | Meaning | What to check |
|---|
| 0 | Message accepted — Success detail code some systems return alongside AA. | Optional; AA already means accept. |
| 100 | Segment sequence error — Segments out of order or a required segment missing. | Compare the message structure to the profile (e.g. ADT_A01). |
| 101 | Required field missing — A required field is empty. | Penford example: empty PID-3 MRN → ask registration, then edit & resend with a confirmed value. |
| 102 | Data type error — Wrong datatype (NM field contains FOO). | Check OBX-2 vs OBX-5; dates must be DTM. |
| 103 | Table value not found — ID/IS value not in the expected table. | Map with a code table (and a * default) instead of forcing a wrong code. |
| 104 | Value too long — Exceeded normative or app-safe length. | Truncate only if the contract allows; otherwise fix the source. |
| 200 | Unsupported message type — Receiver does not support MSH-9.1. | Add a destination filter; do not coerce the type. |
| 201 | Unsupported event code — Trigger in MSH-9.2 not supported. | Filter A40 merges away from systems that cannot merge. |
| 202 | Unsupported processing id — MSH-11 not accepted (often TEST vs PROD). | Fix the connection environment; do not rewrite MSH-11 to sneak it in. |
| 203 | Unsupported version id — MSH-12 version not supported. | Align versions or use a version-tolerant engine path. |
| 204 | Unknown key identifier — Referenced patient/order id was not found. | For merges, ensure the prior MRN was registered first. |
| 205 | Duplicate key identifier — Id already exists on an add-style transaction. | Check whether this should have been an update trigger. |
| 206 | Application record locked — App storage locked. | Retry later; usually transient. |
| 207 | Application internal error — Catch-all application error — detail often in ERR-5. | Read ERR-5/7/8 before resubmitting the same bytes. |
FHIR OperationOutcome issue types
| Code | Meaning | What to check |
|---|
| invalid | Invalid Content — Content failed the specification or profile. | Validate against the IG (e.g. US Core) before retrying. |
| structure | Structural Issue — JSON/XML could not be parsed or structure is wrong. | Check resourceType and required nesting. |
| required | Required element missing — A required element is absent. | Penford example: Patient.identifier missing when the IG requires it. |
| value | Element value invalid — A value is present but not acceptable. | birthDate needs YYYY-MM-DD, not YYYYMMDD. |
| invariant | Validation rule failed — A FHIRPath/invariant (or similar) failed. | Read OperationOutcome.diagnostics. |
| not-supported | Content not supported — Interaction, resource, or profile not supported. | Check CapabilityStatement. |
| duplicate | Duplicate — Create would duplicate an existing record. | Search by identifier before create. |
| not-found | Not Found — Reference target missing (HTTP 404 analogue). | Confirm the id on that server. |
| code-invalid | Invalid Code — Code/system not understood or not in ValueSet. | Fix Coding.system URI (LOINC, SNOMED). |
| business-rule | Business Rule Violation — Failed a business rule beyond schema. | Talk to the owning system — mapping alone may not fix it. |
| conflict | Edit Version Conflict — Version-aware update conflict (HTTP 409 analogue). | GET latest meta.versionId, then retry. |
| transient | Transient Issue — May succeed if retried later. | Use retry with backoff; do not “fix” identifiers. |
| exception | Exception — Unexpected internal error. | Capture issue.diagnostics for the server team. |
| informational | Informational Note — Note unrelated to hard failure. | Do not treat as error unless severity says so. |
Sources: HL7 Table 0008 · HL7 Table 0357 · FHIR R4 issue-type. Related: MSA · ERR