{
  "resourceType" : "Provenance",
  "meta" : {
    "source" : "https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D",
    "profile" : ["https://fhir-ig.digital.health.nz/shared-care/StructureDefinition/OutpatientProvenance"],
    "tag" : [{
      "system" : "https://hub.services.digital.health.nz/ns/correlation-id",
      "code" : "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
    }]
  },
  "text" : {
    "status" : "generated",
    "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Generated Narrative: Provenance DHOProvenanceNhiMergeExample</b></p><a name=\"DHOProvenanceNhiMergeExample\"> </a><a name=\"hcDHOProvenanceNhiMergeExample\"> </a><div style=\"display: inline-block; background-color: #d9e0e7; padding: 6px; margin: 4px; border: 1px solid #8da1b4; border-radius: 5px; line-height: 60%\"><p style=\"margin-bottom: 0px\"/><p style=\"margin-bottom: 0px\">Information Source: <a href=\"https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D\">https://standards.digital.health.nz/ns/hpi-facility-id/F04066-D</a></p><p style=\"margin-bottom: 0px\">Profile: <a href=\"StructureDefinition-OutpatientProvenance.html\">DHO Provenance Profile</a></p><p style=\"margin-bottom: 0px\">Tag: </p></div><p>Provenance for <a href=\"Encounter-dho-outpatient-encounter-instance.html\">Encounter: status = arrived; class = Ambulatory (ActCode#AMB); serviceType = Outpatients; period = 2025-09-03 02:30:35+0000 --&gt; (ongoing)</a></p><p>Summary</p><table class=\"grid\"><tr><td>Recorded</td><td>2026-06-25 16:55:00+0000</td></tr><tr><td>Activity</td><td><span title=\"Codes:{http://terminology.hl7.org/CodeSystem/v3-DataOperation UPDATE}\">revise</span></td></tr></table><p><b>Agents</b></p><table class=\"grid\"><tr><td><b>Type</b></td><td><b>who</b></td></tr><tr><td><span title=\"Codes:{http://terminology.hl7.org/CodeSystem/provenance-participant-type transmitter}\">transmitter</span></td><td>Dunedin Hospital (Identifier: <a href=\"http://fhir.org.nz/ig/base/NamingSystem-hpiFacility.html\" title=\"HPI facilities\">HPIFacility</a>/F04066-D)</td></tr></table></div>"
  },
  "target" : [{
    "reference" : "Encounter/dho-outpatient-encounter-instance"
  }],
  "recorded" : "2026-06-25T16:55:00Z",
  "reason" : [{
    "coding" : [{
      "system" : "https://fhir-ig.digital.health.nz/shared-care/CodeSystem/provenance-reason-type-cs",
      "code" : "nhi-merge",
      "display" : "NHI Merge"
    }]
  }],
  "activity" : {
    "coding" : [{
      "system" : "http://terminology.hl7.org/CodeSystem/v3-DataOperation",
      "code" : "UPDATE",
      "display" : "revise"
    }]
  },
  "agent" : [{
    "type" : {
      "coding" : [{
        "system" : "http://terminology.hl7.org/CodeSystem/provenance-participant-type",
        "code" : "transmitter"
      }]
    },
    "who" : {
      "identifier" : {
        "system" : "https://standards.digital.health.nz/ns/hpi-facility-id",
        "value" : "F04066-D"
      },
      "display" : "Dunedin Hospital"
    }
  }],
  "entity" : [{
    "role" : "removal",
    "what" : {
      "type" : "Patient",
      "identifier" : {
        "use" : "official",
        "system" : "https://standards.digital.health.nz/ns/nhi-id",
        "value" : "ZAC7823"
      },
      "display" : "John Smith"
    }
  },
  {
    "role" : "derivation",
    "what" : {
      "type" : "Patient",
      "identifier" : {
        "use" : "official",
        "system" : "https://standards.digital.health.nz/ns/nhi-id",
        "value" : "XYZ6789"
      },
      "display" : "John Smith"
    }
  }]
}