Skip to main content

Medication Service — Epics

Service: medication-service Epic prefix: MED-EPIC Last updated: 2026-04-17

Epics

MED-EPIC-01 — Longitudinal medication list and prescribing

FieldValue
Issue typeEpic
SummaryMedication list, prescribing draft/sign/update, discontinue, hold, resume
StatusTo Do
PriorityMust
Labelsservice:medication-service, domain:medication, slice:S1
Componentsprescription, med-list, api
Fix versionM1
FR referencesFR-MED-001..003, FR-MED-010..012
Legacy FR refsFR-MEDS-001..003, FR-MEDS-010..012, BR-MEDS-001
DependenciesORDERS-EPIC-01, CHART-EPIC-01, TERM-EPIC-01
Rollup statusPartial

Business outcome: Clinicians can safely prescribe and maintain a single source-of-truth medication list for every patient. Foundation for every other medication workflow.

Description: Deliver the core prescription aggregate and medication list APIs. Status vocabulary aligns with FHIR MedicationRequest.status. Supports structured sig (dose/route/frequency/duration), free-text instructions, substitution flags (DAW), renewals and refills. Uses terminology-service for codes.

Stories: MED-US-001, MED-US-002, MED-US-003, MED-US-004


MED-EPIC-02 — Medication safety checks and alert overrides

FieldValue
Issue typeEpic
SummaryAllergy, drug-drug, drug-condition, duplicate checks with override workflow
StatusTo Do
PriorityMust
Labelsservice:medication-service, domain:safety, slice:S1
Componentssafety-check, drug-kb, override
Fix versionM1
FR referencesFR-MED-030..032
Legacy FR refsFR-MEDS-030..032, BR-MEDS-001
DependenciesCHART-EPIC-03 (allergies), TERM-EPIC-02
Rollup statusPartial

Business outcome: Prevent adverse drug events. Ensure every signing prescriber is presented with safety-relevant alerts and records overrides with reason + KB snapshot for auditable governance.

Description: Integrate configurable drug knowledge base behind DrugKnowledgeBase port. Blocking alerts block sign unless override with ≥10-char reason and drugKbVersion captured. Overrides emitted as DetectedIssue + dedicated event.

Stories: MED-US-010, MED-US-011, MED-US-012


MED-EPIC-03 — Reconciliation sessions and MAR

FieldValue
Issue typeEpic
SummaryReconciliation at transitions of care and medication administration record
StatusTo Do
PriorityMust
Labelsservice:medication-service, domain:reconciliation, slice:S1
Componentsreconciliation, mar
Fix versionM1-M2
FR referencesFR-MED-020..021, FR-MED-022
Legacy FR refsFR-MEDS-020..021
DependenciesMED-EPIC-01, REG-EPIC-01 (encounter)
Rollup statusPartial

Business outcome: Consistent medication list across transitions (admission, transfer, discharge); nurses have a reliable MAR to chart administration events.

Description: Side-by-side comparison of home vs facility meds. Per-line continue/discontinue/modify decisions. MAR events (given / held / refused / not-available) with corrections as linked entries.

Stories: MED-US-020, MED-US-021, MED-US-022


MED-EPIC-04 — Pharmacy fulfillment queue and dispensing

FieldValue
Issue typeEpic
SummaryIngest gateway MRs, dispense with inventory decrement, partial/return
StatusTo Do
PriorityMust
Labelsservice:medication-service, domain:pharmacy, slice:S2
Componentsfulfillment, dispense, inventory
Fix versionM2
FR referencesFR-MED-040, FR-MED-060..066
Legacy FR refsFR-PHARM-009, FR-PHARM-040..046, BR-PHARM-004
DependenciesEPRX-EPIC-01 (gateway MR), BILL-EPIC-02
Rollup statusPartial

Business outcome: Pharmacies can fulfill prescriptions reliably — ingest gateway-routed MRs, atomic dispense with inventory, partial/return workflows.

