Typed Document
Remove All Complexities From Creating EDI Documents
Developers can now spend more of their time on the business rules and not on intricacies of dealing with EDI”
The tools and your support really make it easier for me to engage in re-writing our application hipaa process from a lot of code from another developer to a sustainable, clearer and logical code with RDPCrystal Typed Document and its extensibility – User
Typed Documents removes all complexities from creating EDI documents by making it truly object-oriented
Main Features
- Cut EDI development in half
- Use feature-rich objects like Typed5010Document and Typed4010Document
- Use high level segment objects like ISA, GS, ST, CLM, IEA (1096+ Typed Segments)
- Easily create loops and segments with a truly Object-Oriented paradigm
- Extensible model allows the creation of custom Typed EDI documents and segments
- Supports all 5010 HIPAA and all 4010 transactions sets
- Code is cleaner, more understandable and maintainable
Details
If you’ve ever created an object and set its properties then you can create EDI documents. Typed Documents (Typed5010Document and Typed4010Document) enables developers to quickly create EDI data without any complexity.
Typed5010Document supports all HIPAA transactions and Typed4010Document supports all 4010 transactions. EDI document creation is intuitive and follows a simple loop structure. There is an object for each 4010 and 5010 segment like ISA, GS, ST, PAT, HI etc. Just set properties on the objects and they will be translated into the EDI format when document generation occurs.
Avoid the Details of EDI formats
Typed Documents takes care of annoying things like empty trailing elements and empty trailing composite elements. These can actually result in EDI files errors and file rejections. Element, composite and segment separators are automatically added at the correct places resulting in a flawless EDI document.
Avoid Worrying about ISA Segment Minimum and Maximum Length Requirements
The ISA segment is special in the X12 standard. It has a fixed length and contains metadata. EDI parsers use this metadata to correctly parse EDI data. If this segment is not created correctly parsing failure will occur. Typed Documents will correctly pad or trim ISA element data to conform to the X12 standard.
Auto Placement of Number of Segments, Transactions and Functional Headers
SE segments must contain the total amount of segments used within that specific transaction. Typed Documents will automatically keep a count of the number of segments used and goes as far as to actually enter that data in the SE segment. Additionally the number of ST Transactions and GS Functional Groups are also tracked and added to the GE and IEA segments respectively.
Typed Documents takes care of the following counting scenarios:
- Adding the correct number of segments in SE segments
- Adding the correct number of transactions in GE segments
- Adding the correct number of functional groups in IEA segments
The Code
Typed5010Document sampleEDIFile = new Typed5010Document();
//Create an interchance loop. This loop will contain all other loops in the EDI structure
DocumentLoop interchangeHeader = sampleEDIFile.MainSection.CreateLoop("Interchange Header");
//Create an ISA segment in the interchange loop
ISA isa = interchangeHeader.CreateSegment();
isa.AuthorizationInformationQualifier = "00";
isa.AuthorizationInformation = "";
isa.SecurityInformationQualifier = "00";
isa.SecurityInformation = "";
isa.InterchangeIDQualifier1 = "ZZ";
isa.InterchangeSenderID = "InterchangeSenderID";
isa.InterchangeIDQualifier2 = "ZZ";
isa.InterchangeReceiverID = "InterchangeReceiverID";
isa.InterchangeDate = "150303";
isa.InterchangeTime = "1804";
isa.RepetitionSeparator = "^";
isa.InterchangeControlVersionNumber = "00501";
isa.InterchangeControlNumber = "1";
isa.AcknowledgmentRequested = "1";
isa.InterchangeUsageIndicator = "P";
isa.ComponentElementSeparator = ":";
//Now create the function header section
DocumentLoop functionalHeader = interchangeHeader.CreateLoop("Functional Header");
GS gs = functionalHeader.CreateSegment();
gs.FunctionalIdentifierCode = "HC";
gs.ApplicationSenderCode = "ApplicationSenderCode";
gs.ApplicationReceiverCode = "ApplicationReceiverCode";
gs.Date = "20150303";
gs.Time = "1424";
gs.GroupControlNumber = "1234";
gs.ResponsibleAgencyCode = "X";
gs.VersionReleaseIndustryIdentifierCode = "005010X222";
//Create a transaction header loop
DocumentLoop transactionHeader = functionalHeader.CreateLoop("Transaction Header");
ST st = transactionHeader.CreateSegment();
st.TransactionSetIdentifierCode = "837";
st.TransactionSetControlNumber = "1";
st.ImplementationConventionReference = "005010X222";
//Add an BHT segment to the transaction header loop
BHT bht = transactionHeader.CreateSegment();
bht.HierarchicalStructureCode = "0019";
bht.TransactionSetPurposeCode = "00";
bht.ReferenceIdentification = "44445";
bht.Date = "20040213";
bht.Time = "0345";
//Create the end of the transaction (SE segment). This must be done in a loop.
DocumentLoop endOfTransactionLoop = transactionHeader.CreateLoop("End Of Transaction");
SE se = endOfTransactionLoop.CreateSegment();
se.TransactionSetControlNumber = "1";
se.NumberOfIncludedSegments = "3";//Create the end of the functional group (GE segment). This must be done in a loop.
DocumentLoop endOfFunctionalGroupLoop = functionalHeader.CreateLoop("End Functional Group");
GE ge = endOfFunctionalGroupLoop.CreateSegment();
ge.GroupControlNumber = "11234";
ge.NumberOfTransactionSetsIncluded = "1";
//Finally create the end of the interchange loop (IEA segment). This must be done in a loop.
DocumentLoop endInterchangeSection = interchangeHeader.CreateLoop("End Interchange");
IEA iea = endInterchangeSection.CreateSegment();
iea.InterchangeControlNumber = "123";
iea.NumberOfIncludedFunctionalGroups = "1";
//Generate the EDI file
string ediData= sampleEDIFile.ToEDIString(new Delimiters());
ISA*00**00**ZZ*InterchangeSenderID*ZZ*InterchangeReceiverID*150303*1804*^*00501*1*1*P*:~
GS*HC*ApplicationSenderCode*ApplicationReceiverCode*20150303*1424*1234*X*005010X222~
ST*837*1*005010X222~
BHT*0019*00*44445*20040213*0345~
SE*3*1~
GE*1*11234~
IEA*1*123~
public void DisplayAllClaims(List claims)
{
int rowNumber = 1;
foreach (DocumentLoop claimSection in claims)
{
SBR subscriber = claimSection.GetSegment();
DocumentLoop subscriberInfo = claimSection.GetLoop("2010BA");
NM1 subName = subscriberInfo.GetSegment();
DocumentLoop insuranceInfoSection = claimSection.GetLoop("2010BB");
NM1 insuranceName = insuranceInfoSection.GetSegment();
DataRow subInfoRow = subscriberTable.NewRow();
subInfoRow[0] = rowNumber;
subInfoRow[1] = subName.NameLastOrOrganizationName + " " + subName.FirstName;
subInfoRow[2] = insuranceName.NameLastOrOrganizationName;
subInfoRow[3] = subscriber.IndividualRelationshipCode;
subInfoRow[4] = subscriber.ClaimFilingIndicatorCode;
subscriberTable.Rows.Add(subInfoRow);
List claimLoopSections = claimSection.GetLoops("2300");
foreach (DocumentLoop cl in claimLoopSections)
{
CLM clm = cl.GetSegment();
DataRow claimInfoRow = claimsTable.NewRow();
claimInfoRow[0] = rowNumber;
claimInfoRow[1] = clm.ClaimSubmitterIdentifier;
claimInfoRow[2] = clm.MonetaryAmount;
claimsTable.Rows.Add(claimInfoRow);
List serviceLineSections = cl.GetLoops("2400");
foreach (DocumentLoop sl in serviceLineSections)
{
//Get the service line segment
SV1 sv1 = sl.GetSegment();
DataRow serviceLineInfoRow = serviceLineTable.NewRow();
serviceLineInfoRow[0] = rowNumber;
serviceLineInfoRow[1] = sv1.CompositeMedicalProcedureIdentifier.ProductServiceID1;
serviceLineInfoRow[2] = sv1.MonetaryAmount1;
serviceLineTable.Rows.Add(serviceLineInfoRow);
}
}
rowNumber++;
}
}
Easily Extendable
Typed Documents have a simple architecture that makes it easy to extend. Custom typed documents and segments can easily be created to support any X12 standard.
Example – Create a custom Typed Document with 3 custom segments
public class MyTypedDocument : TypedDocument
{
public MyTypedDocument()
{
}
protected override DocumentSegment GetDocumentSegment(string segmentName)
{
switch (segmentName)
{
case "CS1":
{
return new CustomSegment1();
}
case "CS2":
{
return new CustomSegment2();
}
case "ABC":
{
return new CustomSegment3();
}
}
return null;
}
}
Supported HIPAA Transactions (95+ Typed Segments)
- (837P) Health Care Claim: Professional
- (837I) Health Care Claim: Institutional
- (837D) Health Care Claim: Dental
- (820) Payroll Deducted/Group Premium Payment Ins. Products
- (820) Health Insurance Exchange Related Payments
- (834) Benefit Enrollment and Maintenance
- (835) Health Care Claim Advice
- (276) Health Care Claim Status Request
- (277) Health Care Claim Status Response
- (270) Health Care Claim Eligibility Request
- (271) Health Care Claim Eligibility Response
- (999) Implementation Acknowledgement
- (277 CA) Health Care Claim Acknowledgment
- (278) Health Care Services Review – Request for Review
- (278) Health Care Services Review – Response
Pingback: How Does the EDIValidator Work – RDPCrystal EDI Library
Pingback: Creating EDI data with TypedDocuments and .Net – RDPCrystal EDI Library
Pingback: Consuming EDI data with TypedDocuments and .Net – RDPCrystal EDI Library
Pingback: Fill PDF Forms with EDI data – RDPCrystal EDI Library
Pingback: Validating Typed Documents – RDPCrystal EDI Library