Technical standard · interoperability
HL7 FHIR R4 integration
For hospital IT teams: which FHIR resources PharmaDeux reads and writes, which code systems it uses, and how it connects to your institution.
Status
This page documents the interface design. Formal FHIR profiles (StructureDefinition) and an OpenAPI document are not published yet; they are shared with your IT team during the pre-pilot technical review.
Resources and fields
| Resource | Fields used | Code system |
|---|---|---|
| MedicationRequest | medicationCodeableConcept · dosageInstruction · authoredOn · subject | WHO ATC · UCUM |
| Observation (laboratory) | code · valueQuantity · effectiveDateTime · interpretation | LOINC · UCUM |
| Observation (QTc) | code · method · valueQuantity | LOINC 8636-3 · Fridericia (method) |
| Observation (Tisdale) | code.text · valueInteger · component | text (no standard code) |
| Patient · Condition · AllergyIntolerance | Read; identifiers are anonymised as data enters the system | ICD-10 |
Rules
- Score and measurement are separate resources: the Tisdale score is never folded into the QTc Observation; it is its own Observation.
- LOINC 8636-3 "QT interval corrected" does not fix the correction method; Fridericia is carried as text in method.
- Example and test data carry meta.tag HTEST (v3 ActReason "test health data") and cannot pass as a real record.
Example JSON
{
"resourceType": "MedicationRequest",
"id": "example-amiodarone",
"meta": {
"tag": [
{
"system": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
"code": "HTEST",
"display": "test health data"
}
]
},
"status": "active",
"intent": "order",
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.whocc.no/atc",
"code": "C01BD01",
"display": "amiodarone"
}
],
"text": "Amiodarone 200 mg tablet"
},
"subject": {
"reference": "Patient/example"
},
"authoredOn": "2026-10-12T09:00:00+03:00",
"dosageInstruction": [
{
"text": "200 mg 1×1",
"timing": {
"repeat": {
"frequency": 1,
"period": 1,
"periodUnit": "d"
}
},
"doseAndRate": [
{
"doseQuantity": {
"value": 200,
"unit": "mg",
"system": "http://unitsofmeasure.org",
"code": "mg"
}
}
]
}
]
}{
"resourceType": "Observation",
"id": "example-qtc",
"meta": {
"tag": [
{
"system": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
"code": "HTEST",
"display": "test health data"
}
]
},
"status": "final",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/observation-category",
"code": "procedure"
}
]
}
],
"code": {
"coding": [
{
"system": "http://loinc.org",
"code": "8636-3",
"display": "Q-T interval corrected"
}
],
"text": "QTc (Fridericia)"
},
"subject": {
"reference": "Patient/example"
},
"effectiveDateTime": "2026-10-12T09:00:00+03:00",
"method": {
"text": "Fridericia formula (QTc = QT / RR^(1/3))"
},
"valueQuantity": {
"value": 485,
"unit": "ms",
"system": "http://unitsofmeasure.org",
"code": "ms"
}
}{
"resourceType": "Observation",
"id": "example-tisdale",
"meta": {
"tag": [
{
"system": "http://terminology.hl7.org/CodeSystem/v3-ActReason",
"code": "HTEST",
"display": "test health data"
}
]
},
"status": "final",
"code": {
"text": "Tisdale QT prolongation risk score"
},
"subject": {
"reference": "Patient/example"
},
"effectiveDateTime": "2026-10-12T09:00:00+03:00",
"valueInteger": 11,
"component": [
{
"code": {
"text": "Age ≥68"
},
"valueInteger": 1
},
{
"code": {
"text": "Female"
},
"valueInteger": 1
},
{
"code": {
"text": "Loop diuretic"
},
"valueInteger": 1
},
{
"code": {
"text": "QTc ≥450 ms"
},
"valueInteger": 2
},
{
"code": {
"text": "QT-prolonging drug"
},
"valueInteger": 3
},
{
"code": {
"text": "≥2 QT-prolonging drugs"
},
"valueInteger": 3
}
]
}Examples are generated by the code that builds PharmaDeux's FHIR payloads · fictional data.
Integration architecture
| FHIR R4 | RESTful API · Subscription (rest-hook) |
| HL7 v2 | MLLP listener · FHIR R4 conversion layer |
| Authorisation | OAuth 2.0 · SMART on FHIR |
| Transport | mTLS (mutual TLS) |
| Access | RBAC · least privilege |
| Deployment | On-premises (Docker container, isolated virtual machine) · isolated VPC dedicated to the institution · air-gapped network support |
| Logging | Syslog (RFC 5424) · append-only audit trail |
References
- 1HL7 International. FHIR Release 4 (R4, v4.0.1). https://hl7.org/fhir/R4/
- 2WHO Collaborating Centre for Drug Statistics Methodology. ATC/DDD Index. https://www.whocc.no/atc_ddd_index/
- 3Regenstrief Institute. LOINC. https://loinc.org/
- 4The Unified Code for Units of Measure (UCUM). https://ucum.org/
This page is for information only and is not for clinical decisions. Decisions rest on the product information (SmPC/PIL), current guidelines and the physician's judgement. Last updated: 13 October 2026