834 Benefit Enrollment and Maintenance (005010X220A1)
Employers, sponsors and exchanges send the 834 to enroll members in health plans and to update or end their coverage. This is the standard X12 HIPAA 005010 spec, with 21 loops and 76 segment positions, as OpenEDI JSON, an ediFabric C# template and an ediFabric Native model. To change it for a trading partner, customize it in the EDI Spec Builder.
Use the 834 spec in your code
ediFabric .NET
Add the C# template and its common files to your project, or reference the template NuGet package, and read 834 files into TS834 objects. See ediFabric .NET.
ediFabric Native
Map version 005010X220A1 to the Native model with set_map, then parse 834 files to JSON from Python, Java, C or C#. See Convert between EDI and JSON.
OpenEDI
Select Customize in Spec Builder to copy the spec under your own name, change it for your partner, and parse files against it in EdiNation, ediFabric Native or ediFabric Cloud. Read about OpenEDI.
Generate 834 classes in Python, Java, Node.js, Go, Rust or C
ediFabric Native returns each 834 as JSON, with the property names of the OpenEDI schema. To work with that JSON as typed objects, generate classes from the OpenEDI file in your language and deserialize the JSON into TS834. Serialize the objects back to JSON to build EDI with ediFabric Native. The classes keep the loops, segments, lengths and code lists, but not the EDI data formats, so validate files with ediFabric Native. Read more in Generate a class from OpenEDI.
Python: datamodel-code-generator. Node.js: openapi-typescript. Java, Go, Rust and C: OpenAPI Generator.
For a sample file, the same data as JSON, and code to parse, validate and generate the 834, see the 834 transaction guide.
834 structure
Loops and segments of the standard 834, with their usage and maximum repeats.
| ID | Name | Usage | Max use |
|---|---|---|---|
| ST | Transaction Set Header | Optional | 1 |
| BGN | Beginning Segment | Mandatory | 1 |
| REF | Transaction Set Policy Number | Optional | 1 |
| DTP | File Effective Date | Optional | >1 |
| QTY | Transaction Set Control Totals | Optional | 3 |
| Loop 1000A | Sponsor Name | Mandatory | 1 |
| N1 | Sponsor Name | Mandatory | 1 |
| Loop 1000B | Payer | Mandatory | 1 |
| N1 | Payer | Mandatory | 1 |
| Loop 1000C | TPA Broker Name | Optional | 2 |
| N1 | TPA Broker Name | Mandatory | 1 |
| Loop 1100C | TPA Broker Account Information | Optional | 1 |
| ACT | TPA Broker Account Information | Mandatory | 1 |
| Loop 2000 | Member Level Detail | Mandatory | >1 |
| INS | Member Level Detail | Mandatory | 1 |
| REF | Subscriber Identifier | Mandatory | 1 |
| REF | Member Policy Number | Optional | 1 |
| REF | Member Supplemental Identifier | Optional | 13 |
| DTP | Member Level Dates | Optional | 24 |
| Loop 2100A | Member Name | Mandatory | 1 |
| NM1 | Member Name | Mandatory | 1 |
| PER | Member Communications Numbers | Optional | 1 |
| N3 | Member Residence Street Address | Optional | 1 |
| N4 | Member City State ZIP Code | Optional | 1 |
| DMG | Member Demographics | Optional | 1 |
| EC | Employment Class | Optional | >1 |
| ICM | Member Income | Optional | 1 |
| AMT | Member Policy Amounts | Optional | 7 |
| HLH | Member Health Information | Optional | 1 |
| LUI | Member Language | Optional | >1 |
| Loop 2100B | Incorrect Member Name | Optional | 1 |
| NM1 | Incorrect Member Name | Mandatory | 1 |
| DMG | Incorrect Member Demographics | Optional | 1 |
| Loop 2100C | Member Mailing Address | Optional | 1 |
| NM1 | Member Mailing Address | Mandatory | 1 |
| N3 | Member Mail Street Address | Mandatory | 1 |
| N4 | Member Mail City State ZIP Code | Mandatory | 1 |
| Loop 2100D | Member Employer | Optional | 3 |
| NM1 | Member Employer | Mandatory | 1 |
| PER | Member Employer Communications Numbers | Optional | 1 |
| N3 | Member Employer Street Address | Optional | 1 |
| N4 | Member Employer City State ZIP Code | Optional | 1 |
| Loop 2100E | Member School | Optional | 3 |
| NM1 | Member School | Mandatory | 1 |
| PER | Member School Commmunications Numbers | Optional | 1 |
| N3 | Member School Street Address | Optional | 1 |
| N4 | Member School City State ZIP Code | Optional | 1 |
| Loop 2100F | Custodial Parent | Optional | 1 |
| NM1 | Custodial Parent | Mandatory | 1 |
| PER | Custodial Parent Communications Numbers | Optional | 1 |
| N3 | Custodial Parent Street Address | Optional | 1 |
| N4 | Custodial Parent City State ZIP Code | Optional | 1 |
| Loop 2100G | Responsible Person | Optional | 13 |
| NM1 | Responsible Person | Mandatory | 1 |
| PER | Responsible Person Communications Numbers | Optional | 1 |
| N3 | Responsible Person Street Address | Optional | 1 |
| N4 | Responsible Person City State ZIP Code | Optional | 1 |
| Loop 2100H | Drop Off Location | Optional | 1 |
| NM1 | Drop Off Location | Mandatory | 1 |
| N3 | Drop Off Location Street Address | Optional | 1 |
| N4 | Drop Off Location City State ZIP Code | Optional | 1 |
| Loop 2200 | Disability Information | Optional | >1 |
| DSB | Disability Information | Mandatory | 1 |
| DTP | Disability Eligibility Dates | Optional | 2 |
| Loop 2300 | Health Coverage | Optional | 99 |
| HD | Health Coverage | Mandatory | 1 |
| DTP | Health Coverage Dates | Mandatory | 6 |
| AMT | Health Coverage Policy | Optional | 9 |
| REF | Health Coverage Policy Number | Optional | 14 |
| REF | Prior Coverage Months | Optional | 1 |
| IDC | Identification Card | Optional | 3 |
| Loop 2310A | Provider Information | Optional | 30 |
| LX | Provider Information | Mandatory | 1 |
| NM1 | Provider Name | Mandatory | 1 |
| N3 | Provider Address | Optional | 2 |
| N4 | Provider City State ZIP Code | Optional | 1 |
| PER | Provider Communications Numbers | Optional | 2 |
| PLA | Provider Change Reason | Optional | 1 |
| Loop 2320 | Coordinationof Benefits | Optional | 5 |
| COB | Coordinationof Benefits | Mandatory | 1 |
| REF | Additional Coordinationof Benefits Identifiers | Optional | 4 |
| DTP | Coordinationof Benefits Eligibility Dates | Optional | 2 |
| Loop 2330 | Coordinationof Benefits Related Entity | Optional | 3 |
| NM1 | Coordinationof Benefits Related Entity | Mandatory | 1 |
| N3 | Coordinationof Benefits Related Entity Address | Optional | 1 |
| N4 | Coordinationof Benefits Other Insurance Company City State ZIP Code | Optional | 1 |
| PER | Administrative Communications Contact | Optional | 1 |
| Loop LS | Additional Reporting Categories | Optional | 1 |
| LS | Additional Reporting Categories | Mandatory | 1 |
| Loop 2700 | Member Reporting Categories | Optional | >1 |
| LX | Member Reporting Categories | Mandatory | 1 |
| Loop 2750 | Reporting Category | Optional | 1 |
| N1 | Reporting Category | Mandatory | 1 |
| REF | Reporting Category Reference | Optional | 1 |
| DTP | Reporting Category Date | Optional | 1 |
| LE | Additional Reporting Categories Termination | Mandatory | 1 |
| SE | Transaction Set Trailer | Optional | 1 |