Guidance for populating and consuming the MedicationRequest profile

Introduction

The headings below list the elements of the MedicationRequest profile and describe how to populate and consume them.

Overarching principles

When populating the MedicationRequest profile it may appear that fields are duplicated in other associated resources. In the interests of minimising redundancy, the 2 following principles MUST be applied when populating the MedicationRequest profiles:

  1. All mandatory fields MUST be populated.

  2. Required fields MUST always be populated where the data exists in the system apart from where a lexically identical value exists for an equivalent data item in one of the parent profiles. For a MedicationRequest with intent of plan the associated MedicationStatement would be the parent profile. For a MedicationRequest with intent of order, the associated MedicationStatement and MedicationRequest with intent of plan are both considered parent profiles.

MedicationRequest elements

id

Data type: Id Optionality: Mandatory Cardinality: 1..1

The logical identifier of the MedicationRequest profile.

meta.profile

Data type: uri Optionality: Mandatory Cardinality: 1..1

The MedicationRequest profile URL.

Fixed value https://fhir.nhs.uk/STU3/StructureDefinition/CareConnect-GPC-MedicationRequest-1

extension[repeatInformation]

Data type: Extension Optionality: Required Cardinality: 0..1

Extension elements to hold details of repeat authorisation.

Only populate for a MedicationRequest with an intent = plan. For a MedicationRequest with an intent = order none of the repeatInformation fields are populated.

extension[repeatInformation].numberOfRepeatPrescriptionsAllowed

Data type: UnsignedInt Optionality: Required Cardinality: 0..1

The number of repeat issues authorised if specified.

MUST be present where a repeat is authorised for a defined number of issues.

MUST NOT be specified for acute prescriptions or where the number of repeat issues has not been defined. There is no concept of an initial dispense in GP Connect usage. Therefore, the numberOfRepeats allowed is the total number of allowed issues.

extension[repeatInformation].numberOfRepeatPrescriptionsIssued

Data type: UnsignedInt Optionality: Mandatory Cardinality: 1..1

Running total of number of issues made against a repeat authorisation.

MUST be zero, if not yet issued.

extension[repeatInformation].authorisationExpiryDate

Data type: dateTime Optionality: Required Cardinality: 0..1

The date a repeat prescription authorisation will expire.

Only populate for a MedicationRequest with an intent = plan. For a MedicationRequest with an intent = order this is not populated.

extension[statusReason]

Data type: extension (statusReason) Optionality: Required Cardinality: 0..1

Where a medication/medical device has been stopped (status == ‘stopped’), the reason is provided in the statusReason extension.

Mandatory for authorisations with stopped status.

Only populate for a MedicationRequest with an intent = plan. Do not populate for a MedicationRequest with an intent = order.

extension[statusReason].date

Data type: extension (valueDateTime) Optionality: Mandatory Cardinality: 1..1

The dateTime the medication/medical device was stopped/discontinued.

Mandatory for stopped/discontinued medications/medical devices as the date will always be known. In exceptional cases where for legacy data there is no statusReason recorder in the system then this MUST be populated with the text ‘No information available’.

extension[statusReason].reason

Data type: extension (CodeableConcept) Optionality: Required Cardinality: 0..1

The textual reason either free text or the term of a code for stopping/discontinuing the medication/medical device.

MUST be populated when StatusReason.date is populated.

extension[prescriptionType]

Data type: extension (CodeableConcept) Optionality: Mandatory Cardinality: 0..1

If a medication/medical device is an acute (code : acute), delayed acute (delayed-prescribing), repeat (repeat) or repeat dispense (repeat-dispensing).

This field provides an explicit repeat/acute flag rather than deriving it from presence of extension elements or repeatNumber.

In exceptional cases where for legacy data there is no prescriptionType recorded in the system then this MUST be populated with the text ‘No information available’.

identifier

Data type: Identifier Optionality: Mandatory Cardinality: 1..*

This MUST be populated with a globally unique and persistent identifier (that is, it doesn’t change between requests and therefore stored with the source data). This MUST be scoped by a provider specific namespace for the identifier.

Where consuming systems are integrating data from this resource to their local system, they MUST also persist this identifier at the same time.

If the EPS identifier is present then the identifier.value is where the EPS Id SHOULD also be added. The codeSystem for this identifier is https://fhir.nhs.uk/Id/prescription-order-item-number

basedOn

Data type: Reference(CarePlan, MedicationRequest, ProcedureRequest, ReferralRequest) Optionality: Required Cardinality: 0..*

This field is used to create the links between MedicationRequest profiles to represent the medication ordering process as described here. This MUST be used when a profile has an intent element that is set to order and is basedOn a MedicationRequest profile that has an intent set to plan.

DO NOT USE for authorisations - that is, for a MedicationRequest with intent of plan.

groupIdentifier

Data type: Identifier Optionality: Required Cardinality: 0..1

The EPS prescriptionID if this medication or medical device has been prescribed via the Electronic Prescriptions Service. The element in the Identifier data type that MUST be populated when a groupIdentifier is populated is identifier.value.

All EPS prescribed drugs MUST have the prescriptionID present in this field and have system element set to https://fhir.nhs.uk/Id/prescription-order-number.

status

Data type: Code Optionality: Mandatory Cardinality: 1..1

The status of the authorisation, where ‘intent’ is set to ‘plan’.

Use one of active, completed or stopped:

  • active represents an authorisation where all allowed orders have not been issued, for example an unissued acute or a repeat with outstanding issues.
  • stopped represents an authorisation which has been discontinued, cancelled or stopped.
  • completed represents an authorisation where all orders have been issued.

