X12 EDI Conversion and Parsing API (2.15.0-beta.13)

Download OpenAPI specification:

API for converting healthcare X12 EDI transactions to JSON or CSV and generating EDI from JSON.

New endpoints in this release:

Application Info

Returns application information, including version and license details.

Get version and license information

Returns application information, including version and license details.

Responses

Response Schema: application/json
version
string
buildDateTime
string <date-time>
object (LicenseInfo)

Response samples

Content type
application/json
{
  • "version": "2.10",
  • "buildDateTime": "2024-11-26T12:23:10.875",
  • "licenseInfo": {
    }
}

EDI-to-CSV

Converts X12 EDI input to CSV. You can post EDI content as text or upload files with a multipart/form-data request.

See Python and curl examples in our GitHub repo.
See also the introduction to the CSV conversion API.

Output examples for all formats are available in the api-examples repository.

Convert X12 EDI 837/835/834 to CSV

Converts X12 EDI input into comma-separated value (CSV) flat-file format. EDI can be posted as text in the request body or uploaded with a multipart/form-data request.

The output is streamed as the input is parsed.

See the data dictionary for more details about the response schema, including mappings to X12 EDI elements.

The CSV output is highly customizable. See this guide for more details.

Output examples:

query Parameters
schemaFileName
string
Default: "csv_conversion.yaml"

Name of the file containing the CSV conversion schemas. See the CSV schema documentation for more details.

schemaName
string
Default: "lines-with-header-repeat-first-row"

Name of the schema configuration for CSV conversion in the CSV schema file. See the CSV schema documentation for more details.

ediFileName
string

The name of the EDI file submitted as text. This name will be propagated to the fileName column. Ignored for multipart/form-data requests.

warningsInResponse
boolean
Default: false

Write EDI parsing warnings to the response stream. Warnings are written into the first column and start with the WARNING: prefix. If not set, warnings are only written to logs. See the User Guide for more details.

maxWarnings
integer
Default: 50

Maximum number of EDI parsing warnings per file before raising a Too Many Warnings error and stopping.

chunkSize
integer <int32>
Default: 200

Number of claims or payments (837/835), or members (834), to parse at a time.

Request Body schema:
files
required
Array of strings <binary> [ items <binary > ]

Responses

Response Schema: text/plain
One of
id
string

Unique payment identifier assigned by the converter.

transactionType
string

Transaction set identifier code. EDI: ST01.

fileName
string

Converted X12 EDI file name.

transactionControlNumber
string

Transaction set control number. EDI: ST02.

patientControlNumber
string

Identifier used to track a claim from creation by the health care provider through payment. EDI: CLP01.

claimStatus
string

Claim status.

chargeAmount
number <float>

Charge amount. EDI: CLP03.

paymentAmount
number <float>

Payment amount. EDI: CLP04.

patientResponsibilityAmount
number <float>

Patient responsibility amount. EDI: CLP05.

claimFilingIndicatorCode
string

Claim filing indicator code. EDI: CLP06.

payerControlNumber
string

Payer control number. EDI: CLP07.

object (Code)

Place of service code (professional/dental) or UB facility code (institutional) from the original claim. EDI: CLP08.

frequencyTypeCode
string

Frequency type code. EDI: CLP09.

drgCode
string

Diagnosis-related group code. Institutional claims only. EDI: CLP11.

drgWeight
number <float>

Adjudicated DRG weight. Institutional claims only. EDI: CLP12.

dischargeFraction
number <float>

Adjudicated discharge fraction. Institutional claims only. This is a percentage expressed as decimal. EDI: CLP13.

totalPaymentAmount
number <float>

Total payment amount. EDI: BPR02.

creditOrDebitFlagCode
string

Credit or debit flag code. EDI: BPR03.

paymentMethodType
string

Payment method type. EDI: BPR04.

receiverAccountNumber
string

Receiver account number. EDI: BPR15.

paymentDate
string <date>

Payment date. EDI: BPR16.

checkOrEftTraceNumber
string

Check or eft trace number. EDI: TRN02.

payerEin
string

Payer identifier. This must be a '1' followed by the payer EIN. This field is also copied to the payerIdentifier field if it wasn't provided in N104. EDI: TRN03.

productionDate
string <date>

Production date. EDI: DTP03*405.

totalAdjAmount
number <float>

Sum total of all adjustments from all service lines.

Array of objects (Adjustment)

Claim adjustments. EDI: CAS.

object (Party)

Payer. EDI: N1*PR.

object (Party)

Payee. EDI: N1*PE.

object (PartyIdName)

The insured (subscriber) or patient from the original claim. EDI: NM1*QC.

object (PartyIdName)

The insured (subscriber) from the original claim if the insured is different from the patient. EDI: NM1*44.

object (PartyIdName)

Corrected patient. EDI: NM1*74.

object (PartyIdName)

Service provider. EDI: NM1*SJ.

object (PartyIdName)

Crossover carrier. EDI: NM1*TT.

object (PartyIdName)

Corrected priority payer, meaning that current payer believes that another payer has priority for making a payment. EDI: NM1*PR.

object (PartyIdName)

Other subscriber. EDI: NM1*GB.

Array of objects (Reference)

Other claim-related identifications. EDI: REF.

serviceDateFrom
string <date>

The earliest service date from service lines.

serviceDateTo
string <date>

The latest service date from service lines.

statementDateFrom
string <date>

Statement date from. EDI: DTP03*232.

statementDateTo
string <date>

Statement date to. EDI: DTP03*233.

coverageExpirationDate
string <date>

Coverage expiration date. EDI: DTM02*036.

claimReceivedDate
string <date>

Claim received date. EDI: DTM02*050.

coverageAmount
number <float>

Coverage amount from the list of supplemental amounts. EDI: AMT02*AU.

Array of objects (Amount)

Supplemental claim/payment amounts, such as coverage amount, discount amount, etc. EDI: AMT.

Array of objects (Quantity)

Supplemental claim/payment quantities. EDI: QTY.

Array of objects (PaymentLineCsv)

