Skip to main content

Integration & IT Modernization

Solving Transformation and Routing of an EDI 837 Health Claim

Health Level Seven International (HL7) is a not-for-profit, ANSI-accredited standard-developing organization dedicated to providing a comprehensive framework and related standards for the exchange, integration, sharing, and retrieval of electronic health information that supports clinical practice and the management, delivery, and evaluation of health services. We use these standards to communicate and exchange information at the integration layer with Apache Camel, Active MQ, and the Smooks framework.

JBoss Fuseshutterstock_317047289

JBoss Fuse combines several technologies, Apache Camel, Apache CXF, Apache ActiveMQ, Apache Karaf, and Fabric8 in a single integrated distribution. We will be using the community edition of JBoss Fuse for this example.

What is Smooks?

Straight from the Smooks page (http://www.smooks.org):

“Smooks is an extensible framework for building applications for processing XML and non XML data (CSV, EDI, Java etc.) using Java.”

While Smooks can be used as a lightweight platform on which to build your own custom processing logic for a wide
range of data formats, “out of the box” it comes with some very useful features that can be used individually,
or seamlessly combined together:

  • Java Binding – Populate a Java Object Model from a data source (CSV, EDI, XML, Java etc). Populated object models can be used as a transformation result itself, or can be used by (e.g.) Templating resources for generating XML or other character based results. Also supports Virtual Object Models (Maps and Lists of typed data), which can be used by EL and Templating functionality.
  • Transformation – Perform a wide range of Data Transforms – XML to XML, CSV to XML, EDI to XML, XML to EDI, XML to CSV, Java to XML, Java to EDI, Java to CSV, Java to Java, XML to Java, EDI to Java etc.
  • Huge Message Processing – Process huge messages (GBs) – Split, Transform and Route message fragments to JMS, File, Database etc destinations.
  • Message Enrichment – Enrich a message with data from a Database, or other Datasources.
  • Complex Message Validation – Rules based fragment validation.
  • Combine Perform – Extract Transform Load (ETL) operations by leveraging Smooks’ Transformation, Routing and Persistence functionality.

Using Smooks with JBoss Fuse and Camel

The approach to engaging Smooks in JBoss Fuse with Apache Camel is with a Java Bean called within the route. A Java Bean transforms the payload from a String to XML using the Smooks framework in a route.

Submit an EDI 837 Health Care Claim with Partner Picking Up Claim

The Health Insurance Portability and Accountability Act was enacted by the U.S congress in 1996. A key component of HIPAA is the establishment of national standards for electronic healthcare transactions and national identifiers for providers, health insurance plans, and employers. The HIPAA EDI transaction sets are based on X12. The use case for this example is EDI 837 transaction set, Healthcare Claim: Example Web Service (using REST dsl) that accepts an EDI healthcare claim as plain text EDI and processes it to XML with the Smooks framework and puts on a queue for partner to pick up.

Route 1 (Receive Claim) – REST web service listens on http for claims to process. Upon an inbound request, the web service forwards to Route 2 (Process Claim)

Route 2 (Process Claim) – The route using Smooks framework marshals the payload to XML from String and puts on a queue for partner to pick up.

Route 3 (Pickup Claim) – This route simulates a partner picking up the claim. The claim is written to a file for further processing.

usecasesmooks

Figure 1.

If you want to try out the example use case, it is at:

https://github.com/thiswebs4u/editoxmlexample.git

Refer to Readme.md for installation and use.

References:

http://www.hl7.org/
https://en.wikipedia.org/wiki/Health_Level_7
http://www.jboss.org/products/fuse/overview/
http://www.smooks.org/mediawiki/index.php?title=Main_Page

If you have questions or issues with these instructions, please share below.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Follow Us