OnyeOne Documentation
  1. Health Data Transformation
OnyeOne Documentation
  • Overview
  • OnyeOne Use Cases
  • Authentication
  • Guides
    • OnyeOne Request Flow
  • Core EHR/EMR FHIR R4 APIs
    • Administration
      • Patients
        • Create Patient Resource
        • Update Patient Resource
      • Practitioners
        • Create Practitioner Resource
        • Update Practitioner Resource
        • Create Practitioner Role
        • Update PractitionerRole Resource
      • Locations
        • Create a Location Resource
        • Update Location Resource
      • Health Service
        • Create Health Service Resource
        • Update Health Service Resource
      • Encounters
        • Create Encounter Resource
        • Update Encounter Resource
      • Appointments
        • Create Appointment Resource
        • Update Appointment Resource
      • Group
    • Clinical
      • AllergyIntolerance
      • Condition (Problem)
      • Procedure
      • FamilyMemberHistory
      • CarePlan
      • Goal
      • CareTeam
      • ClinicalImpression
      • AdverseEvent
      • DetectedIssue
      • RiskAssessment
    • Diagnostics
      • Observation
        • Create Observation Resource
      • DiagnosticReport
      • ServiceRequest
      • Media
      • ImagingStudy
      • MolecularSequence
      • Specimen
      • BodyStructure
    • Medications
      • MedicationRequest
      • MedicationDispense
      • MedicationAdministration
      • MedicationStatement
      • Medication
      • MedicationKnowledge
      • Immunization
      • ImmunizationEvaluation
      • ImmunizationRecommendation
    • Financial
      • Account
      • Contract
      • Coverage
      • CoverageEligibilityRequest
      • CoverageEligibilityResponse
      • EnrollmentRequest
      • EnrollmentResponse
      • Claim
      • ClaimResponse
      • PaymentNotice
      • PaymentReconciliation
      • ExplanationOfBenefit
      • VisionPrescription
  • Health Data Transformation
    • Transfrom HL7v2 to FHIR R4
      POST
    • Transform CCDA to FHIR R4
      POST
    • Transform HL7v2 to FHIR R4 and Store in Backend Database
      POST
    • Track API Request
      GET
  • Health Interoperabilty System
    • Create a Subscription
      POST
  • Webhook
  • Get Resource.
    GET
  1. Health Data Transformation

Transfrom HL7v2 to FHIR R4

Testing Env
https://staging.onyeone.com/api
Testing Env
https://staging.onyeone.com/api
POST
/hie/transform/hl7v2-fhir/
hie
This API converts HL7v2 messages into FHIR R4 resources, allowing seamless mapping and transformation of clinical data. It supports essential mappings, validation, and structuring to comply with FHIR R4 standards, enabling accurate and consistent data representation across healthcare applications.

Request

Authorization
Add parameter in header
x-api-key
Example:
x-api-key: ********************
Body Params multipart/form-data
data
string 
required
Hl7v2 message.
Example:
MSH|^~\&|ADT1|GOOD HEALTH HOSPITAL|GHH LAB, INC.|GOOD HEALTH HOSPITAL|198808181126|SECURITY|ADT^A01^ADT_A01|MSG00001|P|2.8||EVN|A01|200708181123||PID|1||PATID1234^5^M11^ADT1^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS||EVERYMAN^ADAM^A^III||19610615|M||C|2222 HOME STREET^^GREENSBORO^NC^27401-1020|GL|(555) 555-2004|(555)555-2004||S||PATID12345001^2^M10^ADT1^AN^A|444333333|987654^NC|NK1|1|NUCLEAR^NELDA^W|SPO^SPOUSE||||NK^NEXT OF KINPV1|1|I|2000^2012^01||||004777^ATTEND^AARON^A|||SUR||||ADM|A0|

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://staging.onyeone.com/api/hie/transform/hl7v2-fhir/' \
--header 'x-api-key;' \
--form 'data="MSH|^~\\&|ADT1|GOOD HEALTH HOSPITAL|GHH LAB, INC.|GOOD HEALTH HOSPITAL|198808181126|SECURITY|ADT^A01^ADT_A01|MSG00001|P|2.8||EVN|A01|200708181123||PID|1||PATID1234^5^M11^ADT1^MR^GOOD HEALTH HOSPITAL~123456789^^^USSSA^SS||EVERYMAN^ADAM^A^III||19610615|M||C|2222 HOME STREET^^GREENSBORO^NC^27401-1020|GL|(555) 555-2004|(555)555-2004||S||PATID12345001^2^M10^ADT1^AN^A|444333333|987654^NC|NK1|1|NUCLEAR^NELDA^W|SPO^SPOUSE||||NK^NEXT OF KINPV1|1|I|2000^2012^01||||004777^ATTEND^AARON^A|||SUR||||ADM|A0|"'

Responses

