Complete User Guide

Step-by-step guide from installation to advanced features. Perfect for beginners!

What is InteropSuite?

InteropSuite is a healthcare data transformation library that converts legacy formats into FHIR R4 - the modern standard for healthcare data exchange.

Input FormatWhat It IsExample
HL7 v2.xHospital messages (admissions, labs)MSH|^~\&|...
X12 5010Insurance transactions (claims)ISA*00*...~
C-CDAClinical documents (summaries)<ClinicalDocument>

Four Processing Pipelines

HL7 US Core 6.1.0
CDA US Core 6.1.0
X12 US Core 6.1.0
CMS-0057-F Federal Mandate

What You'll Need

1. .NET 9.0 SDK

Check if you have it installed:

dotnet --version

You should see 9.0.x or higher. If not, download from dotnet.microsoft.com/download

2. A License Key

You'll receive a license key when you purchase InteropSuite. It looks like this:

eyJpZCI6IklTLTIwMjYwMTE1LTRMRDdURyIs...

3. A .NET Project

If you don't have one yet, create a new console app:

dotnet new console -n MyHealthcareApp
cd MyHealthcareApp

Installation

InteropSuite is available on NuGet.org. Install it with a single command.

Step 1: Open a Terminal

You'll need to run a command. Here's how to open a terminal:

Operating SystemHow to Open Terminal
WindowsPress Win + R, type cmd, press Enter
macOSPress Cmd + Space, type Terminal, press Enter
LinuxPress Ctrl + Alt + T

Step 2: Navigate to Your Project

Change to your project directory. If you don't have a project yet, create one first (see What You'll Need).

# Windows
cd C:\Projects\MyHealthcareApp

# macOS / Linux
cd ~/Projects/MyHealthcareApp

Step 3: Install InteropSuite

Run this command to add InteropSuite to your project:

dotnet add package InteropSuite

Success looks like:

info : Adding PackageReference for package 'InteropSuite' into project 'MyHealthcareApp.csproj'.
info : Package 'InteropSuite' is compatible with all the specified frameworks.
info : PackageReference for package 'InteropSuite' version '1.0.5' added to file 'MyHealthcareApp.csproj'.

Step 4: Verify Installation

Check that the package was added to your project file:

dotnet list package

You should see InteropSuite in the list:

Project 'MyHealthcareApp' has the following package references
   [net9.0]:
   Top-level Package      Requested   Resolved
   > InteropSuite         *           1.0.5
Installation Complete!

InteropSuite is now installed. Next, activate your license (see below) and start transforming healthcare data!

Troubleshooting Installation

ErrorSolution
Unable to find package InteropSuite Check your internet connection. The package is downloaded from NuGet.org.
Access denied On Windows, try running Command Prompt as Administrator. On macOS/Linux, check folder permissions.
'dotnet' is not recognized The .NET SDK isn't installed. Download from dotnet.microsoft.com/download

License Activation

You have three ways to activate your license:

Method 1: Environment Variable (Best for Servers)

macOS/Linux:

export INTEROPSUITE_LICENSE="your-license-key"

Windows (PowerShell):

$env:INTEROPSUITE_LICENSE = "your-license-key"

Method 2: License File

Create a file named interopsuite.lic in your project folder with just your license key.

Method 3: In Your Code (Simplest)

using InteropSuite.Fhir.Engine;

// Activate with your license key
Interop.ActivateLicense("your-license-key");

IDE Setup

We recommend Visual Studio Code - a free, lightweight editor that works on Windows, macOS, and Linux.

Visual Studio Code Setup

Step 1: Install VS Code

  1. Go to code.visualstudio.com
  2. Click the big Download button (it detects your operating system)
  3. Run the downloaded installer
  4. Follow the installation wizard (default options are fine)
  5. Launch VS Code when installation completes

Step 2: Install the C# Extension

  1. In VS Code, look at the left sidebar
  2. Click the Extensions icon (it looks like 4 squares, or press Ctrl+Shift+X)
  3. In the search box at the top, type: C# Dev Kit
  4. Find "C# Dev Kit" by Microsoft (it has a blue verified checkmark)
  5. Click the blue Install button
  6. Wait for installation to complete (may take a minute)
What is C# Dev Kit?

This extension adds C# language support to VS Code: syntax highlighting, IntelliSense (auto-complete), debugging, and project management.

