0% found this document useful (0 votes)
765 views14 pages

Integration of Mirth Connect With OpenEMR2

This document describes how to integrate Mirth Connect with OpenEMR to enable electronic health information exchange. It provides steps to configure a Mirth Connect channel to send and receive HL7 messages from OpenEMR, including setting the source, mappings, destination, and filter. It also describes deploying the channel and verifying the exchange of patient data between the two systems by viewing messages in Mirth Connect and added patients in OpenEMR.

Uploaded by

Muhammad Ali
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
765 views14 pages

Integration of Mirth Connect With OpenEMR2

This document describes how to integrate Mirth Connect with OpenEMR to enable electronic health information exchange. It provides steps to configure a Mirth Connect channel to send and receive HL7 messages from OpenEMR, including setting the source, mappings, destination, and filter. It also describes deploying the channel and verifying the exchange of patient data between the two systems by viewing messages in Mirth Connect and added patients in OpenEMR.

Uploaded by

Muhammad Ali
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

Integrating Mirth Connect with

OpenEMR

Prepared by
ViSolve Inc.,
6559, Springpath Lane, San Jose, California 95120, USA
Email: services@visolve.com
11th January 2019
Version Edited By Date
Initial version ViSolve - Development team 11 January
2020
BUSINESS PROBLEM 5

MIRTH CONNECT 5
Mirth Connect With OpenEMR 5
Test Case Scenario: 6
Mirth Connect Channel 6
Configuration in Mirth Connect: 7

Creating a Channel for OpenEMR 7


Source System 8
Source Transformer (Mappings). 9
Destination System 10
Destination Filter (Optional) 11
Deployment 12
Sending HL7 Message 12
Verification in Mirth and OpenEMR 13

Conclusion 14
References 14
BUSINESS PROBLEM

The need for electronic Health Information Exchange (HIE) among care
professionals are growing along with the efforts to improve the quality,
safety and efficiency of health care delivery. The standardization of health
information and patient data are critical to healthcare organizations and so,
various interconnection engines have been developed to improve the
efficiency of Health Information Exchange. Mirth Connect (MC) is one such
integration engine, and it serves healthcare organizations for more than a
decade and is primarily designed to transfer healthcare information. The
solution could be easily configured, deployed and scaled.

MIRTH CONNECT

Mirth Connect is an integration engine that translates an HL7 message to


other message standards. MC's integration capabilities are as follows:
Filtering – on the way to transformation stage, MC reads a message's
parameters and passes those messages or stops it
Transformation – MC converts the incoming messages from one standard
to another standard (e.g., HL7 to xml)
Extraction – MC can "pull" data from a database and "push" data to a
database
Routing – MC makes sure whether a sent message arrives in their assigned
destinations.

Mirth Connect With OpenEMR

 OpenEMR is the most popular open source electronic health records


and medical practice management solution
 OpenEMR can be enhanced to achieve interoperability with other
healthcare systems
 To Connect OpenEMR with Mirth Connect, we should configure the
Mirth Connect with the database and server details.
 OpenEMR can be either used as server (source) or client (destination)
 Mirth will send / receive data in OpenEMR to other system using HL7
protocols.

Test Case Scenario:

 Consider a scenario, A clinic is using OpenEMR which holds the patient


information and same clinic has an external system like dental
department system. When a new patient enters the dental
department, the information needs to be transferred from dental
system to OpenEMR automatically.
 To achieve this the system needs to send those patient details to
OpenEMR by sending HL7 message via Mirth.
 Source -> Clinic (Dental Department) ; Destination -> OpenEMR

Mirth Connect Channel

Configuration in Mirth Connect:

1. To connect OpenEMR with Mirth, the configuration details has to be


added in the Global scripts.
2. Left Panel -> Channels -> Edit Global Scripts
Fig. 1 - Configuration Details in Mirth Connect

Creating a Channel for OpenEMR

1. The next step is to create a channel in Mirth and name it as “Clinic to


OpenEMR”.
2. Go to Left Panel -> Channels
3. Under Channels (workspace)-> Right Click -> New Channel
4. By clicking new channel , the channel will be created and it will
navigate to the channel summary page
5. Name and description of the channel must be given in the summary
page
Fig. 2 - Channel Summary

Source System

1. Next to the summary tab is the source tab. In the source, set the
connector type as TCP Listener.
2. The user can configure the source channel according to their needs.

Fig.3 - Configuring the Source


Source Transformer (Mappings).