🟢200Success
application/json
Body
messageType
string 
required
data
object 
required
resourceType
string 
required
type
string 
required
timestamp
string 
required
identifier
object 
required
id
string 
required
entry
array [object {3}] 
required
Example
{
    "messageType": "ADT_A01",
    "data": {
        "resourceType": "Bundle",
        "type": "batch",
        "timestamp": "1988-08-18T11:26:00Z",
        "identifier": {
            "value": "MSG00001"
        },
        "id": "513a3d06-5e87-6fbc-ad1b-170ab430499f",
        "entry": [
            {
                "fullUrl": "urn:uuid:64c2d51b-34a4-e841-fb1c-03f1f7762d1a",
                "resource": {
                    "resourceType": "MessageHeader",
                    "id": "64c2d51b-34a4-e841-fb1c-03f1f7762d1a",
                    "source": {
                        "name": "ADT1",
                        "_endpoint": {
                            "extension": [
                                {
                                    "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason",
                                    "valueCode": "unknown"
                                }
                            ]
                        }
                    },
                    "destination": [
                        {
                            "name": "19610615",
                            "_endpoint": {
                                "extension": [
                                    {
                                        "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason",
                                        "valueCode": "unknown"
                                    }
                                ]
                            },
                            "receiver": {
                                "reference": "Organization/50d6f04f-9cf3-df34-6b73-76c6a349edc1"
                            }
                        }
                    ],
                    "meta": {
                        "security": [
                            {
                                "display": "SECURITY"
                            }
                        ],
                        "tag": [
                            {
                                "code": "P",
                                "system": "http://terminology.hl7.org/CodeSystem/v2-0103"
                            }
                        ]
                    },
                    "eventCoding": {
                        "code": "A01",
                        "system": "http://terminology.hl7.org/CodeSystem/v2-0003",
                        "display": "ADT^A01^ADT_A01"
                    },
                    "language": "1",
                    "sender": {
                        "reference": "Organization/2d7d77cd-0ca7-13a5-c9ed-6e70b739adb4"
                    }
                },
                "request": {
                    "method": "PUT",
                    "url": "MessageHeader/64c2d51b-34a4-e841-fb1c-03f1f7762d1a"
                }
            },
            {
                "fullUrl": "urn:uuid:88f72da1-0474-6ee6-34d5-00f1b20b495c",
                "resource": {
                    "resourceType": "Provenance",
                    "id": "88f72da1-0474-6ee6-34d5-00f1b20b495c",
                    "text": {
                        "status": "generated",
                        "div": "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><span>Resource bundle generated on 2024-12-06T18:15:32.585Z using Microsoft FHIR Converter.</span><span>Template Version: TEMPLATE_VERSION_PLACEHOLDER.</span><span>Template URL: https://github.com/microsoft/FHIR-Converter/releases/download/vTEMPLATE_VERSION_PLACEHOLDER/Hl7v2DefaultTemplates.tar.gz.</span><span>Root template: ADT_A01.</span></p></div>"
                    },
                    "occurredDateTime": "1988-08-18T11:26:00Z",
                    "recorded": "1988-08-18T11:26:00Z",
                    "agent": [
                        {
                            "type": {
                                "coding": [
                                    {
                                        "code": "author",
                                        "system": "http://terminology.hl7.org/CodeSystem/provenance-participant-type"
                                    }
                                ]
                            },
                            "who": {
                                "reference": "Organization/2d7d77cd-0ca7-13a5-c9ed-6e70b739adb4"
                            }
                        }
                    ],
                    "activity": {
                        "coding": [
                            {
                                "display": "ADT^A01^ADT_A01"
                            }
                        ]
                    },
                    "target": [
                        {
                            "reference": "Bundle/513a3d06-5e87-6fbc-ad1b-170ab430499f"
                        }
                    ]
                },
                "request": {
                    "method": "PUT",
                    "url": "Provenance/88f72da1-0474-6ee6-34d5-00f1b20b495c"
                }
            },
            {
                "fullUrl": "urn:uuid:2d7d77cd-0ca7-13a5-c9ed-6e70b739adb4",
                "resource": {
                    "resourceType": "Organization",
                    "id": "2d7d77cd-0ca7-13a5-c9ed-6e70b739adb4",
                    "identifier": [
                        {
                            "value": "GOOD HEALTH HOSPITAL",
                            "system": "http://example.com/v2-to-fhir-converter/Identifier/GOOD-HEALTH-HOSPITAL"
                        }
                    ],
                    "partOf": {
                        "reference": "Organization/50d6f04f-9cf3-df34-6b73-76c6a349edc1"
                    }
                },
                "request": {
                    "method": "PUT",
                    "url": "Organization/2d7d77cd-0ca7-13a5-c9ed-6e70b739adb4"
                }
            },
            {
                "fullUrl": "urn:uuid:50d6f04f-9cf3-df34-6b73-76c6a349edc1",
                "resource": {
                    "resourceType": "Organization",
                    "id": "50d6f04f-9cf3-df34-6b73-76c6a349edc1",
                    "name": "EVERYMAN",
                    "identifier": [
                        {
                            "value": "A"
                        }
                    ]
                },
                "request": {
                    "method": "PUT",
                    "url": "Organization/50d6f04f-9cf3-df34-6b73-76c6a349edc1"
                }
            },
            {
                "fullUrl": "urn:uuid:364bf61f-d0ac-3b9a-d91c-dbc2d9d9f46f",
                "resource": {
                    "resourceType": "Patient",
                    "id": "364bf61f-d0ac-3b9a-d91c-dbc2d9d9f46f"
                },
                "request": {
                    "method": "PUT",
                    "url": "Patient/364bf61f-d0ac-3b9a-d91c-dbc2d9d9f46f"
                }
            }
        ]
    }
}
Previous
Create Observation Resource
Next
Transform CCDA to FHIR R4
Built with