2022 CDC Clinical Practice Guideline for Prescribing Opioids Implementation Guide
2022.1.0 - CI Build

2022 CDC Clinical Practice Guideline for Prescribing Opioids Implementation Guide, published by Centers for Disease Control and Prevention (CDC). This guide is not an authorized publication; it is the continuous build for version 2022.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/cqframework/opioid-cds-r4/ and changes regularly. See the Directory of published versions

Resource Profile: CDC_MedicationRequest

Official URL: http://fhir.org/guides/cdc/opioid-cds/StructureDefinition/cdc-medicationrequest Version: 2022.1.0
Draft as of 2017-04-21 Computable Name: CDC_MedicationRequest

Profile of MedicationRequest for use with 2022 CDC Clinical Practice Guideline

Usage:

Formal Views of Profile Content

Description of Profiles, Differentials, Snapshots and how the different presentations work.

This structure is derived from CPGMedicationRequest

NameFlagsCard.TypeDescription & Constraintsdoco
.. MedicationRequest 0..*CPGMedicationRequestOrdering of medication for patient or group
... medication[x] S1..1CodeableConceptMedication to be taken
... dosageInstruction S1..1DosageHow the medication should be taken
.... timing S1..1TimingWhen medication should be administered
..... repeat S1..1ElementWhen the event is to occur
...... frequency S1..1positiveIntEvent occurs frequency times per period
...... period S1..1decimalEvent occurs frequency times per period
...... periodUnit S1..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
.... asNeeded[x] S0..1booleanTake "as needed" (for x)

doco Documentation for this format
NameFlagsCard.TypeDescription & Constraintsdoco
.. MedicationRequest 0..*CPGMedicationRequestOrdering of medication for patient or group
... implicitRules ?!Σ0..1uriA set of rules under which this content was created
... rationale S0..1markdownExplanation
URL: http://hl7.org/fhir/uv/cpg/StructureDefinition/cpg-rationale
... modifierExtension ?!0..*ExtensionExtensions that cannot be ignored
... status ?!SΣ1..1codeactive | on-hold | cancelled | completed | entered-in-error | stopped | draft | unknown
Binding: medicationrequest Status (required): A coded concept specifying the state of the prescribing event. Describes the lifecycle of the prescription.

... intent ?!SΣ1..1codeproposal | plan | order | original-order | reflex-order | filler-order | instance-order | option
Binding: medicationRequest Intent (required): The kind of medication order.

... category S0..*CodeableConceptType of medication usage
Binding: medicationRequest Category Codes (example): A coded concept identifying the category of medication request. For example, where the medication is to be consumed or administered, or the type of medication treatment.


... priority SΣ0..1coderoutine | urgent | asap | stat
Binding: RequestPriority (required): Identifies the level of importance to be assigned to actioning the request.

... doNotPerform ?!SΣ0..1booleanTrue if request is prohibiting action
... medication[x] SΣ1..1CodeableConceptMedication to be taken
Binding: SNOMEDCTMedicationCodes (example): A coded concept identifying substance or product that can be ordered.

... subject SΣ1..1Reference(CPGPatient)Who or group medication request is for
... encounter S0..1Reference(CPGEncounter)Encounter created as part of encounter/admission/stay
... supportingInformation S0..*Reference(Resource)Pertinent information
... instantiatesCanonical SΣ0..*canonical()Source
... dosageInstruction S1..1DosageHow the medication should be taken
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... timing SΣ1..1TimingWhen medication should be administered
..... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
..... repeat SΣC1..1ElementWhen the event is to occur
tim-1: if there's a duration, there needs to be duration units
tim-2: if there's a period, there needs to be period units
tim-4: duration SHALL be a non-negative value
tim-5: period SHALL be a non-negative value
tim-6: If there's a periodMax, there must be a period
tim-7: If there's a durationMax, there must be a duration
tim-8: If there's a countMax, there must be a count
tim-9: If there's an offset, there must be a when (and not C, CM, CD, CV)
tim-10: If there's a timeOfDay, there cannot be a when, or vice versa
...... frequency SΣ1..1positiveIntEvent occurs frequency times per period
...... period SΣ1..1decimalEvent occurs frequency times per period
...... periodUnit SΣ1..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
Binding: UnitsOfTime (required): A unit of time (units from UCUM).

