Skip to main content

Prerequisites

  • Pidgeon CLI installed (dotnet tool install -g pidgeon)
  • Access to Mirth Connect’s file writer output directories
  • A vendor profile for your message patterns (optional but recommended)

Step 1: Identify Mirth output directories

Mirth Connect file writer destinations typically save to a configured directory. Common paths:
/var/mirth/outbound/er-adt/
/var/mirth/outbound/lab-results/
/var/mirth/outbound/pharmacy/
Check your Mirth channel configuration for the exact paths.

Step 2: Create a vendor profile

If you have sample messages from each interface, create a profile so Loft knows what “correct” looks like:
pidgeon config analyze --samples /var/mirth/outbound/er-adt/ --save mirth_er_adt
pidgeon config analyze --samples /var/mirth/outbound/lab-results/ --save mirth_lab

Step 3: Start monitoring via CLI

Watch a single interface:
pidgeon loft watch \
  --directory /var/mirth/outbound/er-adt/ \
  --profile mirth_er_adt \
  --file-pattern "*.hl7"
Loft monitors the directory, validates each new message as it arrives, and alerts on failures.

Step 4: Create interfaces via API

For production setups, create interfaces through the Bridge API so they persist and appear in the Console dashboard:
# Create ER ADT interface
curl -X POST https://api.pidgeon.health/api/loft/interfaces \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Mirth ER ADT",
    "directoryPath": "/var/mirth/outbound/er-adt/",
    "profileName": "mirth_er_adt",
    "filePattern": "*.hl7"
  }'

# Create Lab Results interface
curl -X POST https://api.pidgeon.health/api/loft/interfaces \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Mirth Lab Results",
    "directoryPath": "/var/mirth/outbound/lab-results/",
    "profileName": "mirth_lab",
    "filePattern": "*.hl7"
  }'

Step 5: Configure alerting

Set up alerts in the Console or via the API. Loft supports:
ChannelWatchInsightCommand
Console outputYesYesYes
File logYesYesYes
WebhookYesYesYes
EmailYesYes
SlackYesYes
PagerDutyYesYes

Step 6: Monitor metrics

Check interface health through the API:
# Get metrics for the last 24 hours
curl https://api.pidgeon.health/api/loft/interfaces/{id}/metrics?sinceHours=24
Or view the dashboard in the Console at app.pidgeon.health.

Step 7: Trace patient journeys

Track a specific patient’s messages across interfaces:
curl "https://api.pidgeon.health/api/loft/traces?patient_id=MRN12345&since=2026-02-01"
This returns every message processed for that patient across all monitored interfaces, with timestamps and validation results.

Real-time updates

Subscribe to live updates via SignalR for real-time dashboard integration:
const connection = new HubConnectionBuilder()
  .withUrl("https://api.pidgeon.health/hubs/loft", {
    accessTokenFactory: () => token
  })
  .build();

connection.on("AlertReceived", (alert) => {
  console.log("Alert:", alert.severity, alert.message);
});

await connection.start();
await connection.invoke("SubscribeToAll");

Next steps