Description: Consume eprescribing.medication_request.created.v1; maintain fulfillment projection keyed by gateway_medication_request_fhir_id. Dispense performs atomic inventory decrement + writes MedicationDispense. Posts dispense back to gateway. Emits billing event.

Stories: MED-US-030, MED-US-031, MED-US-032, MED-US-033


MED-EPIC-05 — Inventory, recalls, and expiry management

FieldValue
Issue typeEpic
SummaryDrug inventory per node, reorder/expiry alerts, recall management
StatusTo Do
PriorityMust
Labelsservice:medication-service, domain:inventory, slice:S2
Componentsinventory, recall, reorder
Fix versionM2
FR referencesFR-MED-070..076
Legacy FR refsFR-PHARM-050..056, BR-PHARM-009
DependenciesMED-EPIC-04
Rollup statusPartial

Business outcome: Pharmacies avoid stock-outs, expired/recalled dispense, and comply with supply-chain traceability.

Description: Stock item tracking by lot + expiry + supplier. Reorder alerts below configurable point. Expiry horizon alerts. Recall marking blocks dispense. Supports SupplyDelivery FHIR for external exchange.

Stories: MED-US-040, MED-US-041, MED-US-042


MED-EPIC-06 — Controlled-substance controls (prescribe + dispense)

FieldValue
Issue typeEpic
SummaryStep-up MFA, counter-sign at dispense, enhanced audit, disclosure accounting
StatusTo Do
PriorityMust
Labelsservice:medication-service, domain:controlled-substance, slice:S3
Componentscontrolled-substance, audit, identity-step-up
Fix versionM3
FR referencesFR-MED-050..051, FR-MED-090..093
Legacy FR refsFR-PHARM-033..034, FR-PHARM-072, BR-PHARM-005
DependenciesIDENT-EPIC-04 (MFA step-up), AUDIT-EPIC-01
Rollup statusNot started

Business outcome: Regulatory compliance for Schedule II–V. Auditable chain-of-custody for prescribe and dispense of controlled substances.

Description: Enforce step-up MFA for prescribe. Counter-sign (actor ≠ dispenser) at dispense. Disclosure-accounting report. 10-year retention. MoPH export format support.

Stories: MED-US-050, MED-US-051, MED-US-052


MED-EPIC-07 — Standalone offline-capable pharmacy portal

FieldValue
Issue typeEpic
SummaryPharmacy portal UI with 4h+ offline dispensing and label printing
StatusTo Do
PriorityShould
Labelsservice:medication-service, type:ui, slice:S3
Componentsportal, offline, labels
Fix versionM3
FR referencesFR-MED-080..084
Legacy FR refsFR-PHARM-060..064, NFR-PHARM-005
DependenciesMED-EPIC-04, IDENT-EPIC-02 (device binding)
Rollup statusNot started

Business outcome: Pharmacies operate through intermittent connectivity without blocking care; labels printed locally.

Description: Separate Next.js shell. Offline queue up to 4h. Device-bound encryption for cached PHI. RTL/LTR support. Label printing (prescription + dispense).

Stories: MED-US-060, MED-US-061, MED-US-062


MED-EPIC-08 — External adapters (NCPDP SCRIPT, HL7 v2)

FieldValue
Issue typeEpic
SummaryOptional NCPDP SCRIPT and HL7 v2 adapters for legacy interop
StatusTo Do
PriorityCould
Labelsservice:medication-service, domain:interop, slice:S4
Componentsncpdp, hl7v2
Fix versionM4
FR referencesFR-MED-041, FR-MED-042
Legacy FR refsFR-PHARM-010, BR-PHARM-010
DependenciesINTEROP-EPIC-02
Rollup statusNot started

Business outcome: Enable integration with legacy pharmacy networks in markets where NCPDP SCRIPT / HL7 v2 is required.

Description: Adapter-pattern integrations. NCPDP NewRx, RxChangeRequest, CancelRx. HL7 v2 RDE^O11 / RDS^O13 via hl7v2-interop. Retry + DLQ; prescriber notification on final failure.

Stories: MED-US-070, MED-US-071