Remove RA Record
‘Remove RA Record’ is an extended operation to efficiently close all active Reasonable Adjustment resources for a Patient.
In FHIR, the extended operations paradigm is defined at Operations. Each operation is specified via an instance of an operationDefinion resource.
Here:
operation name | removerarecord |
context | server |
parameters | NHSNumber, RemovalReason, SupportingComment |
‘server’ context entails operation execution is invoked at the FHIR Server baseURL. Invocation syntax, in this case, specifies POST to the baseURL, the operation called by name with $ suffix
Remove RA Record Invocation
Remove RA Record operation can be invoked directly or can be triggered by removal of Consent (to record Reasonable Adjustment information).
http request
POST https://clinicals.spineservices.nhs.uk/STU3/$removerarecord /HTTP1.1
body
The operation request body is a multi-part Parameter resource, containing the NHS Number of the Patient requiring their Reasonable Adjustment Flag removed, and a RemovalReason and supporting comment
Examples of this operation interaction are available at Remove RA Record
Remove RA Record Interaction
Interaction diagram outlining:
- operation request and ‘in’ parameters.
- pseudocode description of server-side actions (happy-path)
- operation response
$removerarecord
(In pseudocode:)
GET Flags WHERE
subject=[NHS#]
status=active
category=RAFlag
Foreach Flag in searchset,
Update status=>inactive & removalReason=>[RemovalReason & SupportingComment]
GET Consent WHERE
subject=[NHS#]
status=active
category=RAFlag
Foreach Consent in searchset,
Update status=>inactive & removalReason=>[RemovalReason & SupportingComment]
GET List WHERE
subject=[NHS#]
status=current
category=[RAFlagCode]
Foreach Condition on List,
Update Condition.clinicalstatus=>inactive &
Update List.entry.deleted=>true
Update List.status=>inactive
OperationDefinition
The OperationDefinition of removerarecord defines the in and out parameters for this operation and their structure and content.