Step 3: Create a New Project

  1. Open VS Code
  2. Open the Terminal: View menu → Terminal (or press Ctrl+`)
  3. Navigate to where you want to create your project:
    # Windows
    cd C:\Projects
    
    # macOS/Linux
    cd ~/Projects
  4. Create a new console application:
    dotnet new console -n MyHealthcareApp
  5. Open the new project folder:
    cd MyHealthcareApp
    code .
  6. VS Code will open with your new project
  7. If prompted "Do you trust the authors?", click Yes, I trust the authors

Step 4: Install InteropSuite NuGet Package

  1. In VS Code, open the Terminal (Ctrl+`)
  2. Install InteropSuite from NuGet.org:
    dotnet add package InteropSuite
  3. You should see: info : Package 'InteropSuite' is compatible with all the specified frameworks

Step 5: Write Your First Code

  1. In VS Code, click on Program.cs in the left sidebar to open it
  2. Delete all the existing code
  3. Paste this code:
    using InteropSuite.Fhir.Engine;
    
    // Activate your license
    Interop.ActivateLicense("your-license-key-here");
    
    // Sample HL7 message
    string hl7Message = @"MSH|^~\&|SENDING|FACILITY|RECEIVING|FACILITY|20231015120000||ADT^A01|MSG001|P|2.5.1
    PID|1||12345^^^HOSP^MR||DOE^JOHN^Q||19800101|M";
    
    // Transform to FHIR
    var result = await Interop.HL7ToFhirAsync(hl7Message);
    
    if (result.Success)
    {
        Console.WriteLine("Success! FHIR Bundle:");
        Console.WriteLine(result.FhirBundle);
    }
    else
    {
        Console.WriteLine("Errors:");
        foreach (var error in result.Errors)
            Console.WriteLine(error);
    }
  4. Save the file: Ctrl+S

