Library

Browse and search developer information

A014: Reject Referral

API

Request Type: POST

URL: https://mhsin.{{env}}.ers.ncrs.nhs.uk/ers-api/v1/ReferralRequest/{{UBRN}}/$ers.reject

 

Description

This API lets the professional user reject the Referral with reject reason and comment.

Input

Header: Provide ASID for the end-point system, Session Key and VersionId.

Example

XAPI_ASID:200000000220

HTTP_X_SESSION_KEY:{{sessionKey}}

Accept:application/json+fhir

If-Match: W/”n”

 

Note: n is the VersionId of the Referral and this can be retrieved by fetching the Referral details.

 

Body: Provide reject details such as reject reason and reject comment.

Example

 {
 "resourceType": "Parameters",
 "meta": {
        "versionId": "1",
        "profile": ["http://fhir.nhs.net/OperationDefinition/ers-rejectreferral-operation-1"]
    },
 "parameter": [
   {
     "name": "reason",
     "valueString": "OTHER"
   },
    {
     "name": "comment",
     "valueString": "Test"
    }
 ]
}

 

Output

If successful the referral is rejected. The response code 200 (OK) is returned. This response has no body.

Code Sample

Refer to ‘API Client Demonstrator tool’ Source code