{
  "resourceType": "StructureDefinition",
  "id": "ncdhc-observation-estimated-gestation",
  "url": "http://hl7.org.au/fhir/ch/v1/StructureDefinition/ncdhc-observation-estimated-gestation",
  "version": "r1.0.0",
  "name": "NCDHCEstimatedGestationObservationProfile",
  "title": "NCDHC Estimated Gestation Observation",
  "status": "draft",
  "date": "2019-03-21",
  "publisher": "National Children's Digital Health Collaborative (NCDHC)",
  "description": "Gestational age in weeks and days (usually equivalent to length of pregnancy).",
  "purpose": "To record Gestational age in weeks and days (usually equivalent to length of pregnancy).",
  "copyright": "Copyright © 2019 Australian Digital Health Agency - All rights reserved. This content is licensed under a Creative Commons Attribution 4.0 International License. See https://creativecommons.org/licenses/by/4.0/",
  "fhirVersion": "3.0.2",
  "kind": "resource",
  "abstract": false,
  "type": "Observation",
  "baseDefinition": "http://hl7.org.au/fhir/ch/v1/StructureDefinition/ncdhc-observation-base",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Observation",
        "path": "Observation",
        "short": "NCDHC Estimated Gestation Observation Profile"
      },
      {
        "id": "Observation.code",
        "path": "Observation.code",
        "short": "Code to represent Estimated Gestation noted during the birthing process",
        "mustSupport": true
      },
      {
        "id": "Observation.code.coding",
        "path": "Observation.code.coding",
        "slicing": {
          "discriminator": [
            {
              "type": "pattern",
              "path": "code"
            },
            {
              "type": "value",
              "path": "system"
            }
          ],
          "rules": "closed"
        },
        "min": 1
      },
      {
        "id": "Observation.code.coding:FetalGestationAgeSNOMED-CT",
        "path": "Observation.code.coding",
        "sliceName": "FetalGestationAgeSNOMED-CT",
        "max": "1",
        "patternCoding": {
          "system": "http://snomed.info/sct",
          "code": "57036006"
        }
      },
      {
        "id": "Observation.code.coding:FetalGestationAgeSNOMED-CT.system",
        "path": "Observation.code.coding.system",
        "min": 1,
        "fixedUri": "http://snomed.info/sct"
      },
      {
        "id": "Observation.subject",
        "path": "Observation.subject",
        "type": [
          {
            "code": "Reference",
            "targetProfile": "http://hl7.org.au/fhir/ch/v1/StructureDefinition/ncdhc-patient-baby"
          },
          {
            "code": "Reference",
            "targetProfile": "http://hl7.org.au/fhir/ch/v1/StructureDefinition/ncdhc-patient-expectant-mother"
          }
        ]
      },
      {
        "id": "Observation.effectiveDateTime:effectiveDateTime",
        "path": "Observation.effectiveDateTime",
        "sliceName": "effectiveDateTime",
        "short": "Date when Gestation age was estimated",
        "min": 1
      },
      {
        "id": "Observation.value[x]:valueQuantity",
        "path": "Observation.valueQuantity",
        "sliceName": "valueQuantity",
        "short": "Gestational age in days",
        "type": [
          {
            "code": "Quantity"
          }
        ],
        "mustSupport": true
      },
      {
        "id": "Observation.value[x]:valueQuantity.value",
        "path": "Observation.valueQuantity.value",
        "min": 1
      },
      {
        "id": "Observation.value[x]:valueQuantity.unit",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable",
            "valueBoolean": true
          }
        ],
        "path": "Observation.valueQuantity.unit",
        "min": 1
      },
      {
        "id": "Observation.value[x]:valueQuantity.system",
        "path": "Observation.valueQuantity.system",
        "min": 1,
        "fixedUri": "http://unitsofmeasure.org"
      },
      {
        "id": "Observation.value[x]:valueQuantity.code",
        "path": "Observation.valueQuantity.code",
        "fixedCode": "d"
      },
      {
        "id": "Observation.comment",
        "path": "Observation.comment",
        "short": "Notes on the Estimated Gestation"
      }
    ]
  }
}