.... asNeeded[x] SΣ0..1booleanTake "as needed" (for x)

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
MedicationRequest.statusrequiredmedicationrequest Status
http://hl7.org/fhir/ValueSet/medicationrequest-status|4.0.1
from the FHIR Standard
MedicationRequest.intentrequiredmedicationRequest Intent
http://hl7.org/fhir/ValueSet/medicationrequest-intent|4.0.1
from the FHIR Standard
MedicationRequest.categoryexamplemedicationRequest Category Codes
http://hl7.org/fhir/ValueSet/medicationrequest-category
from the FHIR Standard
MedicationRequest.priorityrequiredRequestPriority
http://hl7.org/fhir/ValueSet/request-priority|4.0.1
from the FHIR Standard
MedicationRequest.medication[x]exampleSNOMEDCTMedicationCodes
http://hl7.org/fhir/ValueSet/medication-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.periodUnitrequiredUnitsOfTime
http://hl7.org/fhir/ValueSet/units-of-time|4.0.1
from the FHIR Standard

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorMedicationRequestIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorMedicationRequestIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceMedicationRequestA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()
tim-1errorMedicationRequest.dosageInstruction.timing.repeatif there's a duration, there needs to be duration units
: duration.empty() or durationUnit.exists()
tim-2errorMedicationRequest.dosageInstruction.timing.repeatif there's a period, there needs to be period units
: period.empty() or periodUnit.exists()
tim-4errorMedicationRequest.dosageInstruction.timing.repeatduration SHALL be a non-negative value
: duration.exists() implies duration >= 0
tim-5errorMedicationRequest.dosageInstruction.timing.repeatperiod SHALL be a non-negative value
: period.exists() implies period >= 0
tim-6errorMedicationRequest.dosageInstruction.timing.repeatIf there's a periodMax, there must be a period
: periodMax.empty() or period.exists()
tim-7errorMedicationRequest.dosageInstruction.timing.repeatIf there's a durationMax, there must be a duration
: durationMax.empty() or duration.exists()
tim-8errorMedicationRequest.dosageInstruction.timing.repeatIf there's a countMax, there must be a count
: countMax.empty() or count.exists()
tim-9errorMedicationRequest.dosageInstruction.timing.repeatIf there's an offset, there must be a when (and not C, CM, CD, CV)
: offset.empty() or (when.exists() and ((when in ('C' | 'CM' | 'CD' | 'CV')).not()))
tim-10errorMedicationRequest.dosageInstruction.timing.repeatIf there's a timeOfDay, there cannot be a when, or vice versa
: timeOfDay.empty() or when.empty()
NameFlagsCard.TypeDescription & Constraintsdoco
.. MedicationRequest 0..*CPGMedicationRequestOrdering of medication for patient or group
... id Σ0..1idLogical id of this artifact
... meta Σ0..1MetaMetadata about the resource
... implicitRules ?!Σ0..1uriA set of rules under which this content was created
... language 0..1codeLanguage of the resource content
Binding: CommonLanguages (preferred): A human language.

Additional BindingsPurpose
AllLanguagesMax Binding
... text 0..1NarrativeText summary of the resource, for human interpretation
... contained 0..*ResourceContained, inline Resources
... Slices for extension 0..*ExtensionExtension
Slice: Unordered, Open by value:url
... rationale S0..1markdownExplanation
URL: http://hl7.org/fhir/uv/cpg/StructureDefinition/cpg-rationale
... modifierExtension ?!0..*ExtensionExtensions that cannot be ignored
... identifier S0..*IdentifierExternal ids for this request
... status ?!SΣ1..1codeactive | on-hold | cancelled | completed | entered-in-error | stopped | draft | unknown
Binding: medicationrequest Status (required): A coded concept specifying the state of the prescribing event. Describes the lifecycle of the prescription.

... statusReason 0..1CodeableConceptReason for current status
Binding: medicationRequest Status Reason Codes (example): Identifies the reasons for a given status.

... intent ?!SΣ1..1codeproposal | plan | order | original-order | reflex-order | filler-order | instance-order | option
Binding: medicationRequest Intent (required): The kind of medication order.

... category S0..*CodeableConceptType of medication usage
Binding: medicationRequest Category Codes (example): A coded concept identifying the category of medication request. For example, where the medication is to be consumed or administered, or the type of medication treatment.


... priority SΣ0..1coderoutine | urgent | asap | stat
Binding: RequestPriority (required): Identifies the level of importance to be assigned to actioning the request.

... doNotPerform ?!SΣ0..1booleanTrue if request is prohibiting action
... reported[x] Σ0..1Reported rather than primary record
.... reportedBooleanboolean
.... reportedReferenceReference(Patient | Practitioner | PractitionerRole | RelatedPerson | Organization)
... medication[x] SΣ1..1CodeableConceptMedication to be taken
Binding: SNOMEDCTMedicationCodes (example): A coded concept identifying substance or product that can be ordered.

... subject SΣ1..1Reference(CPGPatient)Who or group medication request is for
... encounter S0..1Reference(CPGEncounter)Encounter created as part of encounter/admission/stay
... supportingInformation S0..*Reference(Resource)Pertinent information
... authoredOn Σ0..1dateTimeWhen request was initially authored
... requester Σ0..1Reference(Practitioner | PractitionerRole | Organization | Patient | RelatedPerson | Device)Who/What requested the Request
... performer 0..1Reference(Practitioner | PractitionerRole | Organization | Patient | Device | RelatedPerson | CareTeam)Intended performer of administration
... performerType Σ0..1CodeableConceptDesired kind of performer of the medication administration
Binding: ProcedurePerformerRoleCodes (example): Identifies the type of individual that is desired to administer the medication.

... recorder 0..1Reference(Practitioner | PractitionerRole)Person who entered the request
... reasonCode 0..*CodeableConceptReason or indication for ordering or not ordering the medication
Binding: Condition/Problem/DiagnosisCodes (example): A coded concept indicating why the medication was ordered.


... reasonReference 0..*Reference(Condition | Observation)Condition or observation that supports why the prescription is being written
... instantiatesCanonical SΣ0..*canonical()Source
... instantiatesUri Σ0..*uriInstantiates external protocol or definition
... basedOn Σ0..*Reference(CarePlan | MedicationRequest | ServiceRequest | ImmunizationRecommendation)What request fulfills
... groupIdentifier Σ0..1IdentifierComposite request this is part of
... courseOfTherapyType 0..1CodeableConceptOverall pattern of medication administration
Binding: medicationRequest Course of Therapy Codes (example): Identifies the overall pattern of medication administratio.

... insurance 0..*Reference(Coverage | ClaimResponse)Associated insurance coverage
... note 0..*AnnotationInformation about the prescription
... dosageInstruction S1..1DosageHow the medication should be taken
.... id 0..1stringUnique id for inter-element referencing
.... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... sequence Σ0..1integerThe order of the dosage instructions
.... text Σ0..1stringFree text dosage instructions e.g. SIG
.... additionalInstruction Σ0..*CodeableConceptSupplemental instruction or warnings to the patient - e.g. "with meals", "may cause drowsiness"
Binding: SNOMEDCTAdditionalDosageInstructions (example): A coded concept identifying additional instructions such as "take with water" or "avoid operating heavy machinery".