Service payment information. EDI: Loop: 2110.

Request samples

# Post EDI as text
curl -X POST -H "Content-Type: text/plain" \
--data-binary  @../edi_files/835/835.edi  \ 
"$API_URL/edi/csv?ediFileName=837.edi"

# Upload EDI files using a multipart/form-data request
curl -F files=@"../edi_files/837/837-1.dat" -F files=@"../edi_files/837/837-2.dat" \
$API_URL/edi/csv

Response samples

Content type
text/plain
Example
Id,TransactionType,FileName,TransactionControlNumber,PatientControlNumber,ClaimStatus,ChargeAmount,PaymentAmount,PatientResponsibilityAmount,ClaimFilingIndicatorCode,PayerControlNumber,FacilityCode,FrequencyTypeCode,DrgCode,DrgWeight,DischargeFraction,TotalPaymentAmount,CreditOrDebitFlagCode,PaymentMethodType,ReceiverAccountNumber,PaymentDate,CheckOrEftTraceNumber,PayerEin,ProductionDate,TotalAdjAmount,Adj1Group,Adj1ReasonCode,Adj1Amount,Adj1Quantity,Adj2Group,Adj2ReasonCode,Adj2Amount,Adj2Quantity,Adj3Group,Adj3ReasonCode,Adj3Amount,Adj3Quantity,Adj4Group,Adj4ReasonCode,Adj4Amount,Adj4Quantity,Adj5Group,Adj5ReasonCode,Adj5Amount,Adj5Quantity,PayerIdentificationType,PayerIdentifier,PayerName,PayerAddressLine,PayerAddressLine2,PayerAddressCity,PayerAddressStateCode,PayerAddressZipCode,PayerContact1Name,PayerContact1ContactNumber1Type,PayerContact1ContactNumber1Number,PayerContact1ContactNumber2Type,PayerContact1ContactNumber2Number,PayerContact2Name,PayerContact2ContactNumber1Type,PayerContact2ContactNumber1Number,PayerContact2ContactNumber2Type,PayerContact2ContactNumber2Number,PayerAdditionalId1Type,PayerAdditionalId1Identification,PayerAdditionalId2Type,PayerAdditionalId2Identification,PayeeIdentificationType,PayeeIdentifier,PayeeLastNameOrOrgName,PayeeAddressLine,PayeeAddressLine2,PayeeAddressCity,PayeeAddressStateCode,PayeeAddressZipCode,PayeeContacts,PayeeAdditionalId1Type,PayeeAdditionalId1Identification,PayeeAdditionalId2Type,PayeeAdditionalId2Identification,PatientIdentificationType,PatientIdentifier,PatientLastName,PatientFirstName,PatientMiddleName,SubscriberIdentificationType,SubscriberIdentifier,SubscriberLastName,SubscriberFirstName,SubscriberMiddleName,CorrectedPatientIdentificationType,CorrectedPatientIdentifier,CorrectedPatientLastName,CorrectedPatientFirstName,CorrectedPatientMiddleName,ServiceProviderIdentificationType,ServiceProviderIdentifier,ServiceProviderLastNameOrOrgName,ServiceProviderFirstName,ServiceProviderMiddleName,ServiceProviderContacts,ServiceProviderAdditionalId1Type,ServiceProviderAdditionalId1Identification,ServiceProviderAdditionalId2Type,ServiceProviderAdditionalId2Identification,CrossoverCarrierIdentificationType,CrossoverCarrierIdentifier,CrossoverCarrierName,CorrectedPayerIdentificationType,CorrectedPayerIdentifier,CorrectedPayerName,OtherSubscriberIdentificationType,OtherSubscriberIdentifier,OtherSubscriberLastName,OtherSubscriberFirstName,OtherSubscriberMiddleName,OtherClaimRelatedId1Type,OtherClaimRelatedId1Identification,OtherClaimRelatedId2Type,OtherClaimRelatedId2Identification,ServiceDateFrom,ServiceDateTo,StatementDateFrom,StatementDateTo,CoverageExpirationDate,ClaimReceivedDate,CoverageAmount,SupplementalAmt1QualifierCode,SupplementalAmt1Type,SupplementalAmt1Amount,SupplementalAmt2QualifierCode,SupplementalAmt2Type,SupplementalAmt2Amount,SupplementalQty1QualifierCode,SupplementalQty1Type,SupplementalQty1Quantity,SupplementalQty2QualifierCode,SupplementalQty2Type,SupplementalQty2Quantity,LineControlNumber,LineProcedureCode,LineProcedureModifier1Code,LineProcedureModifier2Code,LineProcedureModifier3Code,LineRevenueCode,LineDrugCode,LineChargeAmount,LinePaidAmount,LineUnitCount,LineOriginalProcedureCode,LineOriginalProcedureModifier1Code,LineOriginalProcedureModifier2Code,LineOriginalProcedureModifier3Code,LineOriginalRevenueCode,LineOriginalDrugCode,LineOriginalUnitCount,LineServiceDateFrom,LineServiceDateTo,LineTotalAdjAmount,LineAdj1Group,LineAdj1ReasonCode,LineAdj1Amount,LineAdj1Quantity,LineAdj2Group,LineAdj2ReasonCode,LineAdj2Amount,LineAdj2Quantity,LineAdj3Group,LineAdj3ReasonCode,LineAdj3Amount,LineAdj3Quantity,LineAdj4Group,LineAdj4ReasonCode,LineAdj4Amount,LineAdj4Quantity,LineAdj5Group,LineAdj5ReasonCode,LineAdj5Amount,LineAdj5Quantity,LineServiceId1Type,LineServiceId1Identification,LineServiceId2Type,LineServiceId2Identification,LineServiceId3Type,LineServiceId3Identification,LineHealthcarePolicyId,LineRenderingProviderId1Type,LineRenderingProviderId1Identification,LineRenderingProviderId2Type,LineRenderingProviderId2Identification,LineAllowedAmount,LineSupplementalAmt1QualifierCode,LineSupplementalAmt1Type,LineSupplementalAmt1Amount,LineSupplementalAmt2QualifierCode,LineSupplementalAmt2Type,LineSupplementalAmt2Amount,LineSupplementalQty1QualifierCode,LineSupplementalQty1Type,LineSupplementalQty1Quantity,LineSupplementalQty2QualifierCode,LineSupplementalQty2Type,LineSupplementalQty2Quantity,LineRemarkCode1,LineRemarkCode2,LineRemarkCode3,LineRemarkCode4,LineRemarkCode5
69efef04ad4799caa7f5ae67,835,835-provider-level-adjustment.dat,0002,5554555444,PRIMARY,800,500,300,12,94060555410000,11,1,,,,500,C,CHECK,RECEIVER_ACCT_1,2024-12-25,CHECK_1,PAYER_ID,2024-12-23,300,,,,,,,,,,,,,,,,,,,,,PAYOR_ID,ADDNL_PAYER_ID,ANY PLAN USA,1 WALK THIS WAY,,ANYCITY,OH,45209,,PHONE,8661112222,,,EDI,PHONE,8002223333,EMAIL,EDI.SUPPORT@ANYPAYER.COM,PAYER_IDENTIFICATION_NUMBER,ADDNL_PAYER_ID,,,NPI,PROVIDER2_NPI,PROVIDER,2255 ANY ROAD,,ANY CITY,CA,12211,,PAYEE_IDENTIFICATION_NUMBER,PAYEE_ID2,,,MEMBER_ID,33344555510,BUDD,WILLIAM,,MEMBER_ID,33344555510,BUDD,WILLIAM,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2024-03-01,2024-03-01,,,,,,,,,,,,,,,,,,1,99211,,,,,,800,500,1,,,,,,,,2024-03-01,2024-03-01,300,PATIENT_RESPONSIBILITY,1,300,,,,,,,,,,,,,,,,,,,,,,,,,,,,,800,B6,ALLOWED_ACTUAL,800,,,,,,,,,,,,,,
69efef04ad4799caa7f5ae99,835,claim_adj_reason.dat,10060875,PATACCT,PRIMARY,400,80,,MC,CLAIMNUMBER,11,1,,,,80,C,CHECK,,2019-08-16,CK NUMBER 1,1234567890,2019-08-27,320,,,,,,,,,,,,,,,,,,,,,PAYOR_ID,1234567890,ANY PLAN USA,1 WALK THIS WAY,,ANYCITY,OH,45209,,PHONE,8661112222,,,EDI,PHONE,8002223333,EMAIL,EDI.SUPPORT@ANYPAYER.COM,,,,,NPI,1123454567,PROVIDER,2255 ANY ROAD,,ANY CITY,CA,12211,,,,,,MEMBER_ID,ABC123456789,DOE,JOHN,N,MEMBER_ID,ABC123456789,DOE,JOHN,N,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2019-01-01,2019-01-01,,,,2019-02-09,150,AU,COVERAGE_AMOUNT,150,,,,,,,,,,1,99213,,,,,,150,80,1,,,,,,,,2019-01-01,2019-01-01,70,CONTRACTUAL,45,70,,,,,,,,,,,,,,,,,,,,,,,,,,,,,80,B6,ALLOWED_ACTUAL,80,,,,,,,,,,,,,,
69efef04ad4799caa7f5ae99,,,,PATACCT,,,,,,CLAIMNUMBER,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2,85003,,,,,,100,0,1,,,,,,,,2019-01-01,2019-01-01,100,CONTRACTUAL,204,100,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
69efef04ad4799caa7f5ae99,,,,PATACCT,,,,,,CLAIMNUMBER,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,3,36415,,,,,,150,0,1,,,,,,,,2019-01-01,2019-01-01,150,CONTRACTUAL,97,150,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
69efef04ad4799caa7f5aec6,835,not_covered_inpatient.dat,10060875,PATACCT,PRIMARY,40000,8000,,MC,CLAIMNUMBER,11,1,,,,8000,C,CHECK,,2019-08-16,CK NUMBER 1,1234567890,2019-08-27,32000,CONTRACTUAL,197,2000,1,CONTRACTUAL,45,30000,,,,,,,,,,,,,,PAYOR_ID,1234567890,ANY PLAN USA,1 WALK THIS WAY,,ANYCITY,OH,45209,,PHONE,8661112222,,,EDI,PHONE,8002223333,EMAIL,EDI.SUPPORT@ANYPAYER.COM,,,,,NPI,1123454567,PROVIDER,2255 ANY ROAD,,ANY CITY,CA,12211,,,,,,MEMBER_ID,ABC123456789,DOE,JOHN,N,MEMBER_ID,ABC123456789,DOE,JOHN,N,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2019-01-01,2019-01-05,2019-02-28,2019-02-09,38000,AU,COVERAGE_AMOUNT,38000,,,,CA,COVERED,4,,,,1,,,,,,,,,,,,,,,,,,,0,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
69efef04ad4799caa7f5af1f,835,negotiated_discount.dat,35681,7722337,PRIMARY,226,132,10,12,119932404007801,11,1,,,,132,C,CHECK,456,2019-03-31,12345,1512345678,2019-03-14,32405,CONTRACTUAL,197,2000,1,CONTRACTUAL,45,30000,,PATIENT_RESPONSIBILITY,132,259,,,,,,,,,,PAYOR_ID,0101,DELTA DENTAL OF ABC,225 MAIN STREET,,CENTERVILLE,PA,17111,JANE DOE,PHONE,9005555555,,,,,,,,PAYER_IDENTIFICATION_NUMBER,0101,HEALTH_INDUSTRY_NUMBER,0202,EIN,999994703,BAN DDS LLC,225 MAIN STREET,,CENTERVILLE,PA,17111,,PAYEE_IDENTIFICATION_NUMBER,0505,,,,,DOE,SALLY,,MEMBER_ID,SJD11111,DOE,John,,,,,,,NPI,1811901945,BAN,ERIN,,,MEDICARE_PROVIDER_NUMBER,12345678,,,CMS_PLAN_ID,9876,ACME INSURANCE,CMS_PLAN_ID,8765,ACME INSURANCE,,,Smith,Jane,,,,,,2019-03-24,2019-03-25,2022-09-15,2022-09-16,2022-10-01,2022-11-24,132,AU,COVERAGE_AMOUNT,132,D8,DISCOUNT_AMOUNT,100,CA,COVERED,4,,,,A123,D0120,02,28,,0222,,46,25,3.1,D0140,1,,,,,3.5,2019-03-24,2019-03-24,21,CONTRACTUAL,131,21,,,,,,,,,,,,,,,,,,RATE_CODE_NUMBER,100,APG_NUMBER,101,AMBULATORY_PAYMENT,102,"1234""5",CMS_NPI,P123,MEDICARE_PROVIDER_NUMBER,P234,25,B6,ALLOWED_ACTUAL,25,,,,ZL,MEDICARE_MEDICAID_CAT_2,3.75,,,,M1,M2,,,
69efef04ad4799caa7f5af1f,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2,D0220,,,,,,25,14,1,,,,,,,,2019-03-24,2019-03-24,11,CONTRACTUAL,131,11,,,,,,,,,,,,,,,,,,,,,,,,,,,,,14,B6,ALLOWED_ACTUAL,14,,,,,,,,,,,,,,
69efef04ad4799caa7f5af1f,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,3,D0230,,,,,,22,10,1,,,,,,,,2019-03-24,2019-03-24,12,CONTRACTUAL,131,12,,,,,,,,,,,,,,,,,,,,,,,,,,,,,10,B6,ALLOWED_ACTUAL,10,,,,,,,,,,,,,,
69efef04ad4799caa7f5af1f,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,4,D0274,,,,,,60,34,1,,,,,,,,2019-03-24,2019-03-24,26,CONTRACTUAL,131,26,,,,,,,,,,,,,,,,,,,,,,,,,,,,,34,B6,ALLOWED_ACTUAL,34,,,,,,,,,,,,,,
69efef04ad4799caa7f5af1f,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,5,D1110,,,,,,73,49,1,,,,,,,,2019-03-24,2019-03-25,76,CONTRACTUAL,131,24,,CONTRACTUAL,3,25,,OTHER,131,27,,,,,,,,,,,,,,,,,,,,,49,B6,ALLOWED_ACTUAL,49,KH,DEDUCTION,50,,,,,,,,,,,
69efef04ad4799caa7f5af51,835,dollars_data_separate.dat,112233,5554555444,PRIMARY,800,500,300,12,94060555410000,11,1,,,,1100,C,ACH,144444,2019-03-16,71700666555,1935665544,2019-03-14,300,,,,,,,,,,,,,,,,,,,,,PAYOR_ID,1935665544,RUSHMORE LIFE,10 SOUTH AVENUET,,RAPID CITY,SD,55111,JOHN WAYNE,PHONE,8005551212,EXTENSION,123,,,,,,,,,,NPI,5544667733,ACME MEDICAL CENTER,,,,,,,,,,,MEMBER_ID,33344555510,BUDD,WILLIAM,,MEMBER_ID,33344555510,BUDD,WILLIAM,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2023-03-01,2023-03-01,,,,,800,AU,COVERAGE_AMOUNT,800,,,,,,,,,,1,99211,,,,,,800,500,1,,,,,,,,2023-03-01,2023-03-01,300,PATIENT_RESPONSIBILITY,1,300,,,,,,,,,,,,,,,,,,,,,,,,,,,,,800,B6,ALLOWED_ACTUAL,800,,,,,,,,,,,,,,
69efef04ad4799caa7f5af52,835,dollars_data_separate.dat,112233,8765432112,PRIMARY,1200,600,600,12,9407779923000,11,1,,,,1100,C,ACH,144444,2019-03-16,71700666555,1935665544,2019-03-14,600,,,,,,,,,,,,,,,,,,,,,PAYOR_ID,1935665544,RUSHMORE LIFE,10 SOUTH AVENUET,,RAPID CITY,SD,55111,JOHN WAYNE,PHONE,8005551212,EXTENSION,123,,,,,,,,,,NPI,5544667733,ACME MEDICAL CENTER,,,,,,,,,,,MEMBER_ID,44455666610,SETTLE,SUSAN,,MEMBER_ID,44455666610,SETTLE,SUSAN,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2023-03-10,2023-03-10,,,,,1200,AU,COVERAGE_AMOUNT,1200,,,,,,,,,,1,93555,,,,,,1200,600,1,,,,,,,,2023-03-10,2023-03-10,600,PATIENT_RESPONSIBILITY,1,600,,,,,,,,,,,,,,,,,,,,,,,,,,,,,1200,B6,ALLOWED_ACTUAL,1200,,,,,,,,,,,,,,
69efef04ad4799caa7f5af80,835,835-denial.dat,10060875,PATACCT,DENIED,150,0,,MC,CLAIMNUMBER,11,1,,,,0,C,NON_PAYMENT,,2019-08-16,TRACE123,1234567890,2019-08-27,150,,,,,,,,,,,,,,,,,,,,,PAYOR_ID,1234567890,ANY PLAN USA,1 WALK THIS WAY,,ANYCITY,OH,45209,,PHONE,8661112222,,,EDI,PHONE,8002223333,EMAIL,EDI.SUPPORT@ANYPAYER.COM,,,,,NPI,1123454567,PROVIDER,2255 ANY ROAD,,ANY CITY,CA,12211,,,,,,MEMBER_ID,ABC123456789,DOE,JOHN,N,MEMBER_ID,ABC123456789,DOE,JOHN,N,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2019-01-01,2019-01-01,,,,2019-02-09,150,AU,COVERAGE_AMOUNT,150,,,,,,,,,,1234,99213,,,,,,150,0,1,,,,,,,,2019-01-01,2019-01-01,150,OTHER,252,150,,,,,,,,,,,,,,,,,,,,,,,,,CMS_NPI,99123,,,,,,,,,,,,,,,,M143,,,,
69efef04ad4799caa7f5afed,835,835-all-fields.dat,35681,7722337,PRIMARY,226,132,10,12,119932404007801,11,1,025,0.5,0.4,132,C,ACH,2200008888,2025-04-09,882509401093167,106609999,2019-03-14,32405,CONTRACTUAL,197,2000,1,CONTRACTUAL,45,30000,,PATIENT_RESPONSIBILITY,132,259,,,,,,,,,,PAYOR_ID,0101,DELTA DENTAL OF ABC,225 MAIN STREET,,CENTERVILLE,PA,17111,JANE DOE,PHONE,9005555555,EXTENSION,123,,URL,myplan.com/policies,,,PAYER_IDENTIFICATION_NUMBER,0101,HEALTH_INDUSTRY_NUMBER,0202,EIN,999994703,BAN DDS LLC,225 MAIN STREET,,CENTERVILLE,PA,17111,,PAYEE_IDENTIFICATION_NUMBER,0505,,,,,DOE,SALLY,,MEMBER_ID,SJD11111,DOE,John,,INSURED_CHANGED_ID,SJD999,Due,,,NPI,1811901945,BAN,ERIN,,,MEDICARE_PROVIDER_NUMBER,12345678,PROVIDER_UPIN_NUMBER,12345678,CMS_PLAN_ID,9876,ACME INSURANCE,CMS_PLAN_ID,8765,ACME INSURANCE,,,Smith,Jane,,,,,,2019-03-24,2019-03-25,2022-09-15,2022-09-16,2022-10-01,2022-11-24,132,AU,COVERAGE_AMOUNT,132,D8,DISCOUNT_AMOUNT,100,CA,COVERED,4,,,,A123,D0120,02,28,,0022,,46,25,3.1,D0140,1,,,,,3.5,2019-03-24,2019-03-24,21,CONTRACTUAL,131,21,,,,,,,,,,,,,,,,,,RATE_CODE_NUMBER,100,APG_NUMBER,101,AMBULATORY_PAYMENT,102,"1234""5",CMS_NPI,P123,MEDICARE_PROVIDER_NUMBER,P234,25,B6,ALLOWED_ACTUAL,25,,,,ZL,MEDICARE_MEDICAID_CAT_2,3.75,,,,M1,M2,,,
69efef04ad4799caa7f5afed,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,2,D0220,,,,,,25,14,1,,,,,,,,2019-03-24,2019-03-24,11,CONTRACTUAL,131,11,,,,,,,,,,,,,,,,,,,,,,,,,,,,,14,B6,ALLOWED_ACTUAL,14,,,,,,,,,,,,,,
69efef04ad4799caa7f5afed,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,3,D0230,,,,,,22,10,1,,,,,,,,2019-03-24,2019-03-24,12,CONTRACTUAL,131,12,,,,,,,,,,,,,,,,,,,,,,,,,,,,,10,B6,ALLOWED_ACTUAL,10,,,,,,,,,,,,,,
69efef04ad4799caa7f5afed,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,4,D0274,,,,,,60,34,1,,,,,,,,2019-03-24,2019-03-24,26,CONTRACTUAL,131,26,,,,,,,,,,,,,,,,,,,,,,,,,,,,,34,B6,ALLOWED_ACTUAL,34,,,,,,,,,,,,,,
69efef04ad4799caa7f5afed,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,5,,,,,0022,,99,59,1,,,,,0023,,2,2019-03-24,2019-03-24,0,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
69efef04ad4799caa7f5afed,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,6,D1110,,,,,,73,49,1,,,,,,,,2019-03-24,2019-03-25,76,CONTRACTUAL,131,24,,CONTRACTUAL,3,25,,OTHER,131,27,,,,,,,,,,,,,,,,,,,,,49,B6,ALLOWED_ACTUAL,49,KH,DEDUCTION,50,,,,,,,,,,,
69efef04ad4799caa7f5afed,,,,7722337,,,,,,119932404007801,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,7,,,,,,00002143481,60,59,10.5,,,,,,00002143482,9.2,2019-03-24,2019-03-24,0,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,

