OperationDefinition-CDR-DocumentReference-Revoke

Overview

Revokes an identified DocumentReference. The operation may be invoked at either the DocumentReference type level, with the target DocumentReference identified using the documentIdentifier input parameter, or at the instance level, with the target DocumentReference identified by the logical id in the request URL.

On successful execution, the CDR patches the current version of the focus DocumentReference. The CDR sets meta.lastUpdated to the supplied timestamp, or to the date and time at which the operation is processed if timestamp is not supplied, sets status to entered-in-error, and updates the meta tag with system errorstatus to code revoked and display Revoked. When invoked at the type level, documentIdentifier may be supplied to identify the target DocumentReference by business identifier. When invoked at the instance level, documentIdentifier SHALL NOT be supplied because the target DocumentReference is identified by the logical id in the request URL.

Formal Views of Operation Content

OperationDefinition
OperationDefinition.id[0]CDR-DocumentReference-Revoke
OperationDefinition.url[0]https://fhir.nhs.wales/OperationDefinition/CDR-DocumentReference-Revoke
OperationDefinition.version[0]0.1
OperationDefinition.name[0]CDRDocumentReferenceRevoke
OperationDefinition.title[0]CDR Revoke DocumentReference
OperationDefinition.status[0]draft
OperationDefinition.kind[0]operation
OperationDefinition.description[0]Revokes an identified DocumentReference. The operation may be invoked at either the DocumentReference type level, with the target DocumentReference identified using the documentIdentifier input parameter, or at the instance level, with the target DocumentReference identified by the logical id in the request URL.
OperationDefinition.affectsState[0]True
OperationDefinition.code[0]revoke
OperationDefinition.comment[0]On successful execution, the CDR patches the current version of the focus DocumentReference. The CDR sets meta.lastUpdated to the supplied timestamp, or to the date and time at which the operation is processed if timestamp is not supplied, sets status to entered-in-error, and updates the meta tag with system errorstatus to code revoked and display Revoked. When invoked at the type level, documentIdentifier may be supplied to identify the target DocumentReference by business identifier. When invoked at the instance level, documentIdentifier SHALL NOT be supplied because the target DocumentReference is identified by the logical id in the request URL.
OperationDefinition.resource[0]DocumentReference
OperationDefinition.system[0]False
OperationDefinition.type[0]True
OperationDefinition.instance[0]True
OperationDefinition.parameter[0].name[0]documentIdentifier
OperationDefinition.parameter[0].use[0]in
OperationDefinition.parameter[0].min[0]0
OperationDefinition.parameter[0].max[0]1
OperationDefinition.parameter[0].documentation[0]The business identifier of the DocumentReference to be revoked. This parameter may be supplied when the operation is invoked at the DocumentReference type level. It SHALL NOT be supplied when the operation is invoked at the instance level because the target DocumentReference is identified by the logical id in the request URL. The server searches DocumentReference.identifier using both Identifier.system and Identifier.value. If no matching DocumentReference exists, or if the identifier does not resolve unambiguously to a single DocumentReference, the server returns an error.
OperationDefinition.parameter[0].type[0]Identifier
OperationDefinition.parameter[1].name[0]source
OperationDefinition.parameter[1].use[0]in
OperationDefinition.parameter[1].min[0]1
OperationDefinition.parameter[1].max[0]1
OperationDefinition.parameter[1].documentation[0]The source Device from which the operation request originated. The CDR uses a business identifier of type applicationInstanceId provided in Device.identifier to determine if the Device already exists. If no matching Device record exists, the server will return an error.
OperationDefinition.parameter[1].type[0]Device
OperationDefinition.parameter[2].name[0]timestamp
OperationDefinition.parameter[2].use[0]in
OperationDefinition.parameter[2].min[0]0
OperationDefinition.parameter[2].max[0]1
OperationDefinition.parameter[2].documentation[0]The date and time at which the DocumentReference was revoked. If not supplied, the server uses the date and time at which the operation is processed.
OperationDefinition.parameter[2].type[0]dateTime
OperationDefinition.parameter[3].name[0]revoker
OperationDefinition.parameter[3].use[0]in
OperationDefinition.parameter[3].min[0]1
OperationDefinition.parameter[3].max[0]1
OperationDefinition.parameter[3].documentation[0]The Practitioner revoking the DocumentReference. The CDR uses the business identifier provided in Practitioner.identifier to determine whether the Practitioner already exists. If no matching Practitioner record exists, the server will return an error.
OperationDefinition.parameter[3].type[0]Practitioner
OperationDefinition.parameter[4].name[0]revocationReason
OperationDefinition.parameter[4].use[0]in
OperationDefinition.parameter[4].min[0]1
OperationDefinition.parameter[4].max[0]1
OperationDefinition.parameter[4].documentation[0]The reason the DocumentReference is being revoked.
OperationDefinition.parameter[4].type[0]string
<OperationDefinition xmlns="http://hl7.org/fhir">
<id value="CDR-DocumentReference-Revoke" />
<url value="https://fhir.nhs.wales/OperationDefinition/CDR-DocumentReference-Revoke" />
<version value="0.1" />
<name value="CDRDocumentReferenceRevoke" />
<title value="CDR Revoke DocumentReference" />
<status value="draft" />
<kind value="operation" />
<description value="Revokes an identified DocumentReference. The operation may be invoked at either the DocumentReference type level, with the target DocumentReference identified using the documentIdentifier input parameter, or at the instance level, with the target DocumentReference identified by the logical id in the request URL." />
<affectsState value="true" />
<code value="revoke" />
<comment value="On successful execution, the CDR patches the current version of the focus DocumentReference. The CDR sets meta.lastUpdated to the supplied timestamp, or to the date and time at which the operation is processed if timestamp is not supplied, sets status to entered-in-error, and updates the meta tag with system errorstatus to code revoked and display Revoked. When invoked at the type level, documentIdentifier may be supplied to identify the target DocumentReference by business identifier. When invoked at the instance level, documentIdentifier SHALL NOT be supplied because the target DocumentReference is identified by the logical id in the request URL." />
<resource value="DocumentReference" />
<system value="false" />
<type value="true" />
<instance value="true" />
<name value="documentIdentifier" />
<use value="in" />
<min value="0" />
<max value="1" />
<documentation value="The business identifier of the DocumentReference to be revoked. This parameter may be supplied when the operation is invoked at the DocumentReference type level. It SHALL NOT be supplied when the operation is invoked at the instance level because the target DocumentReference is identified by the logical id in the request URL. The server searches DocumentReference.identifier using both Identifier.system and Identifier.value. If no matching DocumentReference exists, or if the identifier does not resolve unambiguously to a single DocumentReference, the server returns an error." />
<type value="Identifier" />
</parameter>
<name value="source" />
<use value="in" />
<min value="1" />
<max value="1" />
<documentation value="The source Device from which the operation request originated. The CDR uses a business identifier of type applicationInstanceId provided in Device.identifier to determine if the Device already exists. If no matching Device record exists, the server will return an error." />
<type value="Device" />
</parameter>
<name value="timestamp" />
<use value="in" />
<min value="0" />
<max value="1" />
<documentation value="The date and time at which the DocumentReference was revoked. If not supplied, the server uses the date and time at which the operation is processed." />
<type value="dateTime" />
</parameter>
<name value="revoker" />
<use value="in" />
<min value="1" />
<max value="1" />
<documentation value="The Practitioner revoking the DocumentReference. The CDR uses the business identifier provided in Practitioner.identifier to determine whether the Practitioner already exists. If no matching Practitioner record exists, the server will return an error." />
<type value="Practitioner" />
</parameter>
<name value="revocationReason" />
<use value="in" />
<min value="1" />
<max value="1" />
<documentation value="The reason the DocumentReference is being revoked." />
<type value="string" />
</parameter>
</OperationDefinition>
{
"resourceType": "OperationDefinition",
"id": "CDR-DocumentReference-Revoke",
"url": "https://fhir.nhs.wales/OperationDefinition/CDR-DocumentReference-Revoke",
"version": "0.1",
"name": "CDRDocumentReferenceRevoke",
"title": "CDR Revoke DocumentReference",
"status": "draft",
"kind": "operation",
"description": "Revokes an identified DocumentReference. The operation may be invoked at either the DocumentReference type level, with the target DocumentReference identified using the documentIdentifier input parameter, or at the instance level, with the target DocumentReference identified by the logical id in the request URL.",
"affectsState": true,
"code": "revoke",
"comment": "On successful execution, the CDR patches the current version of the focus DocumentReference. The CDR sets meta.lastUpdated to the supplied timestamp, or to the date and time at which the operation is processed if timestamp is not supplied, sets status to entered-in-error, and updates the meta tag with system errorstatus to code revoked and display Revoked. When invoked at the type level, documentIdentifier may be supplied to identify the target DocumentReference by business identifier. When invoked at the instance level, documentIdentifier SHALL NOT be supplied because the target DocumentReference is identified by the logical id in the request URL.",
"DocumentReference"
],
"system": false,
"type": true,
"instance": true,
{
"name": "documentIdentifier",
"use": "in",
"min": 0,
"max": "1",
"documentation": "The business identifier of the DocumentReference to be revoked. This parameter may be supplied when the operation is invoked at the DocumentReference type level. It SHALL NOT be supplied when the operation is invoked at the instance level because the target DocumentReference is identified by the logical id in the request URL. The server searches DocumentReference.identifier using both Identifier.system and Identifier.value. If no matching DocumentReference exists, or if the identifier does not resolve unambiguously to a single DocumentReference, the server returns an error.",
"type": "Identifier"
},
{
"name": "source",
"use": "in",
"min": 1,
"max": "1",
"documentation": "The source Device from which the operation request originated. The CDR uses a business identifier of type applicationInstanceId provided in Device.identifier to determine if the Device already exists. If no matching Device record exists, the server will return an error.",
"type": "Device"
},
{
"name": "timestamp",
"use": "in",
"min": 0,
"max": "1",
"documentation": "The date and time at which the DocumentReference was revoked. If not supplied, the server uses the date and time at which the operation is processed.",
"type": "dateTime"
},
{
"name": "revoker",
"use": "in",
"min": 1,
"max": "1",
"documentation": "The Practitioner revoking the DocumentReference. The CDR uses the business identifier provided in Practitioner.identifier to determine whether the Practitioner already exists. If no matching Practitioner record exists, the server will return an error.",
"type": "Practitioner"
},
{
"name": "revocationReason",
"use": "in",
"min": 1,
"max": "1",
"documentation": "The reason the DocumentReference is being revoked.",
"type": "string"
}
]
}

Example FHIR Resources