.... patientInstruction Σ0..1stringPatient or consumer oriented instructions
.... timing SΣ1..1TimingWhen medication should be administered
..... id 0..1stringUnique id for inter-element referencing
..... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
..... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
..... event Σ0..*dateTimeWhen the event occurs
..... repeat SΣC1..1ElementWhen the event is to occur
tim-1: if there's a duration, there needs to be duration units
tim-2: if there's a period, there needs to be period units
tim-4: duration SHALL be a non-negative value
tim-5: period SHALL be a non-negative value
tim-6: If there's a periodMax, there must be a period
tim-7: If there's a durationMax, there must be a duration
tim-8: If there's a countMax, there must be a count
tim-9: If there's an offset, there must be a when (and not C, CM, CD, CV)
tim-10: If there's a timeOfDay, there cannot be a when, or vice versa
...... id 0..1stringUnique id for inter-element referencing
...... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
...... bounds[x] Σ0..1Length/Range of lengths, or (Start and/or end) limits
....... boundsDurationDuration
....... boundsRangeRange
....... boundsPeriodPeriod
...... count Σ0..1positiveIntNumber of times to repeat
...... countMax Σ0..1positiveIntMaximum number of times to repeat
...... duration Σ0..1decimalHow long when it happens
...... durationMax Σ0..1decimalHow long when it happens (Max)
...... durationUnit Σ0..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
Binding: UnitsOfTime (required): A unit of time (units from UCUM).

...... frequency SΣ1..1positiveIntEvent occurs frequency times per period
...... frequencyMax Σ0..1positiveIntEvent occurs up to frequencyMax times per period
...... period SΣ1..1decimalEvent occurs frequency times per period
...... periodMax Σ0..1decimalUpper limit of period (3-4 hours)
...... periodUnit SΣ1..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
Binding: UnitsOfTime (required): A unit of time (units from UCUM).

...... dayOfWeek Σ0..*codemon | tue | wed | thu | fri | sat | sun
Binding: DaysOfWeek (required)
...... timeOfDay Σ0..*timeTime of day for action
...... when Σ0..*codeCode for time period of occurrence
Binding: EventTiming (required): Real world event relating to the schedule.


...... offset Σ0..1unsignedIntMinutes from event (before or after)
..... code Σ0..1CodeableConceptBID | TID | QID | AM | PM | QD | QOD | +
Binding: TimingAbbreviation (preferred): Code for a known / defined timing pattern.

.... asNeeded[x] SΣ0..1booleanTake "as needed" (for x)
.... site Σ0..1CodeableConceptBody site to administer to
Binding: SNOMEDCTAnatomicalStructureForAdministrationSiteCodes (example): A coded concept describing the site location the medicine enters into or onto the body.

.... route Σ0..1CodeableConceptHow drug should enter body
Binding: SNOMEDCTRouteCodes (example): A coded concept describing the route or physiological path of administration of a therapeutic agent into or onto the body of a subject.

.... method Σ0..1CodeableConceptTechnique for administering medication
Binding: SNOMEDCTAdministrationMethodCodes (example): A coded concept describing the technique by which the medicine is administered.

.... doseAndRate Σ0..*ElementAmount of medication administered
..... id 0..1stringUnique id for inter-element referencing
..... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
..... type Σ0..1CodeableConceptThe kind of dose or rate specified
Binding: DoseAndRateType (example): The kind of dose or rate specified.

..... dose[x] Σ0..1Amount of medication per dose
...... doseRangeRange
...... doseQuantityQuantity(SimpleQuantity)
..... rate[x] Σ0..1Amount of medication per unit of time
...... rateRatioRatio
...... rateRangeRange
...... rateQuantityQuantity(SimpleQuantity)
.... maxDosePerPeriod Σ0..1RatioUpper limit on medication per unit of time
.... maxDosePerAdministration Σ0..1SimpleQuantityUpper limit on medication per administration
.... maxDosePerLifetime Σ0..1SimpleQuantityUpper limit on medication per lifetime of the patient
... dispenseRequest 0..1BackboneElementMedication supply authorization
.... id 0..1stringUnique id for inter-element referencing
.... extension 0..*ExtensionAdditional content defined by implementations
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... initialFill 0..1BackboneElementFirst fill details
..... id 0..1stringUnique id for inter-element referencing
..... extension 0..*ExtensionAdditional content defined by implementations
..... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
..... quantity 0..1SimpleQuantityFirst fill quantity
..... duration 0..1DurationFirst fill duration
.... dispenseInterval 0..1DurationMinimum period of time between dispenses
.... validityPeriod 0..1PeriodTime period supply is authorized for
.... numberOfRepeatsAllowed 0..1unsignedIntNumber of refills authorized
.... quantity 0..1SimpleQuantityAmount of medication to supply per dispense
.... expectedSupplyDuration 0..1DurationNumber of days supply per dispense
.... performer 0..1Reference(Organization)Intended dispenser
... substitution 0..1BackboneElementAny restrictions on medication substitution
.... id 0..1stringUnique id for inter-element referencing
.... extension 0..*ExtensionAdditional content defined by implementations
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... allowed[x] 1..1Whether substitution is allowed or not
Binding: ActSubstanceAdminSubstitutionCode (example): Identifies the type of substitution allowed.

