ASC X12 Transaction Sets, Envelope Rules & Loop Hierarchies
Architectural overview of ASC X12 interchange envelopes, delimiter discovery at fixed byte offsets 3, 104, and 105, hierarchical HL parent-child pointers, and every major healthcare and retail transaction set.
ASC X12 Three-Layer Envelope Anatomy (ISA → GS → ST)
Every compliant ASC X12 file wraps business payloads inside three nested control envelopes validated independently by clearinghouses and VANs:
ISA*00* *00* *ZZ*SUBMITTERID *ZZ*RECEIVERID *261112*1430*^*00501*000000901*0*P*:~
GS*HC*SUBMITTER*RECEIVER*20261112*1430*901*X*005010X222A1~
ST*837*0001*005010X222A1~
... [Business Loops & HL Hierarchy] ...
SE*42*0001~ <-- SE-01 (42) counts ST..SE inclusive; SE-02 matches ST-02
GE*1*901~ <-- GE-01 (1) counts ST/SE sets in group; GE-02 matches GS-06
IEA*1*000000901~ <-- IEA-01 (1) counts GS/GE groups; IEA-02 matches ISA-13
HIPAA 5010 Healthcare Transaction Guides
837P Professional Claim →
CMS-1500 electronic equivalent: 2000A/B/C HL levels, 2300 CLM, and 2400 SV1 balancing.
005010X223A2837I Institutional Claim →
UB-04 hospital/facility claims: TOB facility codes, HI value/occurrence codes, and SV2 revenue lines.
005010X224A2837D Dental Claim →
ADA dental claims: SV3 procedure lines, TOO tooth numbers/surfaces, and DN1/DN2 segments.
005010X221A1835 ERA Payment & Remittance →
BPR net check math, 2100 CLP claim payments, 2110 SVC lines, CAS adjustments, and PLB offsets.
005010X279A1270 / 271 Eligibility & Benefits →
Real-time coverage inquiries, EQ service types, 2110C/D EB benefit loops, and AAA errors.
005010X212 / X214276 / 277 & 277CA Claim Status →
Payer front-end claim acknowledgments, TRN correlation, and STC status tuples.
005010X217278 Prior Authorization →
Utilization management referrals, UM request codes, HCR dispositions, and 6-tier HL trees.
005010X220A1834 Benefit Enrollment →
Sponsor-to-payer member roster sync, INS subscriber/dependent flags, and 2300 HD plans.
005010X218 / X306820 Premium Payment Order →
Group and HIX individual premium remittance via BPR, ENT, and RMR loops.
Retail, Manufacturing & 3PL Supply-Chain Guides
850 Purchase Order →
BEG order types, N1 ship-to/bill-to loops, PO1 SKU qualifiers, SAC charges, and CTT totals.
Order Confirmation855 PO Acknowledgment →
BAK acceptance codes and line-level ACK backorder/price-change statuses.
Warehouse / ASN856 Advance Ship Notice →
Pick-and-pack vs. standard carton HL trees (S → O → T → P → I) and MAN GS1-128 labels.
AP / AR Settlement810 Commercial Invoice →
IT1 invoice lines, TXI/SAC taxes and allowances, and TDS implied-cents reconciliation.
Frequently Asked Engineering Questions
How does an X12 parser discover delimiters without a schema?
In a compliant 106-byte ISA segment, byte index 3 defines the element separator (typically *), byte 104 defines the composite component separator (typically :), and byte 105 defines the segment terminator (typically ~). For broken chat-pasted headers under 106 bytes, EdiPrism uses heuristic token scanning.
Inspect, Diff, Validate & Scrub This Payload Offline in Your JetBrains IDE
Never paste regulated healthcare PHI (837/835/271) or supply-chain payloads (850/ORDERS) into browser parsers. EdiPrism X12 EDIFACT runs 100% air-gapped inside IntelliJ IDEA, PyCharm, DataGrip, Rider, GoLand, and WebStorm with a free core tier and a 14-day [Pro] trial.