For MedicationRequest instances where intent is set to order:

  • The status MUST be set to completed unless the medication has been stopped by a clinician.
  • Stopped prescription MUST have a stopped status except where the system captures that the order has been stopped prior to dispense such that the patient cannot have received the medication where it SHOULD have a cancelled status

intent

Data type: Code Optionality: Mandatory Cardinality: 1..1

Used to distinguish between authorisations and issues.

Use one of plan or order:

  • plan represents an authorisation of a medication or medical device.
  • order represents a prescription or issue of a medication or medical device.

medication

Data type: Reference(Medication) Optionality: Mandatory Cardinality: 1..1

The medication/medical device the authorisation is for.

The Medication profile provides the coded representation of the medication/medical device.

subject

Data type: Reference(Patient) Optionality: Mandatory Cardinality: 1..1

Who the medication/medical device is for - that is, to whom it will be administered.

Reference to patient.

context

Data type: Reference(Encounter) Optionality: Required Cardinality: 0..1

The consultation when the medication/medical device was authorised.

For a MedicationRequest with an intent = plan this is the consultation where the plan was authorised. For a MedicationRequest with an intent = order this is the consultation where the specific issue was authorised.

authoredOn

Data type: dateTime Optionality: Mandatory Cardinality: 1..1

Authorisation date, when the medication/medical device was authorised.

Unless there is a distinct user-modifiable date and time for the authorisation, this is the audit trail dateTime for when the authorisation was entered.

requester

Data type: BackboneElement Optionality: Required Cardinality: 0..1

Person and their organization requesting authorisation for prescription.

May not always be the user who entered the record on the system but, where a system supports attribution to a responsible clinician, the attributed clinician MUST be referenced here.

If it was prescribed at another practice and has been imported via GP2GP. In that case, the onBehalfOf MUST be completed with a reference to the other organisation.

recorder

Data type: Reference(Practitioner) Optionality: Mandatory Cardinality: 1..1

The person who entered the record on the system.

note

Data type: Annotation Optionality: Required Cardinality: 0..*

All notes that are associated with this medication/medical device record.

Sometimes labelled Pharmacy text or instructions for pharmacy.

dosageInstruction

Data type: Dosage Optionality: Mandatory Cardinality: 1..1

The elements of the dosage datatype detailed below should be populated as described. All other elements that are part of the dosage datatype are optional.

dosageInstruction.text

Data type: String Optionality: Mandatory Cardinality: 1..1

Complete dosage instructions as text.

In exceptional cases where for legacy data, over-the-counter treatments or hospital treatments there is no dosage recorded in the system then this MUST be populated with the text ‘No information available’ or ‘Not recorded’ as most appropriate to the circumstance.

dosageInstruction.patientInstruction

Data type: String Optionality: Required Cardinality: 0..1

Additional instructions for patient - that is, RHS of prescription label.

dispenseRequest.validityPeriod

Data type: Period Optionality: Mandatory Cardinality: 1..1

Prescription start and end dates.

Start date is mandatory. Where there is a defined expiry or end date the end date MUST be supplied.

For MedicationRequest instances where intent is set to plan:

  • This refers to the period that the medication/medical device plan is active.
  • This MUST mirror MedicationStatement.effective

For MedicationRequest instances where intent is set to order:

  • This refers to the period that the issued prescription is active

Period.start is MANDATORY.

Use one of the following dates in order of descending preference:

  • The prescription issue date recorded in the patient record
  • The date the prescription was recorded.

Period.end is MANDATORY.

Use one of the following dates in order of descending preference:

  • The prescription end date recorded in the patient record
  • The prescription end date derived from period.start and the duration
  • The Period.start date
    • This option should only occur where data has been lost (for example, during the record transfer between two systems) and is used to ensure that an ended prescription will always have an end date.

dispenseRequest.quantity

Data type: SimpleQuantity Optionality: Required Cardinality: 0..1

The quantity to dispense.

If the value is text, then the extension dispenseRequest.quantityText MUST be used.

dispenseRequest.quantityText

Data type: String Optionality: Required Cardinality: 0..1

This field is used to contain the units relating to the quantity. For example, ‘tablet(s)’, ‘capsule(s)’ or ‘dose(s)’.

It may also be a textual representation of quantity. Only to be used in this way if there is no numerical value.

dispenseRequest.expectedSupplyDuration

Data type: Duration Optionality: Required Cardinality: 0..1

Number of days’ supply per dispense.

dispenseRequest.performer

Data type: Reference(Organization) Optionality: Required Cardinality: 0..1

The organisation that dispensed the issue. Can only be completed where the provider organisation knows explicitly which organisation dispensed the issue. It cannot be assumed to be the nominated pharmacy or appliance supplier.

Only populate for a medicationRequest with an intent = order. For a medicationRequest with an intent = plan this field is not populated.

priorPrescription

Data type: Reference(MedicationRequest) Optionality: Optional Cardinality: 0..1

References prior prescription authorisation.

May be used, for example, to reference prior authorisation where prescription is re-authorised or where amendments have been made. May reference the previous authorisation before the amendment.

MedicationRequest elements not in use

The following elements MUST NOT be populated:

meta.versionId

Data type: Id

meta.lastUpdated

Data type: Instant

definition

Data type: Reference(ActivityDefinition, PlanDefinition)

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.

category

Data type: CodeableConcept

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.

priority

Data type: code

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.

supportingInformation

Data type: Reference(Any)

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.

reasonCode

Data type: CodeableConcept

This information is available via linking to a Problem record.

reasonReference

Data type: Reference(Condition), Reference(Observation)

This information is available via linking to a Problem record.

substitution

Data type: BackboneElement

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.

detectedIssue

Data type: Reference(DetectedIssue)

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.

eventHistory

Data type: Reference(Provenance)

This is not in scope for this version of Care Connect and therefore not available for use in GP Connect.