..... allowedBooleanboolean
..... allowedCodeableConceptCodeableConcept
.... reason 0..1CodeableConceptWhy should (not) substitution be made
Binding: SubstanceAdminSubstitutionReason (example): A coded concept describing the reason that a different medication should (or should not) be substituted from what was prescribed.

... priorPrescription 0..1Reference(MedicationRequest)An order/prescription that is being replaced
... detectedIssue 0..*Reference(DetectedIssue)Clinical Issue with action
... eventHistory 0..*Reference(Provenance)A list of events of interest in the lifecycle

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
MedicationRequest.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
MedicationRequest.statusrequiredmedicationrequest Status
http://hl7.org/fhir/ValueSet/medicationrequest-status|4.0.1
from the FHIR Standard
MedicationRequest.statusReasonexamplemedicationRequest Status Reason Codes
http://hl7.org/fhir/ValueSet/medicationrequest-status-reason
from the FHIR Standard
MedicationRequest.intentrequiredmedicationRequest Intent
http://hl7.org/fhir/ValueSet/medicationrequest-intent|4.0.1
from the FHIR Standard
MedicationRequest.categoryexamplemedicationRequest Category Codes
http://hl7.org/fhir/ValueSet/medicationrequest-category
from the FHIR Standard
MedicationRequest.priorityrequiredRequestPriority
http://hl7.org/fhir/ValueSet/request-priority|4.0.1
from the FHIR Standard
MedicationRequest.medication[x]exampleSNOMEDCTMedicationCodes
http://hl7.org/fhir/ValueSet/medication-codes
from the FHIR Standard
MedicationRequest.performerTypeexampleProcedurePerformerRoleCodes
http://hl7.org/fhir/ValueSet/performer-role
from the FHIR Standard
MedicationRequest.reasonCodeexampleCondition/Problem/DiagnosisCodes
http://hl7.org/fhir/ValueSet/condition-code
from the FHIR Standard
MedicationRequest.courseOfTherapyTypeexamplemedicationRequest Course of Therapy Codes
http://hl7.org/fhir/ValueSet/medicationrequest-course-of-therapy
from the FHIR Standard
MedicationRequest.dosageInstruction.additionalInstructionexampleSNOMEDCTAdditionalDosageInstructions
http://hl7.org/fhir/ValueSet/additional-instruction-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.durationUnitrequiredUnitsOfTime
http://hl7.org/fhir/ValueSet/units-of-time|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.periodUnitrequiredUnitsOfTime
http://hl7.org/fhir/ValueSet/units-of-time|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.dayOfWeekrequiredDaysOfWeek
http://hl7.org/fhir/ValueSet/days-of-week|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.whenrequiredEventTiming
http://hl7.org/fhir/ValueSet/event-timing|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.codepreferredTimingAbbreviation
http://hl7.org/fhir/ValueSet/timing-abbreviation
from the FHIR Standard
MedicationRequest.dosageInstruction.siteexampleSNOMEDCTAnatomicalStructureForAdministrationSiteCodes
http://hl7.org/fhir/ValueSet/approach-site-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.routeexampleSNOMEDCTRouteCodes
http://hl7.org/fhir/ValueSet/route-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.methodexampleSNOMEDCTAdministrationMethodCodes
http://hl7.org/fhir/ValueSet/administration-method-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.doseAndRate.typeexampleDoseAndRateType
http://hl7.org/fhir/ValueSet/dose-rate-type
from the FHIR Standard
MedicationRequest.substitution.allowed[x]exampleActSubstanceAdminSubstitutionCode
http://terminology.hl7.org/ValueSet/v3-ActSubstanceAdminSubstitutionCode
MedicationRequest.substitution.reasonexampleSubstanceAdminSubstitutionReason
http://terminology.hl7.org/ValueSet/v3-SubstanceAdminSubstitutionReason

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorMedicationRequestIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorMedicationRequestIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceMedicationRequestA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()
tim-1errorMedicationRequest.dosageInstruction.timing.repeatif there's a duration, there needs to be duration units
: duration.empty() or durationUnit.exists()
tim-2errorMedicationRequest.dosageInstruction.timing.repeatif there's a period, there needs to be period units
: period.empty() or periodUnit.exists()
tim-4errorMedicationRequest.dosageInstruction.timing.repeatduration SHALL be a non-negative value
: duration.exists() implies duration >= 0
tim-5errorMedicationRequest.dosageInstruction.timing.repeatperiod SHALL be a non-negative value
: period.exists() implies period >= 0
tim-6errorMedicationRequest.dosageInstruction.timing.repeatIf there's a periodMax, there must be a period
: periodMax.empty() or period.exists()
tim-7errorMedicationRequest.dosageInstruction.timing.repeatIf there's a durationMax, there must be a duration
: durationMax.empty() or duration.exists()
tim-8errorMedicationRequest.dosageInstruction.timing.repeatIf there's a countMax, there must be a count
: countMax.empty() or count.exists()
tim-9errorMedicationRequest.dosageInstruction.timing.repeatIf there's an offset, there must be a when (and not C, CM, CD, CV)
: offset.empty() or (when.exists() and ((when in ('C' | 'CM' | 'CD' | 'CV')).not()))
tim-10errorMedicationRequest.dosageInstruction.timing.repeatIf there's a timeOfDay, there cannot be a when, or vice versa
: timeOfDay.empty() or when.empty()

This structure is derived from CPGMedicationRequest

Summary

Mandatory: 7 elements
Must-Support: 8 elements

Differential View

This structure is derived from CPGMedicationRequest

