834 Benefit Enrollment and Maintenance (004010X095A1)
Employers and sponsors send the 834 to enroll members in health plans and to update or end their coverage. This is the standard X12 HIPAA 004010 spec, with 16 loops and 61 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 004010X095A1 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 |
| Loop N1 | Sponsor Name | Mandatory | 1 |
| N1 | Sponsor Name | Mandatory | 1 |
| Loop N1 | Payer | Mandatory | 1 |
| N1 | Payer | Mandatory | 1 |
| Loop N1 | TPA Broker Name | Optional | 2 |
| N1 | TPA Broker Name | Mandatory | 1 |
| Loop ACT | TPA Broker Account Information | Optional | 1 |
| ACT | TPA Broker Account Information | Mandatory | 1 |
| Loop INS | Member Level Detail | Mandatory | >1 |
| INS | Member Level Detail | Mandatory | 1 |
| REF | Subscriber Number | Mandatory | 1 |
| REF | Member Policy Number | Optional | 1 |
| REF | Member Identification Number | Optional | 5 |
| REF | Prior Coverage Months | Optional | 1 |
| DTP | Member Level Dates | Optional | 20 |
| Loop NM1 | Member Name | Mandatory | 1 |
| NM1 | Member Name | Mandatory | 1 |
| PER | Member Communications Numbers | Optional | 1 |
| N3 | Member Residence Street Address | Optional | 1 |
| N4 | Member Residence City State ZIP Code | Optional | 1 |
| DMG | Member Demographics | Optional | 1 |
| ICM | Member Income | Optional | 1 |
| AMT | Member Policy Amounts | Optional | 4 |
| HLH | Member Health Information | Optional | 1 |
| LUI | Member Language | Optional | 5 |
| Loop NM1 | Incorrect Member Name | Optional | 1 |
| NM1 | Incorrect Member Name | Mandatory | 1 |
| DMG | Incorrect Member Demographics | Optional | 1 |
| Loop NM1 | Member Mailing Address | Optional | 1 |
| NM1 | Member Mailing Address | Mandatory | 1 |
| N3 | Member Mail Street Address | Optional | 1 |
| N4 | Member Mail City State Zip | Optional | 1 |
| Loop NM1 | 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 | Optional | 1 |
| Loop NM1 | 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 | Optional | 1 |
| Loop NM1 | 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 | Optional | 1 |
| Loop NM1 | Responsible Person | Optional | 1 |
| 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 | Optional | 1 |
| Loop DSB | Disability Information | Optional | 1 |
| DSB | Disability Information | Mandatory | 1 |
| DTP | Disability Eligibility Dates | Optional | 2 |
| Loop HD | Health Coverage | Optional | 99 |
| HD | Health Coverage | Mandatory | 1 |
| DTP | Health Coverage Dates | Mandatory | 4 |
| AMT | Health Coverage Policy | Optional | 4 |
| REF | Health Coverage Policy Number | Optional | 2 |
| IDC | Identification Card | Optional | 10 |
| Loop LX | Provider Information | Optional | 30 |
| LX | Provider Information | Mandatory | 1 |
| NM1 | Provider Name | Mandatory | 1 |
| N4 | Provider City State ZIP Code | Optional | 1 |
| PER | Provider Communications Numbers | Optional | 2 |
| PLA | PCP Change Reason | Optional | 1 |
| Loop COB | Coordination Of Benefits | Optional | 5 |
| COB | Coordination Of Benefits | Mandatory | 1 |
| REF | Additional Coordination Of Benefits Identifiers | Optional | 5 |
| N1 | Other Insurance Company Name | Optional | 1 |
| DTP | Coordination Of Benefits Eligibility Dates | Optional | 2 |
| SE | Transaction Set Trailer | Optional | 1 |