MedicationRequest
An order or request for both supply of the medication and the instructions for administration of the medication to a patient. The resource is called “MedicationRequest” rather than “MedicationPrescription” or “MedicationOrder” to generalize the use across inpatient and outpatient settings, including care plans, etc., and to harmonize with workflow patterns.
http://hl7.org/fhir/us/core/STU3.1.1/StructureDefinition-us-core-medicationrequest.html
FHIR MedicationRequest maps to the Prescribe, Refill, Adjust Prescription, Deny Refill or Approve Refill commands in Canvas.
MedicationRequest read
Read a MedicationRequest resource.
Path Parameters
Response Payload Attributes
The FHIR Resource name.
The identifier of the MedicationRequest.
A code specifying the current state of the order.
Whether the request is a proposal, plan, or an original order.
A Medication Request that corresponds to a refill in the patient’s chart will have an intent of filler-order
while all other Medication Requests will be order
.
Indicates if this record was captured as a secondary ‘reported’ record rather than as an original primary source-of-truth record.
Currently this will always be False from Canvas.
Identifies the medication being requested. This is simply an attribute carrying a code that identifies the medication from a known list of medications.
Code defined by a terminology system.
The system url of the coding.
The code of the medication.
The display name of the coding.
Who or group medication request is for.
The reference string of the subject in the format of "Patient/a39cafb9d1b445be95a2e2548e12a787"
.
Type the reference refers to (e.g. “Patient”).
Encounter created as part of encounter/admission/stay.
The reference string of the encounter in the format of "Encounter/f7663d7b-13bd-4236-843e-086306aea125"
.
Type the reference refers to (e.g. “Encounter”).
When request was initially authored. In Canvas this corresponds to the time the command was created.
Who/What requested the Request.
The reference string of the subject in the format of "Practitioner/ed1e304acdb847148338c6b0596d93fd"
.
Type the reference refers to (e.g. “Practitioner”).
Intended performer of administration
This attribute is deprecated and will be removed in a future release. It currently (and incorrectly) contains information about the dispenser of the medication. Canvas recommends disregarding this attribute. Information about the dispenser can be obtained from the performer
attribute under dispenseRequest
.
Reason or indication for ordering or not ordering the medication.
In Canvas this represents the indications on a Prescribe/Refill Command.
Code defined by a terminology system.
The system url of the coding.
The code of the indication.
The display name of the coding.
Information about the prescription.
The annotation - text content.
How the medication should be taken.
Free text dosage instructions. In Canvas this text comes from the SIG
or DIRECTIONS
field on the associated command.
Amount of medication administered.
Amount of medication per dose.
Unit representation.
Medication supply authorization.
Number of refills authorized.
Amount of medication to supply per dispense.
Numerical value.
Number of days supply per dispense.
Numerical value.
Unit representation.
Intended dispenser. In Canvas this represents the pharmacy the medication request was sent to.
Text alternative for the resource.
This display name concatenates the following information about the pharmacy: Name, NCPDP ID, Address, Phone, and Fax
Any restrictions on medication substitution.
Whether substitution is allowed or not.
Responses
Errors
MedicationRequest search
Search for MedicationRequest resources.
Query Parameters
The identifier of the MedicationRequest.
Search Medication Requests by specific intents.
The patient reference associated to the Medication Request in the format Patient/a39cafb9d1b445be95a2e2548e12a787
.
The Practitioner reference associated to the MedicationRequest.requester attribute in the format Practitioner/6c20b7152cf7421791c5ab4113060b3f
.
Search Medication Requests by a specific status.
Response Payload Attributes
The FHIR Resource name.
This element and value designate that the bundle is a search response. Search result bundles will always have the Bundle.type of searchset .
The number of resources that match the search parameter.
Attributes relevant to pagination, see our Pagination page for more detail.
The relation of the page search
The search url for the specific relation
The results bundle that lists out each object returned in the search
The attributes specific to the resource type, see the Attributes section below
Attributes
The FHIR Resource name.
The identifier of the MedicationRequest.
A code specifying the current state of the order.
Whether the request is a proposal, plan, or an original order.
A Medication Request that corresponds to a refill in the patient’s chart will have an intent of filler-order
while all other Medication Requests will be order
.
Indicates if this record was captured as a secondary ‘reported’ record rather than as an original primary source-of-truth record.
Currently this will always be False from Canvas.
Identifies the medication being requested. This is simply an attribute carrying a code that identifies the medication from a known list of medications.
Code defined by a terminology system.
The system url of the coding.
The code of the medication.
The display name of the coding.
Who or group medication request is for.
The reference string of the subject in the format of "Patient/a39cafb9d1b445be95a2e2548e12a787"
.
Type the reference refers to (e.g. “Patient”).
Encounter created as part of encounter/admission/stay.
The reference string of the encounter in the format of "Encounter/f7663d7b-13bd-4236-843e-086306aea125"
.
Type the reference refers to (e.g. “Encounter”).
When request was initially authored. In Canvas this corresponds to the time the command was created.
Who/What requested the Request.
The reference string of the subject in the format of "Practitioner/ed1e304acdb847148338c6b0596d93fd"
.
Type the reference refers to (e.g. “Practitioner”).
Intended performer of administration
This attribute is deprecated and will be removed in a future release. It currently (and incorrectly) contains information about the dispenser of the medication. Canvas recommends disregarding this attribute. Information about the dispenser can be obtained from the performer
attribute under dispenseRequest
.
Reason or indication for ordering or not ordering the medication.
In Canvas this represents the indications on a Prescribe/Refill Command.
Code defined by a terminology system.
The system url of the coding.
The code of the indication.
The display name of the coding.
Information about the prescription.
The annotation - text content.
How the medication should be taken.
Free text dosage instructions. In Canvas this text comes from the SIG
or DIRECTIONS
field on the associated command.
Amount of medication administered.
Amount of medication per dose.
Unit representation.
Medication supply authorization.
Number of refills authorized.
Amount of medication to supply per dispense.
Numerical value.
Number of days supply per dispense.
Numerical value.
Unit representation.
Intended dispenser. In Canvas this represents the pharmacy the medication request was sent to.
Text alternative for the resource.
This display name concatenates the following information about the pharmacy: Name, NCPDP ID, Address, Phone, and Fax
Any restrictions on medication substitution.
Whether substitution is allowed or not.
Responses
Errors
curl --request GET \ --url 'https://fumage-example.canvasmedical.com/MedicationRequest/<id>' \ --header 'Authorization: Bearer <token>' \ --header 'accept: application/json'
import requests url = "https://fumage-example.canvasmedical.com/MedicationRequest/<id>" headers = { "accept": "application/json", "Authorization": "Bearer <token>" } response = requests.get(url, headers=headers) print(response.text)
{ "resourceType": "MedicationRequest", "id": "3423a69c-618d-4cbe-861a-54c60f48744e", "status": "active", "intent": "order", "reportedBoolean": false, "medicationCodeableConcept": { "coding": [ { "system": "http://www.fdbhealth.com/", "code": "244899", "display": "lisinopril 10 mg tablet" }, { "system": "http://www.nlm.nih.gov/research/umls/rxnorm", "code": "314076", "display": "lisinopril 10 mg tablet" } ] }, "subject": { "reference": "Patient/6cb2a409334943c2b48f1686dc739f11", "type": "Patient" }, "encounter": { "reference": "Encounter/bdadce18-098b-40dc-8bdd-ef8481bd999a", "type": "Encounter" }, "authoredOn": "2023-09-21T18:19:36.106449+00:00", "requester": { "reference": "Practitioner/6c20b7152cf7421791c5ab4113060b3f", "type": "Practitioner" }, "reasonCode": [ { "coding": [ { "system": "http://hl7.org/fhir/sid/icd-10-cm", "code": "I10", "display": "Essential (primary) hypertension" } ] } ], "dosageInstruction": [ { "text": "take 1 daily", "doseAndRate": [ { "doseQuantity": { "unit": "Tablet" } } ] } ], "dispenseRequest": { "numberOfRepeatsAllowed": 3, "quantity": { "value": 30.0 }, "expectedSupplyDuration": { "value": 30, "unit": "days" }, "performer": { "display": "Name: CVS Health #68534|NCPDP ID: 0068534|Address: 1 Cvs Dr, Woonsocket, RI, 028956146|Phone: 4017702500|Fax: 4017704486" } }, "substitution": { "allowedBoolean": true } }
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "unknown", "details": { "text": "Authentication failed" } } ] }
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "forbidden", "details": { "text": "Authorization failed" } } ] }
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "not-found", "details": { "text": "Unknown MedicationRequest resource 'a47c7b0e-bbb4-42cd-bc4a-df259d148ea1'" } } ] }
curl --request GET \ --url 'https://fumage-example.canvasmedical.com/MedicationRequest?patient=Patient/b8dfa97bdcdf4754bcd8197ca78ef0f0' \ --header 'Authorization: Bearer <token>' \ --header 'accept: application/json'
import requests url = "https://fumage-example.canvasmedical.com/MedicationRequest?patient=Patient/b8dfa97bdcdf4754bcd8197ca78ef0f0" headers = { "accept": "application/json", "Authorization": "Bearer <token>" } response = requests.get(url, headers=headers) print(response.text)
{ "resourceType": "Bundle", "type": "searchset", "total": 1, "link": [ { "relation": "self", "url": "/MedicationRequest?patient=Patient%2F6cb2a409334943c2b48f1686dc739f11&_count=10&_offset=0" }, { "relation": "first", "url": "/MedicationRequest?patient=Patient%2F6cb2a409334943c2b48f1686dc739f11&_count=10&_offset=0" }, { "relation": "last", "url": "/MedicationRequest?patient=Patient%2F6cb2a409334943c2b48f1686dc739f11&_count=10&_offset=0" } ], "entry": [ { "resource": { "resourceType": "MedicationRequest", "id": "3423a69c-618d-4cbe-861a-54c60f48744e", "status": "active", "intent": "order", "reportedBoolean": false, "medicationCodeableConcept": { "coding": [ { "system": "http://www.fdbhealth.com/", "code": "244899", "display": "lisinopril 10 mg tablet" }, { "system": "http://www.nlm.nih.gov/research/umls/rxnorm", "code": "314076", "display": "lisinopril 10 mg tablet" } ] }, "subject": { "reference": "Patient/6cb2a409334943c2b48f1686dc739f11", "type": "Patient" }, "encounter": { "reference": "Encounter/bdadce18-098b-40dc-8bdd-ef8481bd999a", "type": "Encounter" }, "authoredOn": "2023-09-21T18:19:36.106449+00:00", "requester": { "reference": "Practitioner/6c20b7152cf7421791c5ab4113060b3f", "type": "Practitioner" }, "reasonCode": [ { "coding": [ { "system": "http://hl7.org/fhir/sid/icd-10-cm", "code": "I10", "display": "Essential (primary) hypertension" } ] } ], "dosageInstruction": [ { "text": "take 1 daily", "doseAndRate": [ { "doseQuantity": { "unit": "Tablet" } } ] } ], "dispenseRequest": { "numberOfRepeatsAllowed": 3, "quantity": { "value": 30.0 }, "expectedSupplyDuration": { "value": 30, "unit": "days" }, "performer": { "display": "Name: CVS Health #68534|NCPDP ID: 0068534|Address: 1 Cvs Dr, Woonsocket, RI, 028956146|Phone: 4017702500|Fax: 4017704486" } }, "substitution": { "allowedBoolean": true } } } ] }
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "invalid", "details": { "text": "Bad request" } } ] }
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "unknown", "details": { "text": "Authentication failed" } } ] }
{ "resourceType": "OperationOutcome", "issue": [ { "severity": "error", "code": "forbidden", "details": { "text": "Authorization failed" } } ] }