EDI-to-JSON

Converts (parses) X12 EDI input to JSON. You can post EDI content as text or upload files with a multipart/form-data request.

See Python and curl examples in our GitHub repo.

Introduction to the JSON response schema:

Output examples for all formats are available in the api-examples repository.

Convert X12 EDI to JSON

Converts X12 EDI input to JSON. EDI can be posted as text in the request body or uploaded with a multipart/form-data request.

The response is a JSON array or NDJSON (newline-delimited JSON). The output is streamed as the input is parsed.

See the data dictionary for more details about the response schema, including mappings to X12 EDI elements.

query Parameters
validate
boolean
Default: false

Perform full EDI validation. Validation messages are written to the response stream as VALIDATION objects. See the EDI validation documentation for more details. To change the default behavior, set the EDI_VALIDATE environment variable to true.

ndjson
boolean
Default: false

Use JSON Lines, also known as NDJSON. There is no enclosing array; each JSON object is terminated by a newline. Use this option for large files or streaming. If this option is not set, the response can contain a large array of JSON objects.

descriptions
boolean
Default: true

Provide descriptions for all codes (ICD, HCPCS, NDC, CARC/RARC, etc.). Descriptions can increase the size of the response. You can globally suppress descriptions by setting the codeset_enrichcodes environment variable to false. In that case, this parameter has no effect.

