Use this table to find a segment in a complete example. The field names are short descriptions written for this guide. The X12 standard uses its own names. For complete grammar and situational rules, use the X279A1 implementation guide.
Segment index
Select a segment to show its fields.
SegmentPurposeKey fieldsUsed in
GSOpens a functional group inside the interchange.
GS06 group control value, functional-group identity.Single, Medicare secondary+STOpens a transaction set inside the functional group.
ST01=271, ST02 transaction control, ST03=005010X279A1.Single, Medicare Advantage+BHTSupplies beginning-of-hierarchical-transaction context.Transaction purpose, reference, date, and time values.Single, Medicare secondary+
TRNReturns a trace number sent in the 270 so that you can match the response to its request.
TRN01=2 referenced trace, TRN02 trace number, TRN03 originating company.Not in the examples. See Transaction context+NM1Identifies the party for the current hierarchy level.Entity identifier, entity type, name, and example identifier values.Single, Medicare Advantage+
EBReports one qualified eligibility or benefit statement in the current subscriber context.
EB01 status, EB03 service type, and nearby plan and context values.Single, All complete examples+DTPSupplies a date or date period related to the current benefit context.Date qualifier, format qualifier, and example date value.Medicare secondary, Medicare Advantage+
MSGContains explanatory text for the surrounding response context.Example message text, read with its surrounding
EB and hierarchy.Primary and secondary, Medicare Advantage, X12-RFI-2628+LSOpens a named loop in the current benefit context.Opens loop
2120 in the examples. LS01 must match LE01.Eligibility and benefit statements+LECloses the named loop opened by LS.
LE01 closes the loop that LS01 opened.Eligibility and benefit statements+HSDSupplies a quantity, unit, or period that limits the surrounding benefit.
HSD01 quantity qualifier, HSD02 quantity, HSD05 and HSD06 period.Eligibility and benefit statements+REFSupplies an identifier whose meaning depends on its qualifier and loop.
REF01 qualifier, REF02 identifier.Eligibility and benefit statements+Control-pair lookup
Read opening and closing segments together. The complete examples also declare group, transaction, and segment counts. Validate these relationships first, and then apply the remaining X279A1 rules.
ISA13⇄IEA02
In the single-benefit example000000101
GS06⇄GE02
In the single-benefit example101
ST02⇄SE02
In the single-benefit example0101 · SE01 counts 10 segments