Drug-Drug Interaction (DDI)
How it works
On every MedicationRequest write to HAPI FHIR, JamGuard.DrugDrugInteractionRule fires:
- Fetch golden ID — extract
Patient.link[refer]from the patient resource - Fetch all active medications —
GET /fhir/MedicationRequest?patient=GOLDEN-{id}&status=active - Extract RxNorm CUIs — via JamTS or stored on the MedicationRequest
- Query NLM RxNorm API:
GET https://rxnav.nlm.nih.gov/REST/interaction/list?rxcuis=855288+1191
- Evaluate severity:
| Severity | JamGuard action |
|---|---|
| MAJOR | Block write + alert prescriber immediately |
| MODERATE | Write proceeds + warning card to portal |
| MINOR | Logged only, no alert |
Overriding a MAJOR DDI
The prescriber can acknowledge and override a MAJOR DDI via the admin API:
POST /api/ddi/override
{
"transactionId": "BR03-26060612-042",
"prescriberId": "Practitioner/pr-perera-001",
"reason": "Clinical risk accepted — patient monitored for bleeding"
}
The override is logged as an AuditEvent with the prescriber, reason, and timestamp.
Why cross-branch matters
Without JamGuard, a clinician at Branch 03 has no visibility of Aspirin prescribed at Branch 07. The local HAPI query would return zero active medications for MRN-9901-BR03 — because the Aspirin is stored under MRN-20891-BR07. JamGuard queries by golden ID, which spans all branches.