visit the hl7 website
Provincial Client Registry (PCR) HL7 FHIR® Contribution Implementation Guide v1.0.0-draft1
fhir-logo
  • Index
  • Home
    • Home
    • Introduction
    • Relationship to other Specifications
    • Scope
    • Glossary
  • Business Context
    • Business Context
    • Business Model
    • Business Data
    • Use Cases
    • Business Rules
    • Contribution Models
  • Technical Context
    • Technical Context
    • Implementer Responsibility
    • Conformance Rules
    • Connectivity Summary
  • FHIR Artifacts
    • FHIR Artifacts
    • Interactions
    • Operations
    • Profiles
    • Terminology
    • System URIs
    • Examples
    • Capability Statement
    • Response Handling
    • Downloads
  • Change Log
    • Change Log
    • Known Issues & Future Developments
    • Revision History
    1. Index
    2. FHIR Artifacts
    3. Operations
    4. Patient Unmerge

For a full list of available versions, see the Directory of published versions

4.2.2. Patient Unmerge

Patient Unmerge provides a RESTful approach to separating managed patient identities within PCR that were previously merged and have subsequently been determined to represent different individuals. In a Patient Unmerge request, the patient identities and associated merge relationships to be reversed are provided to PCR, which validates the request and evaluates the proposed unmerge using identity management, source authority, governance, and stewardship rules. PCR assesses the historical merge relationships and determines how the affected patient identities should be restored while applying established identity management policies.

4.2.2.1. Usage

In the PCR Patient Unmerge operation, the request must contain a Parameters resource that identifies the managed patient identities to be separated and the merge relationships to be removed. PCR evaluates the unmerge request to ensure it complies with approved governance controls, stewardship requirements, and identity management policies. Upon successful validation, PCR restores the affected managed patient identities, re-establishes the appropriate identity relationships, preserves source contributions, lineage, and audit history, and maintains traceability of the unmerge action in accordance with established policies. The result is the accurate representation of distinct patient identities while maintaining a trusted, governed, and auditable patient registry that supports reliable patient identification across connected healthcare organizations.

POST: Patient Unmerge

Actor: Contributor
Role: Submits a Patient Unmerge operation request to the PCR.

Actor: PCR Role: Receives, authenticates, validates, and unmerges patients.

4.2.2.2. Specification

Patient Unmerge Request

Patient Unmerge Input Parameters

The update interaction is performed by an HTTP POST command as shown:

POST [base-submit]/Patient/$unmerge

Patient Unmerge Response

Patient Unmerge Output Parameters

Example Patient Unmerge Request

HTTP Method:

POST

Headers:

Content-Type: application/fhir+json

Address:

[base-submit]/Patient/$unmerge

Message Body:

{
"resourceType": "Parameters",
"id": "parameters-unmerge-input-example",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/profile-parameters-unmerge-input"
]
},
"parameter": [
{
"name": "merged-patient",
"valueReference": {
"reference": "Patient/patient-contribution-merged-example"
}
},
{
"name": "restore-patient",
"valueReference": {
"reference": "Patient/patient-contribution-source-example"
}
},
{
"name": "prior-merge-id",
"valueIdentifier": {
"system": "https://ehealthontario.ca/fhir/NamingSystem/pcr-merge-event-id",
"value": "MERGE-20260806-00001"
}
},
{
"name": "unmerge-reason",
"valueCodeableConcept": {
"coding": [
{
"system": "https://ehealthontario.ca/fhir/CodeSystem/pcr-unmerge-reason",
"code": "incorrect-merge",
"display": "Incorrect Merge"
}
],
"text": "Prior merge was determined to be incorrect following governed identity review."
}
},
{
"name": "unmerge-requester",
"valueIdentifier": {
"system": "https://hospital.example.ca/user-id",
"value": "USER12345"
}
}
]
}

Response Body:

{
"resourceType": "Parameters",
"id": "parameters-unmerge-output-example",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/profile-parameters-unmerge-output"
]
},
"parameter": [
{
"name": "input",
"resource": {
"resourceType": "Parameters",
"id": "parameters-unmerge-input-example",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/profile-parameters-unmerge-input"
]
},
"parameter": [
{
"name": "merged-patient",
"valueReference": {
"reference": "Patient/patient-contribution-merged-example"
}
},
{
"name": "restore-patient",
"valueReference": {
"reference": "Patient/patient-contribution-source-example"
}
},
{
"name": "prior-merge-id",
"valueIdentifier": {
"system": "https://ehealthontario.ca/fhir/NamingSystem/pcr-merge-event-id",
"value": "MERGE-20260806-00001"
}
},
{
"name": "unmerge-reason",
"valueCodeableConcept": {
"coding": [
{
"system": "https://ehealthontario.ca/fhir/CodeSystem/pcr-unmerge-reason",
"code": "incorrect-merge",
"display": "Incorrect Merge"
}
],
"text": "Prior merge was determined to be incorrect following governed identity review."
}
},
{
"name": "unmerge-requester",
"valueIdentifier": {
"system": "https://hospital.example.ca/user-id",
"value": "USER12345"
}
}
]
}
},
{
"name": "operation-outcome",
"resource": {
"resourceType": "OperationOutcome",
"id": "operationoutcome-example-success",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/pcr-operationoutcome-contribution"
]
},
"issue": [
{
"severity": "information",
"code": "informational",
"details": {
"text": "Prior merge MERGE-20260806-00001 was reversed. Patient/patient-contribution-source-example was restored and Patient/patient-contribution-target-example remains active as a separate identity."
}
}
]
}
},
{
"name": "retained-patient-result",
"resource": {
"resourceType": "Patient",
"id": "patient-contribution-target-example",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/profile-patient-contribution"
]
},
"identifier": [
{
"type": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0203",
"code": "MR"
}
]
},
"system": "https://hospital.example.ca/mrn",
"value": "MRN999999"
}
],
"active": true,
"name": [
{
"use": "official",
"family": "Smith",
"given": [
"Michael",
"John"
],
"_given": [
{
"extension": [
{
"url": "http://hl7.org/fhir/StructureDefinition/iso21090-EN-qualifier",
"valueCode": "MID"
}
]
},
null
]
}
],
"gender": "male",
"birthDate": "1985-06-15",
"address": [
{
"use": "home",
"type": "postal",
"line": [
"100 Main Street"
],
"city": "Toronto",
"state": "ON",
"postalCode": "M5V2T6",
"country": "CAN"
}
]
}
},
{
"name": "restored-patient-result",
"resource": {
"resourceType": "Patient",
"id": "patient-contribution-source-example",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/profile-patient-contribution"
]
},
"identifier": [
{
"type": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0203",
"code": "MR"
}
]
},
"system": "https://hospital.example.ca/mrn",
"value": "MRN123456"
}
],
"active": true,
"name": [
{
"use": "official",
"family": "Smith",
"given": [
"Michael",
"John"
],
"_given": [
{
"extension": [
{
"url": "http://hl7.org/fhir/StructureDefinition/iso21090-EN-qualifier",
"valueCode": "MID"
}
]
},
null
]
}
],
"gender": "male",
"birthDate": "1985-06-15",
"address": [
{
"use": "home",
"type": "postal",
"line": [
"100 Main Street"
],
"city": "Toronto",
"state": "ON",
"postalCode": "M5V2T6",
"country": "CAN"
}
]
}
}
]
}

Example Validation Failure HTTP Response: 400 Bad Request

Message Body:

{
"resourceType": "OperationOutcome",
"id": "operationoutcome-example-unmerge-error",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/pcr-operationoutcome-contribution"
]
},
"issue": [
{
"severity": "error",
"code": "required",
"details": {
"text": "merged-patient, restore-patient, and prior-merge-id are required for an unmerge request."
},
"expression": [
"Parameters.parameter.where(name = 'merged-patient')",
"Parameters.parameter.where(name = 'restore-patient')",
"Parameters.parameter.where(name = 'prior-merge-id')"
]
}
]
}

Example Patient Not Found HTTP Response: 404 Not Found

Message Body:

{
"resourceType": "OperationOutcome",
"id": "operationoutcome-example-notfound",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/pcr-operationoutcome-contribution"
]
},
"issue": [
{
"severity": "error",
"code": "not-found",
"details": {
"text": "No Patient resource was found for id 987654."
},
"expression": [
"Patient.id"
]
}
]
}

Example Business-Rule Conflict HTTP Response: 409 Conflict

Message Body:

{
"resourceType": "OperationOutcome",
"id": "operationoutcome-example-unmerge-conflict",
"meta": {
"profile": [
"http://ontariohealth.ca/fhir/pcr/StructureDefinition/pcr-operationoutcome-contribution"
]
},
"issue": [
{
"severity": "error",
"code": "business-rule",
"details": {
"text": "The requested unmerge cannot be completed because the prior merge event is not eligible for reversal under PCR governance rules."
}
}
]
}

4.2.2.3. Supported Profiles

Patient Unmerge Input Parameters

Patient Unmerge Output Parameters

4.2.2.4. Expected Behavior

Outcome Header HTTP Response Payload OperationOutcome Expected Handling
Unmerge completed 200 OK Yes Return unmerge status, retained patient reference, restored patient reference, and optional informational OperationOutcome.
Unmerge accepted for review 202 Accepted Yes
Validation failure 400 Bad Request Yes Return computable validation details when required unmerge inputs are missing or malformed.
Merge relationship not found 404 Not Found Yes Indicate that the prior merge event or referenced Patient record could not be resolved.
Unauthorized 401 Unauthorized or 403 Forbidden No
Governance or identity conflict 409 Conflict No Indicate that PCR unmerge governance rules prevent the requested reversal.
Service failure 5xx Server Error No
Version: 1.0.0 FHIR Version: R4.0.1

Powered by SIMPLIFIER.NET

HL7® and FHIR® are the registered trademarks of Health Level Seven International