<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="DataStandardsWales-DiagnosticReport-Lab" />
  <url value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-DiagnosticReport-Lab" />
  <version value="0.2.0" />
  <name value="DataStandardsWalesDiagnosticReportLab" />
  <title value="Data Standards Wales Diagnostic Report - Lab" />
  <status value="draft" />
  <experimental value="false" />
  <date value="2026-02-26" />
  <publisher value="NHS Wales" />
  <copyright value="2026 NHS Wales." />
  <fhirVersion value="4.0.1" />
  <kind value="resource" />
  <abstract value="false" />
  <type value="DiagnosticReport" />
  <baseDefinition value="https://fhir.hl7.org.uk/StructureDefinition/UKCore-DiagnosticReport" />
  <derivation value="constraint" />
  <differential>
    <element id="DiagnosticReport.identifier">
      <path value="DiagnosticReport.identifier" />
      <mustSupport value="true" />
    </element>
    <element id="DiagnosticReport.basedOn">
      <path value="DiagnosticReport.basedOn" />
      <type>
        <code value="Reference" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/CarePlan" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/NutritionOrder" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-MedicationRequest" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-ServiceRequest" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-ImmunizationRecommendation" />
      </type>
    </element>
    <element id="DiagnosticReport.category">
      <path value="DiagnosticReport.category" />
      <min value="1" />
    </element>
    <element id="DiagnosticReport.category.coding:laboratory">
      <path value="DiagnosticReport.category.coding" />
      <sliceName value="laboratory" />
      <min value="1" />
      <max value="1" />
      <fixedCoding>
        <system value="http://terminology.hl7.org/CodeSystem/v2-0074" />
        <code value="LAB" />
        <display value="Laboratory" />
      </fixedCoding>
      <mustSupport value="true" />
    </element>
    <element id="DiagnosticReport.subject">
      <path value="DiagnosticReport.subject" />
      <short value="The subject of the report - which is always a patient for Laboratory Reports" />
      <definition value="The subject of the report - which is always a patient for Laboratory Reports." />
      <min value="1" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Patient" />
      </type>
    </element>
    <element id="DiagnosticReport.encounter">
      <path value="DiagnosticReport.encounter" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Encounter" />
      </type>
    </element>
    <element id="DiagnosticReport.effective[x]">
      <path value="DiagnosticReport.effective[x]" />
      <mustSupport value="true" />
    </element>
    <element id="DiagnosticReport.performer">
      <path value="DiagnosticReport.performer" />
      <type>
        <code value="Reference" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/CareTeam" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Practitioner" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-PractitionerRole" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Organization" />
      </type>
      <mustSupport value="true" />
    </element>
    <element id="DiagnosticReport.resultsInterpreter">
      <path value="DiagnosticReport.resultsInterpreter" />
      <type>
        <code value="Reference" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/CareTeam" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Practitioner" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-PractitionerRole" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Organization" />
      </type>
    </element>
    <element id="DiagnosticReport.specimen">
      <path value="DiagnosticReport.specimen" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Specimen" />
      </type>
    </element>
    <element id="DiagnosticReport.result">
      <path value="DiagnosticReport.result" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Observation-Lab" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-Observation" />
      </type>
    </element>
    <element id="DiagnosticReport.imagingStudy">
      <path value="DiagnosticReport.imagingStudy" />
      <type>
        <code value="Reference" />
        <targetProfile value="https://fhir.nhs.wales/StructureDefinition/DataStandardsWales-ImagingStudy" />
      </type>
    </element>
  </differential>
</StructureDefinition>