NameFlagsCard.TypeDescription & Constraintsdoco
.. MedicationRequest 0..*CPGMedicationRequestOrdering of medication for patient or group
... medication[x] S1..1CodeableConceptMedication to be taken
... dosageInstruction S1..1DosageHow the medication should be taken
.... timing S1..1TimingWhen medication should be administered
..... repeat S1..1ElementWhen the event is to occur
...... frequency S1..1positiveIntEvent occurs frequency times per period
...... period S1..1decimalEvent occurs frequency times per period
...... periodUnit S1..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
.... asNeeded[x] S0..1booleanTake "as needed" (for x)

doco Documentation for this format

Key Elements View

NameFlagsCard.TypeDescription & Constraintsdoco
.. MedicationRequest 0..*CPGMedicationRequestOrdering of medication for patient or group
... implicitRules ?!Σ0..1uriA set of rules under which this content was created
... rationale S0..1markdownExplanation
URL: http://hl7.org/fhir/uv/cpg/StructureDefinition/cpg-rationale
... modifierExtension ?!0..*ExtensionExtensions that cannot be ignored
... status ?!SΣ1..1codeactive | on-hold | cancelled | completed | entered-in-error | stopped | draft | unknown
Binding: medicationrequest Status (required): A coded concept specifying the state of the prescribing event. Describes the lifecycle of the prescription.

... intent ?!SΣ1..1codeproposal | plan | order | original-order | reflex-order | filler-order | instance-order | option
Binding: medicationRequest Intent (required): The kind of medication order.

... category S0..*CodeableConceptType of medication usage
Binding: medicationRequest Category Codes (example): A coded concept identifying the category of medication request. For example, where the medication is to be consumed or administered, or the type of medication treatment.


... priority SΣ0..1coderoutine | urgent | asap | stat
Binding: RequestPriority (required): Identifies the level of importance to be assigned to actioning the request.

... doNotPerform ?!SΣ0..1booleanTrue if request is prohibiting action
... medication[x] SΣ1..1CodeableConceptMedication to be taken
Binding: SNOMEDCTMedicationCodes (example): A coded concept identifying substance or product that can be ordered.

... subject SΣ1..1Reference(CPGPatient)Who or group medication request is for
... encounter S0..1Reference(CPGEncounter)Encounter created as part of encounter/admission/stay
... supportingInformation S0..*Reference(Resource)Pertinent information
... instantiatesCanonical SΣ0..*canonical()Source
... dosageInstruction S1..1DosageHow the medication should be taken
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... timing SΣ1..1TimingWhen medication should be administered
..... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
..... repeat SΣC1..1ElementWhen the event is to occur
tim-1: if there's a duration, there needs to be duration units
tim-2: if there's a period, there needs to be period units
tim-4: duration SHALL be a non-negative value
tim-5: period SHALL be a non-negative value
tim-6: If there's a periodMax, there must be a period
tim-7: If there's a durationMax, there must be a duration
tim-8: If there's a countMax, there must be a count
tim-9: If there's an offset, there must be a when (and not C, CM, CD, CV)
tim-10: If there's a timeOfDay, there cannot be a when, or vice versa
...... frequency SΣ1..1positiveIntEvent occurs frequency times per period
...... period SΣ1..1decimalEvent occurs frequency times per period
...... periodUnit SΣ1..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
Binding: UnitsOfTime (required): A unit of time (units from UCUM).

.... asNeeded[x] SΣ0..1booleanTake "as needed" (for x)

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
MedicationRequest.statusrequiredmedicationrequest Status
http://hl7.org/fhir/ValueSet/medicationrequest-status|4.0.1
from the FHIR Standard
MedicationRequest.intentrequiredmedicationRequest Intent
http://hl7.org/fhir/ValueSet/medicationrequest-intent|4.0.1
from the FHIR Standard
MedicationRequest.categoryexamplemedicationRequest Category Codes
http://hl7.org/fhir/ValueSet/medicationrequest-category
from the FHIR Standard
MedicationRequest.priorityrequiredRequestPriority
http://hl7.org/fhir/ValueSet/request-priority|4.0.1
from the FHIR Standard
MedicationRequest.medication[x]exampleSNOMEDCTMedicationCodes
http://hl7.org/fhir/ValueSet/medication-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.periodUnitrequiredUnitsOfTime
http://hl7.org/fhir/ValueSet/units-of-time|4.0.1
from the FHIR Standard

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorMedicationRequestIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorMedicationRequestIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceMedicationRequestA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()
tim-1errorMedicationRequest.dosageInstruction.timing.repeatif there's a duration, there needs to be duration units
: duration.empty() or durationUnit.exists()
tim-2errorMedicationRequest.dosageInstruction.timing.repeatif there's a period, there needs to be period units
: period.empty() or periodUnit.exists()
tim-4errorMedicationRequest.dosageInstruction.timing.repeatduration SHALL be a non-negative value
: duration.exists() implies duration >= 0
tim-5errorMedicationRequest.dosageInstruction.timing.repeatperiod SHALL be a non-negative value
: period.exists() implies period >= 0
tim-6errorMedicationRequest.dosageInstruction.timing.repeatIf there's a periodMax, there must be a period
: periodMax.empty() or period.exists()
tim-7errorMedicationRequest.dosageInstruction.timing.repeatIf there's a durationMax, there must be a duration
: durationMax.empty() or duration.exists()
tim-8errorMedicationRequest.dosageInstruction.timing.repeatIf there's a countMax, there must be a count
: countMax.empty() or count.exists()
tim-9errorMedicationRequest.dosageInstruction.timing.repeatIf there's an offset, there must be a when (and not C, CM, CD, CV)
: offset.empty() or (when.exists() and ((when in ('C' | 'CM' | 'CD' | 'CV')).not()))
tim-10errorMedicationRequest.dosageInstruction.timing.repeatIf there's a timeOfDay, there cannot be a when, or vice versa
: timeOfDay.empty() or when.empty()