convertControlSegments
boolean
Default: false

Convert ISA and GS control segments to INTERCHANGE_CONTROL and FUNCTIONAL_GROUP objects. The objects will appear at the beginning of the response. If not set, control segments are ignored. To change the default behavior, set the EDI_CONVERT_CONTROL_SEGMENTS environment variable to true.

transactionTopLevel
boolean
Default: false

Write EDI transactions to the root level of the response as TRANSACTION objects. If not set, the EDI transaction is repeated in each claim, payment, or member object. Setting this parameter to true will reduce the size of the response. To change the default behavior, set the EDI_TRANSACTION_TOP_LEVEL environment variable to true.

convertToSegments
string

Convert to the EDI loop and segment tree instead of returning claims, payments, and other business objects.

ediFileName
string

The name of the EDI file submitted as text. This name will be propagated to the transaction.fileInfo.name field. Ignored for multipart/form-data requests.

maxWarnings
integer
Default: 3000

Maximum number of EDI validation issues per file before raising a Too Many Warnings error and stopping.

chunkSize
integer <int32>
Default: 50

The number of EDI transactions, or claims/payments/members for 837/835/834, to parse and convert at once. This option determines the memory footprint and can be used for fine-tuning. A higher value improves performance but consumes more memory.

warningsInResponse
boolean
Deprecated
Default: false

