Skip to main content
POST/transactional-api/update-scr-consent

Update Summary Care Record Consent

Sets the patient's consent preference for their Summary Care Record and pushes the change to Spine. User-restricted only: the calling staff member must have a CIS2 identity with the B0020 (Control Consent Status) RBAC activity code.

Authorization: Bearer token (JWT). See Authentication.

Request​

curl -L -X POST 'https://{tenantId}.api.england.medicus.health/transactional-api/update-scr-consent' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <token>' \
-d '{
"patientId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"consentPreference": "773051000000102",
"reason": "Patient requested at consultation"
}'

Body parameters

FieldTypeRequiredDescription
patientIdstring<uuid>YesMedicus patient identifier.
consentPreferenceenumYesSNOMED CT concept id for the patient's new Summary Care Record consent preference. One of: 773031000000109, 773051000000102, 777441000000102.
reasonstring (nullable)NoOptional free-text reason for the change, recorded on the care record note.

Responses​

200 Consent preference updated.

Response fields

FieldTypeDescription
noteIdstring<uuid>
{
"noteId": "b3d1f7a2-6c4e-4b9a-8e0f-1a2b3c4d5e02"
}
400 Validation error.
5 possible code values
CodeDescriptionWhen
missing-patient-idThe patientId is required.patientId is blank
invalid-patient-idThe patientId is not valid.patientId is not a valid UUID
patient-not-foundPatient not found for this patientIdpatientId doesn't correspond to a patient
missing-consent-preferenceThe consentPreference is required.consentPreference is blank
invalid-consent-preferenceThe consentPreference must be one of the supported values.consentPreference is not one of the supported SNOMED CT concept ids

Response fields

FieldTypeDescription
errors[].codestring
errors[].descriptionstring
{
"errors": [
{
"code": "missing-patient-id",
"description": "The patientId is required."
}
]
}
403 The calling staff member cannot be authorised for this action.
3 possible code values
CodeDescriptionWhen
cis2-not-logged-inThis staff member is not currently logged in with CIS2. They must log in with CIS2 and try again.the calling staff member is not currently logged in with CIS2 (never logged in, or their session has lapsed and could not be refreshed)
cis2-activity-not-grantedThis staff member's CIS2 role does not have the RBAC activity code required.the calling staff member's CIS2 role lacks the required RBAC activity code
application-restricted-not-supportedThis endpoint is only available to user-restricted callers.the call is application-restricted rather than user-restricted

Response fields

FieldTypeDescription
errors[].codestring
errors[].descriptionstring
{
"errors": [
{
"code": "cis2-not-logged-in",
"description": "This staff member is not currently logged in with CIS2. They must log in with CIS2 and try again."
}
]
}