This page is part of the US Core (v5.0.0: STU5) based on FHIR R4. The current version which supercedes this version is 5.0.1. For a full list of available versions, see the Directory of published versions
The guidance below addresses how a patient or a provider can access a patient’s active, historical and future (planned) medications list. This use case adopts the use cases defined as part of the Argonaut Project and US Core, specifically within the scope of accessing medication information as prescribed in the ONC U.S. Core Data for Interoperability (USCDI). This section provide specific guidance on how to to access “all medications” and “all active medications” for a patient using a query on MedicationRequest. Note that in prior versions of this guide, a query on MedicationStatement was required. Because of underlying changes in the FHIR Release 4 pharmacy resources, this guide doesn’t require use of MedicationStatement since an “active” medication list can be obtained using only MedicationRequest.1
The FHIR specification defines 5 FHIR pharmacy resources concerned with the ordering, dispensing, administration and recording of medications. This guide provides guidance for accessing a patient’s medications using the following 2 resources:
The following 3 resources are introduced here to provide background and define the relationships between the pharmacy resources. This guide does not use them for accessing a patient’s medications:
Details about each resource can be found in the FHIR specification. A general discussion regarding the interaction between these resources is described in the FHIR Medications Module and the Guide to Resources Sections.
This IG focuses on access to a patient’s medications. It is therefore important to understand the relationships between these resources. Figure 1 illustrates the workflow relationship between the medication order and the fulfillment as represented by the FHIR medication resources. Note that in the outpatient setting the patient does the administration.
Several sources may be used to create a MedicationRequest as is shown in Figure 2 below. The information may be captured directly a system’s medication orders or reported by a provider. A patient or related person may also report the information (or provide some type of record) including “self-prescribed” orders. For example, oftentimes the patient is the only source of information when the patient reports Cannabis or OTC medication use.
This guide supports representing a medication using either a code or a reference to a Medication resource. Typically, a code will be used to represent either a branded (for example, Crestor 10mg tablet) or a generic (for example, Rosuvastatin 10mg tablet) medication. When using a code, the code SHALL follow the extensible binding rules to Medication Clinical Drug (RxNorm) - i.e. unless the concept is not covered by RxNorm, the RxNorm code SHALL be used. More information about using codes can be found in the General Guidance Section and the FHIR Terminology section. A medication resource is typically used when information that is not included as part of the RxNorm code is required. For example, the Medication resource is the only way to correctly represent compounded or extemporaneously prepared medication. When referencing the Medication resource, the resource may be included in the bundle returned, an external resource, or a contained if the resource can’t stand alone. These options are shown in figure 3 below. The server application MAY choose any combination of these methods, but if an external reference to Medication is used, the server SHALL support the include parameter for searching this element. The client application MUST support all methods. The MedicationRequest examples show these different methods. Additional guidance is provided below and in the US Core Server Capability Statement section.
Definitions
Note that these definition do not convey compliance - i.e. the list is a statement of what is prescribed (or self-prescribed) and not what is consumed by patient.
Requirements to access “all medications” and “all active medications” for a patient:
A MedicationRequest resource query:
intent
= “order” representing authorized medication orders directly derived from the system’s orders.intent
= “plan” representing reported medications
reported[x]
element to indicate the MedicationRequest record was captured as a secondary “reported” record rather than an original primary source-of-truth record. It may also indicate the source of the report.requester
element to indicate the Patient or RelatedPerson as the prescriber.encounter
element SHOULD be supported. Searching by context (i.e., for a given inpatient encounter) will return all medications ordered during that encounter, which can include both medications administered in hospital as well as prescribed or discharge medications, which are intended to be taken at home.category
and encounter
elements MAY be used together to get the intersection of medications for a given encounter (i.e., the context) that were administered during as an inpatient (i.e., the category).Get all medications for a patient by querying MedicationRequest using the patient
search parameter and intent
search parameter = “order,plan”. See MedicationRequest Quick Start for further details.
GET /MedicationRequest?patient=[id]&intent=order,plan{&_include=MedicationRequest:medication}
Storyboard for this example
This example is based upon the following scenario:
Patient Brian Z uses an App to request all his medications from a single provider, Dr Cayr. This test scenario exercises a mix of routine meds, unusual schedule meds and as-needed meds. All meds are in the outpatient setting only.
Provider A’s (Dr Cayr) medication records for Patient Brian Z
Item | Date | Script | Source | Notes |
---|---|---|---|---|
1 | 9/12/2016 | testosterone cypionate 100mg/ml inj 1ml intramuscularly every 3 weeks | Reported by Patient | Get at doctor’s office every third Friday. Taking for energy level and drive. |
2 | 9/1/2016 | testosterone cypionate 100mg/ml inj 1ml intramuscularly | Reported by Dr Cryn | completed |
3 | 1/15/2016 | Zocor (simvastatin) 40mg by mouth once daily | Dr. Cayr Order: BMC | patient med status: taking |
4 | 7/1/2015 | Humulin R (insulin regular, human) U100 10U every AM, 5U every PM, 5U at bedtime. | Dr.Cayr Order:BMC | patient med status: taking |
5 | 6/12/2015 | simvastatin 30mg by mouth once daily | Dr. Cayr Order: BMC | patient med status: completed |
Request:
Get “all medications” for a patient by querying MedicationRequest using the patient search parameter.
GET [base]/MedicationRequest?patient=test2&intent=order,plan
Response:
A Server returns a search Bundle resource containing all the MedicationRequests for the patient Brian Z
HTTP/1.1 200 OK
[other headers]
{
"resourceType": "Bundle",
"id": "f48e4a18-173b-4c82-8eeb-3e39daa59f",
"meta": {
"lastUpdated": "2022-04-12T00:01:27.106Z"
},
"type": "searchset",
"total": 5,
"link": [
{
"relation": "self",
"url": "http://test.fhir.org/r4/MedicationRequest?_format=application/fhir+json&search-id=a27179f4-7471-44dd-b6f1-73ae7ef001&&patient=test2&intent=order,plan&_sort=_id"
}
],
"entry": [
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/269",
"resource": {
"resourceType": "MedicationRequest",
"id": "269",
"meta": {
"versionId": "2",
"lastUpdated": "2022-04-11T23:29:16.906Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "US_Core_5_Example"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "104491",
"display": "Simvastatin 20 MG Oral Tablet [Zocor]"
}
],
"text": "Zocor (simvastatin) 20mg Tablet"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/outpatien-Example-1"
},
"authoredOn": "2016-01-15",
"requester": {
"reference": "Practitioner/practitioner-drcayr",
"display": "Dr Cayr"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "13644009",
"display": "Hypercholesterolemia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "40mg by mouth once daily",
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38288",
"display": "ORAL"
}
]
}
}
],
"dispenseRequest": {
"numberOfRepeatsAllowed": 11,
"quantity": {
"value": 60,
"unit": "tablets",
"system": "http://hl7.org/fhir/v3/orderableDrugForm",
"code": "TAB"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/270",
"resource": {
"resourceType": "MedicationRequest",
"id": "270",
"meta": {
"versionId": "1",
"lastUpdated": "2022-04-11T23:33:38.281Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
}
]
},
"text": {
"status": "generated",
"div": "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p><b>Generated Narrative with Details</b></p><p><b>meta</b>: </p><p><b>status</b>: active</p><p><b>intent</b>: order</p><p><b>category</b>: Outpatient <span style=\"background: LightGoldenRodYellow \">(Details : {http://terminology.hl7.org/CodeSystem/medicationrequest-category code \"outpatient\" := \"outpatient\", given as \"Outpatient\"})</span></p><p><b>reported</b>: false</p><p><b>medication</b>: Humulin R (insulin regular, human) U100 100units/ml inj solution <span style=\"background: LightGoldenRodYellow \">(Details : {RxNorm code \"311036\" := \"311036\", given as \"Humulin R (insulin regular, human) U100 100units/ml inj solution\"})</span></p><p><b>subject</b>: <a href=\"Patient/test2\">Brian Z</a></p><p><b>encounter</b>: <a href=\"Encounter/outpatient-example-2\">Encounter/outpatient-example-2</a></p><p><b>authoredOn</b>: 7/1/2015</p><p><b>requester</b>: </p><p><b>dosageInstruction</b>: </p></div>"
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "311036",
"display": "Humulin R (insulin regular, human) U100 100units/ml inj solution"
}
],
"text": "Humulin R (insulin regular, human) U100 100units/ml inj solution"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/outpatient-example-2"
},
"authoredOn": "2015-07-01",
"requester": {
"reference": "Practitioner/practitioner-drcayr",
"display": "Dr Cayr"
},
"dosageInstruction": [
{
"sequence": 1,
"text": "10U every AM, 5U every PM, 5U at bedtime",
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://snomed.info/sct",
"code": "34206005",
"display": "Subcutaneous route (qualifier value)"
}
]
}
}
],
"dispenseRequest": {
"numberOfRepeatsAllowed": 11,
"quantity": {
"value": 40,
"unit": "ml",
"system": "http://unitsofmeasure.org",
"code": "mL"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/271",
"resource": {
"resourceType": "MedicationRequest",
"id": "271",
"meta": {
"versionId": "1",
"lastUpdated": "2022-04-11T23:46:16.248Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
}
]
},
"status": "active",
"intent": "plan",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "835829",
"display": "testosterone cypionate 100 MG/ML Injectable Solution"
}
],
"text": "testosterone cypionate 100mg/ml inj"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/outpatient-example-3"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/practitioner-drcryn",
"display": "Dr Cryn"
},
"reasonCode": [
{
"text": "Taking for energy level and drive."
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "1ml intramuscularly every 3 weeks"
}
]
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/272",
"resource": {
"resourceType": "MedicationRequest",
"id": "272",
"meta": {
"versionId": "1",
"lastUpdated": "2022-04-11T23:49:12.951Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
}
]
},
"status": "completed",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "314231",
"display": "Simvastatin 10 MG Oral Tablet"
}
],
"text": "simvastatin 10mg Tablet"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"authoredOn": "2015-06-12",
"requester": {
"reference": "Practitioner/practitioner-drcayr",
"display": "Dr Cayr"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "13644009",
"display": "Hypercholesterolemia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "30mg (3 tablets) by mouth once daily",
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38288",
"display": "ORAL"
}
]
}
}
],
"dispenseRequest": {
"numberOfRepeatsAllowed": 6,
"quantity": {
"value": 90,
"unit": "tablets",
"system": "http://hl7.org/fhir/v3/orderableDrugForm",
"code": "TAB"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/273",
"resource": {
"resourceType": "MedicationRequest",
"id": "273",
"meta": {
"versionId": "1",
"lastUpdated": "2022-04-11T23:57:17.715Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
}
]
},
"status": "completed",
"intent": "plan",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "835829",
"display": "testosterone cypionate 100 MG/ML Injectable Solution"
}
],
"text": "testosterone cypionate 100mg/ml inj"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"authoredOn": "2016-09-01",
"requester": {
"reference": "Practitioner/practitioner-drcryn",
"display": "Dr Cryn"
},
"reasonCode": [
{
"text": "Taking for energy level and drive."
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "1ml intramuscularly"
}
]
},
"search": {
"mode": "match"
}
}
]
}
Get all active medications for a patient by querying MedicationRequest using the patient
, and intent
= “order,plan” status
= “active” search parameters. See MedicationRequest Quick Start for further details. Note that the client should also consider MedicationRequests with a status of “unknown” and whether to query those as well.
GET /MedicationRequest?patient=[id]&intent=order,plan&status=active{&_include=MedicationRequest:medication}
Storyboard for this example
This example is based upon the following scenario:
Patient Brian Z uses an App to request all his medications from a single provider, Dr Cayr. This test scenario exercises a mix of routine meds, unusual schedule meds and as-needed meds. All meds are in the outpatient setting only.
Provider A’s (Dr Cayr) medication records for Patient Brian Z. Note that three of these are active, the other two are completed.
Item | Date | Script | Source | Notes |
---|---|---|---|---|
1 | 9/12/2016 | testosterone cypionate 100mg/ml inj 1ml intramuscularly every 3 weeks | Reported by Patient | Get at doctor’s office every third Friday. Taking for energy level and drive. |
2 | 9/1/2016 | testosterone cypionate 100mg/ml inj 1ml intramuscularly | Reported by Dr Cryn | completed |
3 | 1/15/2016 | Zocor (simvastatin) 40mg by mouth once daily | Dr. Cayr Order: BMC | patient med status: taking |
4 | 7/1/2015 | Humulin R (insulin regular, human) U100 10U every AM, 5U every PM, 5U at bedtime. | Dr.Cayr Order:BMC | patient med status: taking |
5 | 6/12/2015 | simvastatin 30mg by mouth once daily | Dr. Cayr Order: BMC | patient med status: completed |
Request:
Get “all active medications” for a patient by querying MedicationRequest using the patient and status= “active” search parameters.
GET [base]/MedicationRequest?patient=test2&intent=order,plan&status=active
Response:
A Server returns a search Bundle resource containing all the MedicationRequests with a status of “active” for the patient Brian Z
HTTP/1.1 200 OK
[other headers]
{
"resourceType": "Bundle",
"id": "1f8a772f-1a54-4ef7-8bf6-7e27325ca4",
"meta": {
"lastUpdated": "2022-04-12T01:01:49.419Z"
},
"type": "searchset",
"total": 3,
"link": [
{
"relation": "self",
"url": "http://test.fhir.org/r4/MedicationRequest?_format=application/fhir+json&search-id=667926e8-efa6-427e-b801-73c66b1789&&patient=test2&intent=order,plan&status=active&_sort=_id"
}
],
"entry": [
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/269",
"resource": {
"resourceType": "MedicationRequest",
"id": "269",
"meta": {
"versionId": "3",
"lastUpdated": "2022-04-12T01:01:29.279Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "US_Core_5_Example"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "104491",
"display": "Simvastatin 20 MG Oral Tablet [Zocor]"
}
],
"text": "Zocor (simvastatin) 20mg Tablet"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/outpatien-Example-1"
},
"authoredOn": "2016-01-15",
"requester": {
"reference": "Practitioner/practitioner-drcayr",
"display": "Dr Cayr"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "13644009",
"display": "Hypercholesterolemia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "40mg by mouth once daily",
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38288",
"display": "ORAL"
}
]
}
}
],
"dispenseRequest": {
"numberOfRepeatsAllowed": 11,
"quantity": {
"value": 60,
"unit": "tablets",
"system": "http://hl7.org/fhir/v3/orderableDrugForm",
"code": "TAB"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/270",
"resource": {
"resourceType": "MedicationRequest",
"id": "270",
"meta": {
"versionId": "2",
"lastUpdated": "2022-04-12T01:01:29.498Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "311036",
"display": "Humulin R (insulin regular, human) U100 100units/ml inj solution"
}
],
"text": "Humulin R (insulin regular, human) U100 100units/ml inj solution"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/outpatient-example-2"
},
"authoredOn": "2015-07-01",
"requester": {
"reference": "Practitioner/practitioner-drcayr",
"display": "Dr Cayr"
},
"dosageInstruction": [
{
"sequence": 1,
"text": "10U every AM, 5U every PM, 5U at bedtime",
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://snomed.info/sct",
"code": "34206005",
"display": "Subcutaneous route (qualifier value)"
}
]
}
}
],
"dispenseRequest": {
"numberOfRepeatsAllowed": 11,
"quantity": {
"value": 40,
"unit": "ml",
"system": "http://unitsofmeasure.org",
"code": "mL"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/271",
"resource": {
"resourceType": "MedicationRequest",
"id": "271",
"meta": {
"versionId": "2",
"lastUpdated": "2022-04-12T01:01:29.795Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
}
]
},
"status": "active",
"intent": "plan",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "outpatient",
"display": "Outpatient"
}
],
"text": "Outpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "835829",
"display": "testosterone cypionate 100 MG/ML Injectable Solution"
}
],
"text": "testosterone cypionate 100mg/ml inj"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/outpatient-example-3"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/practitioner-drcryn",
"display": "Dr Cryn"
},
"reasonCode": [
{
"text": "Taking for energy level and drive."
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "1ml intramuscularly every 3 weeks"
}
]
},
"search": {
"mode": "match"
}
}
]
}
Get “all medications” for an encounter by querying MedicationRequest using the patient
and encounter
and intent
=”order,plan” search parameters. See MedicationRequest Quick Start for further details.
GET /MedicationRequest?patient=[id]&intent=order,plan&encounter=[id]{&_include=MedicationRequest:medication}
Storyboard for this example
This example is based upon the following scenario.
Patient Brain Z has presented with the same condition (pneumonia) as in a previous inpatient encounter. Provider A (Dr Cayr) uses a desktop or mobile application to request all the medications from this previous inpatient encounter (Encounter A).
Medication records for Patient Brian Z during Encounter A
Item | Date | Script | Source | Notes |
---|---|---|---|---|
1 | 9/10/2016 - 9/12-2016 | Cefatoxime 1gm intravenously every 6 hours | Provider B’s Order | Administered in hospital |
2 | 9/10/2016 - 9/12-2016 | Zithromax (azithromycin) 500 MG in 250 ml Normal Saline intravenous infusion over 1hr daily | Provider B’s Order | Administered in hospital |
3 | 9/10/2016 - 9/12-2016 | Ketorolac 15 mg intravenously every 6 hours | Provider B’s Order | Administered in hospital |
2 | 9/10/2016 - 9/12-2016 | LRS Solution 200 ml/hr intravenously CRI | Provider B’s Order | Administered in hospital |
5 | 9/12/2016 | Amoxicillin 500mg by mouth every 6 hours for 10 days | Provider B’s Order | discharge prescription, patient reported did not comply (fill prescription) |
6 | 9/12/2016 | Zithromax (azithromycin) 250mg by mouth every 12 hours for 10 days | Provider B’s Order | discharge prescription, patient reported did not comply (fill prescription) |
Request:
Get “all medications” for a patient inpatient encounter by querying MedicationRequest using the patient and encounter search parameters.
GET [base]/MedicationRequest?patient=test2&intent=order,plan&encounter=A
Response:
A Server returns a search Bundle resource containing all the MedicationRequests for the patient Brian Z during inpatient Encounter A:
HTTP/1.1 200 OK
[other headers]
{
"resourceType": "Bundle",
"id": "bb33a47a-cab8-4b4b-ba2e-3b663ffb98",
"meta": {
"lastUpdated": "2022-04-12T01:55:49.093Z"
},
"type": "searchset",
"total": 6,
"link": [
{
"relation": "self",
"url": "http://test.fhir.org/r4/MedicationRequest?_format=application/fhir+json&search-id=3f726452-7d24-4740-86f8-9c4a8f993a&&patient=test2&intent=order,plan&encounter=inpatient-example&_sort=_id"
}
],
"entry": [
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/0e2dda71-7122-4840-9252-17c84a0d50",
"resource": {
"resourceType": "MedicationRequest",
"id": "0e2dda71-7122-4840-9252-17c84a0d50",
"meta": {
"versionId": "4",
"lastUpdated": "2022-04-12T01:54:45.483Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "Inpatient"
}
]
},
"contained": [
{
"resourceType": "Medication",
"id": "med-1",
"meta": {
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medication"
]
},
"code": {
"text": "Azithromycin 500mg in 250 ml Normal Saline"
},
"ingredient": [
{
"itemCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "1668240",
"display": "Zithromax 500 MG Injection"
}
],
"text": "Zithromax (azithromycin) 500 MG Injection"
},
"isActive": true
},
{
"itemCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "313002",
"display": "Sodium Chloride 0.9% injectable solution"
}
],
"text": "Normal Saline"
},
"isActive": true
}
]
}
],
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "inpatient",
"display": "Inpatient"
}
],
"text": "Inpatient"
}
],
"reportedBoolean": false,
"medicationReference": {
"reference": "#med-1"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/inpatient-example",
"display": "Inpatient encounter"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/example-drb",
"display": "Dr B"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "Azithromycin 500mg in 250 ml Normal Saline intravenously over 1hour every 24 hours",
"timing": {
"repeat": {
"duration": 1,
"durationUnit": "h",
"frequency": 1,
"period": 24,
"periodUnit": "h"
}
},
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38276",
"display": "INTRAVENOUS"
}
]
},
"method": {
"text": "1 hr infusion"
}
}
]
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/1e51d801-1cdf-4d61-9dc0-8937945a35",
"resource": {
"resourceType": "MedicationRequest",
"id": "1e51d801-1cdf-4d61-9dc0-8937945a35",
"meta": {
"versionId": "4",
"lastUpdated": "2022-04-12T01:54:45.608Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "Inpatient"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "inpatient",
"display": "Inpatient"
}
],
"text": "Inpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "212446",
"display": "Zithromax 250 MG Oral Tablet"
}
],
"text": "Zithromax 500 MG Oral Tablet"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/inpatient-example",
"display": "Inpatient encounter"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/example-drb",
"display": "Dr B"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "Zithromax (azithromycin) 250mg by mouth every 12 hours for 10 days",
"additionalInstruction": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "311504000",
"display": "With or after food"
}
]
}
],
"timing": {
"repeat": {
"frequency": 1,
"period": 12,
"periodUnit": "h"
}
},
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38288",
"display": "ORALLY",
"userSelected": false
}
]
}
}
],
"dispenseRequest": {
"validityPeriod": {
"start": "2016-09-12",
"end": "2016-10-12"
},
"quantity": {
"value": 20,
"unit": "TAB",
"system": "http://hl7.org/fhir/v3/orderableDrugForm",
"code": "TAB"
},
"expectedSupplyDuration": {
"value": 10,
"unit": "days",
"system": "http://unitsofmeasure.org",
"code": "d"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/4362b3f0-37bc-4463-93b3-c6b8228d91",
"resource": {
"resourceType": "MedicationRequest",
"id": "4362b3f0-37bc-4463-93b3-c6b8228d91",
"meta": {
"versionId": "4",
"lastUpdated": "2022-04-12T01:54:45.671Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "Inpatient"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "inpatient",
"display": "Inpatient"
}
],
"text": "Inpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "308191",
"display": "Amoxicillin 500 MG Oral Capsule"
}
],
"text": "Amoxicillin 500 MG"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/inpatient-example",
"display": "Inpatient encounter"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/example-drb",
"display": "Dr B"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "Amoxicillin 500mg by mouth every 6 hours for 10 days",
"additionalInstruction": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "311504000",
"display": "With or after food"
}
]
}
],
"timing": {
"repeat": {
"frequency": 1,
"period": 6,
"periodUnit": "h"
}
},
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38288",
"display": "ORALLY",
"userSelected": false
}
]
}
}
],
"dispenseRequest": {
"validityPeriod": {
"start": "2016-09-12",
"end": "2016-10-12"
},
"numberOfRepeatsAllowed": 0,
"quantity": {
"value": 40,
"unit": "Oral Capsule",
"system": "http://hl7.org/fhir/v3/orderableDrugForm",
"code": "ORCAP"
},
"expectedSupplyDuration": {
"value": 10,
"unit": "days",
"system": "http://unitsofmeasure.org",
"code": "d"
}
}
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/5996de24-bb15-44d5-ad5e-e942090123",
"resource": {
"resourceType": "MedicationRequest",
"id": "5996de24-bb15-44d5-ad5e-e942090123",
"meta": {
"versionId": "4",
"lastUpdated": "2022-04-12T01:54:45.765Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "Inpatient"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "inpatient",
"display": "Inpatient"
}
],
"text": "Inpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "860601",
"display": "Calcium Chloride 0.0014 MEQ/ML / Potassium Chloride 0.024 MEQ/ML / Sodium Chloride 0.103 MEQ/ML / Sodium Lactate 0.028 MEQ/ML Injectable Solution"
}
],
"text": "LRS"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/inpatient-example",
"display": "Inpatient encounter"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/example-drb",
"display": "Dr B"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "LRS IV at 250 ml/hr",
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38276",
"display": "INTRAVENOUS",
"userSelected": false
}
]
},
"method": {
"text": "Constant Rate Infusion"
}
}
]
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/bb95536c-eca6-4f31-af6e-821c3bc9d3",
"resource": {
"resourceType": "MedicationRequest",
"id": "bb95536c-eca6-4f31-af6e-821c3bc9d3",
"meta": {
"versionId": "4",
"lastUpdated": "2022-04-12T01:54:45.811Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "Inpatient"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "inpatient",
"display": "Inpatient"
}
],
"text": "Inpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "1656313",
"display": "Cefotaxime 1000 MG Injection"
}
],
"text": "Cefotaxime 1000Mg Powder For Solution For Injection"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/inpatient-example",
"display": "Inpatient encounter"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/example-drcayr",
"display": "Dr Cayr"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "Cefatoxime 1gm intravenously every 6 hours",
"timing": {
"repeat": {
"frequency": 1,
"period": 6,
"periodUnit": "h"
}
},
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38276",
"display": "INTRAVENOUS",
"userSelected": false
}
]
},
"method": {
"text": "Slow Push"
}
}
]
},
"search": {
"mode": "match"
}
},
{
"fullUrl": "http://test.fhir.org/r4/MedicationRequest/e5fb50da-bff9-414a-a229-68b431c489",
"resource": {
"resourceType": "MedicationRequest",
"id": "e5fb50da-bff9-414a-a229-68b431c489",
"meta": {
"versionId": "4",
"lastUpdated": "2022-04-12T01:54:45.858Z",
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-medicationrequest"
],
"tag": [
{
"code": "US_Core_5"
},
{
"code": "Inpatient"
}
]
},
"status": "active",
"intent": "order",
"category": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/medicationrequest-category",
"code": "inpatient",
"display": "Inpatient"
}
],
"text": "Inpatient"
}
],
"reportedBoolean": false,
"medicationCodeableConcept": {
"coding": [
{
"system": "http://www.nlm.nih.gov/research/umls/rxnorm",
"code": "860092",
"display": "1 ML Ketorolac Tromethamine 15 MG/ML Injection"
}
],
"text": "Ketorolac Tromethamine 15 MG/ML For Injection"
},
"subject": {
"reference": "Patient/test2",
"display": "Brian Z"
},
"encounter": {
"reference": "Encounter/inpatient-example",
"display": "Inpatient encounter"
},
"authoredOn": "2016-09-12",
"requester": {
"reference": "Practitioner/example-drb",
"display": "Dr B"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia (disorder)"
}
]
}
],
"dosageInstruction": [
{
"sequence": 1,
"text": "Ketoralac 15mg every six hours",
"timing": {
"repeat": {
"frequency": 1,
"period": 6,
"periodUnit": "h"
}
},
"asNeededBoolean": false,
"route": {
"coding": [
{
"system": "http://ncimeta.nci.nih.gov",
"code": "C38276",
"display": "INTRAVENOUS",
"userSelected": false
}
]
},
"method": {
"text": "Slow Push"
}
}
]
},
"search": {
"mode": "match"
}
}
]
}
See the US Core Server Capability Statement for a complete list of supported RESTful operations and search parameters for this IG.
Medications may be duplicated in a medication list when multiple sources of data are used to generate the list. To provide a list of a patient’s medications, it may be necessary to “de-duplicate” the medications on the list. The deduplication activity MAY be provided by the server but SHOULD be provided by the client.
This specification does not specify deduplication best practices, however systems can consider the following approaches:
Footnotes
It is anticipated that there will be further changes to the medication resources in future versions of FHIR which may lead to changes in our guidance for fetching patient medications in future versions of this guide. ↩