Write EDI parsing warnings to the response stream as warning objects. If not set, warnings are only written to logs. See the User Guide for more details. This parameter is deprecated in favor of the validate parameter. When validate is set, warnings are always written to the response stream.

splitTran
boolean
Deprecated
Default: true

Do not parse the entire transaction. Instead, parse by claims (CLM or CLP segments, 837/835) or members (INS segment, 834). This is the default for 835, 837, and 834 transactions, which can be large. Ignored for all other transaction types. As of 2.14.4, the API server automatically detects the transaction type and sets this parameter to true for 837/835/834 and false for all other transactions.

Request Body schema:
files
required
Array of strings <binary> [ items <binary > ]

Responses

Response Schema: application/json
Array
One of
id
string

Unique payment identifier assigned by the converter.

objectType
string

Type of this object, set to 'PAYMENT'.

patientControlNumber
required
string

Identifier used to track a claim from creation by the health care provider through payment. EDI: CLP01.

chargeAmount
required
number <float>

Charge amount. EDI: CLP03.

paymentAmount
required
number <float>

Payment amount. EDI: CLP04.

object (Code)

Place of service code (professional/dental) or UB facility code (institutional) from the original claim. EDI: CLP08.

object (Code)

Frequency code. EDI: CLP09.

statementDateFrom
string <date>

