Clinical Test Data Medications Guidance - nhsconnect/gpc-consumer-support GitHub Wiki

We've worked with consumers previously to help them understand the data they receive from the GP Connect API. This has enabled them to process the data and display it to their users in a clinically safe way (complying with clinical safety standards: SCCI0160 and SCCI0129).

We've answered some common questions in the pages below.

Notes:

  • These pages contain examples of how the data may be presented. Hopefully, you'll find them useful, but bear in mind they are only suggestions - the way your users need to see the data may be different from that shown here.
  • Both the consumer test data spreadsheet and hazard log are referred to in these pages.

Contents

Building a user interface

Using search and filters

Understanding the medication prescribing and dispensing process

Handling different types of medication, terminology, and device

Handling stopped medications and allergies

Building a user interface

Mock up of medical record

The image above shows one way that medications retrieved from GP Connect may be represented to your users.

It's split into 4 different sections so the user/clinician who is interpreting the data can easily find the data they need. It also allows for the detail about each medication to be different depending on the heading it is under, which makes it possible to provide more relevant information to the clinician - for example, the discontinued repeats contains fields for when the medication was stopped and why it was stopped.

For repeats, it is possible to see when the drug was last issued and how many times it has been issued but does not clutter the screen with details of every repeat issue.

Which fields do I need to display to my users?

In the majority of circumstances, the fields displayed on the diagram above would be obligatory when displaying medication data (with the possible exception of prescriber).

The fields you need to display to your users will depend on the use case that your product has been built for. Ultimately it should be the clinicians/users of the application who dictate what it is they need. However, to do this they must first understand what is available.

The GP Connect specification describes the process of prescribing in primary care and is a good place to start, as well as offering further guidance and details of the data available in each of the resources.

When working with your users to build your application some things to consider are:

  • how can you make the information concise and easy to navigate?
  • what are the key things your users need to know?
    • how recently a medication was issued
    • whether a medication was stopped due to an allergy
    • what is an appropriate time frame for the information to cover?
  • what level of detail do your users need?
  • will the application have different use cases that need different views of the data?

The better you understand how the application will be used, the more appropriate your design can be. The diagram above is one example of how medications data may be displayed and would be appropriate for a use case such as out of hours (OOH) care or for a clinician in secondary care to see what medications a patient is taking.

GP Connect FHIR® elements

All elements in Medication, Medication Statement and Medication Request.

GP Connect test data examples

All the items in the 2 medications records should be used to develop a user interface to ensure all variations of data produced by GP Connect are accommodated and displayed to the user where necessary.

Associated hazards

Hazards 11, 51, 52

Back to top

If I need to display the prescription type what types are there?

There are 4 different types of prescription:

  • Acute
  • Delayed prescribing (a different type of acute)
  • Repeat
  • Repeat dispensing

The diagram above is an example of how these might be displayed. In the view presented above, the 2 acute types are grouped together.

Any stopped repeat or repeat dispense drugs are separated out so the date and reason they were stopped is easily visible.

There are many options for displaying the data and it will come down to what is best for your users.

GP Connect FHIR® elements

MedicationRequest.extension[prescribingAgency]

GP Connect test data items

All the items in the 2 medications test records are relevant to how to categorise medications.

Related hazards

Hazards 11, 51, 52

Back to top

Using search and filters

How does the date filter work?

Medications can be requested for a given period - for example, a date in the past until today's date or, alternatively, all medications can be requested regardless of date. If a date range is required, the medicationSearchFromDate field is used to identify the start date of the requested medication's search period. An end date cannot be requested so that all searches go to the end of the patient’s record. This ensures that all current and future medications are returned and are not missed for all searches carried out.

The rules for restricting medications returned on or after the date specified are:

  • if the medicationSearchFromDate is not specified, all medications will be returned
  • if the medicationSearchFromDate is populated, all medications which are active on or after the medicationSearchFromDate MUST be returned
  • medicationSearchFromDate MUST be populated with a date less than or equal to the current date
  • medicationSearchFromDate MUST be populated with whole dates only (for example, 2017-02-01) - that is, no partial dates, or with a time period or offset

GP Connect FHIR® elements

When the medicationSearchFromDate parameter is set:

  • all medications which are active on or after the medicationSearchFromDate MUST be returned
    • a medication is considered active between its effective.start and effective.end (inclusive)
      • when a medication does not have an effective.end:
        • an acute medication is considered active on its effective.start only
        • a repeat medication is considered on-going and is active from its effective.start
        • when a medication is not defined as an acute or repeat it MUST be treated as repeat

GP Connect test data examples

Generic data visual example:

The scenario below represents how a selection of acute and repeat medications is returned based on the search date in the request. Medications that have been greyed out are not returned in the response because the associated end date is prior to the medicationSearchFromDate, which in this example is 01/03/2018.

Test data example (provided test data):

Below shows the expected results from the above test data. However, note that the demonstrator may not support all searches.

Associated hazards

None identified

Back to top

How do I know what the patient's current meds are?

In primary care, there is no consistent definition of what medications are current. Each of the GP system suppliers defines it slightly differently and in some clinical systems it is also configurable, so can vary from practice to practice that have the same system.

The GP Connect clinical team has suggested that medications that have had issues with an effective period spanning the last 12 months could be considered as the current medications. However, there are certain medications that may not have been issued in the last 12 months. There are also medications that are prescribed for the patient to have available - for example, adrenaline self-injectors that can have a shelf life of longer than 12 months. There is no easy way, therefore, to have every possible medication displayed without including excessive medications a patient is no longer taking.

This would take into account any medications that may have in theory reached the end of the course, but which the patient may still be taking. It is reasonable to assume that if a medication has not been issued in over 6 months then it is no longer current.

GP Connect FHIR® elements

Medication Request

GP Connect test data examples

  • Clarithromycin 250mg tablets
  • Salbutamol 100micrograms/dose inhaler CFC free
  • Timolol 0.25% eye drops
  • Omeprazole 20mg gastro-resistant capsules

Associated hazards

Hazards 55 and 84

Back to top

Understand the medication prescribing and dispensing process

How do I find out if a patient has been prescribed a certain medication?

Any check for medication history should include discussion with the patient and reference to as many information sources as possible. Whilst accessing the registered GP's full patient medication history via GP Connect is likely to provide the most complete source of medication details available, it may still be incomplete.

When viewing or applying data searches to a patient medication history to search for a particular medication, the consuming system should be aware of the naming conventions used for medications via GP Connect. GP Connect may use any of the dm+d (the NHS standard drug dictionary - see the dm+d description guidance for more detail) formats with SNOMED CT or other coding. Currently, medications are most commonly in a VMP or AMP form, but other forms are possible. Medications will occasionally be shared uncoded as text only.

GP Connect FHIR® elements

The medication or medical device is identified in the following element

The medication resource is only used to identify the medication item. All other details of the medication are provided in the medicationStatement and medicationRequest resources which reference to the medication resource.

GP Connect test data examples

There are two items for aspirin with different coding and text

  • VMP: Aspirin 300mg gastro-resistant tablets
  • AMP: Nu-Seals 300 gastro-resistant tablets (Alliance Pharmaceuticals Ltd)

Other examples of AMP medication include

  • Cocois ointment (RPH Pharmaceuticals AB)
  • Priadel 200mg modified-release tablets (Essential Pharma M)

Text / transfer degraded medication

  • Magic Tincture

Associated hazards

7, 11, 37, 42, 85

Back to top

How can I tell whether the medication has been issued/was last issued?

It may be important to understand when the patient last received a prescription for a medication or to view the history of prescription issues for a medication. There may also be occasions where there is a medication prescription on a patient's record which has not been issued to the patient.

GP Connect offers a variety of means to see whether the medication has been issued, when it was last issued and gives details of each individual issue. Where the last issue date is present it indicates that the medication has been issued at least once. The last issue date will be absent when the medication has not been issued by the GP. Consumers should note that medications recorded as 'prescribed by another organisation' will not include a last issued date but may have been issued and taken by the patient. Care should also be taken with repeat dispense medication where the GP will issue the full course of medication and the last issue date therefore relates to the first issue / issue of the full course.

A repeat medication course includes a count of how many prescriptions have been issued for the course to date (for the current authorisation). The absence of this count is another indicator that a medication may not have been issued to the patient.

GP Connect also includes all individual prescription issues by default. Sorting through these can also identify a last issue date for a medication but the consumer must also be aware that

  • prescription issues are not included for medications 'prescribed by another organisation'
  • prescription issues for repeat dispense are estimated, calculated from the initial issue

GP Connect FHIR® elements

The last issue date is extension in the medicationStatement

The number of issues for a repeat medication course is an extension of the medicationRequest

Each individual prescription issue is in a medicationRequest with intent = order

GP Connect test data examples

The following items are examples of unissued medications

  • Lansoprazole 15mg orodispersible tablets
  • Amoxicillin 500mg capsules

The following items are examples of issued repeat and repeat dispense medications, with multiple issue records

  • Furosemide 40mg tablets
  • Contour TS testing strips (Ascensia Diabetes Care UK Ltd)

Associated hazards

7, 11, 37, 42, 85

Back to top

How do I know if the medication was being managed by an organisation other than the GP practice?

Sometimes GPs need to record information about medication that was prescribed elsewhere, for example by a hospital or bought over the counter in a pharmacy. These types of records are highlighted in GP Connect using the prescribingAgency extension to the MedicationStatement resource. Depending on your use case it may be necessary to indicate the origin of these medications to the end-user of your system.

Unissued medications/medical devices and medications/medical devices that have been prescribed elsewhere are different concepts but modelled in a similar manner. They will both have been added to the system by a clinician at the practice and will be represented by a MedicationStatement and a MedicationRequest with an intent of plan, but with no further resources. This reflects that no orders have been placed for these medications/medical devices by the GP practice. Medications/medical devices that were prescribed elsewhere will be flagged as such by populating the PrescribingAgency extension in the Medication Statement.

For the purpose of decision support interaction-checking, these medications need to be considered.

GP Connect FHIR® elements

MedicationStatement.extension[prescribingAgency]

GP Connect test data examples

Co-codamol 15mg/500mg tablets

Associated hazards

37, 38, 45, 86

Back to top

How do I know if the patient's dosage has changed over time?

Changes in medication dosage may be necessary as a result of monitoring a patient’s condition. The information of a change in the dosage may be key to understanding changes in test results or other aspects of a patient’s condition or the clinician may want to check that the medication has been changed in response to such circumstances.

The latest prescription of the medication may not be the only one, so it may be necessary to trace back through a number of instances to see the full history.

GP Connect specifies that each prescription record should relate to a single dosage instruction. Where a provider cannot support this and a prescription has changed in dosage throughout the full course, then the provider must include a warning message and date the dosage last changed (although there could be more than one change). GP Connect includes all issues of a repeat medication by default so that the consumer can inspect all those issues for changes over time.

GP Connect will link all prescription records from the provider with the same medication item (where that medication is identical across repeat courses) so they can easily be sorted and displayed if required. GP Connect may also include a reference to a prior prescription where there has been a re-authorisation enabling a chain of prescriptions to be traced back. However, where the form or the strength of the medication has changed then GP Connect will present them as separate plans.

GP Connect FHIR® elements

Data items where dosage changes within a repeat course (no re-authorisation)

NB The equivalent dosage information in medicationRequest does not include the change warning

Differences may occur across resources instances for the following elements

Identification of a re-authorised prescription (for any reason not just dosage changes)

GP Connect test data examples

The following medication record has a change of dosage information within a repeat course

  • Clarithromycin 250mg tablets

The following medication records have a change across repeat courses and include a prior prescription reference

  • Omeprazole 20mg gastro-resistant capsules

Associated hazards

Back to top

How do I know if the patient's medication item has changed over time?

The medication item may be changed for example changes in medication strength or changes between generic and trade. Being able to recognise these changes may be key to understanding how long a medication has been taken by the patient and how that medication has changed over time.

Generally, separate prescription for equivalent but different medication items will not be linked in any way in the message. The medication item will be coded and the consumer could use that information to identify similar or equivalent medications. In some cases, where the prescription has been directly changed from one medication to another such as a generic / trade switch, there may be a direct reference to the previous prescription thereby enabling the records to be linked.

GP Connect FHIR® elements

The medication resource is referenced from the following elements from which the medication item code can be utilised

Identification of a linked prior prescription (for any reason not just generic / trade switch)

GP Connect test data examples

Linked records for a generic / trade switch

  • Aspirin 300mg gastro-resistant tablets
  • Nu-Seals 300 gastro-resistant tablets (Alliance Pharmaceuticals Ltd)

Separate (not linked) prescriptions for different strengths of the same medication

  • Atorvastatin 20mg tablets
  • Atorvastatin 30mg tablets

Associated hazards

Back to top

How do I know if the medication was dispensed/taken?

At present, there is no way to determine whether a medication has been dispensed or taken. Once the medication has been prescribed by the GP, it is up to the patient to decide whether to get the medication and take it. As there is no link between the dispensing system and the GP System, it is not possible to determine whether medication has been dispensed or taken.

Back to top

How are repeat-dispense medications represented?

A repeat dispensed medication is for when a patient is expected to be on a medication for a prolonged period and is unlikely to be changed. In these circumstances, the clinician will have pre-authorised a set of prescriptions which can be obtained from a pharmacy without further interaction with the GP practice.

When a medication or medical device is repeat-dispensed the patient will be able to pick up the item from the pharmacy without the need for each prescription to be issued by the GP practice. Apart from the practice not needing to issue each prescription, repeat-dispensing works in a similar manner to repeat prescriptions where the doctor is able to determine the number of issues or the time period before needing to visit the doctor again for the prescription to be re-authorised.

Overview of how GP Connect supports this

Both repeat prescriptions and repeat dispenses are represented in a similar manner to the acute prescriptions.

The difference is that there is now a one-to-many relationship where there can be one MedicationRequest with an intent of plan and it can relate to many MedicationRequest resources that have an intent of order. In this relationship, every time a repeat has been issued it will be represented by a separate MedicationRequest with an intent of order.

For repeat dispensed medication or medical device, some of the resources relating to individual issues may be post-dated if the effective period of the medication or medical device has not elapsed. However, for all MedicationRequest resources with an intent of order the authoredOn date SHOULD be the same as the related MedicationRequest with intent of plan.

GP Connect FHIR® elements

extension[prescriptionType]

Data type: extension (CodeableConcept) Optionality: Mandatory Cardinality

GP Connect test data examples

  • Cocois ointment (RPH Pharmaceuticals AB)
  • Contour TS testing strips (Ascensia Diabetes Care UK Ltd)

Associated hazards

87

Back to top

How should I interpret information about repeat courses?

Mock up of medical record

The diagram above splits the different methods of prescribing repeat medication into repeat, repeat dispensed and discontinued repeat drugs.

The example shows a summary of each course of the repeat drug without containing all the details about every issue. Splitting the types up will make it easier for clinicians to understand more easily what has been prescribed and dispensed. It also clearly displays when the medication was last issued so it is obvious when the patient was last given a prescription by their GP practice.

Depending on the use case, it may also be helpful for a clinician to see the details of the issues of each repeat drug. One way to display this may be to click through on a single medication to a list of all the issues which may be displayed using similar fields to the ‘Acute’ table above.

GP Connect FHIR® elements

MedicationRequest.extension[prescriptionType]

GP Connect test data examples

There are numerous repeat medication items in the medications test data record and all should be used to ensure repeat and repeat dispenses are communicated appropriately.

Associated hazards

Hazards 55, 84, 85 and 87

Back to top

Handle different types of medication, terminology, and device

How should I process medications that are not SNOMED coded?

Some data that is returned by GP Connect may not be SNOMED coded. Details about the variations in coding and how to process them are available in the Populating the codable concept document.

Data that is received may be coded in another terminology or coded as a degraded item that contains a textual representation of the medication. Other examples of alternative terminologies to SNOMED are Read2 or multilex. A medication may not contain a code and only have the code.text field populated or may be populated with a record degrade code.

Processing a code other than SNOMED

Where an item has been coded in a GP system using a code other than SNOMED and there is no translation, then you will receive a coding element with a different system entry.

If the ‘system’ represents a terminology that the consuming system understands, then it can process the code.

If the consuming system does not understand the terminology, then it can use the relevant SNOMED degrade code. In this case, it would be:

196421000000109    Transfer-degraded medication entry 

It MUST then take the display element from the example below and store that with the degrade code to the user:

Display element

If this information is then propagated on via export the consuming system MUST export it as a SNOMED degrade code with the code.text element containing the ‘display’, which is what the clinician that entered the data at the GP practice would have seen at the time.

The above EMIS code would look like the example below if de-graded and then re-exported.

Degrade example

Processing a translation set

In some cases, there may be more than one code in a codeable concept. In the example below, there is an EMIS drug code that has a SNOMED translation that will be part of dm+d:

EMIS drug code

When processing the above, a consuming system should process the SNOMED code.

If the coding.display elements are not lexicaly identical then in order to preserve the originally input text this must be processed as follows,

  • Identify the originally entered coding element using the coding.userSelected element which is set to 'TRUE'
  • Select the coding.display element from this instance of coding
  • This string of text MUST be displayed to the user of the consumer application.
  • If the data may be exported at a later time this text MUST be stored and exported in the code.text field.

This preserves the text originally entered by the clinician at the GP practice.

Processing a degrade

Where a code has been exported using a degrade code the consuming system MUST display the string from the code.text field to the user so they are able to see what the clinician had originally recorded. If the data may be exported at a later time this MUST be stored and exported in the code.text field. This preserves the text originally entered by the clinician at the GP practice.

Preserved_text

GP Connect FHIR® elements

AllergyIntolerance.code

Medication.code

GP Connect test data items

  • Loratadine 5mg/5ml oral solution / LORATADINE syrp 5mg/5ml (translation)
  • Magic Tincture (degrade)

Related hazards

Hazard 2

Back to top

How is dosage represented in GP Connect?

Dosage information is always included as a text string. GP systems don't hold dosage data in a structured format. The dosage text reflects how the information is presented in the GP systems. GP Connect allows providers to return the dosage in a structured format in addition to the text as soon as it is fully supported by the source GP systems following the standards defined by the Digital Medicines programme.

Systems receiving information from GP Connect and wishing to process or store medication information will need to consider how this aligns with its own medication recording and whether user actions will be required to translate the dosage in its required format.

GP Connect FHIR® elements

GP Connect test data examples

This applies to all test data items.

Related hazards

Back to top

How are medical devices treated in GP Connect?

Medical devices are treated in the same way as any other medication in GP Connect. The vast majority will be dm+d coded and they can be any type of prescription acute, repeat, etc. They can be discontinued or unissued and behave identically to any other medication in GP Connect.

GP Connect FHIR® elements

Medication.code

GP Connect test data examples

  • Adjustable ostomy belt NSI 23 25mm (A H Shaw and Partners Ltd)

Related hazards

Back to top

Handling stopped medications

How should I handle stopped (actively discontinued) medication?

Medications which have been stopped or discontinued may provide significant information which may influence prescribing decisions. All GP systems capture a date and a reason when medications are stopped. A stopped or discontinued medication may provide details of adverse reactions to a medication although full details of allergies or adverse reaction are only available in the allergies and adverse reactions resource (further information below). It may also indicate another reason that a medication was stopped, for example, that a medication was ineffective. It is important that the consuming system can highlight stopped or discontinued medications where this is significant to its users.

GP Connect requires providers to return a 'stopped' status for all medications where a medication/medical device is stopped or discontinued and include a textual stop reason. This status is to be used in all circumstances when the medication is stopped prior to the intended course completion not just for adverse circumstances as described above.

GP Connect FHIR® elements

The stopped status is found in the following status elements

The reason the medication was stopped or discontinued is found in the following element

The reason may be text or coded.

GP Connect test data examples

There are several test records with a stopped status which represent different circumstances and element population.

Some examples are:

  • Prednisolone 5mg gastro-resistant tablets
  • Rosuvastatin 20mg tablets
  • Fluoxetine 20mg capsules

Associated hazards

55

Back to top

How do I know if the patient is allergic to the medication?

To know what allergies a patient has the user/system must request the allergies from GP Connect.

It may not be possible to add all allergies received by GP Connect to the sending system in the format they arrive. Thought needs to be given to how these degraded items are presented to clinicians. It may be possible to use these degraded items to trigger decision support in the consuming system, for instance preventing prescribing until they have been dealt with.

If a medication has been stopped by the GP then the reason and the date it was stopped will be available in the data model. The status of the medication will be set to stopped and the statusReason extension will be populated with the date and reason.

Although the reason may sometimes be due to an allergy, in order to see all a patient's allergies these should be requested separately from the medications.

GP Connect FHIR® elements

GP Connect test data examples

All the items in the GP Connect allergies record.

Associated hazards

Hazards 2, 7

Back to top

Quick links