PackagesCanonicalsLogsProblems
    Packages
    de.gematik.dipag@1.0.5
    https://gematik.de/fhir/dipag/StructureDefinition/dipag-dokumentenmetadaten-intern
description: null
package_name: de.gematik.dipag
derivation: constraint
name: DiPagDokumentenmetadatenIntern
type: DocumentReference
elements:
  description: {mustSupport: true, index: 39}
  meta:
    extensions:
      markierung: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-markierung', min: 0, type: Extension, mustSupport: true, index: 1}
    elements:
      extension:
        mustSupport: true
        index: 0
        slicing:
          slices:
            markierung:
              match: {}
              schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-markierung', index: 1}
              min: 0
      tag:
        mustSupport: true
        index: 2
        slicing:
          rules: open
          discriminator:
          - {path: $this, type: pattern}
          min: null
          slices:
            dipag-rechnungsstatus:
              match: {}
              schema:
                binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-rechnungsstatus-vs'}
                mustSupport: true
                index: 3
                elements:
                  system: {mustSupport: true, index: 4}
                  code: {mustSupport: true, index: 5}
                required: [system, code]
  content:
    mustSupport: true
    index: 40
    slicing:
      rules: open
      discriminator:
      - {path: format, type: pattern}
      min: null
      slices:
        originaleRechnung:
          match:
            format: {code: originaleRechnung, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
          schema:
            mustSupport: true
            index: 41
            elements:
              attachment:
                mustSupport: true
                index: 42
                extensions:
                  signature:
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    type: Extension
                    mustSupport: true
                    index: 43
                    elements:
                      value[x]:
                        elements:
                          type:
                            mustSupport: true
                            pattern:
                              type: Coding
                              value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                            index: 44
                          when: {mustSupport: true, index: 45}
                          who:
                            mustSupport: true
                            index: 46
                            elements:
                              identifier:
                                mustSupport: true
                                index: 47
                                elements:
                                  system:
                                    pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                    mustSupport: true
                                    index: 48
                                  value:
                                    mustSupport: true
                                    pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                    index: 49
                          targetFormat:
                            binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                            mustSupport: true
                            index: 50
                          sigFormat: {mustSupport: true, index: 51}
                          data: {mustSupport: true, index: 52}
                elements:
                  extension:
                    type: Extension
                    mustSupport: true
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    index: 43
                    slicing:
                      slices:
                        signature:
                          match: {}
                          schema:
                            type: Extension
                            mustSupport: true
                            url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                            index: 43
                            elements:
                              value[x]:
                                elements:
                                  type:
                                    mustSupport: true
                                    pattern:
                                      type: Coding
                                      value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                                    index: 44
                                  when: {mustSupport: true, index: 45}
                                  who:
                                    mustSupport: true
                                    index: 46
                                    elements:
                                      identifier:
                                        mustSupport: true
                                        index: 47
                                        elements:
                                          system:
                                            pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                            mustSupport: true
                                            index: 48
                                          value:
                                            mustSupport: true
                                            pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                            index: 49
                                  targetFormat:
                                    binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                                    mustSupport: true
                                    index: 50
                                  sigFormat: {mustSupport: true, index: 51}
                                  data: {mustSupport: true, index: 52}
                  contentType:
                    mustSupport: true
                    pattern: {type: Code, value: application/pdf}
                    index: 53
                  data: {index: 54}
                  url: {mustSupport: true, index: 55}
                required: [url, contentType]
              format:
                mustSupport: true
                pattern:
                  type: Coding
                  value: {code: originaleRechnung, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
                index: 56
            required: [format]
        angereicherteRechnung:
          match:
            format: {code: angereichertesPDF, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
          schema:
            mustSupport: true
            index: 57
            elements:
              attachment:
                mustSupport: true
                index: 58
                extensions:
                  signature:
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    type: Extension
                    mustSupport: true
                    index: 59
                    elements:
                      value[x]:
                        elements:
                          type:
                            mustSupport: true
                            pattern:
                              type: Coding
                              value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                            index: 60
                          when: {mustSupport: true, index: 61}
                          who:
                            mustSupport: true
                            index: 62
                            elements:
                              identifier:
                                mustSupport: true
                                index: 63
                                elements:
                                  system:
                                    pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                    mustSupport: true
                                    index: 64
                                  value:
                                    mustSupport: true
                                    pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                    index: 65
                          targetFormat:
                            binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                            mustSupport: true
                            index: 66
                          sigFormat: {mustSupport: true, index: 67}
                          data: {mustSupport: true, index: 68}
                elements:
                  extension:
                    type: Extension
                    mustSupport: true
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    index: 59
                    slicing:
                      slices:
                        signature:
                          match: {}
                          schema:
                            type: Extension
                            mustSupport: true
                            url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                            index: 59
                            elements:
                              value[x]:
                                elements:
                                  type:
                                    mustSupport: true
                                    pattern:
                                      type: Coding
                                      value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                                    index: 60
                                  when: {mustSupport: true, index: 61}
                                  who:
                                    mustSupport: true
                                    index: 62
                                    elements:
                                      identifier:
                                        mustSupport: true
                                        index: 63
                                        elements:
                                          system:
                                            pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                            mustSupport: true
                                            index: 64
                                          value:
                                            mustSupport: true
                                            pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                            index: 65
                                  targetFormat:
                                    binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                                    mustSupport: true
                                    index: 66
                                  sigFormat: {mustSupport: true, index: 67}
                                  data: {mustSupport: true, index: 68}
                  contentType:
                    mustSupport: true
                    pattern: {type: Code, value: application/pdf}
                    index: 69
                  data: {index: 70}
                  url: {mustSupport: true, index: 71}
                required: [url, contentType]
              format:
                mustSupport: true
                pattern:
                  type: Coding
                  value: {code: angereichertesPDF, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
                index: 72
            required: [format]
        strukturierterRechnungsinhalt:
          match:
            format: {code: rechnungsinhalt, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
          schema:
            mustSupport: true
            index: 73
            elements:
              attachment:
                mustSupport: true
                index: 74
                extensions:
                  signature:
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    type: Extension
                    mustSupport: true
                    index: 75
                    elements:
                      value[x]:
                        elements:
                          type:
                            mustSupport: true
                            pattern:
                              type: Coding
                              value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                            index: 76
                          when: {mustSupport: true, index: 77}
                          who:
                            mustSupport: true
                            index: 78
                            elements:
                              identifier:
                                mustSupport: true
                                index: 79
                                elements:
                                  system:
                                    pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                    mustSupport: true
                                    index: 80
                                  value:
                                    mustSupport: true
                                    pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                    index: 81
                          targetFormat:
                            binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                            mustSupport: true
                            index: 82
                          sigFormat: {mustSupport: true, index: 83}
                          data: {mustSupport: true, index: 84}
                elements:
                  extension:
                    type: Extension
                    mustSupport: true
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    index: 75
                    slicing:
                      slices:
                        signature:
                          match: {}
                          schema:
                            type: Extension
                            mustSupport: true
                            url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                            index: 75
                            elements:
                              value[x]:
                                elements:
                                  type:
                                    mustSupport: true
                                    pattern:
                                      type: Coding
                                      value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                                    index: 76
                                  when: {mustSupport: true, index: 77}
                                  who:
                                    mustSupport: true
                                    index: 78
                                    elements:
                                      identifier:
                                        mustSupport: true
                                        index: 79
                                        elements:
                                          system:
                                            pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                            mustSupport: true
                                            index: 80
                                          value:
                                            mustSupport: true
                                            pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                            index: 81
                                  targetFormat:
                                    binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                                    mustSupport: true
                                    index: 82
                                  sigFormat: {mustSupport: true, index: 83}
                                  data: {mustSupport: true, index: 84}
                  contentType:
                    mustSupport: true
                    pattern: {type: Code, value: application/fhir+json}
                    index: 85
                  data: {index: 86}
                  url: {mustSupport: true, index: 87}
                required: [url, contentType]
              format:
                mustSupport: true
                pattern:
                  type: Coding
                  value: {code: rechnungsinhalt, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
                index: 88
            required: [format]
        anhang:
          match:
            format: {code: rechnungsanhang, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
          schema:
            mustSupport: true
            index: 89
            elements:
              attachment:
                mustSupport: true
                index: 90
                extensions:
                  signature:
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    type: Extension
                    mustSupport: true
                    index: 91
                    elements:
                      value[x]:
                        elements:
                          type:
                            mustSupport: true
                            pattern:
                              type: Coding
                              value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                            index: 92
                          when: {mustSupport: true, index: 93}
                          who:
                            mustSupport: true
                            index: 94
                            elements:
                              identifier:
                                mustSupport: true
                                index: 95
                                elements:
                                  system:
                                    pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                    mustSupport: true
                                    index: 96
                                  value:
                                    mustSupport: true
                                    pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                    index: 97
                          targetFormat:
                            binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                            mustSupport: true
                            index: 98
                          sigFormat: {mustSupport: true, index: 99}
                          data: {mustSupport: true, index: 100}
                elements:
                  extension:
                    type: Extension
                    mustSupport: true
                    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                    index: 91
                    slicing:
                      slices:
                        signature:
                          match: {}
                          schema:
                            type: Extension
                            mustSupport: true
                            url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
                            index: 91
                            elements:
                              value[x]:
                                elements:
                                  type:
                                    mustSupport: true
                                    pattern:
                                      type: Coding
                                      value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                                    index: 92
                                  when: {mustSupport: true, index: 93}
                                  who:
                                    mustSupport: true
                                    index: 94
                                    elements:
                                      identifier:
                                        mustSupport: true
                                        index: 95
                                        elements:
                                          system:
                                            pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                                            mustSupport: true
                                            index: 96
                                          value:
                                            mustSupport: true
                                            pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                                            index: 97
                                  targetFormat:
                                    binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                                    mustSupport: true
                                    index: 98
                                  sigFormat: {mustSupport: true, index: 99}
                                  data: {mustSupport: true, index: 100}
                  contentType:
                    mustSupport: true
                    pattern: {type: Code, value: application/pdf}
                    index: 101
                  data: {index: 102}
                  url: {mustSupport: true, index: 103}
                required: [url, contentType]
              format:
                mustSupport: true
                pattern:
                  type: Coding
                  value: {code: rechnungsanhang, system: 'https://gematik.de/fhir/dipag/CodeSystem/dipag-attachment-format-cs'}
                index: 104
            required: [format]
  type:
    mustSupport: true
    index: 27
    elements:
      coding:
        index: 28
        slicing:
          rules: open
          discriminator:
          - {path: $this, type: pattern}
          min: 1
          slices:
            DokumentenKlassifizierung:
              match: {}
              schema:
                binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-sonstigesdokument-type-vs'}
                mustSupport: true
                index: 29
                elements:
                  system: {mustSupport: true, index: 30}
                  code: {mustSupport: true, index: 31}
                  display: {mustSupport: true, index: 32}
                required: [display, system, code]
            Rechnungstyp:
              match: {code: AM010106, system: 'http://dvmd.de/fhir/CodeSystem/kdl'}
              schema:
                mustSupport: true
                pattern:
                  type: Coding
                  value: {code: AM010106, system: 'http://dvmd.de/fhir/CodeSystem/kdl'}
                index: 33
              min: 0
              max: 1
    required: [coding]
  author:
    mustSupport: true
    index: 36
    elements:
      identifier: {type: Identifier, mustSupport: true, index: 37}
      display: {mustSupport: true, index: 38}
    required: [identifier, display]
  extension:
    mustSupport: true
    index: 6
    slicing:
      rules: open
      ordered: false
      discriminator:
      - {path: url, type: value}
      min: null
      slices:
        docRef-signature:
          match: {url: null}
          schema:
            type: Extension
            mustSupport: true
            url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
            index: 7
            elements:
              value[x]:
                elements:
                  type:
                    mustSupport: true
                    pattern:
                      type: Coding
                      value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
                    index: 8
                  when: {mustSupport: true, index: 9}
                  who:
                    mustSupport: true
                    index: 10
                    elements:
                      identifier:
                        mustSupport: true
                        index: 11
                        elements:
                          system:
                            pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                            mustSupport: true
                            index: 12
                          value:
                            mustSupport: true
                            pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                            index: 13
                  targetFormat:
                    binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
                    mustSupport: true
                    index: 14
                  sigFormat: {mustSupport: true, index: 15}
                  data: {mustSupport: true, index: 16}
        rechnungsdatum:
          match: {url: null}
          schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-rechnungsdatum', index: 17}
          min: 0
          max: 1
        zahlungszieldatum:
          match: {url: null}
          schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-zahlungszieldatum', index: 18}
          min: 0
          max: 1
        gesamtbetrag:
          match: {url: null}
          schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-gesamtbetrag', index: 19}
          min: 0
          max: 1
        fachrichtung:
          match: {url: null}
          schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-fachrichtung', index: 20}
          min: 0
          max: 1
        leistungsart:
          match: {url: null}
          schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-leistungsart', index: 21}
          min: 0
          max: 1
        behandlungsart:
          match: {url: null}
          schema: {type: Extension, mustSupport: true, url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-behandlungsart', index: 22}
          min: 0
          max: 1
  status:
    mustSupport: true
    pattern: {type: Code, value: current}
    index: 26
  identifier:
    mustSupport: true
    index: 23
    elements:
      system: {mustSupport: true, index: 24}
      value: {mustSupport: true, index: 25}
    required: [value, system]
  context:
    mustSupport: true
    index: 105
    elements:
      related:
        mustSupport: true
        index: 106
        slicing:
          rules: open
          discriminator:
          - {path: $this.resolve(), type: type}
          min: 1
          slices:
            patient:
              match: {}
              schema:
                type: Reference
                mustSupport: true
                refers: ['http://hl7.org/fhir/StructureDefinition/Patient']
                _required: true
                index: 107
              min: 1
              max: 1
            anhaenge:
              match: {}
              schema:
                type: Reference
                mustSupport: true
                refers: ['http://hl7.org/fhir/StructureDefinition/DocumentReference']
                array: true
                index: 108
              min: 0
    required: [related]
  subject:
    mustSupport: true
    index: 34
    elements:
      display: {mustSupport: true, index: 35}
    required: [display]
package_version: 1.0.5
extensions:
  docRef-signature:
    url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-signature
    type: Extension
    mustSupport: true
    index: 7
    elements:
      value[x]:
        elements:
          type:
            mustSupport: true
            pattern:
              type: Coding
              value: {code: 1.2.840.10065.1.12.1.13, system: 'urn:iso-astm:E1762-95:2013'}
            index: 8
          when: {mustSupport: true, index: 9}
          who:
            mustSupport: true
            index: 10
            elements:
              identifier:
                mustSupport: true
                index: 11
                elements:
                  system:
                    pattern: {type: Uri, value: 'urn:ietf:rfc:3986'}
                    mustSupport: true
                    index: 12
                  value:
                    mustSupport: true
                    pattern: {type: String, value: 'urn:oid:1.2.276.0.76.4.323'}
                    index: 13
          targetFormat:
            binding: {strength: required, valueSet: 'https://gematik.de/fhir/dipag/ValueSet/dipag-restricted-mime-types-in-binary-vs'}
            mustSupport: true
            index: 14
          sigFormat: {mustSupport: true, index: 15}
          data: {mustSupport: true, index: 16}
  rechnungsdatum: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-rechnungsdatum', min: 0, max: 1, type: Extension, mustSupport: true, index: 17}
  zahlungszieldatum: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-zahlungszieldatum', min: 0, max: 1, type: Extension, mustSupport: true, index: 18}
  gesamtbetrag: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-documentreference-gesamtbetrag', min: 0, max: 1, type: Extension, mustSupport: true, index: 19}
  fachrichtung: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-fachrichtung', min: 0, max: 1, type: Extension, mustSupport: true, index: 20}
  leistungsart: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-docref-leistungsart', min: 0, max: 1, type: Extension, mustSupport: true, index: 21}
  behandlungsart: {url: 'https://gematik.de/fhir/dipag/StructureDefinition/dipag-behandlungsart', min: 0, max: 1, type: Extension, mustSupport: true, index: 22}
class: profile
kind: resource
url: https://gematik.de/fhir/dipag/StructureDefinition/dipag-dokumentenmetadaten-intern
base: http://hl7.org/fhir/StructureDefinition/DocumentReference
version: 1.0.5
required: [identifier, subject, type, description]