<?xml version="1.0" encoding="UTF-8"?>

<CodeSystem xmlns="http://hl7.org/fhir">
  <id value="hnz-global-opt-out-reason"/>
  <meta>
    <versionId value="1"/>
  </meta>
  <text>
    <status value="generated"/><div xmlns="http://www.w3.org/1999/xhtml"><p class="res-header-id"><b>Generated Narrative: CodeSystem hnz-global-opt-out-reason</b></p><a name="hnz-global-opt-out-reason"> </a><a name="hchnz-global-opt-out-reason"> </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">version: 1</p></div><p>This  code system <code>https://fhir-ig.digital.health.nz/sdhr/CodeSystem/hnz-global-opt-out-reason</code> defines the following codes:</p><table class="codes"><tr><td style="white-space:nowrap"><b>Code</b></td><td><b>Display</b></td><td><b>Definition</b></td></tr><tr><td style="white-space:nowrap">patient-choice<a name="hnz-global-opt-out-reason-patient-choice"> </a></td><td>Patient choice</td><td>Global opt-off was recorded based on patient choice.</td></tr><tr><td style="white-space:nowrap">patient-deceased<a name="hnz-global-opt-out-reason-patient-deceased"> </a></td><td>Patient deceased</td><td>Global opt-off was recorded because the patient is deceased.</td></tr><tr><td style="white-space:nowrap">imported-external-consent<a name="hnz-global-opt-out-reason-imported-external-consent"> </a></td><td>Imported external consent</td><td>Global opt-off was imported from an external consent source.</td></tr></table></div>
  </text>
  <url value="https://fhir-ig.digital.health.nz/sdhr/CodeSystem/hnz-global-opt-out-reason"/>
  <version value="1.1.4"/>
  <name value="HNZGlobalOptOutReason"/>
  <title value="HNZ Global Opt Out Reason Codes"/>
  <status value="active"/>
  <experimental value="false"/>
  <date value="2026-09-21T23:47:20+00:00"/>
  <publisher value="Health New Zealand"/>
  <contact>
    <name value="Health New Zealand"/>
    <telecom>
      <system value="url"/>
      <value value="https://github.com/tewhatuora"/>
    </telecom>
  </contact>
  <contact>
    <name value="HNZ Integration Team"/>
    <telecom>
      <system value="email"/>
      <value value="integration@tewhatuora.govt.nz"/>
      <use value="work"/>
    </telecom>
  </contact>
  <description value="This code system defines the reasons for an HNZ global opt-off decision."/>
  <content value="complete"/>
  <count value="3"/>
  <concept>
    <code value="patient-choice"/>
    <display value="Patient choice"/>
    <definition value="Global opt-off was recorded based on patient choice."/>
  </concept>
  <concept>
    <code value="patient-deceased"/>
    <display value="Patient deceased"/>
    <definition value="Global opt-off was recorded because the patient is deceased."/>
  </concept>
  <concept>
    <code value="imported-external-consent"/>
    <display value="Imported external consent"/>
    <definition value="Global opt-off was imported from an external consent source."/>
  </concept>
</CodeSystem>