Snapshot View

NameFlagsCard.TypeDescription & Constraintsdoco
.. MedicationRequest 0..*CPGMedicationRequestOrdering of medication for patient or group
... id Σ0..1idLogical id of this artifact
... meta Σ0..1MetaMetadata about the resource
... implicitRules ?!Σ0..1uriA set of rules under which this content was created
... language 0..1codeLanguage of the resource content
Binding: CommonLanguages (preferred): A human language.

Additional BindingsPurpose
AllLanguagesMax Binding
... text 0..1NarrativeText summary of the resource, for human interpretation
... contained 0..*ResourceContained, inline Resources
... Slices for extension 0..*ExtensionExtension
Slice: Unordered, Open by value:url
... rationale S0..1markdownExplanation
URL: http://hl7.org/fhir/uv/cpg/StructureDefinition/cpg-rationale
... modifierExtension ?!0..*ExtensionExtensions that cannot be ignored
... identifier S0..*IdentifierExternal ids for this request
... status ?!SΣ1..1codeactive | on-hold | cancelled | completed | entered-in-error | stopped | draft | unknown
Binding: medicationrequest Status (required): A coded concept specifying the state of the prescribing event. Describes the lifecycle of the prescription.

... statusReason 0..1CodeableConceptReason for current status
Binding: medicationRequest Status Reason Codes (example): Identifies the reasons for a given status.

... intent ?!SΣ1..1codeproposal | plan | order | original-order | reflex-order | filler-order | instance-order | option
Binding: medicationRequest Intent (required): The kind of medication order.

... category S0..*CodeableConceptType of medication usage
Binding: medicationRequest Category Codes (example): A coded concept identifying the category of medication request. For example, where the medication is to be consumed or administered, or the type of medication treatment.


... priority SΣ0..1coderoutine | urgent | asap | stat
Binding: RequestPriority (required): Identifies the level of importance to be assigned to actioning the request.

... doNotPerform ?!SΣ0..1booleanTrue if request is prohibiting action
... reported[x] Σ0..1Reported rather than primary record
.... reportedBooleanboolean
.... reportedReferenceReference(Patient | Practitioner | PractitionerRole | RelatedPerson | Organization)
... medication[x] SΣ1..1CodeableConceptMedication to be taken
Binding: SNOMEDCTMedicationCodes (example): A coded concept identifying substance or product that can be ordered.

... subject SΣ1..1Reference(CPGPatient)Who or group medication request is for
... encounter S0..1Reference(CPGEncounter)Encounter created as part of encounter/admission/stay
... supportingInformation S0..*Reference(Resource)Pertinent information
... authoredOn Σ0..1dateTimeWhen request was initially authored
... requester Σ0..1Reference(Practitioner | PractitionerRole | Organization | Patient | RelatedPerson | Device)Who/What requested the Request
... performer 0..1Reference(Practitioner | PractitionerRole | Organization | Patient | Device | RelatedPerson | CareTeam)Intended performer of administration
... performerType Σ0..1CodeableConceptDesired kind of performer of the medication administration
Binding: ProcedurePerformerRoleCodes (example): Identifies the type of individual that is desired to administer the medication.

... recorder 0..1Reference(Practitioner | PractitionerRole)Person who entered the request
... reasonCode 0..*CodeableConceptReason or indication for ordering or not ordering the medication
Binding: Condition/Problem/DiagnosisCodes (example): A coded concept indicating why the medication was ordered.


... reasonReference 0..*Reference(Condition | Observation)Condition or observation that supports why the prescription is being written
... instantiatesCanonical SΣ0..*canonical()Source
... instantiatesUri Σ0..*uriInstantiates external protocol or definition
... basedOn Σ0..*Reference(CarePlan | MedicationRequest | ServiceRequest | ImmunizationRecommendation)What request fulfills
... groupIdentifier Σ0..1IdentifierComposite request this is part of
... courseOfTherapyType 0..1CodeableConceptOverall pattern of medication administration
Binding: medicationRequest Course of Therapy Codes (example): Identifies the overall pattern of medication administratio.

... insurance 0..*Reference(Coverage | ClaimResponse)Associated insurance coverage
... note 0..*AnnotationInformation about the prescription
... dosageInstruction S1..1DosageHow the medication should be taken
.... id 0..1stringUnique id for inter-element referencing
.... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... sequence Σ0..1integerThe order of the dosage instructions
.... text Σ0..1stringFree text dosage instructions e.g. SIG
.... additionalInstruction Σ0..*CodeableConceptSupplemental instruction or warnings to the patient - e.g. "with meals", "may cause drowsiness"
Binding: SNOMEDCTAdditionalDosageInstructions (example): A coded concept identifying additional instructions such as "take with water" or "avoid operating heavy machinery".


.... patientInstruction Σ0..1stringPatient or consumer oriented instructions
.... timing SΣ1..1TimingWhen medication should be administered
..... id 0..1stringUnique id for inter-element referencing
..... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
..... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
..... event Σ0..*dateTimeWhen the event occurs
..... repeat SΣC1..1ElementWhen the event is to occur
tim-1: if there's a duration, there needs to be duration units
tim-2: if there's a period, there needs to be period units
tim-4: duration SHALL be a non-negative value
tim-5: period SHALL be a non-negative value
tim-6: If there's a periodMax, there must be a period
tim-7: If there's a durationMax, there must be a duration
tim-8: If there's a countMax, there must be a count
tim-9: If there's an offset, there must be a when (and not C, CM, CD, CV)
tim-10: If there's a timeOfDay, there cannot be a when, or vice versa
...... id 0..1stringUnique id for inter-element referencing
...... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
...... bounds[x] Σ0..1Length/Range of lengths, or (Start and/or end) limits
....... boundsDurationDuration
....... boundsRangeRange
....... boundsPeriodPeriod
...... count Σ0..1positiveIntNumber of times to repeat
...... countMax Σ0..1positiveIntMaximum number of times to repeat
...... duration Σ0..1decimalHow long when it happens
...... durationMax Σ0..1decimalHow long when it happens (Max)
...... durationUnit Σ0..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
Binding: UnitsOfTime (required): A unit of time (units from UCUM).

