{"openapi":"3.0.0","info":{"contact":{"email":"api.management@nhs.net","name":"gp-connect/patient-facing/prescriptions-management-fhir/FHIR/R4 API Support","url":"https://digital.nhs.uk/developer/help-and-support"},"description":"## Overview\n\n![GP Connect Patient Facing Prescriptions Management API Overview](https://raw.githubusercontent.com/NHSDigital/gp-connect-prescriptions-management-fhir/master/specification/images/overview-diagram.svg)\n\nUse this API to manage a patient's prescriptions as held by their GP practice.\n\nYou can:\n\n* request a new instance of a repeat prescription\n\n* view all of a patients medications, whether acute or repeat, past or present\n\n* cancel a repeat prescription request\n\n* check the status of a current prescription request\n\n* request a new instance of a repeat prescription to a one off nomination pharmacy\n\nThe end user must be a patient who is:\n\n*  registered with the GP practice\n\n*  registered with NHS login to P9 identity verification level\n\nFor example:\n\n* a patient can view their own medication, request a new instance of a repeat prescription and cancel that request\n\n## Who can use this API\n\nThis API can be used by developers of clinical systems that support clinicians delivering direct care. It is a patient-facing API.\n\nThis API:\n\n* is intended only for use by patient-facing applications\n\n* is intended only for non-clinical use\n\n* can only be used where there is a legal basis to do so\n\nMake sure you have a valid use case before you go too far with development. To do this, contact us.\n\nYou must do this before you can go live (see Onboarding below).\n\n### Prerequisites\n\n#### Information governance (IG)\n\nYou must:\n\n* be compliant with the GP Connect Direct Care API Information Governance Model\n\n#### Clinical safety\n\nYou must:\n\n* have a clinical safety officer (CSO) who is responsible for DCB0129 and, if necessary, DCB0160. For more on clinical risk management, visit Clinical risk management standards\n\n## Related APIs\n\n* [Electronic Prescription Service - FHIR API](https://digital.nhs.uk/developer/api-catalogue/electronic-prescription-service-fhir) - use this API to issue requested prescriptions as electronic prescriptions.\n\n* [Electronic Prescription Service Tracker - REST API](https://digital.nhs.uk/developer/api-catalogue/spine-electronic-prescription-service-tracker-rest) - use this API to track the dispensing status of EPS prescriptions once they leave the GP system.\n\n* [GP Connect (Patient Facing) User Permissions API](https://digital.nhs.uk/developer/api-catalogue/gp-connect-patient-facing-user-permissions) - use this API to manage a patient's permissions as held by the GP practice systems.\n\n* [GP Connect (Patient Facing) Appointment Management - FHIR API](https://digital.nhs.uk/developer/api-catalogue/gp-connect-patient-facing-appointment-management-fhir) - use this API to manage GP practice appointments.\n\n* [GP Connect (Patient Facing) Access Record - FHIR API](https://digital.nhs.uk/developer/api-catalogue/gp-connect-patient-facing-access-record-fhir) - use this API to manage a patient's medical record from the GP practice systems.\n\n* [GP Connect Access Record: Structured - FHIR API](https://digital.nhs.uk/developer/api-catalogue/gp-connect-access-record-structured-fhir) - use this API for clinical access to the record, including structured medications linked to other elements of the patient record.\n\n\n## API status and roadmap\n\nThis API is in [production](https://digital.nhs.uk/developer/guides-and-documentation/reference-guide#statuses).\n\n## Service level\n\nThis API is a silver service, meaning it is operational 24 hours a day, 365 days a year but only supported during business hours (8am to 6pm), Monday to Friday excluding bank holidays.\n\nFor more details, see [service levels](https://digital.nhs.uk/developer/guides-and-documentation/reference-guide#service-levels).\n\n## Technology\n\nThis API is [RESTful](https://digital.nhs.uk/developer/guides-and-documentation/our-api-technologies#basic-rest).\n\nIt conforms to the [FHIR](https://digital.nhs.uk/developer/guides-and-documentation/our-api-technologies#fhir) global standard for health care data exchange, specifically to [FHIR R4 (v4.0.1)](https://hl7.org/fhir/r4/), except that it does not support the [capabilities](http://hl7.org/fhir/R4/http.html#capabilities) interaction.\n\nIt includes some country-specific FHIR extensions, which are built against [FHIR UK Core, specifically [UKcore.stu2 1.1.3](https://simplifier.net/guide/uk-core-implementation-guide-stu2?version=1.1.3).\n\nYou do not need to know much about FHIR to use this API - FHIR APIs are just RESTful APIs that follow specific rules. In particular:\n\n* resource names are capitalised and singular, for example `/Patient` not `/patients`\n\n* array names are singular, for example `line` not `lines` for address lines\n\n* data items that are country-specific and thus not included in the FHIR global base resources are usually wrapped in an `extension` object\n\nThere are [libraries and software development kits available](https://digital.nhs.uk/developer/guides-and-documentation/api-technologies-at-nhs-digital#fhir-libraries-and-sdks) to help with FHIR API integration.\n\n### Resources\n\nUse the [GP Connect Prescriptions Management Implementation Guide](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions?version=0.1.1-private-beta) to assist with your integration.\n\nThis is the FHIR specification for GP Connect Prescriptions.\n\n## Network access\n\nThis API is available on the internet and, indirectly, on the [Health and Social Care Network (HSCN)](https://digital.nhs.uk/services/health-and-social-care-network).\n\nFor more details, see [Network access for APIs](https://digital.nhs.uk/developer/guides-and-documentation/network-access-for-apis).\n\n## Security and authorisation\n\nThis API is [user-restricted](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis), meaning an end user must be present and authenticated to use it.\n\nThe end user must be:\n\n* a patient\n\n* authenticated with NHS login to P9 identity verification level\n\nThe API uses Open ID Connect to authenticate the end user and OAuth 2.0 to authorise the calling system. It supports the following security pattern using NHS login:\n\n* [User-restricted RESTful APIs - NHS login separate authentication and authorisation](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation/user-restricted-restful-apis-nhs-login-separate-authentication-and-authorisation)\n\n## Environments and testing\n\n|Environment|Base URL|\n|-----------|--------|\n|Sandbox|`https://sandbox.api.service.nhs.uk/gp-connect/patient-facing/prescriptions-management-fhir/FHIR/R4`|\n|Integration Testing|`Not yet available`|\n|Production|`Not yet available`|\n\n### Sandbox testing (Not yet available)\n\nOur [sandbox environment](https://digital.nhs.uk/developer/guides-and-documentation/testing#sandbox-testing):\n\n* is for early developer testing\n\n* only covers a limited set of scenarios\n\n* is stateless, so it does not store data\n\n* is open access, so does not allow you to test authorisation\n\nFor more details on sandbox testing, or to try out the sandbox using our \"Try this API\" feature, see the documentation for each endpoint.\n\nAlternatively, you can try out the sandbox using our Postman collection:\n\n[![Run in Postman](https://run.pstmn.io/button.svg)](https://god.gw.postman.com/run-collection/34036044-3c90d3e4-24ec-4a09-867e-26da1516ee61?action=collection%2Ffork&source=rip_markdown&collection-url=entityId%3D34036044-3c90d3e4-24ec-4a09-867e-26da1516ee61%26entityType%3Dcollection%26workspaceId%3Dbad72f85-20d6-41c3-bd55-f30bf83f8c63)\n\n### Integration testing (not yet available)\n\nOur [integration test environment](https://digital.nhs.uk/developer/guides-and-documentation/testing#integration-testing):\n\n* is for formal integration testing\n\n* is stateful, so it does persist data\n\n* includes authorisation\n\nFor more details see [integration testing with our RESTful APIs](https://digital.nhs.uk/developer/guides-and-documentation/testing#integration-testing-with-our-restful-apis).\n\n## Onboarding\n\nThe GP Connect Patient Facing APIs are currently only available for New Market Entrant suppliers as data providers, and are in use with the NHS App as the consumer.\n\nAt the time of writing (July 2025), we are not onboarding any additional consumer suppliers to use these APIs.\n\n## Errors\n\nWe use standard HTTP status codes to show whether an API request succeeded or not. They are usually in the range:\n\n- 200 to 299 if it succeeded, including code 202 if it was accepted by an API that needs to wait for further action\n\n- 400 to 499 if it failed because of a client error by your application\n\n- 500 to 599 if it failed because of an error on our server\n\nErrors specific to each API are shown in the Endpoints section, under Response. See our [reference guide](https://digital.nhs.uk/developer/guides-and-documentation/reference-guide#http-status-codes) for more on errors.\n\nAPI Specific errors can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/Design/Errors-and-issues?version=0.1.1-private-beta).\n","title":"GP Connect Prescriptions Management FHIR API","version":"Computed and injected at build time by `scripts/set_version.py`"},"servers":[{"description":"Sandbox environment.","url":"https://sandbox.api.service.nhs.uk/gp-connect/patient-facing/prescriptions-management-fhir/FHIR/R4"},{"description":"Integration test environment.","url":"https://int.api.service.nhs.uk/gp-connect/patient-facing/prescriptions-management-fhir/FHIR/R4"},{"description":"Production environment.","url":"https://api.service.nhs.uk/gp-connect/patient-facing/prescriptions-management-fhir/FHIR/R4"}],"paths":{"/Patient/{id}/MedicationStatement":{"get":{"description":"## Overview\n\nThis end point returns MedicationStatements relating to a patient, which show courses of medication prescribed to the patient.\n\nThese MedicationStatements must reference a MedicationRequest within the basedOn attribute: MedicationRequests provide details of specific prescriptions. The display within basedOn should quote the courseOfTherapyType from the referenced MedicationRequest, showing the prescription treatment type.\n\nThe referenced MedicationRequest must have intent set to plan.\n\nThe request must include the following parameter:\n\n* patient\n\n## Use cases\n\nUse cases covered by this endpoint include:\n\n* presenting a patients current medications\n\n* presenting a patients past/discontinued medications\n\n* presenting a choice of medications to reorder\n","operationId":"get-medicationstatement","parameters":[{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"},{"description":"The NHS number of the patient whose requests you are searching for\n","explode":false,"in":"path","name":"id","required":true,"schema":{"example":"9000000009","type":"string"},"style":"simple"},{"description":"The start date should be when the medication started in the episode of care. <eq|ge|le>yyyy-mm-dd. To use a range use effective=geyyyy-mm-dd&effective=leyyyy-mm-dd\n","examples":{"exact date":{"description":"Exact match date","value":"eq2010-10-22"},"greater than or equals":{"description":"Greater than or equals which matches 2022-01-15 or 2022-01-16","value":"ge2022-01-15"},"less than or equals":{"description":"Less than or equals which matches 2022-01-15 or 2022-01-14","value":"le2022-01-15"}},"explode":true,"in":"query","name":"effective","required":false,"schema":{"type":"string"},"style":"form"}],"responses":{"200":{"content":{"application/fhir+json":{"examples":{"example":{"description":"Successful response to view medication.","value":{"resourceType":"Bundle","id":"ec6077a4-553f-4087-944c-ea04c4593e3a","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"86af4f6c-30c5-4947-acc7-2f55145181de"},"type":"searchset","entry":[{"fullUrl":"8e357e94-8e5c-496f-92d6-5d14f2e70016","resource":{"resourceType":"MedicationStatement","id":"44f85d15-8744-47c2-a790-4f5e38aacdb0","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationStatement"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"fbf914b7-bb28-43e3-84ad-ab389dc1231f"}],"basedOn":[{"reference":"MedicationRequest/0ae6ac98-6b0f-404f-a95b-c38a4318f686","display":"Repeat prescription request for Aspirin 300mg Dispersible tablets."}],"status":"active","medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"329526003","display":"Aspirin 300mg dispersible tablets"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"effectivePeriod":{"start":"2022-10-23T13:50:00+00:00","end":"2023-01-10T13:50:00+00:00"},"dateAsserted":"2022-11-23","dosage":[{"text":"2 tablet - 4 times a day - at a meal - Dissolve or mix with water before taking - up to a maximum of 3.6 gram in 24 hours","additionalInstruction":[{"coding":[{"system":"http://snomed.info/sct","code":"417995008","display":"Dissolve or mix with water before taking"}]}],"timing":{"repeat":{"frequency":4,"period":1,"periodUnit":"d","when":["C"]}},"doseAndRate":[{"doseQuantity":{"value":2,"unit":"tablet","system":"http://snomed.info/sct","code":"428673006"}}]}]}},{"fullUrl":"a5b1910d-3241-4eed-9b5e-cb9d239e9fd7","resource":{"resourceType":"MedicationStatement","id":"4a3f265d-1c12-4aa1-9d22-49b7c5aa2048","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationStatement"]},"extension":[{"url":"https://fhir.hl7.org.uk/StructureDefinition/Extension-UKCore-MedicationStatementLastIssueDate","valueDateTime":"2017-02-24"}],"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"504e8d5b-0444-41ae-b5b7-f6f161b2bbbc"}],"basedOn":[{"reference":"MedicationRequest/0f450c33-67b2-4ca3-b0f9-fea75ccdcd44","display":"Acute prescription request for Amoxicillin 250mg capsules."}],"status":"active","medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"39732311000001104","display":"Amoxicillin 250mg capsules"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"effectivePeriod":{"start":"2022-10-23T13:50:00+00:00","end":"2023-01-10T13:50:00+00:00"},"dateAsserted":"2022-11-23","dosage":[{"text":"2 capsules 4 times a day.","timing":{"repeat":{"frequency":4,"period":1,"periodUnit":"d"}},"asNeededCodeableConcept":{"coding":[{"system":"http://snomed.info/sct","code":"301354004","display":"Pain of ear"}]},"site":{"coding":[{"system":"http://snomed.info/sct","code":"123851003","display":"Mouth region structure"}]},"route":{"coding":[{"system":"http://snomed.info/sct","code":"26643006","display":"Oral route"}]},"method":{"coding":[{"system":"http://snomed.info/sct","code":"421984009","display":"Until finished"}]},"doseAndRate":[{"doseQuantity":{"value":500,"unit":"milligram","system":"http://unitsofmeasure.org","code":"mg"}}]}]}}]}}},"schema":{"$ref":"#/components/schemas/MedicationStatementSchema"}}},"description":"Successful request to view medication."},"4XX":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"value","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"INVALID_NHS_NUMBER","display":"Invalid NHS Number"}]}}]}}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occurred as follows:\n\n\n| HTTP Status | Spine error code                | Description\n|-------------|---------------------------------|------------\n| 400         | BAD_REQUEST                     | X-Request-ID is not present\n| 400         | INVALID_NHS_NUMBER              | The NHS Number is invalid\n| 400         | INVALID_PARAMETER               | Invalid date\n| 403         | ACCESS_DENIED                   | Access denied, the patient logged in does not have the correct access level\n| 404         | PATIENT_NOT_FOUND               | The request is for the record of a non-Regular/GMS patient (i.e. the patient's registered practice is somewhere else)\n| 404         | PATIENT_NOT_FOUND               | The patient's NHS number in the provider system is not associated with a NHS number status indicator code of 'Number present and verified'                               |\n| 404         | PATIENT_NOT_FOUND               | The request is for the permissions of a non-Regular/GMS patient (i.e. the patient's registered practice is somewhere else)                                               |\n| 404         | PATIENT_NOT_FOUND               | The request is for the permissions of an inactive or deceased patient        \n| 422         | REFERENCE_NOT_FOUND             | BasedOn reference to previous prescription is not valid\n| 422         | INVALID_RESOURCE                | BasedOn reference to previous prescription not present\n"}},"summary":"Get medications relating to a patient"}},"/MedicationRequest/{id}":{"get":{"description":"## Overview\nUse this endpoint to get specific MedicationRequests. \n\nThe request must include the following parameter:\n\n* id\n* patient\n\n## Use cases\nUse cases covered by this endpoint include:\n\n* to resolve references for MedicationRequest's from other responses\n\n* to resolve the BasedOn reference to confirm whether the MedicationStatement is representing an acute or repeat Medication\n\n* to get further information about what medication the Task is focused by resolving the focus reference\n","operationId":"get-planned-medicationrequest","parameters":[{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"},{"description":"The id of the MedicationRequest you are searching for\n","explode":false,"in":"path","name":"id","required":true,"schema":{"example":"0ae6ac98-6b0f-404f-a95b-c38a4318f686","type":"string"},"style":"simple"},{"description":"The NHS number of the patient for whom the medication request belongs.","explode":true,"in":"query","name":"patient","required":true,"schema":{"example":"9000000009","type":"string"},"style":"form"}],"responses":{"200":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"MedicationRequest","id":"b269d1d7-1acf-47bb-8b3c-e38b583d9a07","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"extension":[{"url":"https://fhir.hl7.org.uk/StructureDefinition/Extension-UKCore-MedicationRepeatInformation","extension":[{"url":"numberOfPrescriptionsIssued","valueUnsignedInt":1},{"url":"authorisationExpiryDate","valueDateTime":"2023-09-10T19:00:00.000Z"}]}],"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"42b4a841-9d69-4d13-bf91-ee5882e85765"}],"status":"active","intent":"plan","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/ed313d93-f470-420f-ae4e-2b7eb91d3f45","display":"Dr Jane Smith"},"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"PDI12E-Y765908-4FF3LQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-10-13T16:20:27+07:00","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"}}}}},"schema":{"$ref":"#/components/schemas/SingularMedicationRequestSchema"}}},"description":"Successful request to view current and previous prescription details"},"4XX":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"value","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"INVALID_NHS_NUMBER","display":"Invalid NHS Number"}]}}]}}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occurred as follows:\n\n\n| HTTP Status | Spine error code   | Description\n|-------------|--------------------|------------\n| 400         | BAD_REQUEST        | X-Request-ID is not present\n| 403         | ACCESS_DENIED      | Access denied, the patient logged in does not have the correct access level\n| 404         | RESOURCE_NOT_FOUND | The request is for a MedicationRequest that doesn't exist\n| 422         | INVALID_PARAMETER  | The MedicationRequest id supplied is invalid\n| 400         | INVALID_NHS_NUMBER | The NHS number provided is invalid, for example it fails format or check digit tests    \n| 422         | INVALID_PARAMETER  | The patient parameter is not provided                                          \n"}},"summary":"Get a specific planned medication request"}},"/Patient/{id}/MedicationRequest":{"get":{"description":"## Overview\nUse this endpoint to get details of previous prescription issues.\nThe request must include the following parameter:\n\n* patient\n\nThe request can optionally include include one of following parameters:\n\n* authoredon\n\n* identifier\n\n* intent\n\n* status\n\nEach MedicationRequest with intent of order must reference a MedicationRequest with intent plan within the basedOn element.\n## Use cases\nUse cases covered by this endpoint include:\n\n* to get information about previously prescribed medication to display to the patient\n\n* present previously prescribed repeat medications available to reorder\n","operationId":"get-ordered-medicationrequest","parameters":[{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"},{"description":"The NHS number of the patient whose requests you are searching for\n","explode":false,"in":"path","name":"id","required":true,"schema":{"example":"9912003489","type":"string"},"style":"simple"},{"description":"Date the prescription was requested, format: <eq|ge|le>YYYY-MM-DD. To use a range use authoredon=geYYYY-MM-DD&authoredon=leYYYY-MM-DD\n","examples":{"exact date":{"description":"Exact match date","value":"eq2010-10-22"},"greater than or equals":{"description":"Greater than or equals which matches 2022-01-15 or 2022-01-16","value":"ge2022-01-15"},"less than or equals":{"description":"Less than or equals which matches 2022-01-15 or 2022-01-14","value":"le2022-01-15"}},"explode":true,"in":"query","name":"authoredon","required":false,"schema":{"type":"string"},"style":"form"},{"description":"This will either be a uuid OR an EPS prescription identifier, this should only be used to obtain specific EPS orders using their identifier.\n\nEPS prescription Identifier for the prescription. Searches for EPS prescriptions need to provide a data type of `https://fhir.nhs.uk/Id/prescription-order-number` in the format `<data-type>|<prescription-identifier>`\n","examples":{"eps-prescription":{"value":"https://fhir.nhs.uk/Id/prescription-order-number|CDT38E-Y765968-4FG3BQ"}},"explode":true,"in":"query","name":"identifier","required":false,"schema":{"type":"string"},"style":"form"},{"description":"Intent of the MedicationRequest, will either be plan or order. If plan is selected only MedicationRequest's with intent of plan will be returned.\n","examples":{"intent":{"value":"plan"}},"explode":true,"in":"query","name":"intent","required":false,"schema":{"type":"string"},"style":"form"},{"description":"The type of status to search: you can find valid values [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-MedicationRequest?version=0.1.1-private-beta#status)\n","explode":true,"in":"query","name":"status","required":false,"schema":{"example":"active","type":"string"},"style":"form"}],"responses":{"200":{"content":{"application/fhir+json":{"examples":{"GetResponsePreviousPrescriptionDetailed":{"$ref":"#/components/examples/GetResponsePreviousPrescriptionDetailed"},"GetResponseMultiplePrescriptions":{"$ref":"#/components/examples/GetResponseMultiplePrescriptions"},"GetResponseMethotrexate":{"$ref":"#/components/examples/GetResponseMethotrexate"}},"schema":{"description":"Information surrounding how the resource is populated can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-MedicationRequest?version=0.1.1-private-beta).","type":"object"}}},"description":"Successful request to view previous prescription issue details"},"4XX":{"content":{"application/fhir+json":{"examples":{"InvalidRequestError":{"$ref":"#/components/examples/InvalidRequestError"}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occurred as follows:\n\n\n| HTTP Status | Spine error code   | Description\n|-------------|--------------------|------------\n| 404         | RESOURCE_NOT_FOUND | The request is for a MedicationRequest that doesn't exist\n| 422         | INVALID_PARAMETER  | The MedicationRequest id supplied is invalid\n| 422         | INVALID_PARAMETER  | The date is invalid or in future\n| 422         | INVALID_PARAMETER  | The identifier value is invalid\n"}},"summary":"Get prescription issue details"}},"/Task":{"get":{"description":"## Overview\n\nUse this end point to check the status of past and current prescription reorder requests.\n\nIf a Patient identifier is provided past and present requests will be returned for the patient inside as multiple Task rescources inside a Bundle resource.\n\nIf just the id of a specific request is passed a singular Task resource will be returned inside a Bundle resource.\n\nIf the prescription request is then sent to EPS to be fulfilled the EPS id of the new MedicationRequest must be included in the output element of the Task resource. \n\nYou must provide at least one of the following parameters:\n\n* id\n\n* patient\n## Use cases\nUse cases covered by this endpoint include:\n\n* present inflight prescription requests to the Patient\n\n* allow the patient to check the status of a specific request\n\n* obtain the EPS id of a prescription reorder request that has been sent to be dispensed\n\n* obtain a list of requests to enable the patient to send a cancellation\n","operationId":"get-task","parameters":[{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"},{"description":"The NHS number of the patient whose requests you are searching for\n","explode":true,"in":"query","name":"patient","required":true,"schema":{"example":"9912003489","type":"string"},"style":"form"},{"description":"Task:focus:MedicationRequest - Include MedicationRequest resources referenced within the returned Task resources, further information around the benefits and using this parameter can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/Build/How-to-determine-the-medication-the-request-belongs-to?version=0.1.1-private-beta).\n","explode":true,"in":"query","name":"_include","required":false,"schema":{"items":{"enum":["Task:focus:MedicationRequest"],"type":"string"},"type":"array"},"style":"form"},{"description":"The id of the Task itself\n","explode":true,"in":"query","name":"id","required":false,"schema":{"example":"dad85fcc-d3a0-4806-886a-a573bd48ad2c","type":"string"},"style":"form"},{"description":"The type of status to search: you can find valid values [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-Task?version=0.1.1-private-beta#status).\n","explode":true,"in":"query","name":"status","required":false,"schema":{"example":"requested","type":"string"},"style":"form"},{"description":"Date the prescription was requested, format: <eq|ge|le>YYYY-MM-DD. To use a range use authored-on=geYYYY-MM-DD&authored-on=leYYYY-MM-DD\n","examples":{"exact date":{"description":"Exact match date","value":"eq2010-10-22"},"greater than or equals":{"description":"Greater than or equals which matches 2022-01-15 or 2022-01-16","value":"ge2022-01-15"},"less than or equals":{"description":"Less than or equals which matches 2022-01-15 or 2022-01-14","value":"le2022-01-15"}},"explode":true,"in":"query","name":"authored-on","required":false,"schema":{"type":"string"},"style":"form"}],"responses":{"200":{"content":{"application/fhir+json":{"examples":{"bundle":{"description":"Successful request to view requests for prescriptions when a patient identifier is passed.","value":{"resourceType":"Bundle","id":"a96bb563-c86b-4021-903e-5917b927c386","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"a3294018-6c63-4556-8797-f782d1c95480"},"type":"searchset","entry":[{"fullUrl":"20885a31-acf0-42d5-bd5b-85c23f7a32fd","resource":{"resourceType":"Task","id":"aef77afb-7e3c-427a-8657-2c427f71a271","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"725ca1bd-2860-4476-8802-8d035d802e7f"}],"status":"requested","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/06c7d0e2-1022-4e47-ac55-f6463d701a4f","display":"Repeat prescription for Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-11-23T20:20:27+07:00","lastModified":"2022-11-23T20:20:27+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"note":[{"authorString":"Patient","text":"Ran out of previous prescription"}]}},{"fullUrl":"15c5ee13-73cf-45f8-a1f1-a7de3e10dae6","resource":{"resourceType":"Task","id":"b395d57e-5d6c-4d2c-b590-fe2f2d708458","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"725ca1bd-2860-4476-8802-8d035d802e7f"}],"status":"rejected","statusReason":{"text":"No longer suitable, please contact GP to organise an appointment"},"intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/06c7d0e2-1022-4e47-ac55-f6463d701a4f","display":"Repeat prescription for Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-08-14T07:20:23+07:00","lastModified":"2022-08-14T11:40:47+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"}}},{"fullUrl":"561d0bfa-a937-4d91-81ab-abe65bca2d95","resource":{"resourceType":"Task","id":"84722efb-95b0-4769-921a-eda53382b320","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"2270b136-7a4c-491e-8bf1-624b5c4f20b7"}],"status":"in-progress","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/06c7d0e2-1022-4e47-ac55-f6463d701a4f","display":"Repeat prescription for Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-10-13T16:20:27+07:00","lastModified":"2022-10-15T11:28:13+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"}}}]}},"completed and sent to EPS":{"description":"Completed prescription reorder request when sent to EPS.","value":{"resourceType":"Bundle","id":"a96bb563-c86b-4021-903e-5917b927c386","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"a3294018-6c63-4556-8797-f782d1c95480"},"type":"searchset","entry":[{"fullUrl":"20885a31-acf0-42d5-bd5b-85c23f7a32fd","resource":{"resourceType":"Task","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"30d65c8e-98e8-4806-b6a6-fpwjfkhs729"}],"status":"completed","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/b269d1d7-1acf-47bb-8b3c-e38b583d9a07","display":"Repeat prescription for Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2023-01-10T09:20:27.000Z","lastModified":"2023-01-20T10:20:24.000Z","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"output":[{"type":{"coding":[{"system":"https://fhir.nhs.uk/England/CodeSystem/England-PFSPrescriptionOrderingParameter","code":"sent-to-eps","display":"Sent to EPS"}]},"valueIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"4857b9d3-b714-44b9-9e67-3df67275b785"}}]}}]}},"include Medication Requests":{"description":"Successful request to view requests for prescriptions when a patient identifier is passed and _include parameters are used to return the referenced medication requests.","value":{"resourceType":"Bundle","id":"a96bb563-c86b-4021-903e-5917b927c386","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"a3294018-6c63-4556-8797-f782d1c95480"},"type":"searchset","entry":[{"fullUrl":"20885a31-acf0-42d5-bd5b-85c23f7a32fd","resource":{"resourceType":"MedicationRequest","id":"06c7d0e2-1022-4e47-ac55-f6463d701a4f","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"extension":[{"url":"https://fhir.hl7.org.uk/StructureDefinition/Extension-UKCore-MedicationRepeatInformation","extension":[{"url":"numberOfPrescriptionsIssued","valueUnsignedInt":1},{"url":"authorisationExpiryDate","valueDateTime":"2023-09-10T19:00:00.000Z"}]}],"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"42b4a841-9d69-4d13-bf91-ee5882e85765"}],"status":"active","intent":"plan","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/ed313d93-f470-420f-ae4e-2b7eb91d3f45","display":"Dr Jane Smith"},"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"PDI12E-Y765908-4FF3LQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-10-13T16:20:27+07:00","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"}}}},{"fullUrl":"20885a31-acf0-42d5-bd5b-85c23f7a32fd","resource":{"resourceType":"Task","id":"aef77afb-7e3c-427a-8657-2c427f71a271","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"725ca1bd-2860-4476-8802-8d035d802e7f"}],"status":"requested","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/06c7d0e2-1022-4e47-ac55-f6463d701a4f","display":"Repeat prescription for Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-11-23T20:20:27+07:00","lastModified":"2022-11-23T20:20:27+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"note":[{"authorString":"Patient","text":"Ran out of previous prescription"}]}},{"fullUrl":"15c5ee13-73cf-45f8-a1f1-a7de3e10dae6","resource":{"resourceType":"Task","id":"fjugkd8281-4tngn-j4fn-8657-2knrkfjrgu","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"725ca1bd-2860-4476-8802-8d035d802e7f"}],"status":"rejected","statusReason":{"text":"No longer suitable, please contact GP to organise an appointment"},"intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/06c7d0e2-1022-4e47-ac55-f6463d701a4f"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-08-14T07:20:23+07:00","lastModified":"2022-08-14T11:40:47+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"}}},{"fullUrl":"561d0bfa-a937-4d91-81ab-abe65bca2d95","resource":{"resourceType":"Task","id":"84722efb-95b0-4769-921a-eda53382b320","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"2270b136-7a4c-491e-8bf1-624b5c4f20b7"}],"status":"in-progress","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/06c7d0e2-1022-4e47-ac55-f6463d701a4f","display":"Repeat prescription for Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-10-13T16:20:27+07:00","lastModified":"2022-10-15T11:28:13+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"}}}]}}},"schema":{"description":"Information surrounding how the Task resource is populated can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-Task?version=0.1.1-private-beta).","type":"object"}}},"description":"Successful query"},"4XX":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"business-rule","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"CONFLICTING_VALUES","display":"Mismatched prescribed item to quantity"}]}}]}}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occured as follows:\n\n\n| HTTP Status | Spine error code   | Description\n|-------------|--------------------|------------\n| 400         | BAD_REQUEST        | X-Request-ID is not present            \n| 403         | ACCESS_DENIED      | Access denied, the patient logged in does not have the correct access level\n| 404         | RESOURCE_NOT_FOUND | The request is for a Task that doesn't exist\n| 404         | PATIENT_NOT_FOUND  | The request is for a Patient that doesn't exist\n| 422         | INVALID_PARAMETER  | The Task id supplied is invalid\n| 422         | INVALID PARAMERER  | Date is invalid \n"}},"summary":"Get requested prescription reorders"},"patch":{"description":"## Overview\n\nUse this endpoint to cancel a current request that has not been actioned yet. \n\nThis means only has status of \"Requested\", a cancellation request against any other status will return an error.\n\nThe content-type for this request must be \"application/json-patch+json\".\n\nThe request must include the following parameter:\n\n* id\n* patient\n## Use cases\nUse cases covered by this endpoint include:\n\n* a patient cancelling a prescription reorder request\n## Request handling\nIf the cancellation is sent after it has been actioned it will be rejected and return a 404 errror.\nIf the cancellation is sent to a prescription request before it is actioned, the status will update to cancelled. \n","operationId":"patch-task","parameters":[{"description":"The content-type of the request.\n","explode":false,"in":"header","name":"content-type","required":true,"schema":{"example":"application/json-patch+json","type":"string"},"style":"simple"},{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"},{"description":"The id of the Task to cancel\n","explode":true,"in":"query","name":"id","required":true,"schema":{"example":"aef77afb-7e3c-427a-8657-2c427f71a271","type":"string"},"style":"form"},{"description":"The NHS number of the patient","explode":true,"in":"query","name":"patient","required":true,"schema":{"example":"9000000009","type":"string"},"style":"form"}],"requestBody":{"content":{"application/json-patch+json":{"examples":{"jsonpatch":{"description":"A valid JSON patch for cancelling the status.\n","value":{"op":"replace","path":"/status","value":"cancelled"}}},"schema":{"description":"JSON patch for cancellation\n","type":"object"}}},"description":"Successful Request.","required":true},"responses":{"200":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"Task","id":"825fabd0-23dd-4f4c-adce-4a7ac2c71659","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"d66af104-b835-43a7-b723-32445b3051cc"}],"status":"cancelled","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/e2235eb5-9537-417e-91e8-9b272b8a10f6"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-11-10T15:10:57+07:00","lastModified":"2022-12-19T12:28:53+07:00","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"}}}},"schema":{"type":"object"}}},"description":"Successful request to cancel a request must return the updated object."},"4XX":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"business-rule","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"INVALID_PARAMETER","display":"The Task id supplied is invalid"}]}}]}}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occured as follows:\n\n\n| HTTP Status | Spine error code   | Description\n|-------------|--------------------|------------\n| 400         | INVALID_NHS_NUMBER | The NHS number provided is invalid, for example it fails format or check digit tests    \n| 404         | RESOURCE_NOT_FOUND | The request is for a Task that doesn't exist\n| 404         | RESOURCE_NOT_FOUND | The request is for a Task that has already been cancelled\n| 404         | RESOURCE_NOT_FOUND | The request is for a Task that has already been actioned\n| 422         | INVALID_PARAMETER  | The patient parameter is not provided        \n| 422         | INVALID_PARAMETER  | The Task id supplied is invalid                                  \n"}},"summary":"Cancel an unactioned repeat prescription request"},"post":{"description":"## Overview\n\nUse this end point to create a request for a repeat prescription.\n\nThe same end point can be used to request a prescription to a one off pharmacy nomination - the ODS code is set in Task.input using code [preferred-performer](https://simplifier.net/guide/nhs-england-implementation-guide-stu1/Home/Terminology/All-CodeSystems/CodeSystem-England-PFSPrescriptionOrderingParameter?version=1.1.0).\n\nFor this, send a Task with a focus of a prior MedicationRequest which has an intent of plan. This can be obtain by using the GET `/MedicationRequest/Patient/` endpoint within this API.\n\n## Use cases\nUse cases covered by this endpoint include:\n\n* request the next issue of a repeat prescription\n\n* request the next issue of a repeat prescription to a one off pharmacy nomination\n\n* request  \n\n## Request workflow\nWhen a request is made it is added to the GP system's workflow and processed at some point in the future.\nAt this point the status of the Task resource will be updated as it passes through the GP system's workflow. \nIf a request is rejected the statusReason element of the Task resource will be populated with the reason to be displayed to the patient.\n","operationId":"post-task","parameters":[{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"}],"requestBody":{"content":{"application/fhir+json":{"example":{"resourceType":"Task","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"ce3354f5-98c2-43ad-95bd-a6df1c5ed169"}],"status":"requested","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/b269d1d7-1acf-47bb-8b3c-e38b583d9a07"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-10-13T09:20:27.000Z","lastModified":"2022-10-13T09:20:27.000Z","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"note":[{"authorString":"Patient","text":"ran out of previous prescription"}],"input":[{"type":{"coding":[{"system":"https://fhir.nhs.uk/England/CodeSystem/England-PFSPrescriptionOrderingParameter","code":"preferred-performer","display":"Preferred performer"}]},"valueIdentifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"FLM49"}}]},"schema":{"description":"Information surrounding how the Task resource is populated can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-Task?version=0.1.1-private-beta).\n","type":"object"}}},"description":"Successful Request.","required":true},"responses":{"201":{"content":{"application/fhir+json":{"examples":{"operation-outcome-success":{"value":{"resourceType":"Task","id":"7c747c6e-15c8-4b2f-8aa0-441f2ef703d6","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-Task"]},"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"ce3354f5-98c2-43ad-95bd-a6df1c5ed169"}],"status":"requested","intent":"order","code":{"coding":[{"system":"http://snomed.info/sct","code":"103742009","display":"Renewal of prescription"}]},"focus":{"reference":"MedicationRequest/b269d1d7-1acf-47bb-8b3c-e38b583d9a07"},"for":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"authoredOn":"2022-10-13T09:20:27.000Z","lastModified":"2022-10-13T09:20:27.000Z","requester":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"note":[{"authorString":"Patient","text":"ran out of previous prescription"}],"input":[{"type":{"coding":[{"system":"https://fhir.nhs.uk/England/CodeSystem/England-PFSPrescriptionOrderingParameter","code":"preferred-performer","display":"Preferred performer"}]},"valueIdentifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"FLM49"}}]}}},"schema":{"type":"object"}}},"description":"A successful response to the POST request will return the created object now populated with an id."},"4XX":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"business-rule","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"CONFLICTING_VALUES","display":"Mismatched prescribed item to quantity"}]}}]}}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occured as follows:\n\n\n| HTTP Status | Spine error code      | Description\n|-------------|-----------------------|------------\n| 400         | BAD_REQUEST           | X-Request-ID is not present\n| 403         | ACCESS_DENIED         | Access denied, the patient logged in does not have the correct access level\n| 409         | DUPLICATE_REJECTED\t  | Create would lead to creation of a duplicate resource\n| 422         | INVALID_RESOURCE      | Task resource failed validation (any incorrect values)\n| 422         | INVALID_RESOURCE      | Task missing required focus reference\n| 422         | REFERENCE_NOT_FOUND   | focus reference to MedicationRequest not valid\n| 422         | REFERENCE_NOT_FOUND   | requester reference to Patient not valid\n| 422         | REFERENCE_NOT_FOUND   | for reference to Patient not valid\n"}},"summary":"Request a repeat prescription"}},"/PractitionerRole/{id}":{"get":{"description":"## Overview\n\nUse this endpoint to get details of practitioners issuing previous prescriptions.\n\nThe request must include the following parameter:\n\n* id\n* patient\n## Use cases\nUse cases covered by this endpoint include:\n* to present to the patient information about the practitioner who issued the previous prescriptions\n","operationId":"get-practitioner-role","parameters":[{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"},{"description":"The id of the practitioner role you are requesting details for.\n","explode":false,"in":"path","name":"id","required":true,"schema":{"example":"ed313d93-f470-420f-ae4e-2b7eb91d3f45","type":"string"},"style":"simple"},{"description":"The NHS number of the patient","explode":true,"in":"query","name":"patient","required":true,"schema":{"example":"9000000009","type":"string"},"style":"form"}],"responses":{"200":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"PractitionerRole","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-PractitionerRole"]},"id":"e35f0382-ac2e-47f9-9164-afd7d6adf952","practitioner":{"display":"Dr Jane Smith","identifier":{"system":"https://fhir.hl7.org.uk/Id/gmc-number","value":"C9876543"}},"organization":{"identifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"L8048"}}}}},"schema":{"description":"Information surrounding how the PractitionerRole resource is populated can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-PractitionerRole?version=0.1.1-private-beta).","type":"object"}}},"description":"Successful request to view practitioner role details"},"4XX":{"content":{"application/fhir+json":{"examples":{"example":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"value","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"INVALID_PARAMETER","display":"The PractitionerRole id supplied is invalid"}]}}]}}},"schema":{"description":"Link to UKCore-OperationOutcome resource population guidance [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-OperationOutcome?version=0.1.1-private-beta).","type":"object"}}},"description":"An error occured as follows:\n\n\n| HTTP Status | Spine error code   | Description\n|-------------|--------------------|------------\n| 400         | BAD_REQUEST        | X-Request-ID is not present\n| 400         | INVALID_NHS_NUMBER | The NHS number provided is invalid, for example it fails format or check digit tests  \n| 403         | ACCESS_DENIED      | Access denied, the patient logged in does not have the correct access level\n| 404         | RESOURCE_NOT_FOUND | The request is for a PractitionerRole that doesn't exist\n| 422         | INVALID_PARAMETER  | The PractitionerRole id supplied is invalid  \n| 422         | INVALID_PARAMETER  | The patient parameter is not provided \n"}},"summary":"Get practitioner role details"}}},"components":{"examples":{"GetResponsePreviousPrescriptionDetailed":{"value":{"resourceType":"Bundle","id":"2b62ff26-25a9-4a88-8cb6-f69e85fb6159","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"86af4f6c-30c5-4947-acc7-2f55145181de"},"type":"searchset","entry":[{"fullUrl":"222c7ae0-9e54-4980-a46b-c259146a5730","resource":{"resourceType":"MedicationRequest","id":"b269d1d7-1acf-47bb-8b3c-e38b583d9a07","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"4857b9d3-b714-44b9-9e67-3df67275b785"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"CDT38E-Y765968-4FG3BQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-10-13T09:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"},"performer":{"identifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"Y12345"}}}}},{"fullUrl":"e1264b69-b55b-44b9-9b2b-6655a39c8506","resource":{"resourceType":"MedicationRequest","id":"159757f8-6409-4b8c-b0df-f8feefc3ad0e","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"4857b9d3-b714-44b9-9e67-3df67275b785"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"PDI12E-Y765908-4FF3LQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-11-13T07:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"},"performer":{"identifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"Y12345"}}}}},{"fullUrl":"9bb81cb7-30fe-4406-bbed-e4b82bab2d4c","resource":{"resourceType":"MedicationRequest","id":"4de39acf-73b1-4dc6-bb87-c98b57ee5413","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"extension":[{"url":"https://fhir.hl7.org.uk/StructureDefinition/Extension-UKCore-MedicationRepeatInformation","extension":[{"url":"numberOfPrescriptionsIssued","valueUnsignedInt":2},{"url":"authorisationExpiryDate","valueDateTime":"2022-10-11T19:00:00.000Z"}]}],"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"42b4a841-9d69-4d13-bf91-ee5882e85765"}],"status":"active","intent":"plan","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"PDI12E-Y765908-4FF3LQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-11-13T07:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"}}}}]}},"InvalidRequestError":{"value":{"resourceType":"OperationOutcome","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-OperationOutcome"]},"issue":[{"severity":"error","code":"value","details":{"coding":[{"system":"https://fhir.nhs.uk/R4/ValueSet/Spine-ErrorOrWarningCode-1","code":"INVALID_NHS_NUMBER","display":"Invalid NHS Number"}]}}]}},"GetResponseMultiplePrescriptions":{"value":{"resourceType":"Bundle","id":"aec4566e-e1af-4aa5-898b-32754ffdbc59","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"7c1301d3-1c45-4552-9e07-deaf82b0ef32"},"type":"searchset","entry":[{"fullUrl":"222c7ae0-9e54-4980-a46b-c259146a5730","resource":{"resourceType":"MedicationRequest","id":"b269d1d7-1acf-47bb-8b3c-e38b583d9a07","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"4857b9d3-b714-44b9-9e67-3df67275b785"}],"status":"active","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"CDT38E-Y765968-4FG3BQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-10-13T09:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"},"performer":{"identifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"Y12345"}}}}},{"fullUrl":"e1264b69-b55b-44b9-9b2b-6655a39c8506","resource":{"resourceType":"MedicationRequest","id":"159757f8-6409-4b8c-b0df-f8feefc3ad0e","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"4857b9d3-b714-44b9-9e67-3df67275b785"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"PDI12E-Y765908-4FF3LQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-11-13T07:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"},"performer":{"identifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"Y12345"}}}}},{"fullUrl":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413","resource":{"resourceType":"MedicationRequest","id":"4de39acf-73b1-4dc6-bb87-c98b57ee5413","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"extension":[{"url":"https://fhir.hl7.org.uk/StructureDefinition/Extension-UKCore-MedicationRepeatInformation","extension":[{"url":"numberOfPrescriptionsIssued","valueUnsignedInt":2},{"url":"authorisationExpiryDate","valueDateTime":"2022-10-11T19:00:00.000Z"}]}],"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"42b4a841-9d69-4d13-bf91-ee5882e85765"}],"status":"active","intent":"plan","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"3113111000001106","display":"Pulmicort 100 Turbohaler (AstraZeneca UK Ltd)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"PDI12E-Y765908-4FF3LQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-11-13T07:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"One to two puffs to be inhaled as needed","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"}}}},{"fullUrl":"1cb73413-45b8-4994-a86f-cb69f4bd6a51","resource":{"resourceType":"MedicationRequest","id":"5f670e15-0eee-4822-9334-a24560794caa","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"33a0a087-d1f8-4f8a-85bd-7a21ff66773a"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"21011811000001100","display":"Enshake oral powder 96.5g sachets (Flavour Not Specified)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/97046973-afbc-4a8f-98d1-27f9412c94e3"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"754CB4-E81001-0B9EB8"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-11-13T07:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"As Directed Enshake oral powder 96.5g sachets (Flavour Not Specified) Please call the practice","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"inhaler","system":"http://snomed.info/sct","code":"334980009"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"},"performer":{"identifier":{"system":"https://fhir.nhs.uk/Id/ods-organization-code","value":"Y12345"}}}}},{"fullUrl":"c5a87fcf-8cb7-46f8-8bae-62e76b62a058","resource":{"resourceType":"MedicationRequest","id":"97046973-afbc-4a8f-98d1-27f9412c94e3","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"extension":[{"url":"https://fhir.hl7.org.uk/StructureDefinition/Extension-UKCore-MedicationRepeatInformation","extension":[{"url":"numberOfPrescriptionsIssued","valueUnsignedInt":2},{"url":"authorisationExpiryDate","valueDateTime":"2022-10-11T19:00:00.000Z"}]}],"identifier":[{"system":"https://tools.ietf.org/html/rfc4122","value":"6b859ae0-9666-4331-ac84-4034a937f576"}],"status":"active","intent":"plan","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"https://dmd.nhs.uk","code":"21011811000001100","display":"Enshake oral powder 96.5g sachets (Flavour Not Specified)"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"754CB4-E81001-0B9EB8"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2022-11-13T07:20:27.000Z","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"As Directed Enshake oral powder 96.5g sachets (Flavour Not Specified) Please call the practice","method":{"coding":[{"system":"http://snomed.info/sct","code":"420652005","display":"Until gone"}]}}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":28,"unit":"sachet","system":"http://snomed.info/sct","code":"426148002"},"expectedSupplyDuration":{"value":28,"unit":"days","system":"http://unitsofmeasure.org","code":"d"}}}}]}},"GetResponseMethotrexate":{"value":{"resourceType":"Bundle","id":"83fdd1ca-b9cc-44bd-8e99-5e9219910517","identifier":{"system":"https://tools.ietf.org/html/rfc4122","value":"e242f46c-5875-4eb4-875d-148298c52977"},"type":"searchset","entry":[{"fullUrl":"a48c085d-ca8c-4646-afd3-7a0dae64efd2","resource":{"resourceType":"MedicationRequest","id":"e18131f3-3ac2-41ef-9cde-2639739e80be","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"00db57d1-fd0c-4ae2-8536-6990f31d8ea4"}],"status":"active","intent":"plan","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"http://snomed.info/sct","code":"15517911000001104","display":"Methotrexate 10mg/0.2ml solution for injection pre-filled syringes"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"CDT38E-Y765968-4FG3BQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2020-07-13T12:00:00+00:00","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"10 milligram, Inject, Subcutaneous route, once weekly","additionalInstruction":[{"coding":[{"system":"http://snomed.info/sct","code":"421769005","display":"Follow directions"}]}],"patientInstruction":"As directed","timing":{"repeat":{"boundsDuration":{"value":10,"unit":"day","system":"http://unitsofmeasure.org","code":"d"},"frequency":5,"period":1,"periodUnit":"d"}},"route":{"coding":[{"system":"http://snomed.info/sct","code":"34206005","display":"Subcutaneous route"}]},"method":{"coding":[{"system":"http://snomed.info/sct","code":"422145002","display":"Inject"}]},"doseAndRate":[{"doseQuantity":{"value":10,"unit":"milligram","system":"http://unitsofmeasure.org","code":"mg"}}]}],"dispenseRequest":{"validityPeriod":{"start":"2020-07-13T12:00:00+00:00","end":"2020-08-07T12:00:00+00:00"},"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"Injection","system":"http://snomed.info/sct","code":"3092611000001103"},"expectedSupplyDuration":{"value":7,"unit":"day","system":"http://unitsofmeasure.org","code":"d"}}}},{"fullUrl":"a48c085d-ca8c-4646-afd3-7a0dae64efd2","resource":{"resourceType":"MedicationRequest","id":"e18131f3-3ac2-41ef-9cde-2639739e80be","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"00db57d1-fd0c-4ae2-8536-6990f31d8ea4"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"http://snomed.info/sct","code":"15517911000001104","display":"Methotrexate 10mg/0.2ml solution for injection pre-filled syringes"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"CDT38E-Y765968-4FG3BQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2020-07-20T12:00:00+00:00","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"10 milligram, Inject, Subcutaneous route, once weekly","additionalInstruction":[{"coding":[{"system":"http://snomed.info/sct","code":"421769005","display":"Follow directions"}]}],"patientInstruction":"As directed","timing":{"repeat":{"boundsDuration":{"value":10,"unit":"day","system":"http://unitsofmeasure.org","code":"d"},"frequency":5,"period":1,"periodUnit":"d"}},"route":{"coding":[{"system":"http://snomed.info/sct","code":"34206005","display":"Subcutaneous route"}]},"method":{"coding":[{"system":"http://snomed.info/sct","code":"422145002","display":"Inject"}]},"doseAndRate":[{"doseQuantity":{"value":10,"unit":"milligram","system":"http://unitsofmeasure.org","code":"mg"}}]}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"Injection","system":"http://snomed.info/sct","code":"3092611000001103"},"expectedSupplyDuration":{"value":7,"unit":"day","system":"http://unitsofmeasure.org","code":"d"}}}},{"fullUrl":"a48c085d-ca8c-4646-afd3-7a0dae64efd2","resource":{"resourceType":"MedicationRequest","id":"e18131f3-3ac2-41ef-9cde-2639739e80be","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"00db57d1-fd0c-4ae2-8536-6990f31d8ea4"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"http://snomed.info/sct","code":"15517911000001104","display":"Methotrexate 10mg/0.2ml solution for injection pre-filled syringes"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"CDT38E-Y765968-4FG3BQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2020-07-27T12:00:00+00:00","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"10 milligram, Inject, Subcutaneous route, once weekly","additionalInstruction":[{"coding":[{"system":"http://snomed.info/sct","code":"421769005","display":"Follow directions"}]}],"patientInstruction":"As directed","timing":{"repeat":{"boundsDuration":{"value":10,"unit":"day","system":"http://unitsofmeasure.org","code":"d"},"frequency":5,"period":1,"periodUnit":"d"}},"route":{"coding":[{"system":"http://snomed.info/sct","code":"34206005","display":"Subcutaneous route"}]},"method":{"coding":[{"system":"http://snomed.info/sct","code":"422145002","display":"Inject"}]},"doseAndRate":[{"doseQuantity":{"value":10,"unit":"milligram","system":"http://unitsofmeasure.org","code":"mg"}}]}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"Injection","system":"http://snomed.info/sct","code":"3092611000001103"},"expectedSupplyDuration":{"value":7,"unit":"day","system":"http://unitsofmeasure.org","code":"d"}}}},{"fullUrl":"a48c085d-ca8c-4646-afd3-7a0dae64efd2","resource":{"resourceType":"MedicationRequest","id":"e18131f3-3ac2-41ef-9cde-2639739e80be","meta":{"profile":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"]},"identifier":[{"system":"https://fhir.nhs.uk/Id/prescription-order-item-number","value":"00db57d1-fd0c-4ae2-8536-6990f31d8ea4"}],"status":"completed","intent":"order","category":[{"coding":[{"system":"http://terminology.hl7.or/CodeSystem/medicationrequest-category","code":"community","display":"Community"}]}],"medicationCodeableConcept":{"coding":[{"system":"http://snomed.info/sct","code":"15517911000001104","display":"Methotrexate 10mg/0.2ml solution for injection pre-filled syringes"}]},"subject":{"reference":"Patient/9000000009","identifier":{"system":"https://fhir.nhs.uk/Id/nhs-number","value":"9000000009"},"display":"Jane Smith"},"requester":{"reference":"PractitionerRole/e35f0382-ac2e-47f9-9164-afd7d6adf952","display":"Dr Jane Smith"},"basedOn":[{"reference":"MedicationRequest/4de39acf-73b1-4dc6-bb87-c98b57ee5413"}],"groupIdentifier":{"system":"https://fhir.nhs.uk/Id/prescription-order-number","value":"CDT38E-Y765968-4FG3BQ"},"courseOfTherapyType":{"coding":[{"system":"http://terminology.hl7.org/CodeSystem/medicationrequest-course-of-therapy","code":"continuous","display":"Continuous long term therapy"}]},"authoredOn":"2020-07-27T12:00:00+00:00","substitution":{"allowedBoolean":false},"dosageInstruction":[{"text":"10 milligram, Inject, Subcutaneous route, once weekly","additionalInstruction":[{"coding":[{"system":"http://snomed.info/sct","code":"421769005","display":"Follow directions"}]}],"patientInstruction":"As directed","timing":{"repeat":{"boundsDuration":{"value":10,"unit":"day","system":"http://unitsofmeasure.org","code":"d"},"frequency":5,"period":1,"periodUnit":"d"}},"route":{"coding":[{"system":"http://snomed.info/sct","code":"34206005","display":"Subcutaneous route"}]},"method":{"coding":[{"system":"http://snomed.info/sct","code":"422145002","display":"Inject"}]},"doseAndRate":[{"doseQuantity":{"value":10,"unit":"milligram","system":"http://unitsofmeasure.org","code":"mg"}}]}],"dispenseRequest":{"numberOfRepeatsAllowed":6,"quantity":{"value":1,"unit":"Injection","system":"http://snomed.info/sct","code":"3092611000001103"},"expectedSupplyDuration":{"value":7,"unit":"day","system":"http://unitsofmeasure.org","code":"d"}}}}]}}},"parameters":{"BearerAuthorization":{"description":"An [OAuth 2.0 bearer token](https://digital.nhs.uk/developer/guides-and-documentation/security-and-authorisation#user-restricted-apis).\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"Authorization","required":true,"schema":{"example":"Bearer g1112R_ccQ1Ebbb4gtHBP1aaaNM","format":"^Bearer\\ [[:ascii:]]+$","type":"string"},"style":"simple"},"CorrelationID":{"description":"An optional ID which you can use to track transactions across multiple systems. It can have any value, but we recommend avoiding `.` characters.\nMirrored back in a response header.\n","explode":false,"in":"header","name":"X-Correlation-ID","required":false,"schema":{"example":"11C46F5F-CDEF-4865-94B2-0EE0EDCC26DA","type":"string"},"style":"simple"},"RequestID":{"description":"A globally unique identifier (GUID) for the request, which we use to de-duplicate repeated requests and to trace the request if you contact our helpdesk.\nMust be a universally unique identifier (UUID) (ideally version 4).\n\nMirrored back in a response header.\n\nIf you re-send a failed request, use the same value in this header.\n\nRequired in all environments except sandbox.\n","explode":false,"in":"header","name":"X-Request-ID","required":true,"schema":{"example":"60E0B220-8136-4CA5-AE46-1D97EF59D068","pattern":"^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","type":"string"},"style":"simple"}},"schemas":{"MedicationStatementSchema":{"description":"Information surrounding how the MedicationStatement resource is populated can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-MedicationStatement?version=0.1.0-private-beta).","properties":{"resourceType":{"enum":["Bundle"],"type":"string"},"id":{"format":"uuid","type":"string"},"identifier":{"$ref":"#/components/schemas/MedicationStatementSchema_identifier"},"type":{"enum":["searchset"],"type":"string"},"entry":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner"},"type":"array"}},"required":["id","identifier","resourceType","type"],"type":"object"},"SingularMedicationRequestSchema":{"description":"Information surrounding how the MedicationRequest resource is populated can be found [here](https://simplifier.net/guide/gp-connect--patient-facing-services--prescriptions/Home/FHIR-Assets/All-Assets/Profiles/UKCore-MedicationRequest?version=0.1.0-private-beta).","properties":{"resourceType":{"enum":["MedicationRequest"],"type":"string"},"id":{"type":"string"},"meta":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_meta"},"extension":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_extension_inner"},"type":"array"},"identifier":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_identifier_inner"},"type":"array"},"status":{"enum":["active","stopped","completed"],"type":"string"},"intent":{"enum":["plan","order"],"type":"string"},"category":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_category_inner"},"type":"array"},"medicationCodeableConcept":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_medicationCodeableConcept"},"subject":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_subject"},"requester":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_basedOn_inner"},"groupIdentifier":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_groupIdentifier"},"courseOfTherapyType":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_courseOfTherapyType"},"authoredOn":{"format":"date-time","type":"string"},"substitution":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_substitution"},"dosageInstruction":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_dosageInstruction_inner"},"type":"array"}},"required":["authoredOn","category","courseOfTherapyType","dosageInstruction","extension","groupIdentifier","id","identifier","intent","medicationCodeableConcept","meta","requester","resourceType","status","subject","substitution"],"type":"object"},"MedicationStatementSchema_identifier":{"properties":{"system":{"format":"uri","type":"string"},"value":{"type":"string"}},"required":["system","value"],"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_meta":{"properties":{"profile":{"items":{"enum":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationStatement"],"format":"uri","type":"string"},"type":"array"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_extension_inner":{"properties":{"url":{"format":"uri","type":"string"},"valueDateTime":{"format":"date-time","type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_identifier_inner":{"properties":{"system":{"format":"uri","type":"string"},"value":{"type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_basedOn_inner":{"properties":{"reference":{"format":"uri","type":"string"},"display":{"type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_medicationCodeableConcept_coding_inner":{"properties":{"system":{"enum":["https://dmd.nhs.uk"],"format":"uri","type":"string"},"code":{"type":"string"},"display":{"type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_medicationCodeableConcept":{"properties":{"coding":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_medicationCodeableConcept_coding_inner"},"type":"array"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_effectivePeriod":{"properties":{"start":{"format":"date-time","type":"string"},"end":{"format":"date-time","type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_additionalInstruction_inner_coding_inner":{"properties":{"system":{"format":"uri","type":"string"},"code":{"type":"string"},"display":{"type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_additionalInstruction_inner":{"properties":{"coding":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_additionalInstruction_inner_coding_inner"},"type":"array"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_timing_repeat":{"properties":{"frequency":{"minimum":1,"type":"integer"},"period":{"minimum":1,"type":"integer"},"periodUnit":{"enum":["d"],"type":"string"},"when":{"items":{"enum":["C"],"type":"string"},"type":"array"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_timing":{"properties":{"repeat":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_timing_repeat"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_doseAndRate_inner_doseQuantity":{"properties":{"value":{"type":"number"},"unit":{"type":"string"},"system":{"format":"uri","type":"string"},"code":{"type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_doseAndRate_inner":{"properties":{"doseQuantity":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_doseAndRate_inner_doseQuantity"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner":{"properties":{"text":{"type":"string"},"additionalInstruction":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_additionalInstruction_inner"},"type":"array"},"timing":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_timing"},"doseAndRate":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_doseAndRate_inner"},"type":"array"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_resource":{"properties":{"resourceType":{"enum":["MedicationStatement"],"type":"string"},"id":{"format":"uuid","type":"string"},"meta":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_meta"},"extension":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_extension_inner"},"type":"array"},"identifier":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_identifier_inner"},"type":"array"},"basedOn":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_basedOn_inner"},"type":"array"},"status":{"enum":["active","stopped","complete"],"type":"string"},"medicationCodeableConcept":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_medicationCodeableConcept"},"effectivePeriod":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_effectivePeriod"},"dateAsserted":{"format":"date","type":"string"},"dosage":{"items":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner"},"type":"array"}},"required":["basedOn","dateAsserted","dosage","effectivePeriod","id","identifier","medicationCodeableConcept","meta","resourceType","status"],"type":"object"},"MedicationStatementSchema_entry_inner_oneOf":{"properties":{"fullUrl":{"format":"uuid","type":"string"},"resource":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_1_resource":{"properties":{"resourceType":{"enum":["ResourceType"],"type":"string"},"id":{"format":"uuid","type":"string"}},"type":"object"},"MedicationStatementSchema_entry_inner_oneOf_1":{"properties":{"fullUrl":{"format":"uuid","type":"string"},"resource":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_1_resource"}},"type":"object"},"MedicationStatementSchema_entry_inner":{"oneOf":[{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf"},{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_1"}]},"SingularMedicationRequestSchema_meta":{"properties":{"profile":{"items":{"enum":["https://fhir.hl7.org.uk/StructureDefinition/UKCore-MedicationRequest"],"format":"uri","type":"string"},"type":"array"}},"type":"object"},"SingularMedicationRequestSchema_extension_inner_extension_inner":{"properties":{"url":{"format":"uri","type":"string"},"valueUnsignedInt":{"type":"integer"},"valueDateTime":{"format":"date-time","type":"string"}},"type":"object"},"SingularMedicationRequestSchema_extension_inner":{"properties":{"url":{"format":"uri","type":"string"},"extension":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_extension_inner_extension_inner"},"type":"array"}},"type":"object"},"SingularMedicationRequestSchema_identifier_inner":{"properties":{"system":{"format":"uri","type":"string"},"value":{"format":"uuid","type":"string"}},"type":"object"},"SingularMedicationRequestSchema_category_inner_coding_inner":{"properties":{"system":{"enum":["http://terminology.hl7.or/CodeSystem/medicationrequest-category"],"format":"uri","type":"string"},"code":{"enum":["community"],"type":"string"},"display":{"enum":["Community"],"type":"string"}},"type":"object"},"SingularMedicationRequestSchema_category_inner":{"properties":{"coding":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_category_inner_coding_inner"},"type":"array"}},"type":"object"},"SingularMedicationRequestSchema_subject_identifier":{"properties":{"system":{"enum":["https://fhir.nhs.uk/Id/nhs-number"],"format":"uri","type":"string"},"value":{"enum":["9000000009"],"type":"string"}},"type":"object"},"SingularMedicationRequestSchema_subject":{"properties":{"reference":{"enum":["Patient/9000000009"],"format":"uri","type":"string"},"identifier":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_subject_identifier"},"display":{"type":"string"}},"type":"object"},"SingularMedicationRequestSchema_groupIdentifier":{"properties":{"system":{"enum":["https://fhir.nhs.uk/Id/prescription-order-number"],"format":"uri","type":"string"},"value":{"type":"string"}},"type":"object"},"SingularMedicationRequestSchema_courseOfTherapyType_coding_inner":{"properties":{"system":{"enum":["https://fhir.hl7.org.uk/CodeSystem/UKCore-MedicationRequestCourseOfTherapy"],"format":"uri","type":"string"},"code":{"enum":["continuous","acute"],"type":"string"},"display":{"enum":["Continuous long term therapy","Short course (acute) therapy"],"type":"string"}},"type":"object"},"SingularMedicationRequestSchema_courseOfTherapyType":{"properties":{"coding":{"items":{"$ref":"#/components/schemas/SingularMedicationRequestSchema_courseOfTherapyType_coding_inner"},"type":"array"}},"type":"object"},"SingularMedicationRequestSchema_substitution":{"properties":{"allowedBoolean":{"type":"boolean"}},"type":"object"},"SingularMedicationRequestSchema_dosageInstruction_inner":{"properties":{"text":{"type":"string"},"method":{"$ref":"#/components/schemas/MedicationStatementSchema_entry_inner_oneOf_resource_dosage_inner_additionalInstruction_inner"}},"type":"object"}}},"x-spec-publication":{"operation-order":[{"operations":[{"method":"GET","path":"/{id}/MedicationStatement"},{"method":"GET","path":"/MedicationRequest/{id}"},{"method":"GET","path":"/Patient/{id}/MedicationRequest"},{"method":"POST","path":"/Task"},{"method":"GET","path":"/Task"},{"method":"PATCH","path":"/Task"},{"method":"GET","path":"/PractionerRole/{id}"}]}]}}