{
  "resourceType": "StructureDefinition",
  "id": "cde-sex-assigned-at-birth",
  "url": "http://somewhere.org/fhir/uv/myig/StructureDefinition/cde-sex-assigned-at-birth",
  "version": "0.2.0",
  "name": "CDE_SexAssignedAtBirth",
  "title": "CDE Sex Assigned At Birth",
  "status": "active",
  "date": "2023-03-09T12:00:30.596245+00:00",
  "description": "Dieses CDE enthält das 'bei Geburt zugewiesene Geschlecht'.",
  "fhirVersion": "4.0.1",
  "mapping": [
    {
      "identity": "workflow",
      "uri": "http://hl7.org/fhir/workflow",
      "name": "Workflow Pattern"
    },
    {
      "identity": "sct-concept",
      "uri": "http://snomed.info/conceptdomain",
      "name": "SNOMED CT Concept Domain Binding"
    },
    {
      "identity": "v2",
      "uri": "http://hl7.org/v2",
      "name": "HL7 v2 Mapping"
    },
    {
      "identity": "rim",
      "uri": "http://hl7.org/v3",
      "name": "RIM Mapping"
    },
    {
      "identity": "w5",
      "uri": "http://hl7.org/fhir/fivews",
      "name": "FiveWs Pattern Mapping"
    },
    {
      "identity": "sct-attr",
      "uri": "http://snomed.org/attributebinding",
      "name": "SNOMED CT Attribute Binding"
    }
  ],
  "kind": "resource",
  "abstract": false,
  "type": "Observation",
  "baseDefinition": "http://somewhere.org/fhir/uv/myig/StructureDefinition/cls-snomed-patient-sex",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Observation.code",
        "path": "Observation.code",
        "mustSupport": true
      },
      {
        "id": "Observation.code.coding",
        "path": "Observation.code.coding",
        "min": 1,
        "mustSupport": true
      },
      {
        "id": "Observation.code.coding.system",
        "path": "Observation.code.coding.system",
        "min": 1,
        "fixedUri": "http://loinc.org"
      },
      {
        "id": "Observation.code.coding.code",
        "path": "Observation.code.coding.code",
        "min": 1,
        "fixedCode": "76689-9"
      },
      {
        "id": "Observation.code.text",
        "path": "Observation.code.text",
        "min": 1,
        "patternString": "Sex assigned at birth",
        "mustSupport": true
      },
      {
        "id": "Observation.valueCodeableConcept",
        "path": "Observation.valueCodeableConcept",
        "min": 0,
        "max": "0",
        "type": [
          {
            "code": "CodeableConcept"
          }
        ]
      },
      {
        "id": "Observation.component",
        "path": "Observation.component",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "code.coding.code"
            }
          ],
          "description": "Slice basiert auf component.code.coding.code #value",
          "ordered": false,
          "rules": "open"
        }
      },
      {
        "id": "Observation.component.valueCodeableConcept",
        "path": "Observation.component.valueCodeableConcept",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "CodeableConcept"
          }
        ],
        "mustSupport": true,
        "binding": {
          "strength": "required",
          "valueSet": "http://somewhere.org/fhir/uv/myig/ValueSet/vs-biological-gender"
        }
      },
      {
        "id": "Observation.component:male",
        "path": "Observation.component",
        "sliceName": "male",
        "min": 0,
        "max": "*"
      },
      {
        "id": "Observation.component:male.code",
        "path": "Observation.component.code",
        "short": "Male sex",
        "definition": "Biological male sex",
        "comment": "Zusätzliche Codes, die diesen Code übersetzen oder abbilden, sind erlaubt. Beispielsweise ein granularerer LOINC-Code oder Code, der lokal in einem System verwendet wird.",
        "alias": [
          "Masculine",
          "Männlich"
        ]
      },
      {
        "id": "Observation.component:male.code.coding",
        "path": "Observation.component.code.coding",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "code"
            }
          ],
          "ordered": false,
          "rules": "open"
        },
        "min": 3
      },
      {
        "id": "Observation.component:male.code.coding:maleSNOMEDCode",
        "path": "Observation.component.code.coding",
        "sliceName": "MaleSNOMEDCode",
        "min": 1,
        "max": "1",
        "mustSupport": true
      },
      {
        "id": "Observation.component:male.code.coding:maleSNOMEDCode.system",
        "path": "Observation.component.code.coding.system",
        "min": 1,
        "fixedUri": "http://snomed.info/sct"
      },
      {
        "id": "Observation.component:male.code.coding:maleSNOMEDCode.code",
        "path": "Observation.component.code.coding.code",
        "min": 1,
        "fixedCode": "248153007"
      },
      {
        "id": "Observation.component:male.code.coding:maleUMLSCode",
        "path": "Observation.component.code.coding",
        "sliceName": "MaleUMLSCode",
        "min": 1,
        "max": "1",
        "mustSupport": true
      },
      {
        "id": "Observation.component:male.code.coding:maleUMLSCode.system",
        "path": "Observation.component.code.coding.system",
        "min": 1,
        "fixedUri": "http://terminology.hl7.org/CodeSystem/umls"
      },
      {
        "id": "Observation.component:male.code.coding:maleUMLSCode.code",
        "path": "Observation.component.code.coding.code",
        "min": 1,
        "fixedCode": "C1706180"
      },
      {
        "id": "Observation.component:male.code.coding:maleLOINCCode",
        "path": "Observation.component.code.coding",
        "sliceName": "maleLOINCCode",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Observation.component:male.valueInteger",
        "path": "Observation.component.valueInteger",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "integer"
          }
        ],
        "mustSupport": true
      },
      {
        "id": "Observation.component:male.valueInteger.value",
        "path": "Observation.component.valueInteger.value",
        "definition": "Internal coding of German Center for Diabetes Research (DZD)",
        "min": 1,
        "patternInteger": 1
      },
      {
        "id": "Observation.component:female",
        "path": "Observation.component",
        "sliceName": "female",
        "min": 0,
        "max": "*"
      },
      {
        "id": "Observation.component:female.code",
        "path": "Observation.component.code",
        "short": "Female sex",
        "definition": "Biological female sex",
        "comment": "Zusätzliche Codes, die diesen Code übersetzen oder abbilden, sind erlaubt. Beispielsweise ein granularerer LOINC-Code oder Code, der lokal in einem System verwendet wird.",
        "alias": [
          "Feminine",
          "Weiblich"
        ]
      },
      {
        "id": "Observation.component:female.code.coding",
        "path": "Observation.component.code.coding",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "code"
            }
          ],
          "ordered": false,
          "rules": "open"
        },
        "min": 3
      },
      {
        "id": "Observation.component:female.code.coding:femaleSNOMEDCode",
        "path": "Observation.component.code.coding",
        "sliceName": "FemaleSNOMEDCode",
        "min": 1,
        "max": "1",
        "mustSupport": true
      },
      {
        "id": "Observation.component:female.code.coding:femaleSNOMEDCode.system",
        "path": "Observation.component.code.coding.system",
        "min": 1,
        "fixedUri": "http://snomed.info/sct"
      },
      {
        "id": "Observation.component:female.code.coding:femaleSNOMEDCode.code",
        "path": "Observation.component.code.coding.code",
        "min": 1,
        "fixedCode": "248152002"
      },
      {
        "id": "Observation.component:female.code.coding:femaleUMLSCode",
        "path": "Observation.component.code.coding",
        "sliceName": "FemaleUMLSCode",
        "min": 1,
        "max": "1",
        "mustSupport": true
      },
      {
        "id": "Observation.component:female.code.coding:femaleUMLSCode.system",
        "path": "Observation.component.code.coding.system",
        "min": 1,
        "fixedUri": "http://terminology.hl7.org/CodeSystem/umls"
      },
      {
        "id": "Observation.component:female.code.coding:femaleUMLSCode.code",
        "path": "Observation.component.code.coding.code",
        "min": 1,
        "fixedCode": "C0015780"
      },
      {
        "id": "Observation.component:female.code.coding:femaleLOINCCode",
        "path": "Observation.component.code.coding",
        "sliceName": "femaleLOINCCode",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Observation.component:female.valueInteger",
        "path": "Observation.component.valueInteger",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "integer"
          }
        ],
        "mustSupport": true
      },
      {
        "id": "Observation.component:female.valueInteger.value",
        "path": "Observation.component.valueInteger.value",
        "definition": "Internal coding of German Center for Diabetes Research (DZD)",
        "min": 1,
        "patternInteger": 2
      },
      {
        "id": "Observation.component:intersex",
        "path": "Observation.component",
        "sliceName": "intersex",
        "min": 0,
        "max": "*"
      },
      {
        "id": "Observation.component:intersex.code",
        "path": "Observation.component.code",
        "short": "Intersex",
        "definition": "Biological intersexuality",
        "comment": "Zusätzliche Codes, die diesen Code übersetzen oder abbilden, sind erlaubt. Beispielsweise ein granularerer LOINC-Code oder Code, der lokal in einem System verwendet wird.",
        "alias": [
          "Non-binary",
          "Divers"
        ]
      },
      {
        "id": "Observation.component:intersex.code.coding",
        "path": "Observation.component.code.coding",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "code"
            }
          ],
          "ordered": false,
          "rules": "open"
        },
        "min": 3
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexSNOMEDCode",
        "path": "Observation.component.code.coding",
        "sliceName": "IntersexSNOMEDCode",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexSNOMEDCode.system",
        "path": "Observation.component.code.coding.system",
        "min": 1,
        "fixedUri": "http://snomed.info/sct"
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexSNOMEDCode.code",
        "path": "Observation.component.code.coding.code",
        "min": 1,
        "fixedCode": "32570691000036108"
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexUMLSCode",
        "path": "Observation.component.code.coding",
        "sliceName": "IntersexUMLSCode",
        "min": 1,
        "max": "1",
        "mustSupport": true
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexUMLSCode.system",
        "path": "Observation.component.code.coding.system",
        "min": 1,
        "fixedUri": "http://terminology.hl7.org/CodeSystem/umls"
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexUMLSCode.code",
        "path": "Observation.component.code.coding.code",
        "min": 1,
        "fixedCode": "C1704620"
      },
      {
        "id": "Observation.component:intersex.code.coding:intersexLOINCCode",
        "path": "Observation.component.code.coding",
        "sliceName": "intersexLOINCCode",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Observation.component:intersex.valueInteger",
        "path": "Observation.component.valueInteger",
        "min": 0,
        "max": "1",
        "type": [
          {
            "code": "integer"
          }
        ],
        "mustSupport": true
      },
      {
        "id": "Observation.component:intersex.valueInteger.value",
        "path": "Observation.component.valueInteger.value",
        "definition": "Internal coding of German Center for Diabetes Research (DZD)",
        "min": 1,
        "patternInteger": 3
      }
    ]
  }
}