...... frequency SΣ1..1positiveIntEvent occurs frequency times per period
...... frequencyMax Σ0..1positiveIntEvent occurs up to frequencyMax times per period
...... period SΣ1..1decimalEvent occurs frequency times per period
...... periodMax Σ0..1decimalUpper limit of period (3-4 hours)
...... periodUnit SΣ1..1codes | min | h | d | wk | mo | a - unit of time (UCUM)
Binding: UnitsOfTime (required): A unit of time (units from UCUM).

...... dayOfWeek Σ0..*codemon | tue | wed | thu | fri | sat | sun
Binding: DaysOfWeek (required)
...... timeOfDay Σ0..*timeTime of day for action
...... when Σ0..*codeCode for time period of occurrence
Binding: EventTiming (required): Real world event relating to the schedule.


...... offset Σ0..1unsignedIntMinutes from event (before or after)
..... code Σ0..1CodeableConceptBID | TID | QID | AM | PM | QD | QOD | +
Binding: TimingAbbreviation (preferred): Code for a known / defined timing pattern.

.... asNeeded[x] SΣ0..1booleanTake "as needed" (for x)
.... site Σ0..1CodeableConceptBody site to administer to
Binding: SNOMEDCTAnatomicalStructureForAdministrationSiteCodes (example): A coded concept describing the site location the medicine enters into or onto the body.

.... route Σ0..1CodeableConceptHow drug should enter body
Binding: SNOMEDCTRouteCodes (example): A coded concept describing the route or physiological path of administration of a therapeutic agent into or onto the body of a subject.

.... method Σ0..1CodeableConceptTechnique for administering medication
Binding: SNOMEDCTAdministrationMethodCodes (example): A coded concept describing the technique by which the medicine is administered.

.... doseAndRate Σ0..*ElementAmount of medication administered
..... id 0..1stringUnique id for inter-element referencing
..... extension 0..*ExtensionAdditional content defined by implementations
Slice: Unordered, Open by value:url
..... type Σ0..1CodeableConceptThe kind of dose or rate specified
Binding: DoseAndRateType (example): The kind of dose or rate specified.

..... dose[x] Σ0..1Amount of medication per dose
...... doseRangeRange
...... doseQuantityQuantity(SimpleQuantity)
..... rate[x] Σ0..1Amount of medication per unit of time
...... rateRatioRatio
...... rateRangeRange
...... rateQuantityQuantity(SimpleQuantity)
.... maxDosePerPeriod Σ0..1RatioUpper limit on medication per unit of time
.... maxDosePerAdministration Σ0..1SimpleQuantityUpper limit on medication per administration
.... maxDosePerLifetime Σ0..1SimpleQuantityUpper limit on medication per lifetime of the patient
... dispenseRequest 0..1BackboneElementMedication supply authorization
.... id 0..1stringUnique id for inter-element referencing
.... extension 0..*ExtensionAdditional content defined by implementations
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... initialFill 0..1BackboneElementFirst fill details
..... id 0..1stringUnique id for inter-element referencing
..... extension 0..*ExtensionAdditional content defined by implementations
..... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
..... quantity 0..1SimpleQuantityFirst fill quantity
..... duration 0..1DurationFirst fill duration
.... dispenseInterval 0..1DurationMinimum period of time between dispenses
.... validityPeriod 0..1PeriodTime period supply is authorized for
.... numberOfRepeatsAllowed 0..1unsignedIntNumber of refills authorized
.... quantity 0..1SimpleQuantityAmount of medication to supply per dispense
.... expectedSupplyDuration 0..1DurationNumber of days supply per dispense
.... performer 0..1Reference(Organization)Intended dispenser
... substitution 0..1BackboneElementAny restrictions on medication substitution
.... id 0..1stringUnique id for inter-element referencing
.... extension 0..*ExtensionAdditional content defined by implementations
.... modifierExtension ?!Σ0..*ExtensionExtensions that cannot be ignored even if unrecognized
.... allowed[x] 1..1Whether substitution is allowed or not
Binding: ActSubstanceAdminSubstitutionCode (example): Identifies the type of substitution allowed.

..... allowedBooleanboolean
..... allowedCodeableConceptCodeableConcept
.... reason 0..1CodeableConceptWhy should (not) substitution be made
Binding: SubstanceAdminSubstitutionReason (example): A coded concept describing the reason that a different medication should (or should not) be substituted from what was prescribed.

... priorPrescription 0..1Reference(MedicationRequest)An order/prescription that is being replaced
... detectedIssue 0..*Reference(DetectedIssue)Clinical Issue with action
... eventHistory 0..*Reference(Provenance)A list of events of interest in the lifecycle

doco Documentation for this format

Terminology Bindings