Step 6: Run Your Application

  1. Open Terminal in VS Code (Ctrl+`)
  2. Run the application:
    dotnet run
  3. You should see the FHIR bundle output in the terminal!

Keyboard Shortcuts

ActionShortcut
Run/DebugF5
Run without DebugCtrl+F5
Open TerminalCtrl+`
Go to DefinitionF12 or Ctrl+Click
Find in FilesCtrl+Shift+F
Save FileCtrl+S
Comment/UncommentCtrl+/
Using Visual Studio or another IDE?

InteropSuite works with any .NET IDE. The dotnet CLI commands work the same way in any terminal.

Troubleshooting

ProblemSolution
'dotnet' is not recognized Install the .NET SDK from dotnet.microsoft.com/download
Package not found Check your internet connection and verify the package source is set to nuget.org
Red squiggly lines under Interop Add using InteropSuite.Fhir.Engine; at the top of your file
License error Make sure you called Interop.ActivateLicense("key") before any other Interop methods
Build errors about async Make sure your code is inside an async method, or use top-level statements (default in .NET 6+)

HL7 v2.x Messages

HL7 v2.x messages are pipe-delimited text messages used by hospitals.

using InteropSuite.Fhir.Engine;

// Your HL7 message
string hl7Message = @"MSH|^~\&|SENDING|FACILITY|...";

// Transform it
var result = await Interop.HL7ToFhirAsync(hl7Message);

if (result.Success)
{
    string fhirJson = result.FhirBundle;
    Console.WriteLine($"Detected: {result.DetectedFormat}");
}

Supported Message Types (30 total)

  • ADT - A01, A02, A03, A04, A05, A08, A11, A12, A13, A28, A31, A40
  • ORU - R01, R30, R32 (Lab Results)
  • ORM/OML - O01, O21 (Orders)
  • SIU - S12, S13, S14, S15, S26 (Scheduling)
  • MDM - T02, T04, T06 (Documents)
  • VXU - V04 (Immunizations)
  • RDS/RDE - O13, O11 (Pharmacy)
  • DFT - P03 (Financial)

X12 5010 Transactions

X12 is the format used by insurance companies in the US.

using InteropSuite.Fhir.Engine;

// Your X12 transaction
string x12Message = "ISA*00*...";

// Transform it
var result = await Interop.X12ToFhirAsync(x12Message);

if (result.Success)
{
    Console.WriteLine($"Detected: {result.DetectedFormat}"); // e.g., "X12^837P"
}

Supported Transaction Types

TransactionDescriptionFHIR Output
270/271EligibilityCoverageEligibilityRequest/Response
278Prior AuthorizationClaim + ClaimResponse
834EnrollmentCoverage + Patient
835RemittanceExplanationOfBenefit
837P/I/DClaimsClaim

C-CDA Documents

C-CDA is an XML format for clinical documents like patient summaries.

using InteropSuite.Fhir.Engine;

// Your C-CDA document
string cdaDocument = "<ClinicalDocument>...</ClinicalDocument>";

// Transform it
var result = await Interop.CDAToFhirAsync(cdaDocument);

if (result.Success)
{
    Console.WriteLine($"Detected: {result.DetectedFormat}"); // e.g., "CDA^34133-9"
}

Supported Document Types

  • CCD (34133-9) - Continuity of Care Document
  • Discharge Summary (18842-5)
  • Progress Note (11506-3)
  • Consultation Note (11488-4)
  • History & Physical (34117-2)
  • Operative Note (11504-8)
  • Referral Note (57133-1)

CMS-0057-F Compliance

Federal Mandate

CMS-0057-F requires health plans to exchange patient data using standardized FHIR APIs with specific profiles.

Use OutputFormat.Cms0057F to generate compliant bundles:

// Standard US Core output
var usCore = await Interop.X12ToFhirAsync(x12Message);

// CMS-0057-F compliant output
var cms = await Interop.X12ToFhirAsync(x12Message, OutputFormat.Cms0057F);

Profile Mapping

X12 TransactionCMS-0057-F Profile
278Da Vinci PAS 2.0.1
270/271US Core 6.1.0
835CARIN Blue Button 2.1.0
837P/I/DCARIN Blue Button 2.1.0

Batch Processing

Process hundreds or thousands of files at once. InteropSuite supports two batch processing modes.

Processing Modes

ModeDescriptionBest For
Sequential Process one directory at a time Simple single-format batches
Unified Recommended Process multiple directories with RoundRobin interleaving Mixed formats, no blocking between domains

Unified Processing (Recommended)

Process multiple directories in a single call. Files are interleaved across sources so no domain blocks another.

using InteropSuite.Fhir.Engine;
using InteropSuite.Fhir.Engine.Batch;

var options = new BatchOptions
{
    Sources = new[]
    {
        new BatchSource("input/hl7", "HL7", OutputFormat.UsCore),
        new BatchSource("input/x12", "X12", OutputFormat.UsCore),
        new BatchSource("input/cda", "CDA", OutputFormat.UsCore),
        new BatchSource("input/cms", "CMS-0057-F", OutputFormat.Cms0057F),
    }
};

// Files interleaved: HL7[0], X12[0], CDA[0], CMS[0], HL7[1]...
var result = await Interop.ProcessBatchAsync(options);

Console.WriteLine($"Total: {result.TotalFiles}");
Console.WriteLine($"Succeeded: {result.Succeeded}");
Console.WriteLine($"Failed: {result.Failed}");
Why Unified Mode?

Each source can have its own OutputFormat. A single TraceServer session shows all domains together, making it easy to monitor mixed workloads.

Sequential Processing

Process one directory at a time. Each batch completes before the next starts.

using InteropSuite.Fhir.Engine;
using InteropSuite.Fhir.Engine.Batch;

var options = new BatchOptions
{
    Domain = "HL7",
    OutputFormat = OutputFormat.UsCore
};

var result = await Interop.ProcessBatchAsync("./input", options);

Console.WriteLine($"Total: {result.TotalFiles}");
Console.WriteLine($"Succeeded: {result.Succeeded}");
Console.WriteLine($"Failed: {result.Failed}");

BatchSource Parameters

ParameterTypeDescription
inputDirectorystringPath to input files
domainstringDomain identifier for TraceServer (HL7, X12, CDA, CMS-0057-F)
outputFormatOutputFormatUsCore or Cms0057F

Domain Options (Sequential Mode)

DomainInputOutput Profiles
"HL7"HL7 v2.x messagesUS Core 6.1.0
"CDA"C-CDA documentsUS Core 6.1.0
"X12"X12 transactionsUS Core 6.1.0
"CMS-0057-F"X12 transactionsDa Vinci PAS, CARIN BB
"Mixed"Any formatAuto-selected

TraceServer Dashboard

Real-time monitoring dashboard for your transformations. TraceServer displays transformation history, validation results, and performance metrics in a web-based UI.

Step 1: Download for Your Platform

Download the ZIP file for your operating system:

Step 2: Extract and Run

Extract the ZIP file to any folder. Then run the executable:

Windows

Run from Command Prompt, pointing to your app's dashboard directory:

InteropSuite.TraceServer.exe -d C:\path\to\your\app\interopsuite\dashboard

macOS / Linux

Open Terminal in the extracted folder and run:

# Make executable (first time only)
chmod +x InteropSuite.TraceServer

# Run with -d pointing to your app's dashboard directory
./InteropSuite.TraceServer -d /path/to/your/app/interopsuite/dashboard

macOS users: If blocked by Gatekeeper, run this once:

xattr -d com.apple.quarantine ./InteropSuite.TraceServer 2>/dev/null
Required: Use -d flag

TraceServer must be pointed to your app's dashboard directory using -d. This is where InteropSuite writes session data when Interop.DashboardEnabled = true.

You should see:

InteropSuite Trace Server
=========================

Server running at: http://localhost:8765/report.html
Dashboard directory: /path/to/your/app/interopsuite/dashboard

Press Ctrl+C to stop.

Command-Line Options

# Show help
./InteropSuite.TraceServer --help

# Point to specific dashboard directory
./InteropSuite.TraceServer -d /path/to/dashboard
./InteropSuite.TraceServer --directory /path/to/dashboard

# Or just pass the path directly
./InteropSuite.TraceServer /path/to/dashboard

Step 3: Open the Dashboard

Open your browser and navigate to:

http://localhost:8765/report.html

Tip

Keep TraceServer running in a separate terminal window while you process files with InteropSuite.

Troubleshooting

ProblemSolution
Port 8765 already in use Stop any other process using that port, or check if TraceServer is already running
Dashboard shows no data Make sure Interop.DashboardEnabled = true in your app (see below)
macOS: "cannot be opened because the developer cannot be verified" Right-click the executable → Open → Open anyway

Enable Dashboard in Your Application

TraceServer displays data generated by your InteropSuite application. You must enable dashboard data generation in your code:

using InteropSuite.Fhir.Engine;

// Enable dashboard data generation (required!)
Interop.DashboardEnabled = true;

// Optional: Configure data retention (default: 7 days)
Interop.DashboardRetentionDays = 7;

// Now process files - TraceServer will see them!
var result = await Interop.ProcessBatchAsync("./input", options);
Important

Without Interop.DashboardEnabled = true, no data will appear in the dashboard! This setting must be enabled before processing files.

What Gets Tracked

Processing MethodTracked in Dashboard
Interop.ToFhirAsync(string) ❌ No (in-memory only)
Interop.ToFhirAsync(string, filePath) ✅ Yes (Live session)
Interop.ProcessBatchAsync(...) ✅ Yes (Batch session)

Dashboard Data Location

Your application writes dashboard data to:

# Relative to your application directory
{workingDir}/interopsuite/dashboard/sessions/

# Example: if your app is in /Users/john/MyHealthApp/
/Users/john/MyHealthApp/interopsuite/dashboard/sessions/

To view this data, point TraceServer to your app's dashboard directory:

# Point TraceServer to your app's data
./InteropSuite.TraceServer -d /path/to/your/app/interopsuite/dashboard

# Or use environment variable
export INTEROPSUITE_DASHBOARD_DIR=/path/to/your/app/interopsuite/dashboard
./InteropSuite.TraceServer
Path Override

You can customize all data paths using environment variables: INTEROPSUITE_ROOT, INTEROPSUITE_DASHBOARD_DIR, INTEROPSUITE_AUDIT_DIR, INTEROPSUITE_QUARANTINE_DIR, INTEROPSUITE_OUTPUT_DIR

API Reference

Namespace

using InteropSuite.Fhir.Engine;
using InteropSuite.Fhir.Engine.Batch;  // For batch processing

Single Message Methods

MethodDescription
Interop.HL7ToFhirAsync(string)Transform HL7 v2.x to FHIR
Interop.X12ToFhirAsync(string)Transform X12 to FHIR (US Core)
Interop.X12ToFhirAsync(string, OutputFormat)Transform X12 with profile selection
Interop.CDAToFhirAsync(string)Transform C-CDA to FHIR
Interop.ToFhirAsync(string)Auto-detect format and transform

Result Handling

var result = await Interop.ToFhirAsync(message);

if (result.Success)
{
    string fhir = result.FhirBundle;      // FHIR JSON string
    string format = result.DetectedFormat; // e.g., "HL7 ADT^A01"
}
else
{
    foreach (var error in result.Errors)
    {
        Console.WriteLine(error);
    }
}