{
  "resourceType": "StructureDefinition",
  "id": "Account",
  "meta": {
    "lastUpdated": "2021-03-23T09:48:30.001+00:00"
  },
  "url": "http://dedalus-group.com/fhir/StructureDefinition/Account",
  "name": "Account",
  "status": "draft",
  "date": "2021-03-23T09:47:42.770174+00:00",
  "fhirVersion": "4.0.1",
  "mapping": [
    {
      "identity": "rim",
      "uri": "http://hl7.org/v3",
      "name": "RIM Mapping"
    },
    {
      "identity": "w5",
      "uri": "http://hl7.org/fhir/fivews",
      "name": "FiveWs Pattern Mapping"
    }
  ],
  "kind": "resource",
  "abstract": false,
  "type": "Account",
  "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Account",
  "derivation": "constraint",
  "differential": {
    "element": [
      {
        "id": "Account.language",
        "path": "Account.language",
        "max": "0"
      },
      {
        "id": "Account.contained",
        "path": "Account.contained",
        "max": "0"
      },
      {
        "id": "Account.identifier",
        "path": "Account.identifier",
        "min": 1,
        "max": "1",
        "mustSupport": true,
        "mapping": [
          {
            "identity": "v2",
            "map": "PID-18 (fallback PV1-19)"
          }
        ]
      },
      {
        "id": "Account.identifier.id",
        "path": "Account.identifier.id",
        "max": "0"
      },
      {
        "id": "Account.identifier.use",
        "path": "Account.identifier.use",
        "max": "0"
      },
      {
        "id": "Account.identifier.type",
        "path": "Account.identifier.type",
        "min": 1
      },
      {
        "id": "Account.identifier.type.coding",
        "path": "Account.identifier.type.coding",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Account.identifier.type.coding.id",
        "path": "Account.identifier.type.coding.id",
        "max": "0"
      },
      {
        "id": "Account.identifier.type.coding.system",
        "path": "Account.identifier.type.coding.system",
        "min": 1,
        "fixedUri": "http://terminology.hl7.org/CodeSystem/v2-0203"
      },
      {
        "id": "Account.identifier.type.coding.version",
        "path": "Account.identifier.type.coding.version",
        "max": "0"
      },
      {
        "id": "Account.identifier.type.coding.code",
        "path": "Account.identifier.type.coding.code",
        "min": 1,
        "fixedCode": "VN"
      },
      {
        "id": "Account.identifier.type.coding.userSelected",
        "path": "Account.identifier.type.coding.userSelected",
        "max": "0"
      },
      {
        "id": "Account.identifier.system",
        "path": "Account.identifier.system",
        "min": 1,
        "mapping": [
          {
            "identity": "v2",
            "map": "MSH-4 (when PV1-19, then PV1-19.4)",
            "comment": "System-URI with Value from Mapping"
          }
        ]
      },
      {
        "id": "Account.identifier.value",
        "path": "Account.identifier.value",
        "min": 1,
        "mapping": [
          {
            "identity": "v2",
            "map": "PID-18 (fallback PV1-19.1)"
          }
        ]
      },
      {
        "id": "Account.identifier.period",
        "path": "Account.identifier.period",
        "max": "0"
      },
      {
        "id": "Account.identifier.assigner",
        "path": "Account.identifier.assigner",
        "max": "0"
      },
      {
        "id": "Account.status",
        "path": "Account.status",
        "fixedCode": "active",
        "mustSupport": true
      },
      {
        "id": "Account.type",
        "path": "Account.type",
        "min": 1,
        "mustSupport": true,
        "mapping": [
          {
            "identity": "v2",
            "map": "PV1-24"
          }
        ]
      },
      {
        "id": "Account.type.coding",
        "path": "Account.type.coding",
        "min": 1,
        "max": "1"
      },
      {
        "id": "Account.type.coding.id",
        "path": "Account.type.coding.id",
        "max": "0"
      },
      {
        "id": "Account.type.coding.system",
        "path": "Account.type.coding.system",
        "min": 1,
        "fixedUri": "http://fhir.de/CodeSystem/Aufnahmeart"
      },
      {
        "id": "Account.type.coding.version",
        "path": "Account.type.coding.version",
        "max": "0"
      },
      {
        "id": "Account.type.coding.code",
        "path": "Account.type.coding.code",
        "min": 1
      },
      {
        "id": "Account.type.coding.userSelected",
        "path": "Account.type.coding.userSelected",
        "max": "0"
      },
      {
        "id": "Account.type.text",
        "path": "Account.type.text",
        "max": "0"
      },
      {
        "id": "Account.name",
        "path": "Account.name",
        "max": "0"
      },
      {
        "id": "Account.subject",
        "path": "Account.subject",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "http://dedalus-group.com/fhir/StructureDefinition/Patient"
            ]
          }
        ],
        "mustSupport": true
      },
      {
        "id": "Account.subject.id",
        "path": "Account.subject.id",
        "max": "0"
      },
      {
        "id": "Account.subject.type",
        "path": "Account.subject.type",
        "max": "0"
      },
      {
        "id": "Account.subject.identifier",
        "path": "Account.subject.identifier",
        "max": "0"
      },
      {
        "id": "Account.servicePeriod",
        "path": "Account.servicePeriod",
        "mustSupport": false
      },
      {
        "id": "Account.coverage",
        "path": "Account.coverage",
        "mustSupport": true,
        "mapping": [
          {
            "identity": "v2",
            "map": "IN1"
          }
        ]
      },
      {
        "id": "Account.coverage.coverage",
        "path": "Account.coverage.coverage",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "http://dedalus-group.com/fhir/StructureDefinition/Coverage"
            ]
          }
        ]
      },
      {
        "id": "Account.coverage.coverage.reference",
        "path": "Account.coverage.coverage.reference",
        "min": 1
      },
      {
        "id": "Account.coverage.coverage.type",
        "path": "Account.coverage.coverage.type",
        "max": "0"
      },
      {
        "id": "Account.coverage.coverage.identifier",
        "path": "Account.coverage.coverage.identifier",
        "max": "0"
      },
      {
        "id": "Account.coverage.priority",
        "path": "Account.coverage.priority",
        "comment": "It is common in some jurisdictions for there to be multiple coverages allocated to an account, and a sequence is required to order the settling of the account (often with insurance claiming).\r\nMapping from HL7 v2 IN1-22, H=1, N=2, I=3",
        "min": 1
      },
      {
        "id": "Account.owner",
        "path": "Account.owner",
        "type": [
          {
            "code": "Reference",
            "targetProfile": [
              "http://dedalus-group.com/fhir/StructureDefinition/Organization"
            ]
          }
        ],
        "mustSupport": true
      },
      {
        "id": "Account.owner.reference",
        "path": "Account.owner.reference",
        "min": 1
      },
      {
        "id": "Account.owner.type",
        "path": "Account.owner.type",
        "max": "0"
      },
      {
        "id": "Account.owner.identifier",
        "path": "Account.owner.identifier",
        "max": "0"
      },
      {
        "id": "Account.description",
        "path": "Account.description",
        "max": "0"
      },
      {
        "id": "Account.guarantor",
        "path": "Account.guarantor",
        "max": "0"
      },
      {
        "id": "Account.partOf",
        "path": "Account.partOf",
        "max": "0"
      }
    ]
  }
}