PathConformanceValueSetURI
MedicationRequest.languagepreferredCommonLanguages
Additional Bindings Purpose
AllLanguages Max Binding
http://hl7.org/fhir/ValueSet/languages
from the FHIR Standard
MedicationRequest.statusrequiredmedicationrequest Status
http://hl7.org/fhir/ValueSet/medicationrequest-status|4.0.1
from the FHIR Standard
MedicationRequest.statusReasonexamplemedicationRequest Status Reason Codes
http://hl7.org/fhir/ValueSet/medicationrequest-status-reason
from the FHIR Standard
MedicationRequest.intentrequiredmedicationRequest Intent
http://hl7.org/fhir/ValueSet/medicationrequest-intent|4.0.1
from the FHIR Standard
MedicationRequest.categoryexamplemedicationRequest Category Codes
http://hl7.org/fhir/ValueSet/medicationrequest-category
from the FHIR Standard
MedicationRequest.priorityrequiredRequestPriority
http://hl7.org/fhir/ValueSet/request-priority|4.0.1
from the FHIR Standard
MedicationRequest.medication[x]exampleSNOMEDCTMedicationCodes
http://hl7.org/fhir/ValueSet/medication-codes
from the FHIR Standard
MedicationRequest.performerTypeexampleProcedurePerformerRoleCodes
http://hl7.org/fhir/ValueSet/performer-role
from the FHIR Standard
MedicationRequest.reasonCodeexampleCondition/Problem/DiagnosisCodes
http://hl7.org/fhir/ValueSet/condition-code
from the FHIR Standard
MedicationRequest.courseOfTherapyTypeexamplemedicationRequest Course of Therapy Codes
http://hl7.org/fhir/ValueSet/medicationrequest-course-of-therapy
from the FHIR Standard
MedicationRequest.dosageInstruction.additionalInstructionexampleSNOMEDCTAdditionalDosageInstructions
http://hl7.org/fhir/ValueSet/additional-instruction-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.durationUnitrequiredUnitsOfTime
http://hl7.org/fhir/ValueSet/units-of-time|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.periodUnitrequiredUnitsOfTime
http://hl7.org/fhir/ValueSet/units-of-time|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.dayOfWeekrequiredDaysOfWeek
http://hl7.org/fhir/ValueSet/days-of-week|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.repeat.whenrequiredEventTiming
http://hl7.org/fhir/ValueSet/event-timing|4.0.1
from the FHIR Standard
MedicationRequest.dosageInstruction.timing.codepreferredTimingAbbreviation
http://hl7.org/fhir/ValueSet/timing-abbreviation
from the FHIR Standard
MedicationRequest.dosageInstruction.siteexampleSNOMEDCTAnatomicalStructureForAdministrationSiteCodes
http://hl7.org/fhir/ValueSet/approach-site-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.routeexampleSNOMEDCTRouteCodes
http://hl7.org/fhir/ValueSet/route-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.methodexampleSNOMEDCTAdministrationMethodCodes
http://hl7.org/fhir/ValueSet/administration-method-codes
from the FHIR Standard
MedicationRequest.dosageInstruction.doseAndRate.typeexampleDoseAndRateType
http://hl7.org/fhir/ValueSet/dose-rate-type
from the FHIR Standard
MedicationRequest.substitution.allowed[x]exampleActSubstanceAdminSubstitutionCode
http://terminology.hl7.org/ValueSet/v3-ActSubstanceAdminSubstitutionCode
MedicationRequest.substitution.reasonexampleSubstanceAdminSubstitutionReason
http://terminology.hl7.org/ValueSet/v3-SubstanceAdminSubstitutionReason

Constraints

IdGradePath(s)DetailsRequirements
dom-2errorMedicationRequestIf the resource is contained in another resource, it SHALL NOT contain nested Resources
: contained.contained.empty()
dom-3errorMedicationRequestIf the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
dom-4errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
dom-5errorMedicationRequestIf a resource is contained in another resource, it SHALL NOT have a security label
: contained.meta.security.empty()
dom-6best practiceMedicationRequestA resource should have narrative for robust management
: text.`div`.exists()
ele-1error**ALL** elementsAll FHIR elements must have a @value or children
: hasValue() or (children().count() > id.count())
ext-1error**ALL** extensionsMust have either extensions or value[x], not both
: extension.exists() != value.exists()
tim-1errorMedicationRequest.dosageInstruction.timing.repeatif there's a duration, there needs to be duration units
: duration.empty() or durationUnit.exists()
tim-2errorMedicationRequest.dosageInstruction.timing.repeatif there's a period, there needs to be period units
: period.empty() or periodUnit.exists()
tim-4errorMedicationRequest.dosageInstruction.timing.repeatduration SHALL be a non-negative value
: duration.exists() implies duration >= 0
tim-5errorMedicationRequest.dosageInstruction.timing.repeatperiod SHALL be a non-negative value
: period.exists() implies period >= 0
tim-6errorMedicationRequest.dosageInstruction.timing.repeatIf there's a periodMax, there must be a period
: periodMax.empty() or period.exists()
tim-7errorMedicationRequest.dosageInstruction.timing.repeatIf there's a durationMax, there must be a duration
: durationMax.empty() or duration.exists()
tim-8errorMedicationRequest.dosageInstruction.timing.repeatIf there's a countMax, there must be a count
: countMax.empty() or count.exists()
tim-9errorMedicationRequest.dosageInstruction.timing.repeatIf there's an offset, there must be a when (and not C, CM, CD, CV)
: offset.empty() or (when.exists() and ((when in ('C' | 'CM' | 'CD' | 'CV')).not()))
tim-10errorMedicationRequest.dosageInstruction.timing.repeatIf there's a timeOfDay, there cannot be a when, or vice versa
: timeOfDay.empty() or when.empty()

This structure is derived from CPGMedicationRequest

Summary

Mandatory: 7 elements
Must-Support: 8 elements

 

Other representations of profile: CSV, Excel, Schematron