Introduction
medzinc medical data exchange platform facilitates universal interoperability framework for simplified care coordination. medzinc enables seamless clinical communication, integrated care coordination and automated data exchange between healthcare providers, clearing houses and other related parties.
Authentication
curl --location --request POST 'https://keycloak.mityung.com/auth/realms/medzinc/protocol/openid-connect/token' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'username=<USERNAME>' \
--data-urlencode 'password=<PASSWORD>' \
--data-urlencode 'client_secret=31bdb045-815e-42a3-99b0-97d5df7692f1' \
--data-urlencode 'scope=openid' \
--data-urlencode 'client_id=medzinc-datax' \
--data-urlencode 'grant_type=password'
Applications must secure and protect the privacy of patients and their data. To help meet this objective, MedData-X supports using the OAuth 2.0 framework to authenticate and authorize applications.
MEDZINC MEDDATAX API expects for the Bearer token in Header to be included in all API requests to the server in a header that looks like the following:
Authorization: Bearer <Access Token>
Also, process of how to generate Token.
1. METHOD TYPE : POST
2. HEADER
Content Type : x-www-form-urlencoded
Request Parameters in Body :
3. BODY
Body Name | Value |
---|---|
username: | Enter the username used to create your account. For example, john.doe@gmail.com. |
password: | ***************o5d |
client_secret: | client secret key get by forming an app |
scope: | openid |
client_id: | The client_id identifies your application to authentication servers. It will obtained from App details |
grant_type: | password |
The MEDZIC API uses Bearer Token to authenticate requests.
Base URL: https://keycloak.mityung.com/auth/realms/medzinc/protocol/openid-connect/token
{
"access_token": "eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJRX2t3bXF4Umk1YXZDc2dGZEh5ZHoyY2tQTVY3NU9jYU5pdXh2MkZyVzFRIn0.eyJqdGkiOiI0NjNhMmQ1Yy1iNDBjLTRiMTgtOTJiZi1lMGUwNTc1NmE5ZDIiLCJleHAiOjE2NDg1MzkwOTMsIm5iZiI6MCwiaWF0IjoxNjQ4NTM1NDkzLCJpc3MiOiJodHRwczovL2tleWNsb2FrLm1pdHl1bmcuY29tL2F1dGgvcmVhbG1zL01FRFpJTkMiLCJhdWQiOiJtZWR6aW5jLWRhdGF4I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hdWQiOiJtZWR6aW5jLWRhdGF4Iiwic3ViIjoiNTM2MzUxZTgtYjM5MS00OTZhLWJjMGYtYTI0ZTg5ZTYzYmQ2IiwidHlwIjoiSUQiLCJhenAiOiJtZWR6aW5jLWRhdGF4IiwiYXV0aF90aW1lIjowLCJzZXNzaW9uX3N0YXRlIjoiNjZiZDdkNjItODg5ZC00MTg5LWFlOWItM2QzMzA3MDM5Nzk2IiwiYWNyIjoiMSIsImVtYWlsX3ZlcmlmaWVkIjp0cnVlLCJuYW1lIjoiUkFIVUwgR0FSRyIsInByZWZlcnJlZF91c2VybmFtZSI6InJhaHVsbWVkemluYyIsImdpdmVuX25hbWUiOiJSQUhVTCIsImZhbWlseV9uYW1lIjoiR0FSRyIsImVtYWlsIjoicmFodWwuZ2FyZ0BtaXR5dW5nLmNvbSJ9.WU99uytJ1LksILndKJHhAcz5z-eoPTORzogj2EnkWbHlO2JQbOJD4jdEp9Vvcnj5kQGxQqdAEZoMpkwM9VwrVVgr5e5w84lFUBC2DnNagCCCt8B-FXi_LEJy88yz6hWXYuOSk3PgIgPcmofYv0Kmb4_IPADphfCvmgFVZ4I3eegUEDEPzgtZoXHh4TkBdgs4T4FvoebY7CJF8KNtASPMNEBcJwhiSnysJ6qorqOI46bsjBA3U0Nhxh9ynoG8dW7RYHyOHKweAbfBqC28IVt7M2202vsxHXAyUNnQ_mhc1XpMWqgwBpWD9DwhztOv5-KdfQs47PD7oU5g48XjYRXjBQ",
"not-before-policy": 0,
"session_state": "66bd7d62-889d-4189-ae9b-3d3307039796",
"scope": "openid profile email"
}
Get FHIR By Id
Consume token to access GET FHIR APIs:
https://gateway-dev.mityung.com/v1/meddata-x/fhirResourceType=Patient&id=12799585
The read interaction accesses the current contents of a resource. The interaction is performed by an HTTP GET command.And it returns a single instance with the content specified for the resource type.The returned resource SHALL have an id element with a value that is the [id].
Response:
{
"resourceType": "Patient",
"id": "12784689",
"meta": {
"versionId": "0",
"lastUpdated": "2022-03-17T12:34:21.000Z"
},
"text": {
"status": "extensions",
"div": "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Patient</b></p><p><b>Name</b>: Singh, Manmohan</p><p><b>Status</b>: Active</p><p><b>DOB</b>: May 1, 1973</p><p><b>Birth Sex</b>: Male</p><p><b>Administrative Gender</b>: Male</p></div>"
},
"extension": [
{
"valueCode": "M",
"url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex"
}
],
"identifier": [
{
"id": "CI-490711443-0",
"use": "usual",
"type": {
"coding": [
{
"system": "https://fhir.cerner.com/ec2458f2-1e24-41c8-b71b-0e701af7583d/codeSet/4",
"code": "2",
"display": "Community Medical Record Number",
"userSelected": true
},
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0203",
"code": "MR",
"display": "Medical record number",
"userSelected": false
}
],
"text": "Community Medical Record Number"
},
"system": "urn:oid:2.16.840.1.113883.3.787.0.0",
"value": "36397",
"_value": {
"extension": [
{
"valueString": "36397",
"url": "http://hl7.org/fhir/StructureDefinition/rendered-value"
}
]
},
"period": {
"start": "2022-03-17T12:34:21.000Z"
}
},
{
"id": "CI-490711447-1",
"use": "usual",
"type": {
"coding": [
{
"system": "https://fhir.cerner.com/ec2458f2-1e24-41c8-b71b-0e701af7583d/codeSet/4",
"code": "10",
"display": "MRN",
"userSelected": true
},
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0203",
"code": "MR",
"display": "Medical record number",
"userSelected": false
}
],
"text": "MRN"
},
"system": "urn:oid:2.16.840.1.113883.6.1000",
"value": "44390",
"_value": {
"extension": [
{
"valueString": "00000044390",
"url": "http://hl7.org/fhir/StructureDefinition/rendered-value"
}
]
},
"period": {
"start": "2022-03-17T12:34:21.000Z"
}
},
{
"id": "CI-490711445-2",
"use": "usual",
"type": {
"coding": [
{
"system": "https://fhir.cerner.com/ec2458f2-1e24-41c8-b71b-0e701af7583d/codeSet/4",
"code": "2553236785",
"display": "MIllennium Person Identifier",
"userSelected": true
}
],
"text": "MIllennium Person Identifier"
},
"_system": {
"extension": [
{
"valueCode": "unknown",
"url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason"
}
]
},
"value": "52610",
"_value": {
"extension": [
{
"valueString": "52610",
"url": "http://hl7.org/fhir/StructureDefinition/rendered-value"
}
]
},
"period": {
"start": "2022-03-17T12:34:21.000Z"
}
}
],
"active": true,
"name": [
{
"id": "CI-12784689-0",
"use": "official",
"text": "Singh, Manmohan",
"family": "Singh",
"given": [
"Manmohan"
]
}
],
"telecom": [
{
"id": "CI-PH-29915411-0",
"extension": [
{
"valueUrl": "9898674590",
"url": "http://hl7.org/fhir/StructureDefinition/iso21090-TEL-address"
}
],
"system": "phone",
"value": "9898674590",
"use": "home",
"rank": 1
},
{
"id": "CI-EM-29915413-0",
"system": "email",
"value": "KitolPlazo1222@test.com",
"use": "home",
"rank": 1
}
],
"gender": "male",
"birthDate": "1973-05-01"
}
Summary: Get FHIR data from respective EMRs using FHIR Resource Id
1. METHOD-TYPE:
GET
2. LIST OF GET RESOURCES:
1. EPIC
: List of Resource:-
AllergyIntolerance | Location |
Appointment | MedicationRequest |
Condition | Observation |
DocumentReference | Patient |
DiagnosticReport | Practitioner |
Encounter | Procedure |
2. CERNER
: List of Resource:-
Account | FamilyMemberHistory |
AllergyIntolerance | Goal |
Appointment | Immunization |
Binary | InsurancePlan |
CarePlan | Location |
Condition | MedicationAdministration |
Consent | MedicationRequest |
Contract | MedicationStatement |
Device | NutritionOrder |
DiagnosticReport | Observation |
DocumentReference | OperationDefinition |
Encounter | Organization |
3. ATHENA
: List of Resource:-
AuditEvent | MedicationStatement |
CarePlan | Medication |
CareTeam | Organization |
Condition | Observation |
Device | Practitioner |
DiagnosticReport | PractitionerRole |
Encounter | Provenance |
Goal | Patient |
Immunization | RelatedPerson |
InsurancePlan | Schedule |
Location | Slot |
3. HEADERS: in header:-
Header Name | Value |
---|---|
Authorization | Bearer |
HealthSystem | EPIC / CERNER / ATHENA |
ClientId | Client ID for respective EMRs |
4. PARAMETERS: required parameter is:-
Name | Located in | Description | Required | Type |
---|---|---|---|---|
ResourceType | query | ResourceType | Yes | string |
id | query | id | Yes | string |
5. RESPONSES:
Code | Description |
---|---|
200 | OK |
401 | Unauthorized |
403 | Forbidden |
404 | Not Found |
CREATE FHIR
Consume token to access CREATE FHIR APIs:
Request URL = https://gateway-dev.mityung.com/v1/meddata-x/fhir/Create
Content Type: application/json
Accept: application/json
The create interaction creates a new resource in a server-assigned location. If the client wishes to have control over the id of a newly submitted resource, it should use the update interaction instead. The create interaction is performed by an HTTP POST command.
Summary: Create FHIR Resource in respective EMRs
Request Body FHIR Resource:
{
"resourceType": "Patient",
"extension": [
{
"url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex",
"valueCode": "M"
}
],
"identifier": [
{
"assigner": {
"reference": "Organization/675844"
}
}
],
"active": true,
"name": [
{
"use": "official",
"family": "Pritee",
"given": [
"Garg"
]
}
],
"telecom": [
{
"system": "phone",
"value": "9878455640",
"use": "home"
},
{
"system": "email",
"value": "Pritee@test.com",
"use": "home"
}
],
"gender": "male",
"birthDate": "1987-05-01"
}
1. METHOD-TYPE:
POST
2. LIST OF CREATE RESOURCES:
1. CERNER
: List of Resource:-
AllergyIntolerance | Immunization |
Appointment | MedicationRequest |
Condition | Observation |
Coverage | Organization |
DocumentReference | Patient |
Encounter | Practitioner |
FamilyMemberHistory | Procedure |
Provenance | RelatedPerson |
2. ATHENA
: List of Resource:-
Condition | Observation |
DocumentReference | Patient |
Immunization | RelatedPerson |
MedicationStatement |
3. EPIC
: List of Resource:-
Patient | Observation |
Appointment | DocumentReference |
Condition | AllergyIntolerance |
3. HEADERS: in header:-
Header Name | Value |
---|---|
Authorization | Bearer |
HealthSystem | EPIC / CERNER / ATHENA |
ClientId | Client ID for respective EMRs |
FhirVersion | DSTU2/ STU3 / R4 |
Response:
{
"resourceType": "Patient",
"id": "12804832",
"extension": [
{
"url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex",
"valueCode": "M"
}
],
"identifier": [
{
"use": "usual",
"system": "CERNER",
"value": "12804832",
"assigner": {
"display": "CERNER"
}
}
],
"active": true,
"name": [
{
"use": "official",
"family": "Pritee",
"given": [
"Garg"
]
}
],
"telecom": [
{
"system": "phone",
"value": "9878455640",
"use": "home"
},
{
"system": "email",
"value": "Pritee@test.com",
"use": "home"
}
],
"gender": "male",
"birthDate": "1987-05-01"
}
4. PARAMETERS:
Name | Located in | Description | Required | Type |
---|---|---|---|---|
FhirMessage | body | FhirMessage | Yes |
5. RESPONSES:
Code | Description |
---|---|
200 | OK |
201 | Created |
401 | Unauthorized |
403 | Forbidden |
404 | Not Found |
SEARCH FHIR
Consume token to access SAERCH FHIR APIs:
Request URL = https://gateway-dev.mityung.com/v1/meddata-x/fhir?
This interaction searches a set of resources based on some filter criteria. The interaction can be performed by several different HTTP commands. This searches all resources of a particular type using the criteria represented in the parameters. Because of the way that some user agents and proxies treat GET and POST requests, in addition to the get based search method above, servers that support search SHALL also support a POST based search:
Summary: Search FHIR data from respective EMRs
Request Body :
{
"patient": {
"_Count": "",
"_Id": "",
"address_postalcode": "",
"birthdate": "1987-05-01",
"count": "",
"family": "Pritee",
"gender": "",
"given": "Garg",
"identifier": "",
"name": ""
},
"resourceType": "Patient"
}
1. METHOD-TYPE:
POST
2. LIST OF CREATE RESOURCES:
1. CERNER
: List of Resource:-
Account | FamilyMemberHistory |
AllergyIntolerance | Goal |
Appointment | Immunization |
Binary | InsurancePlan |
CarePlan | Location |
Condition | MedicationAdministration |
Consent | MedicationRequest |
Contract | MedicationStatement |
Device | NutritionOrder |
DocumentReference | Observation |
Encounter | Organization |
Coverage |
3. EPIC
: List of Resource:-
AllergyIntolerance | Location |
Appointment | MedicationRequest |
Condition | Observation |
DocumentReference | Patient |
DiagnosticReport | Practitioner |
Encounter | Procedure |
Response:
{
"resourceType": "Bundle",
"id": "36582190-616d-4ae1-88bc-4853d71ac083",
"type": "searchset",
"link": [
{
"relation": "self",
"url": "https://fhir-ehr.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/Patient?family=Pritee&given=Garg&birthdate=1987-05-01"
},
{
"relation": "next",
"url": "https://fhir-ehr.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/Patient?-pageContext=09e2f96a-45bb-4ee4-8672-a916db5be0a6&-pageDirection=NEXT"
}
],
"entry": [
{
"fullUrl": "https://fhir-ehr.cerner.com/r4/ec2458f2-1e24-41c8-b71b-0e701af7583d/Patient/12802281",
"resource": {
"resourceType": "Patient",
"id": "12802281",
"meta": {
"versionId": "0",
"lastUpdated": "2022-07-26T07:40:03.000Z"
},
"text": {
"status": "extensions",
"div": "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Patient</b></p><p><b>Name</b>: Pritee, Garg</p><p><b>Status</b>: Active</p><p><b>DOB</b>: May 1, 1987</p><p><b>Birth Sex</b>: Male</p><p><b>Administrative Gender</b>: Male</p></div>"
},
"extension": [
{
"url": "http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex",
"valueCode": "M"
}
],
"identifier": [
{
"use": "usual",
"system": "CERNER",
"value": "12802281",
"assigner": {
"display": "CERNER"
}
}
],
"active": true,
"name": [
{
"id": "CI-12802281-0",
"use": "official",
"text": "Pritee, Garg",
"family": "Pritee",
"given": [
"Garg"
]
}
],
"telecom": [
{
"id": "CI-PH-29945195-0",
"extension": [
{
"url": "http://hl7.org/fhir/StructureDefinition/iso21090-TEL-address",
"valueUrl": "9878455640"
}
],
"system": "phone",
"value": "9878455640",
"use": "home",
"rank": 1
},
{
"id": "CI-EM-29945197-0",
"system": "email",
"value": "Pritee@test.com",
"use": "home",
"rank": 1
}
],
"gender": "male",
"birthDate": "1987-05-01"
},
"search": {
"mode": "match"
}
}
]
}
2. ATHENA
: List of Resource:-
CarePlan | Medication |
CareTeam | Organization |
Condition | Observation |
Device | Practitioner |
DiagnosticReport | PractitionerRole |
Encounter | Provenance |
Goal | Patient |
Immunization | RelatedPerson |
InsurancePlan | Schedule |
Location | Slot |
MedicationStatement | Subscription |
3. HEADERS: in header:-
Header Name | Value |
---|---|
Authorization | Bearer |
HealthSystem | EPIC / CERNER / ATHENA |
ClientId | Client ID for respective EMRs |
4. PARAMETERS:
Search Parameter | Located in | Description | Required | Type |
---|---|---|---|---|
Search Parameter | Body | yes |
5. RESPONSES:
Code | Description |
---|---|
200 | OK |
401 | Unauthorized |
403 | Forbidden |
404 | Not Found |
Convert HL7 Message to FHIR
POST
{{Base_URL}}/v1/meddata-x/hl7/create
Content Type: text/plain
Accept: application/json
Search operations search through an existing set of resources by a set of search criteria supplied as parameters to the search.
Summary: Accept HL7 message
Request Body HL Message:
MSH|^~\&|SOURCEEHR|WA|MIRTHDST|WA|201611111111||ADT^A01|MSGID10001|P|2.3|
EVN|A01|201611111111||
PID|1|100001^^^1^MRN|900001||Adam^Lily^^^^||19810723|M||WH|111 THAT PL^^HERE^WA^98020^US||321-123-9870|||M|NON|999999999|123456789
NK1|1|DOE^JANE^|WIFE||(206)555-5555||||NK^NEXT OF KIN
PV1|1|O|1001^2002^01||||123456^DOCTOR^BOB^T^^DR|||||||ADM|A0|
Respons:
{
"resourceType": "Patient",
"id": "ejXIuQrmx5igKssFrdFTblA3",
"meta": {
"extension": [
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/source-event-trigger",
"valueCodeableConcept": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0003",
"code": "A01"
}
]
}
},
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/source-record-type",
"valueCodeableConcept": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0076",
"code": "ADT"
}
]
}
},
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/source-event-timestamp",
"valueDateTime": "2016-11-11T11:11:00+08:00"
},
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/source-record-id",
"valueString": "MSGID10001"
},
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/source-data-model-version",
"valueString": "2.3"
},
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/process-client-id",
"valueString": "SOURCEEHR"
}
]
},
"extension": [
{
"url": "http://hl7.org/fhir/StructureDefinition/patient-religion",
"valueCodeableConcept": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation",
"display": "Invalid input: code 'NON' could not be mapped to values in system 'http://terminology.hl7.org/CodeSystem/v3-ReligiousAffiliation' with original display 'null' and version 'null'."
}
]
}
},
{
"url": "http://ibm.com/fhir/cdm/StructureDefinition/local-race-cd",
"valueCodeableConcept": {
"coding": [
{
"code": "WH"
}
]
}
}
],
"identifier": [
{
"use": "usual",
"system": "EPIC",
"value": "ejXIuQrmx5igKssFrdFTblA3",
"assigner": {
"display": "EPIC"
}
}
],
"active": true,
"name": [
{
"use": "usual",
"family": "Adam",
"given": [
"Lily"
]
}
],
"telecom": [
{
"system": "phone",
"value": "321-123-9870",
"use": "home"
}
],
"gender": "male",
"birthDate": "1981-07-23",
"address": [
{
"use": "home",
"line": [
"111 THAT PL"
],
"city": "HERE",
"state": "WA",
"postalCode": "98020",
"country": "US"
}
],
"maritalStatus": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v3-MaritalStatus",
"code": "M",
"display": "Married"
}
]
}
}
HTTP Request
POST /hl7/create
Parameters
Name | Located in | Description | Required | Type |
---|---|---|---|---|
HL7Message | body | HL7Message | Yes |
Responses
Code | Description |
---|---|
200 | OK |
201 | Created |
401 | Unauthorized |
403 | Forbidden |
404 | Not Found |
Errors
The MEDZINC API uses the following error codes:
Error Code | Meaning |
---|---|
400 | Bad Request - resource could not be parsed or failed basic FHIR validation rules (or multiple matches were found for conditional criteria) |
401 | Not Authorized - authorization is required for the interaction that was attempted |
404 | Not Found - resource type not supported, or not a FHIR end-point |
405 | Method Not allowed - the resource did not exist prior to the update, and the server does not allow client defined ids |
409/412 | Version conflict management |
422 | Unprocessable Entity - the proposed resource violated applicable FHIR profiles or server business rules |