{
  "resourceType": "StructureDefinition",
  "id": "HospitalXPatientNZ",
  "meta": {
    "lastUpdated": "2020-08-27T11:33:17.865+00:00"
  },
  "url": "http://example.org/fhir/StructureDefinition/HospitalXPatientNZ",
  "name": "HospitalXPatientNZ",
  "status": "draft",
  "date": "2020-08-27T11:14:46.1579379+00:00",
  "fhirVersion": "4.0.1",
  "mapping": [
    {
      "identity": "rim",
      "uri": "http://hl7.org/v3",
      "name": "RIM Mapping"
    },
    {
      "identity": "cda",
      "uri": "http://hl7.org/v3/cda",
      "name": "CDA (R2)"
    },
    {
      "identity": "w5",
      "uri": "http://hl7.org/fhir/fivews",
      "name": "FiveWs Pattern Mapping"
    },
    {
      "identity": "v2",
      "uri": "http://hl7.org/v2",
      "name": "HL7 v2 Mapping"
    },
    {
      "identity": "loinc",
      "uri": "http://loinc.org",
      "name": "LOINC code for the element"
    }
  ],
  "kind": "resource",
  "abstract": false,
  "type": "Patient",
  "baseDefinition": "http://wardweistra.nl/forgeletsbuild/fhir/StructureDefinition/HospitalXPatient",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Patient.identifier",
        "path": "Patient.identifier",
        "slicing": {
          "discriminator": [
            {
              "type": "value",
              "path": "use"
            }
          ],
          "rules": "open"
        }
      },
      {
        "id": "Patient.identifier:OfficialNHI",
        "path": "Patient.identifier",
        "sliceName": "OfficialNHI",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Patient.identifier:OfficialNHI.use",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
            "valueCode": "normative"
          },
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
            "valueCode": "4.0.0"
          }
        ],
        "path": "Patient.identifier.use",
        "fixedCode": "official"
      },
      {
        "id": "Patient.identifier:OfficialNHI.system",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
            "valueCode": "normative"
          },
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
            "valueCode": "4.0.0"
          }
        ],
        "path": "Patient.identifier.system",
        "fixedUri": "https://standards.digital.health.nz/id/nhi"
      },
      {
        "id": "Patient.identifier:OldNHI",
        "path": "Patient.identifier",
        "sliceName": "OldNHI"
      },
      {
        "id": "Patient.identifier:OldNHI.use",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
            "valueCode": "normative"
          },
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
            "valueCode": "4.0.0"
          }
        ],
        "path": "Patient.identifier.use",
        "fixedCode": "old"
      },
      {
        "id": "Patient.identifier:OldNHI.system",
        "extension": [
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
            "valueCode": "normative"
          },
          {
            "url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version",
            "valueCode": "4.0.0"
          }
        ],
        "path": "Patient.identifier.system",
        "fixedUri": "https://standards.digital.health.nz/id/nhi"
      }
    ]
  }
}