HL7 Integration using Mule Healthcare Toolkit- Part 3

DZone 's Guide to

HL7 Integration using Mule Healthcare Toolkit- Part 3

Continuing from Part 2 of this series, this tutorial walks you through installation of Mule Healthcare Toolkit, which facilitates integration with HL7 healthcare systems.

· Integration Zone ·
Free Resource

In this article, we will cover the HL7 Delete Segment Component and HL7 Encoding Transformer. This article continues from Part 2, located here.

HL7 Delete Segment Component

Working with instances of HAPI message objects, this component deletes a segment from an HL7 message. If your HL7 message is not a HAPI message object, you must use the HL7 Encoding Transformer to convert it before it passes through the Delete Segment component.

HL7 Encoding Transformer

This transformer allows you to convert an HL7 message to and from the following formats:

  • HL7 XML.

  • HL7 ER7.

  • HAPI Message Object.

When configuring this transformer, you define the HL7 message encoding for the output message only. The transformer automatically detects the format of the incoming message and applies the conversion accordingly. You can use this transformer as a building block in your flow or as a Global Element, which you define once and then reference from your building blocks.

The below Mule project explains how to delete a segment from an inbound message and change the format from ER7 to XML. Here are the steps to configure this flow:

  1. Place the HL7 MLLP in the source area and HL7 Delete Segment, HL7 Encoding transformer and Logger in the process area.Image title

  2. Inbound message snapshot of ADT_A01 message:Image title

  3. Configuration of the HL7 Delete segment component; we will delete the EVN segment placed in between the MSH and PID segments:Image title

  4. Configuration of the HL7 Encoding Transformer component; we will change the format from ER7 to XML:Image title

  5. Launch the project in debug mode.

  6. Send the above ADT_A01 message from the HL7 interface client.

  7. After passing the HL7 Delete segment, the EVN segment is deleted:Image title

  8. After passing the HL7 Encoding Transformer component, the format has been changed from ER7 to XML:Image title

  9. Logged XML payload in console:Image title

Find more details on MuleSoft Healthcare Toolkit here.

This article will be continued in Part 4, coming soon.

mule ,integration ,integration tools ,mulesoft ,hl7

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}