<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="digidot-Coding-SCTpre-no" />
  <url value="https://novari.no/fhir/digidot/StructureDefinition/digidot-Coding-SCTpre-no" />
  <version value="0.4.0" />
  <name value="DigidotCodingSctPreNo" />
  <title value="DigiDOT Coding - SNOMED CT Precoordinated" />
  <status value="draft" />
  <date value="2026-09-29T12:57:07Z" />
  <publisher value="Novari AS - DigiDOT" />
  <description value="Readiness: [In development](https://simplifier.net/guide/Visual-overview/Home/Review-status-and-releases.page.md?version=current#readiness-coding-sctpre).&#xA;&#xA;Reusable constraints for a single precoordinated SNOMED CT Coding. In clinical code.coding slicing, SCTpre is an optional companion to the required extended coding. Other uses, including directly coded anatomy, retain their own cardinalities." />
  <purpose value="Used by the active DigiDOT Condition, Observation, Procedure and ServiceRequest profiles. It requires the SNOMED CT system, a version URI for a published SNOMED CT edition release, and a numeric SNOMED CT concept identifier. It is not used to carry compositional grammar expressions or codings from other code systems." />
  <fhirVersion value="4.0.1" />
  <kind value="complex-type" />
  <abstract value="false" />
  <type value="Coding" />
  <baseDefinition value="http://hl7.org/fhir/StructureDefinition/Coding" />
  <derivation value="constraint" />
  <differential>
    <element id="Coding">
      <path value="Coding" />
      <short value="Precoordinated SNOMED CT concept" />
    </element>
    <element id="Coding.extension">
      <path value="Coding.extension" />
      <short value="Extensions are not used" />
      <definition value="This helper profile represents one direct SNOMED CT concept. No named Coding extension is agreed for the current DigiDOT scope, so extensions are prohibited to avoid a parallel representation of code meaning or terminology context." />
      <max value="0" />
    </element>
    <element id="Coding.system">
      <path value="Coding.system" />
      <short value="SNOMED CT code system" />
      <definition value="Fixed to the canonical SNOMED CT code system URI." />
      <min value="1" />
      <fixedUri value="http://snomed.info/sct" />
    </element>
    <element id="Coding.version">
      <path value="Coding.version" />
      <short value="Published SNOMED CT edition release URI" />
      <definition value="Identify the SNOMED CT edition and release used to select the precoordinated concept, for example the Norwegian edition version URI." />
      <min value="1" />
      <constraint>
        <key value="sct-pre-version-sct" />
        <severity value="error" />
        <human value="Version must be an SCT version in the form .../sct/edition/version/yyyymmdd." />
        <expression value="matches('^http://snomed[.]info/sct/.*/version/[0-9]{8}$')" />
      </constraint>
    </element>
    <element id="Coding.code">
      <path value="Coding.code" />
      <short value="Numeric SNOMED CT concept identifier" />
      <definition value="A directly usable numeric SNOMED CT concept identifier. Use the SNOMED CT Extended code profile when a coding must also support postcoordinated expressions." />
      <min value="1" />
      <constraint>
        <key value="sct-pre-numeric" />
        <severity value="error" />
        <human value="SNOMED conceptId (6-18 digits)." />
        <expression value="matches('^[0-9]{6,18}$')" />
      </constraint>
    </element>
    <element id="Coding.display">
      <path value="Coding.display" />
      <short value="Human-readable SNOMED CT term" />
      <definition value="Include the display term when it is available from the terminology service. It is informative and must remain consistent with the code and version." />
    </element>
    <element id="Coding.userSelected">
      <path value="Coding.userSelected" />
      <short value="User-selection marker is not used" />
      <definition value="Whether a code was selected directly by a user is a source-system interaction detail, not stable clinical or terminology meaning. It is not retained in the current DigiDOT coding model." />
      <max value="0" />
    </element>
  </differential>
</StructureDefinition>