Patsientide üldandmete teenus / Master Patient Index
1.0.0 - ballot Estonia flag

Patsientide üldandmete teenus / Master Patient Index - Local Development build (v1.0.0). See the Directory of published versions

OperationDefinition: patient-link

Official URL: https://fhir.ee/OperationDefinition/patient-link Version: 1.0.0
Standards status: Trial-use Maturity Level: 1 Computable Name: EEMPIPatientLink

The link operation is used to link two patient resources. One of the two patients is identified as the source and one as the target. The link with type ‘replaces’ created from source to destination patient, the another link with type ‘replaced-byä created from destination to source patient. As result of linking the destination patient is deactivated.

URL: [base]/Patient/$link

Parameters

UseNameScopeCardinalityTypeBindingDocumentation
INsource-patient0..1Reference

A direct resource reference to the source patient resource (this may include an identifier).

INsource-patient-identifier0..*Identifier

When source-patient-identifiers are provided, the server is expected to perform an internal lookup to identify the source patient record. The server SHALL reject the request if the provided identifiers do not resolve to a single patient record. This resolution MAY occur asynchronously, for example, as part of a review by a user.

INtarget-patient0..1Reference

A direct resource reference to the target patient resource.

This is the surviving patient resource, the target for the link.

INtarget-patient-identifier0..*Identifier

When target-patient-identifiers are provided, the server is expected to perform an internal lookup to identify the target patient record. The server SHALL reject the request if the provided identifiers do not resolve to a single patient record. This resolution MAY occur asynchronously, for example, as part of a review by a user.

OUTreturn1..1Patient

The status of the response will be one of:

  • 200 OK - If the merge request doesn't expect any issues (although warning may be present) for a preview, or was completed without issues if not a preview
  • 202 Accepted - The merge request has been accepted and does not expect any issues and will continue processing the merge in the background, and you can monitor the Task for completion
  • 400 Bad Request - There are errors in the input parameters that need to corrected
  • 422 Unprocessable Entity - Business rules prevent this merge from completing

The Parameters resource will include:

  • The Input parameters to the operation
  • An OperationOutcome containing errors, warnings, and information messages
  • The resulting merged Patient resource (or a patient reference if the patient is not committed)
  • Optionally a Task resource to track any additional processing that was required.