Skip to main content

A python package to communicate with mirth connects client api.

Project description

mirthpy

Basic python api for Mirth Connect

NOTE: This api only has Channels, Code Templates, Events, and Users built in. You should still be able to get to the rest, you'll just need to use the ElementTree to navigate.

Installation

Use the package manager pip to install mirthpy.

pip install mirthpy

Setup

Config file must match the following:

{
    "instanceName": "{instance IP or DNS Name}",
    "credentials": {
        "username": "{username}", 
        "password": "{password}"
    }
}

alternatively you can provide the mirth instance (ip or domain name) and user/pass combo

service = MirthService(username="{username}", password="{password}", instance="{mirthInstance}")

Usage

import json
import mirthpy

config = json.load(open('config.json'))

service = MirthService(config)
service.open()

# Get a list of channels
channels = service.getChannels({"channelId":"3bb08639-7725-4b1b-a2ac-13687101fe9b"}) 

for channel in channels:
    print(f"{channel.name} - {channel.revision}")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mirthpy-0.1.4.tar.gz (11.8 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page