PackagesCanonicalsLogsProblems
    Packages
    hl7.fhir.us.davinci-cdex.r4@2.0.0
    http://hl7.org/fhir/us/davinci-cdex/StructureDefinition/cdex-task-attachment-request
description: Payers use the [Task](http://hl7.org/StructureDefinition/Task) based profile to request additional documentation (\"attachments\") for claims or prior authorizations. It constrains the Task resource to minimal necessary data elements needed to request attachments and respond in a way that is compatible with existing X12 277 RFAI and 278 response transactions to allow for association and requests for (typically PDF and CCDA) documents using LOINC as the standard. It also supports requests for more detailed missing data using Questionnaire, CQL, and QuestionnaireResponse, as supported by Da Vinci DTR.\n\nIt constrains the following elements to be *mandatory* (min=1):\n\n- A [contained](http://hl7.org/fhir/R4/references.html) Patient Resource defined by the [CDex Patient Demographics Profile](http://hl7.org/fhir/us/davinci-cdex/StructureDefinition/cdex-patient-demographics) and communicating additional patient demographic data elements.\n- A [contained](http://hl7.org/fhir/R4/references.html) PractitionerRole Resource defined by the [CDex PractitionerRole Profile](http://hl7.org/fhir/us/davinci-cdex/StructureDefinition/cdex-practitionerrole) to communicate the provider ID as either a unique organization/location identifier (e.g., Type 2 NPI) or unique provider identifier (e.g., Type 1 NPI) or both.\n- A Task.identifier element representing the payers tracking identifier (referred to as the “re-association tracking control numbers”)\n- A Task.status with a required binding to HRex [Task Status ValueSet](http://hl7.org/fhir/us/davinci-hrex/STU1/ValueSet-hrex-task-status.html) (this element is a mandatory Task element). For guidance when the provider is not able to complete the Task, refer to the [When The Task Cannot Be Completed section](http://hl7.org/fhir/us/davinci-cdex/STU2/task-based-approach.html#when-the-task-cannot-be-completed).\n- A Task.intent fixed to \"order\" (this element is a mandatory Task element)\n- A Task.code of either \"attachment-request-code\" or \"attachment-request-questionnaire\"  communicating that the Payer is requesting attachments for a claim or prior authorization using a code or data request questionnaire.\n  - If the code is \"attachment-request-code\", the provider system returns attachment(s) identified by the LOINC attachment code(s) in the \"code\" input parameter.\n  - If the code is \"attachment-request-questionnaire\", the provider system uses [Documentation Templates and Rules (DTR)](http://hl7.org/fhir/us/davinci-dtr/2022May/) to complete the Questionnaire referenced in the \"questionnaire\" input parameter.\n  - When either code is present, the provider system uses the $submit-attachment operation to return the information to the endpoint provided in \"payer-url\" input parameter.    \n- A Task.requester.identifier element representing the Payer ID\n- A Task.owner.reference element fixed to \"\\#practionerrole\" -  a reference the contained PractitionerRole Resource that represents the Provider ID.\n- A Task.for.reference element fixed to \"\\#patient\" - a reference the contained Patient Resource that represents basic Patient demographic data.\n- A Task.reasonCode to communicate whether the attachments are for a Claim or Prior Authorization\n- A Task.reasonReference.reference referencing the Claim or Prior Authorization ID (business Identifier)\n- A \"payer-url\" Task.input element representing the Payer endpoint URL to communicate to the provider to submit the attachments using the `$submit-attachment` operation\n\nIt constrains following elements to be [*must support*](attachments-conformance.html#cdex-must-support-definition) (min=0):\n\n- A Task.Restriction.period element representing the due date for submitting the attachments\n- A Task.statusReason.text to communicate the reason for the status (for example, if the Task is rejected or failed)\n- A \"code\" Task.input element to communicate to the provider what attachments are needed using LOINC attachment codes.*\n- A \"code\" or \"questionnaire\" Task.input element extension representing a claim or prior authorization line item numbers associated with the attachment or questionnaire.\n- A \"signature\" Task.input element representing a flag to indicate whether the requested data requires a signature. For more information about requiring and requesting signatures, refer to the [Signatures section](http://hl7.org/fhir/us/davinci-cdex/STU2/sending-attachments.html#signatures).\n- A \"service-date\" Task.input element representing the date of service or starting date of the service for the claim or prior authorization. It SHALL be present if the attachment is for a claim.\n\nIt defines the following elements to be *optional*:\n\n- A \"questionnaire\" Task.input element to communicate to the provider a URL of a data request [FHIR Questionnaire](http://hl7.org/fhir/questionnaire.html) that conforms to the [DTR SDC Questionnaire Profile](http://hl7.org/fhir/us/davinci-dtr/StructureDefinition/dtr-sdc-questionnaire) or the [DTR SDC Questionnaire for Adaptive Form Profile](http://hl7.org/fhir/us/davinci-dtr/StructureDefinition/dtr-sdc-questionnaire-adapt).*\n  - A questionnaireDisplay extension to communicate the display name of the Questionnaire\n- A \"POU\" Task.input element representing the purpose of use (POU) for the requested data using an extensible [CDex Purpose of Use Value Set](http://hl7.org/fhir/us/davinci-cdex/ValueSet/cdex-POU). For more information about sending purpose POU codes, refer to the [Purpose of Use section](http://hl7.org/fhir/us/davinci-cdex/STU2/sending-attachments.html#signatures).\n- A \"multiple-submits\" Task.input element representing a flag to indicate whether the requested data can be sent in multiple submissions\n- A \"data-value\" Task.output element referring to FHIR resource(s) representing the result(s) of the data request code.\n- A \"response\" Task.output element which is a local reference to the [FHIR QuestionnaireResponse](http://hl7.org/fhir/questionnaireresponse.html) resulting from the data request Questionnaire. The QuestionnaireResponse conforms to the [SDC Questionnaire Response Profile](http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaireresponse) or the [SDC Adaptive Questionnaire Response Profile](http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaireresponse-adapt).\n\n\\* Either a \"code\" or a \"questionnaire\" Task.input element is required
package_name: hl7.fhir.us.davinci-cdex.r4
derivation: constraint
name: CDexTaskAttachmentRequest
type: Task
elements:
  restriction:
    mustSupport: true
    index: 29
    elements:
      period: {short: Attachments due date, mustSupport: true, index: 30}
  reasonCode:
    mustSupport: true
    index: 21
    elements:
      coding:
        mustSupport: true
        index: 22
        slicing:
          rules: open
          discriminator:
          - {path: $this, type: value}
          min: 1
          slices:
            use:
              match: {}
              schema:
                binding: {strength: required, valueSet: 'http://hl7.org/fhir/us/davinci-cdex/ValueSet/cdex-claim-use'}
                mustSupport: true
                array: true
                min: 1
                _required: true
                index: 23
                elements:
                  system: {mustSupport: true, index: 24}
                  code: {short: claim | preauthorization, mustSupport: true, index: 25}
                required: [code]
      text:
        short: claim | preauthorization
        binding: {strength: required, valueSet: 'http://hl7.org/fhir/us/davinci-cdex/ValueSet/cdex-claim-use'}
        mustSupport: true
        index: 26
    required: [coding]
  statusReason:
    mustSupport: true
    index: 8
    elements:
      text: {mustSupport: true, index: 9}
    required: [text]
  output:
    index: 78
    slicing:
      rules: open
      discriminator:
      - {path: type, type: pattern}
      min: null
      slices:
        data:
          match:
            type:
              coding:
              - {code: data-value, system: 'http://hl7.org/fhir/us/davinci-hrex/CodeSystem/hrex-temp'}
          schema:
            short: Requested data
            index: 79
            elements:
              type:
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: data-value, system: 'http://hl7.org/fhir/us/davinci-hrex/CodeSystem/hrex-temp'}
                index: 80
              value:
                short: data reference
                choices: [valueReference]
                index: 82
              valueReference: {type: Reference, short: data reference, choiceOf: value, index: 83}
        response:
          match:
            type:
              coding:
              - {code: questionnaire-response, system: 'http://hl7.org/fhir/uv/sdc/CodeSystem/temp'}
          schema:
            index: 84
            elements:
              type:
                type: CodeableConcept
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: questionnaire-response, system: 'http://hl7.org/fhir/uv/sdc/CodeSystem/temp'}
                index: 85
              value:
                short: Reference to the QuestionnaireResponse
                choices: [valueReference]
                index: 87
              valueReference:
                type: Reference
                short: Reference to the QuestionnaireResponse
                choiceOf: value
                refers: ['http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaireresponse', 'http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaireresponse-adapt']
                index: 88
            required: [valueReference, value]
  contained:
    mustSupport: true
    index: 0
    slicing:
      rules: open
      discriminator:
      - {path: $this, type: type}
      min: 1
      slices:
        practitionerrole:
          match: {}
          schema: {short: Contained PractitionerRole resource, type: PractitionerRole, mustSupport: true, _required: true, index: 1}
          min: 1
          max: 1
        patient:
          match: {}
          schema: {short: Contained Patient resource, type: Patient, mustSupport: true, _required: true, index: 2}
          min: 1
          max: 1
  for:
    type: Reference
    short: Contained Patient.
    mustSupport: true
    refers: ['http://hl7.org/fhir/us/davinci-cdex/StructureDefinition/cdex-patient-demographics']
    index: 15
    elements:
      reference:
        short: Contained resource reference
        pattern: {type: String, value: '#patient'}
        mustSupport: true
        index: 16
    required: [reference]
  requester:
    type: Reference
    short: Payer asking for attachments
    mustSupport: true
    refers: ['http://hl7.org/fhir/us/core/StructureDefinition/us-core-organization']
    index: 17
    elements:
      identifier: {short: Payer ID, mustSupport: true, index: 18}
    required: [identifier]
  status:
    binding: {strength: required, valueSet: 'http://hl7.org/fhir/us/davinci-hrex/ValueSet/hrex-task-status'}
    mustSupport: true
    index: 7
  code:
    short: attachment-request-code | attachment-request-questionnaire
    binding: {strength: required, valueSet: 'http://hl7.org/fhir/us/davinci-cdex/ValueSet/cdex-attachment-task-code'}
    mustSupport: true
    index: 11
    elements:
      coding:
        mustSupport: true
        index: 12
        elements:
          system:
            pattern: {type: Uri, value: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
            mustSupport: true
            index: 13
          code: {mustSupport: true, index: 14}
        required: [code]
    required: [coding]
  identifier:
    mustSupport: true
    index: 3
    slicing:
      rules: open
      discriminator:
      - {path: $this, type: pattern}
      min: 1
      slices:
        tracking-id:
          match:
            type:
              coding:
              - {code: tracking-id, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
          schema:
            short: Re-association tracking control number
            mustSupport: true
            _required: true
            pattern:
              type: Identifier
              value:
                type:
                  coding:
                  - {code: tracking-id, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
            index: 4
            elements:
              system: {mustSupport: true, index: 5}
              value: {mustSupport: true, index: 6}
            required: [value]
  intent:
    pattern: {type: Code, value: order}
    mustSupport: true
    index: 10
  input:
    mustSupport: true
    array: true
    min: 2
    index: 31
    slicing:
      rules: open
      discriminator:
      - {path: type, type: pattern}
      min: 2
      slices:
        code:
          match:
            type:
              coding:
              - {code: data-code, system: 'http://hl7.org/fhir/us/davinci-hrex/CodeSystem/hrex-temp'}
          schema:
            short: Attachment Codes
            mustSupport: true
            binding: {strength: extensible, valueSet: 'http://loinc.org/vs/valid-hl7-attachment-requests'}
            index: 32
            extensions: {}
            elements:
              extension:
                mustSupport: true
                index: 33
                elements:
                  url:
                    pattern: {type: Uri, value: 'http://hl7.org/fhir/us/davinci-pas/StructureDefinition/extension-serviceLineNumber'}
                    mustSupport: true
                    index: 34
                  value:
                    mustSupport: true
                    choices: [valuePositiveInt]
                    index: 36
                  valuePositiveInt: {type: positiveInt, mustSupport: true, choiceOf: value, index: 37}
                required: [valuePositiveInt, value]
              type:
                mustSupport: true
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: data-code, system: 'http://hl7.org/fhir/us/davinci-hrex/CodeSystem/hrex-temp'}
                index: 38
              value:
                short: LOINC attachment code value
                mustSupport: true
                choices: [valueCodeableConcept]
                index: 40
              valueCodeableConcept: {type: CodeableConcept, short: LOINC attachment code value, mustSupport: true, choiceOf: value, index: 41}
        questionnaire:
          match:
            type:
              coding:
              - {code: questionnaire, system: 'http://hl7.org/fhir/uv/sdc/CodeSystem/temp'}
          schema:
            short: Data Request questionnaire
            index: 42
            extensions: {}
            elements:
              extension:
                mustSupport: true
                index: 43
                elements:
                  url:
                    pattern: {type: Uri, value: 'http://hl7.org/fhir/us/davinci-pas/StructureDefinition/extension-serviceLineNumber'}
                    mustSupport: true
                    index: 44
                  value:
                    mustSupport: true
                    choices: [valuePositiveInt]
                    index: 46
                  valuePositiveInt: {type: positiveInt, mustSupport: true, choiceOf: value, index: 47}
                required: [valuePositiveInt, value]
              type:
                type: CodeableConcept
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: questionnaire, system: 'http://hl7.org/fhir/uv/sdc/CodeSystem/temp'}
                index: 48
              value:
                short: URL
                choices: [valueCanonical]
                index: 50
              valueCanonical: {type: canonical, short: URL, choiceOf: value, index: 51}
              value[x]:
                extensions:
                  questionnaireDisplay: {url: 'http://hl7.org/fhir/StructureDefinition/display', min: 0, max: 1, type: Extension, index: 52}
                elements:
                  extension:
                    type: Extension
                    url: http://hl7.org/fhir/StructureDefinition/display
                    index: 52
                    slicing:
                      slices:
                        questionnaireDisplay:
                          match: {}
                          schema: {type: Extension, url: 'http://hl7.org/fhir/StructureDefinition/display', index: 52}
                          min: 0
                          max: 1
            required: [valueCanonical, value, type]
        payer-url:
          match:
            type:
              coding:
              - {code: payer-url, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
          schema:
            short: Payer Url
            mustSupport: true
            _required: true
            index: 53
            elements:
              type:
                mustSupport: true
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: payer-url, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
                index: 54
              value:
                short: Payer url value
                mustSupport: true
                choices: [valueUrl]
                index: 56
              valueUrl: {type: url, short: Payer url value, mustSupport: true, choiceOf: value, index: 57}
        service-date:
          match:
            type:
              coding:
              - {code: service-date, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
          schema:
            short: Service Date
            mustSupport: true
            index: 58
            elements:
              type:
                mustSupport: true
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: service-date, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
                index: 59
              value:
                short: Service Date value
                constraint:
                  cdex-2: {human: Date must be to day., severity: error, expression: $this.toString().length() = 10}
                mustSupport: true
                choices: [valueDate]
                index: 61
              valueDate:
                type: date
                short: Service Date value
                constraint:
                  cdex-2: {human: Date must be to day., severity: error, expression: $this.toString().length() = 10}
                mustSupport: true
                choiceOf: value
                index: 62
        signature:
          match:
            type:
              coding:
              - {code: signature-flag, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
          schema:
            short: Signature flag
            mustSupport: true
            index: 63
            elements:
              type:
                mustSupport: true
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: signature-flag, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
                index: 64
              value:
                short: Signature flag value
                mustSupport: true
                choices: [valueBoolean]
                index: 66
              valueBoolean: {type: boolean, short: Signature flag value, mustSupport: true, choiceOf: value, index: 67}
        POU:
          match:
            type:
              coding:
              - {code: purpose-of-use, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
          schema:
            short: Purpose of use code'
            index: 68
            elements:
              type:
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: purpose-of-use, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
                index: 69
              value:
                short: Purpose of use value
                choices: [valueCodeableConcept]
                index: 71
              valueCodeableConcept: {type: CodeableConcept, short: Purpose of use value, choiceOf: value, index: 72}
        multiple-submits:
          match:
            type:
              coding:
              - {code: multiple-submits-flag, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
          schema:
            short: Multiple submits flag
            index: 73
            elements:
              type:
                pattern:
                  type: CodeableConcept
                  value:
                    coding:
                    - {code: multiple-submits-flag, system: 'http://hl7.org/fhir/us/davinci-cdex/CodeSystem/cdex-temp'}
                index: 74
              value:
                short: Multiple submits flag value
                choices: [valueBoolean]
                index: 76
              valueBoolean: {type: boolean, short: Multiple submits flag value, choiceOf: value, index: 77}
  owner:
    type: Reference
    short: Provider who submitted claim or preauthorization
    mustSupport: true
    refers: ['http://hl7.org/fhir/us/davinci-cdex/StructureDefinition/cdex-practitionerrole']
    index: 19
    elements:
      reference:
        short: Contained resource reference
        pattern: {type: String, value: '#practitionerrole'}
        mustSupport: true
        index: 20
    required: [reference]
  reasonReference:
    mustSupport: true
    index: 27
    elements:
      identifier: {short: Claim or Prior Authorization ID, mustSupport: true, index: 28}
    required: [identifier]
package_version: 2.0.0
class: profile
kind: resource
url: http://hl7.org/fhir/us/davinci-cdex/StructureDefinition/cdex-task-attachment-request
base: http://hl7.org/fhir/StructureDefinition/Task
version: 2.0.0
required: [owner, requester, for, identifier, reasonCode, code, contained, reasonReference]