1. Source Tab -> Left Panel -> Edit Transformer -> Message template (In
Right Panel)
2. In the Source transformer paste the sample HL7 message which was
given below. The message tree will expand the segments from HL7
message separately and the PID segment in the HL7 message will have
the patient’s demographics details.

MSH|^~\&||N|||201506250954|3^JLW61|ADT^A08|63728_35_SC6|P|2.3|||||||
PID|1|1000060662|03656495~3131313|8003378|^^^||19330103|F|SANDIEGO^CARLITA**ACO**^^^^|
OTH|601W168THSTREET^APT 5^NEW YORK^NY^10032-3706|060|(212)305-3131^@NONE||POLISH|
SINGLE||123-66-3131|||DRE||||||||N|

3. The Next process is to add new step and map the message variable
4. Now Right click the main tab as shown below and click the Add New
Step
5. Then Give the Variable name and Default Value Here

Fig. 4 - Source Transformer Mapping


6. Now Click on the message tree and expand the HL7 message by
clicking the plus icon
7. Now Drag the Name from message tree and drop the name in Mapping
, This will map the variable and save the new step
8. The Example Mapping of first name with the variable name
patient_fname is given in the below figure.

Fig. 4.1 - Source Transformer Mapping


Destination System

1. Next to the Source Tab, Destination tab is located


2. Based on the specified scenario, OpenEMR is the destination. Create a
destination named OpenEMR-ADT by right clicking on the Destination
3. A sample script has been given below the figure.

Fig. 5 - Destination System


var params = new Packages.java.util.ArrayList();
var patient_id = make_pid($('idx_mrn'));
params.clear();
params.add($('patient_fname'));
params.add($('patient_lname'));
params.add(($('patient_dob')));
params.add($('patient_sex'));
params.add(patient_id);
params.add($('idx_mrn'));
result = dbConn.executeUpdateAndGetGeneratedKeys($g('insert_patient'), params);

4. The Variables used in this code where the same variable which was
mapped earlier in Source transformer.
Destination Filter (Optional)

1. Left Panel -> Edit Filter .


2. Right Click the Main tab as shown in the figure and then click “Add
New Rule” to add new condition for the message filter.
3. We need to map variable from HL7 message along with the conditions
and values.
4. For Example, if the system should accept only ADT^A04 message type
then we need to add $(‘mirth_type’) in Field which will be the message
header(predefined variable for message header in mirth), then select
the Condition as exists ,and value as “ADT-A04” as given in the
figure.
5. Finally the Filter will be added in the destination.

Fig. 6 - Destination Filter


Deployment

1. The global variable $g(‘insert_patient’) is declared in global scripts as


shown in figure which will insert the data into the openemr database
as a final step.
2. After completing the channel changes, the channel should be deployed
3. Left Panel -> Right Click on the Channel Name -> Deploy Channel
4. This will Deploy the Channel and the channel will be started

Fig. 7- Query in Global Script


Sending HL7 Message

1. In dashboard->Right-click-> Send message ,then paste the below


sample message
2. The Sample Message will contain patient details inside the PID
segment of the HL7 message
MSH|^~\&||N|||201506250954|3^JLW61|ADT^A08|63728_35_SC6|P|2.3|||||||
PID|1|1000060662|03656495~3131313|8003378|^^^||19330103|F|SANDIEGO^CARLITA**ACO**^^^^|OTH|
601W168THSTREET^APT 5^NEW YORK^NY^10032-3706|060|(212)305-3131^@NONE||POLISH|SINGLE||123-66-
3131|||DRE||||||||N|

Fig. 8- Sending HL7 Message


Verification Process in Mirth and OpenEMR

1. Status of a message can be seen at the top of the dashboard


page and also in the server log in the bottom of the dashboard

Fig. 9- Message Status

2. Finally, after a message is sent, the patient details can be seen


in our OpenEMR

Fig. 10- OpenEMR Patient List


Fig. 11- Created Patient Details
Conclusion

The details or procedures specified in this document is based on a sample


test case scenario to create a patient using Mirth with HL7 protocol. By using
the same process one can create / update patient demographics and
schedule appointments. One can write custom scripts according to their
needs in OpenEMR.

References

1. Download link for Mirth Connect https://www.nextgen.com/products-and-


services/nextgen-connect-integration-engine-downloads
2. Note: To know in detail about HL7 message formats please refer
https://www.hl7soup.com/HL7TutorialWhatIsHL7.html#:~:targetText=HL7%20is%20a
%20set%20of,systems%20speak%20the%20same%20language.
3. The system requirements and installation process can be followed in
the user guide https://www.nextgen.com/-/media/files/nextgen-connect/nextgen-
connect-38-user-guide.pdf.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy