Skip to main content
Skip table of contents

List Prescription Requests

Overview

This endpoint allows a PFS Consumer app to list all of the patient’s prescription requests.

A prescription request is a prescription or a prescription issue that has previously been requested by the patient (via the PFS Consumer app). Patient apps can use the Prescription Request ID retrieved from this endpoint to make a Cancel Prescription request (See the ‘Cancel Prescription Request’ endpoint).

Elements Marked as “Hidden From Patient Services”

Any Prescription that is marked as being 'Hidden from patient-facing services' in the Medicus staff app will not be returned by the endpoint.

Making a Request

HTTP method: GET

Endpoint URL: https://{{medicusTenant}}.{{medicusBaseURL}}/pfs-api/v1/patient/{{patientId}}/prescription-requests

Request Headers

Header

Value

Description

Authorization

Bearer [token]

The JWT token provided by the Consumer

URL Parameters

Parameter

Description

Validation Rules

patientId

Patient ID

e.g. e9af860e-cf8e-4272-b81a-a95cc8a531f7

Mandatory

UUID

Example Request

CODE
GET /pfs-api/v1/patient/e9af860e-cf8e-4272-b81a-a95cc8a531f7/prescription-requests
Authorization: Bearer [token]

Response Details

Response Structure

The Prescription Request response structure.
The diagram shows the relationship between each entity returned in the response

Response Schema

Prescription Requests (Array)

This parent object contains:

  • Requested Items - Prescriptions and/or Prescription Issues requested by the patient.

  • New Prescriptions - New Prescriptions created by a Practitioner in response to a Prescription Request.

Field

Type

Description

id

uuid

The Prescription Request ID

status

enum

Possible values:

pending, processed, cancelled

messageToPatient

string

The practitioner's message to the patient

requestedItems

An array of Requested Prescriptions or Requested Prescription Issues

The prescriptions / prescription issues requested by the patient

The child “type” parameter specifies the type of request

Possible values:

  • prescription-reorder

  • prescription-issue

newPrescriptions

An array of New Prescriptions (See below)

New prescriptions created by the practitioner as a result of this request

Requested Item: Requested Prescription (a Prescription Reorder)

A reordered Prescription, based on an original Prescription.

Field

Type

Description

id

uuid

The prescription request item identifier

type

enum

The value is always “prescription-reorder”

basedOnPrescription

A Prescription object

The original prescription object

status

enum

Possible values:

  • pending

  • processed

  • rejected

messageFromPatient

string

A message supplied by the patient for the clinician

Requested Item: Prescription Issue

Field

Type

Description

id

uuid

The prescription request item identifier

type

enum

The value is always prescription-issue

prescriptionIssue

Prescription Issue (see below)

The prescription’s issue details

status

enum

Possible values:

  • pending

  • processed

  • rejected

Prescription Issue

An “issue” of a particular Prescription.

Field

Description

Example

id

uuid

The unique prescription identifier

status

enum

The prescription’s issue status

Possible values:
"not-issued", "issued", "cancelled"

dueDate

date

The date that the prescription issue was intended to be issued on

issueDate

date

The date the prescription was issued

quantityRequired

decimal

The quantity of the prescription issue that is required

Note: this is the quantity required per-Prescription Issue

expectedDaysSupply

int

The prescription issue’s expected days supply

epsOrderId

uuid

Only applicable if the issue method is “EPS”

prescription

Prescription

The prescription that the prescription issue is based on

Based on Prescription

The original Prescription that the Prescription Reorder or Prescription Issue is based on.

Property

Type

Description

id

uuid

The unique prescription identifier

type

enum

The type of prescription

Possible values: ["acute", "repeat", "repeat-dispensing", "instalment"]

product

Product (see schema below)

The prescription’s pharmaceutical product

dosageInstructions

string

 

quantityRequired

Quantity (see schema below)

 

authorisedIssues

int

 

reviewDate

date

The Prescription’s review date

authorisedDate

date

 

authorisedByOrganisation

Organisation

 Example Payload:

JSON
{
    "odsCode": "HAD12345",
    "name": "Happy Valley Hospital"
}

authorisedByPractitioner

Practitioner

 Example payload

JSON
{
    "id": "324b5437-ef40-43f1-9ecc-26a76c1938d0",
    "name": "Dr Turner", 
}

discontinuedDate

date

 

status

enum

Possible values: ['authorised', 'discontinued']

discontinuedReason

enum

Possible values:

["change-of-dosage","clinical-contra-indication","other-clinical-reason","patient-death","patient-deducted","patients-request","pharmacists-request","prescribing-error","prescription-not-collected","product-no-longer-available","product-no-longer-effective"]

Specific Response Codes

HTTP Code

Error Code

Scenario

200

 

Request successful

Example Response

JSON
HTTP/1.1 200 OK
Content-Type: application/json

{
    "prescriptions": [
        {
            "id": "495071be-28d9-11eb-adc1-dc39e0571b8a",
            "type": "repeat",
            "status": "authorised",
            "product": {
                "dmdCode": "52911000001107",
                "name": "Prednisolone 1mg tablets",
                "description": "Prednisolone 1mg tablets (Alliance Healthcare (Distribution) Ltd)",
                "manufacturerName": "Alliance Healthcare (Distribution) Ltd",
                "manufacturerCode": "2089901000001107"
            },
            "dosageInstructions": "1 tablet - every MORNING",
            "startDate": "2022-09-25",
            "endDate": "2023-03-12",
            "authorisedDate": "2022-09-16",
            "authorisedByOrganisation": {
                "name": "Riley House GP Practice",
                "odsCode": "F85003"
            },
            "authorisedByPractitioner": {
                "name": "Caitlin Davies",
                "id": "1339aa9b-28d6-11eb-adc1-0242ac120002"
            },
            "prescriptionIssue": [
                {
                    "id": "48f10b63-28d9-11eb-adc1-702be19df358",
                    "status": "issued",
                    "issueDate": "2022-09-25",
                    "quantityRequired": {
                        "value": 1,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    },
                    "expectedDaysSupply": 28
                },
                {
                    "id": "2d53147a-28d9-11eb-adc1-812ad5f6079b",
                    "status": "not-issued",
                    "dueDate": "2022-10-23",
                    "quantityRequired": {
                        "value": 1,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    },
                    "expectedDaysSupply": 28
                },
                {
                    "id": "85b03c96-28d9-11eb-adc1-bf45dc960a78",
                    "status": "not-issued",
                    "dueDate": "2022-11-20",
                    "quantityRequired": {
                        "value": 1,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    },
                    "expectedDaysSupply": 28
                },
                {
                    "id": "60ef5372-28d9-11eb-adc1-81ea9bf40c32",
                    "status": "not-issued",
                    "dueDate": "2022-12-18",
                    "quantityRequired": {
                        "value": 1,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    },
                    "expectedDaysSupply": 28
                },
                {
                    "id": "ef7b1984-28d9-11eb-adc1-79f12ce8b43a",
                    "status": "not-issued",
                    "dueDate": "2023-01-15",
                    "quantityRequired": {
                        "value": 1,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    },
                    "expectedDaysSupply": 28
                },
                {
                    "id": "53f806ba-28d9-11eb-adc1-064c37e19da2",
                    "status": "not-issued",
                    "dueDate": "2023-02-12",
                    "quantityRequired": {
                        "value": 1,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    },
                    "expectedDaysSupply": 28
                }
            ]
        },
        {
            "id": "95d237dc-43c4-11ed-869a-0a58a9feac02",
            "type": "acute",
            "status": "authorised",
            "product": {
                "dmdCode": "323739006",
                "name": "Amoxicillin 1g powder for solution for injection vials"
            },
            "dosageInstructions": "test",
            "startDate": "2022-10-04",
            "authorisedDate": "2022-10-04",
            "authorisedByOrganisation": {
                "name": "Riley House GP Practice",
                "odsCode": "F85003"
            },
            "authorisedByPractitioner": {
                "name": "Lara Lincoln",
                "id": "1332aa9c-28d6-11eb-adc1-0242ac120002"
            },
            "prescriptionIssue": [
                {
                    "id": "95d25a64-43c4-11ed-8ba7-0a58a9feac02",
                    "status": "not-issued",
                    "dueDate": "2022-10-04",
                    "quantityRequired": {
                        "value": 12,
                        "unit": {
                            "conceptId": "415818006",
                            "description": "vial"
                        }
                    }
                }
            ]
        },
        {
            "id": "2b2d1598-674e-11ed-acec-06399f90722e",
            "type": "acute",
            "status": "authorised",
            "product": {
                "dmdCode": "320822001",
                "name": "Loratadine 10mg tablets"
            },
            "dosageInstructions": "One a day",
            "startDate": "2022-11-18",
            "authorisedDate": "2022-11-18",
            "authorisedByOrganisation": {
                "name": "Riley House GP Practice",
                "odsCode": "F85003"
            },
            "authorisedByPractitioner": {
                "name": "Lara Lincoln",
                "id": "1332aa9c-28d6-11eb-adc1-0242ac120002"
            },
            "prescriptionIssue": [
                {
                    "id": "2b2db0b6-674e-11ed-943e-06399f90722e",
                    "status": "not-issued",
                    "dueDate": "2022-11-18",
                    "quantityRequired": {
                        "value": 100,
                        "unit": {
                            "conceptId": "428673006",
                            "description": "tablet"
                        }
                    }
                }
            ]
        }
    ]
}

Example Empty Response (the Patient Has No Outstanding Prescription Requests)

JSON
HTTP/1.1 200 OK
Content-Type: application/json

[]

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.