Statement date from. EDI: DTM02*232.

statementDateTo
string <date>

Statement date to. EDI: DTM02*233.

serviceDateFrom
string <date>

The earliest service date from service lines.

serviceDateTo
string <date>

The latest service date from service lines.

object (PatientSubscriber835)

The insured (subscriber) from the original claim if the insured is different from the patient. EDI: Loop: 2100.

object (PatientSubscriber835)

The insured (subscriber) or patient from the original claim. EDI: Loop: 2100.

Array of objects (PatientSubscriber835)

Other subscriber; only one other subscriber is allowed on 835. EDI: Loop: 2100.

Array of objects (PaymentLine)

Service lines. EDI: Loop: 2110.

Array of objects (ValidationIssue)

Validation issues.

object (Transaction835)

Parent EDI transaction for this object. EDI: ST.

claimStatusCode
string

Claim status code. EDI: CLP02.

claimStatus
string
Enum: "DENIED" "NOT_OUR_CLAIM" "PREDETERMINATION_NO_PAYMENT" "PRIMARY" "PRIMARY_FORWARDED" "REVERSAL" "SECONDARY" "SECONDARY_FORWARDED" "TERTIARY" "TERTIARY_FORWARDED"

Claim status code translated to a string constant (enum). EDI: CLP02.

patientResponsibilityAmount
number <float>

Patient responsibility amount. EDI: CLP05.

claimFilingIndicatorCode
string

Claim filing indicator code. EDI: CLP06.

insurancePlanType
string
Enum: "AUTOMOBILE_MEDICAL" "BCBS" "CHAMPUS" "COMMERCIAL" "EPO" "FEDERAL_EMPLOYEE_PROGRAM" "HMO" "HMO_MEDICARE" "INDEMNITY_INSURANCE" "MEDICAID" "MEDICARE_A" "MEDICARE_B" "MUTUALLY_DEFINED" "OTHER_FEDERAL" "OTHER_NON_FEDERAL" "POS" "PPO" "VETERAN_AFFAIRS" "WORKERS_COMPENSATION"

Claim filing indicator code translated to a string constant (enum). EDI: CLP06.

payerControlNumber
string

Payer control number. EDI: CLP07.

object (Code)

Diagnosis-related group code. Institutional claims only. EDI: CLP11.

drgWeight
number <float>

Adjudicated DRG weight. Institutional claims only. EDI: CLP12.

dischargeFraction
number <float>

Adjudicated discharge fraction. Institutional claims only. This is a percentage expressed as decimal. EDI: CLP13.

Array of objects (Reference)

Other claim-related identifications. EDI: REF.

Array of objects (Amount)

Supplemental claim/payment amounts, such as coverage amount, discount amount, etc. EDI: AMT.

Array of objects (Quantity)

Supplemental claim/payment quantities. EDI: QTY.

object (Party)

Payer. EDI: N1*PR.

object (Party)

Payee. EDI: N1*PE.

object (OutpatientAdjudication)

Outpatient adjudication. EDI: MOA.

object (InpatientAdjudication)

Inpatient adjudication. EDI: MIA.

Array of objects (Adjustment)

Claim adjustments. EDI: CAS.

coverageExpirationDate
string <date>

Coverage expiration date. EDI: DTM02*036.

claimReceivedDate
string <date>

Claim received date. EDI: DTM02*050.

object (PartyIdName)

Service provider. EDI: NM1*SJ.

object (PartyIdName)

Crossover carrier. EDI: NM1*TT.

object (PartyIdName)

Corrected priority payer, meaning that current payer believes that another payer has priority for making a payment. EDI: NM1*PR.

object (PartyIdName)

Corrected insured. EDI: NM1*74.

Array of objects (ContactInfo)

Claim contacts. EDI: PER.

Request samples

# Post EDI as text
curl -X POST -H "Content-Type: text/plain" \
--data-binary  @../edi_files/837/837.edi  \ 
"$API_URL/edi/json?ndjson=true&ediFileName=837.edi"

# Upload EDI files using a multipart/form-data request
curl -F files=@"../edi_files/837/837-1.dat" -F files=@"../edi_files/837/837-2.dat" \
"$API_URL/edi/json?ndjson=true"

Response samples

Content type
application/json
Example
[
  • {
    }
]

Validate EDI

Validates EDI and returns validation issues. See the EDI validation documentation for more details.

query Parameters
fileName
string

The name of the EDI file submitted as text. This name is used in validation warnings and parsing errors. If not set, a randomly generated file name is used.

ndjson
boolean
Default: false

Use JSON Lines, also known as NDJSON. There is no enclosing array; each validation issue object is terminated by a newline. Use this option for large files or streaming.

chunkSize
integer <int32>
Default: 50

The number of EDI transactions, or claims/payments/members for 837/835/834, to parse at once. This option determines the memory footprint and can be used for fine-tuning. A higher value improves performance but consumes more memory.

Request Body schema:
string

Text in X12 EDI format

Responses

Response Schema: application/json
Array
objectType
string

Type of this object, always 'VALIDATION'.

issueType
required
string
Enum: "BALANCE" "CONTROL" "INVALID" "INVALID_CODE" "LENGTH_EXCEEDED" "LENGTH_TOO_SHORT" "MISMATCH" "NOT_ALLOWED" "NUMBER_OF_ITEMS" "REQUIRED" "REQUIRED_CODE" "VALUE_NOT_IN_ENUM_LIST" "WRONG_TYPE"

Issue type.

issueObjectClass
string

Class (type) of the object where the issue was detected, such as Claim, ServiceLine, etc.

jsonPath
string

JSON path for the object where the issue was detected.

fieldName
string

Field name or element name.

object (SourceLocation)

Location of the issue in the EDI file.

loop
string

EDI loop where the issue was found.

segment
string

EDI segment ID.

element
string

EDI element designator.

ediCode
string

EDI qualifier or code for the segment if the segment is uniquely identified by the code.

maxNumberOfItems
integer

Maximum number of items allowed for the segment, list, or loop.

actualNumberOfItems
integer

Actual number of items.

length
integer

Expected length of the element's value (LENGTH_TOO_SHORT, LENGTH_EXCEEDED issue types).

actualLength
integer

Actual length (LENGTH_TOO_SHORT, LENGTH_EXCEEDED issue types).

dataType
string
Enum: "BINARY" "COMPOSITE" "DATE" "DECIMAL" "ENUM" "IDENTIFIER" "NUMERIC" "STRING" "TIME"

Expected data type (WRONG_TYPE issue type).

actualDataType
string
Enum: "BINARY" "COMPOSITE" "DATE" "DECIMAL" "ENUM" "IDENTIFIER" "NUMERIC" "STRING" "TIME"

Actual data type (WRONG_TYPE issue type).

codeSubType
string

Type of the code that failed validation (INVALID_CODE issue type), such as HCPCS, ProviderTaxonomy, ICD_10.

value
string

The value that caused the validation to fail.

ediString
string

Value that caused the issue.

message
string

Additional message describing the issue.

allowedValues
Array of strings

Allowed values (VALUE_NOT_IN_ENUM_LIST issue type).

Response samples

Content type
application/json
Example
[
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    },
  • {
    }
]

Validate EDI and return validation messages as text

Validates EDI and returns the entire EDI file with validation messages below each segment. Validation messages are denoted by the prefix !! in the EDI file.

query Parameters
issueStringPrefix
string
Default: "!!"

Prefix for lines that contain validation messages.

Request Body schema:
string

Text in X12 EDI format

Responses

Response Schema: text/plain
string

Response samples

Content type
text/plain
Example
ISA*00*          *00*          *ZZ*ABCPAYER       *ZZ*ABCPAYER       *190827*0212*^*00501*191511902*0*P*:~
GS*HP*SENDER CODE*RECEIVER CODE*20241225*0533*225426820*X*005010X221A1~
ST*835*0002~
!!Loop:0000, Segment:ST, Field: transaction_set_header | Required segment TRN (reassociation_trace_number) is missing in loop 0000
BPR*I*132*C*CHK***********456*20190331~
REF*EV*CLEARINGHOUSE_ID~
DTM*405*20241223~
N1*PR*DELTA DENTAL OF ABC~
!!Loop:1000A, Segment:N1, Field: payer_identification | Required segment PER (payer_technical_contact_information) is missing in loop 1000A
N3*225 MAIN STREET~
N4*CENTERVILLE*PA*17111~
REF*2U*0101~
N1*PE*PROVIDER*XX*PROVIDER2_NPI~
N3*2255 ANY ROAD~
N4*ANY CITY*CA*12211~
REF*TJ*123456789~
REF*PQ*PAYEE_ID2~
LX*1~
CLP*5554555444*1*700*500*300*12*94060555410000*11*1~
!!Loop:2100, Segment:CLP, Field: Payment.chargeAmount | Claim 5554555444: The sum of line charge amounts 800.00 does not match the claim charge amount 700.00
!!Loop:2100, Segment:CLP, Field: Payment.paymentAmount | Claim 5554555444: The sum of line paid amounts 400.00 does not match the claim paid amount 500.00
NM1*QC*1*BUDD*WILLIAM****MI*33344555510~
SVC*HC:99211*800*400~
!!Loop:2110, Segment:SVC, Field: ServiceLine.paymentAmount | Line 1: Paid amount 400.00 does not match the charge amount 800.00 minus the sum of adjustments 300.00
DTM*472*20240301~
CAS*PR*XX*300~
!!Loop:2110, Element:CAS02, Field: adjustment_reason_code | Claim Adjustment Reason Code XX is not a valid code
AMT*B6*800~
XX*B6*800~
!!Loop:2110, Segment:XX | Unknown segment 'XX' for the transaction set 835
SE*18*0002~
!!Loop:0000, Element:SE01, Field: transaction_segment_count | Count  '18' in the closing segment does not match actual count '22'
GE*1*225426820~
IEA*1*191511902~

Convert X12 EDI to JSON in memory (small files) Deprecated

Parses X12 EDI and returns an array of claims (837), payments (835), or segments (all other transactions). Parsing is done entirely in memory, so this endpoint is only suitable for small files. The endpoint is fully synchronous: the entire file is parsed before the response is returned.

This operation is deprecated as of 2.15.0; use the /api/edi/json endpoint instead.

See the Python example.

query Parameters
asSegments
boolean
Default: false

Return the JSON representation of loops and segments. This is the default mode for transactions other than 835 and 837.

gen999
boolean
Default: false

Generate a 999 Functional Group Acknowledgment report for all parsed transactions. The resulting EDI is available in the ackEdi field of the response.

Request Body schema: text/plain
required

Text in X12 EDI format.

string

Responses

Response Schema: application/json
Array of ProfClaim (object) or InstClaim (object) or DentClaim (object)
Array of objects (Payment)
Array of objects (MemberCoverage)
Array of ClaimStatus (object) or ReceiverStatus (object) or ProviderStatus (object)
segments
object (ArrayNode)
ackEdi
string

Generated 999–Functional Group Acknowledgement Report for all parsed transactions

Array of objects (ParsingIssue)

Response samples

Content type
application/json
{
  • "claims": [
    ],
  • "payments": [
    ],
  • "coverages": [
    ],
  • "statuses": [
    ],
  • "segments": { },
  • "ackEdi": "string",
  • "parsingIssues": [
    ]
}

Generate EDI

Generates EDI from JSON claim objects.

Generate 837I and 837P EDI from JSON claims

Generates X12 EDI 837I and 837P files from JSON claims.

query Parameters
failOnValidationErrors
boolean
Default: false

Fail the request if validation errors are found. If not set, validation errors are logged but ignored.

fileName
string

The name of the EDI file submitted as text. This name is used in validation warnings and parsing errors. If not set, a randomly generated file name is used.

Request Body schema: application/json
object (InterchangeControl)

Interchange control.

object (FunctionalGroup)

Functional group.

object (Transaction837)

Transaction.

Array of ProfClaim (object) or InstClaim (object)

Claims.

Responses

Response Schema: text/plain
string

EDI file content.

Request samples

Content type
application/json
{
  • "interchangeControl": {
    },
  • "functionalGroup": {
    },
  • "transaction": {
    },
  • "claims": [
    ]
}

Response samples

Content type
application/json
{
  • "objectType": "string",
  • "message": "string",
  • "fileName": "string"
}

Validate an EDI generation request for 837P or 837I

Validates a JSON request for EDI generation and returns any validation issues.

query Parameters
fileName
string

The name of the EDI file submitted as text. This name is used in validation warnings and parsing errors. If not set, a randomly generated file name is used.

Request Body schema: application/json
object (InterchangeControl)

Interchange control.

object (FunctionalGroup)

Functional group.

object (Transaction837)

Transaction.

Array of ProfClaim (object) or InstClaim (object)

Claims.

Responses

Response Schema: application/json
Array
objectType
string

Type of this object, always 'VALIDATION'.

issueType
required
string
Enum: "BALANCE" "CONTROL" "INVALID" "INVALID_CODE" "LENGTH_EXCEEDED" "LENGTH_TOO_SHORT" "MISMATCH" "NOT_ALLOWED" "NUMBER_OF_ITEMS" "REQUIRED" "REQUIRED_CODE" "VALUE_NOT_IN_ENUM_LIST" "WRONG_TYPE"

Issue type.

issueObjectClass
string

Class (type) of the object where the issue was detected, such as Claim, ServiceLine, etc.

jsonPath
string

JSON path for the object where the issue was detected.

fieldName
string

Field name or element name.

object (SourceLocation)

Location of the issue in the EDI file.

loop
string

EDI loop where the issue was found.

segment
string

EDI segment ID.

element
string

EDI element designator.

ediCode
string

EDI qualifier or code for the segment if the segment is uniquely identified by the code.

maxNumberOfItems
integer

Maximum number of items allowed for the segment, list, or loop.

actualNumberOfItems
integer

Actual number of items.

length
integer

Expected length of the element's value (LENGTH_TOO_SHORT, LENGTH_EXCEEDED issue types).

actualLength
integer

Actual length (LENGTH_TOO_SHORT, LENGTH_EXCEEDED issue types).

dataType
string
Enum: "BINARY" "COMPOSITE" "DATE" "DECIMAL" "ENUM" "IDENTIFIER" "NUMERIC" "STRING" "TIME"

Expected data type (WRONG_TYPE issue type).

actualDataType
string
Enum: "BINARY" "COMPOSITE" "DATE" "DECIMAL" "ENUM" "IDENTIFIER" "NUMERIC" "STRING" "TIME"

Actual data type (WRONG_TYPE issue type).

codeSubType
string

Type of the code that failed validation (INVALID_CODE issue type), such as HCPCS, ProviderTaxonomy, ICD_10.

value
string

The value that caused the validation to fail.

ediString
string

Value that caused the issue.

message
string

Additional message describing the issue.

allowedValues
Array of strings

Allowed values (VALUE_NOT_IN_ENUM_LIST issue type).

Request samples

Content type
application/json
{
  • "interchangeControl": {
    },
  • "functionalGroup": {
    },
  • "transaction": {
    },
  • "claims": [
    ]
}

Response samples

Content type
application/json
[
  • {
    }
]

NCPDP-to-JSON

Parses text in NCPDP Telecom format and returns JSON with an array of NCPDP transactions.

See an NCPDP transaction and parsing-output example.

Additional examples are available from our GitHub repo.

Convert NCPDP input to JSON

Converts NCPDP Telecom-format input to JSON.

Request Body schema: text/plain
required

Text in NCPDP Telecom format.

string

Responses

Response Schema: application/json
Array of objects (Segment)

Request samples

curl -H "Content-Type: text/plain" --data-binary @../edi_files/ncpdp/b1_telco_cob.dat "$API_URL/ncpdp/parse"

Response samples

Content type
application/json
{
  • "transactions": [
    ]
}