DRAFT - The specification is currently in development and subject to significant change. It is not ready for limited roll-out or production level use.

Task (CA:eReC)

Structure Definition: Task Profile

Canonical URL:http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Task

Simplifier project page: Task

Derived from: Task (R4)

Formal Views of Profile Content

Description of Profiles, Differentials, Snapshots and how the different presentations work

idΣ0..1string
metaΣ0..1Meta
implicitRulesΣ ?!0..1uri
language0..1codeBinding
text0..1Narrative
contained0..*Resource
PatientNeedsToBeSeenS I0..1Extension(boolean)
modifierExtension?! I0..*Extension
identifier0..*Identifier
instantiatesCanonicalΣ0..1canonical(ActivityDefinition)
instantiatesUriΣ0..1uri
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
groupIdentifierΣ0..1Identifier
partOfΣ I0..*Reference(Task)
statusS Σ ?!1..1codeBinding
statusReasonΣ0..1CodeableConcept
id0..1string
StatusReasonS I0..1Extension(CodeableConcept)
codingΣ0..*Coding
textΣ0..1string
intentS Σ1..1codeBindingPattern
priority0..1codeBinding
codeS Σ0..1CodeableConceptBinding
descriptionΣ0..1string
focusΣ I0..1Reference(Resource)
forΣ I0..1Reference(Resource)
encounterΣ I0..1Reference(Encounter)
executionPeriodΣ I0..1Period
authoredOnS I0..1dateTime
lastModifiedΣ I0..1dateTime
requesterΣ I0..1Reference(Device | Organization | Patient | Practitioner | PractitionerRole | RelatedPerson)
performerType0..*CodeableConceptBinding
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
locationΣ I0..1Reference(Location)
reasonCode0..1CodeableConcept
reasonReferenceI0..1Reference(Resource)
insuranceI0..*Reference(Coverage | ClaimResponse)
note0..*Annotation
relevantHistoryI0..*Reference(Provenance)
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
repetitions0..1positiveInt
periodI0..1Period
recipientI0..*Reference(Patient | Practitioner | PractitionerRole | RelatedPerson | Group | Organization)
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
type1..1CodeableConcept
valueBase64Binarybase64Binary
valueBooleanboolean
valueCanonicalcanonical()
valueCodecode
valueDatedate
valueDateTimedateTime
valueDecimaldecimal
valueIdid
valueInstantinstant
valueIntegerinteger
valueMarkdownmarkdown
valueOidoid
valuePositiveIntpositiveInt
valueStringstring
valueTimetime
valueUnsignedIntunsignedInt
valueUriuri
valueUrlurl
valueUuiduuid
valueAddressAddress
valueAgeAge
valueAnnotationAnnotation
valueAttachmentAttachment
valueCodeableConceptCodeableConcept
valueCodingCoding
valueContactPointContactPoint
valueCountCount
valueDistanceDistance
valueDurationDuration
valueHumanNameHumanName
valueIdentifierIdentifier
valueMoneyMoney
valuePeriodPeriod
valueQuantityQuantity
valueRangeRange
valueRatioRatio
valueSampledDataSampledData
valueSignatureSignature
valueTimingTiming
valueContactDetailContactDetail
valueContributorContributor
valueDataRequirementDataRequirement
valueExpressionExpression
valueParameterDefinitionParameterDefinition
valueRelatedArtifactRelatedArtifact
valueTriggerDefinitionTriggerDefinition
valueUsageContextUsageContext
valueDosageDosage
valueMetaMeta
valueReferenceReference()
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
type1..1CodeableConcept
valueReferenceReference(Communication)
idΣ0..1string
metaΣ0..1Meta
implicitRulesΣ ?!0..1uri
language0..1codeBinding
text0..1Narrative
contained0..*Resource
PatientNeedsToBeSeenS I0..1Extension(boolean)
modifierExtension?! I0..*Extension
identifier0..*Identifier
instantiatesCanonicalΣ0..1canonical(ActivityDefinition)
instantiatesUriΣ0..1uri
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
groupIdentifierΣ0..1Identifier
partOfΣ I0..*Reference(Task)
statusS Σ ?!1..1codeBinding
statusReasonΣ0..1CodeableConcept
id0..1string
StatusReasonS I0..1Extension(CodeableConcept)
codingΣ0..*Coding
textΣ0..1string
intentS Σ1..1codeBindingPattern
priority0..1codeBinding
codeS Σ0..1CodeableConceptBinding
descriptionΣ0..1string
focusΣ I0..1Reference(Resource)
forΣ I0..1Reference(Resource)
encounterΣ I0..1Reference(Encounter)
executionPeriodΣ I0..1Period
authoredOnS I0..1dateTime
lastModifiedΣ I0..1dateTime
requesterΣ I0..1Reference(Device | Organization | Patient | Practitioner | PractitionerRole | RelatedPerson)
performerType0..*CodeableConceptBinding
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
locationΣ I0..1Reference(Location)
reasonCode0..1CodeableConcept
reasonReferenceI0..1Reference(Resource)
insuranceI0..*Reference(Coverage | ClaimResponse)
note0..*Annotation
relevantHistoryI0..*Reference(Provenance)
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
repetitions0..1positiveInt
periodI0..1Period
recipientI0..*Reference(Patient | Practitioner | PractitionerRole | RelatedPerson | Group | Organization)
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
type1..1CodeableConcept
valueBase64Binarybase64Binary
valueBooleanboolean
valueCanonicalcanonical()
valueCodecode
valueDatedate
valueDateTimedateTime
valueDecimaldecimal
valueIdid
valueInstantinstant
valueIntegerinteger
valueMarkdownmarkdown
valueOidoid
valuePositiveIntpositiveInt
valueStringstring
valueTimetime
valueUnsignedIntunsignedInt
valueUriuri
valueUrlurl
valueUuiduuid
valueAddressAddress
valueAgeAge
valueAnnotationAnnotation
valueAttachmentAttachment
valueCodeableConceptCodeableConcept
valueCodingCoding
valueContactPointContactPoint
valueCountCount
valueDistanceDistance
valueDurationDuration
valueHumanNameHumanName
valueIdentifierIdentifier
valueMoneyMoney
valuePeriodPeriod
valueQuantityQuantity
valueRangeRange
valueRatioRatio
valueSampledDataSampledData
valueSignatureSignature
valueTimingTiming
valueContactDetailContactDetail
valueContributorContributor
valueDataRequirementDataRequirement
valueExpressionExpression
valueParameterDefinitionParameterDefinition
valueRelatedArtifactRelatedArtifact
valueTriggerDefinitionTriggerDefinition
valueUsageContextUsageContext
valueDosageDosage
valueMetaMeta
valueReferenceReference()
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
type1..1CodeableConcept
valueReferenceReference(Communication)
idΣ0..1string
metaΣ0..1Meta
implicitRulesΣ ?!0..1uri
language0..1codeBinding
text0..1Narrative
contained0..*Resource
PatientNeedsToBeSeenS I0..1Extension(boolean)
modifierExtension?! I0..*Extension
identifier0..*Identifier
instantiatesCanonicalΣ0..1canonical(ActivityDefinition)
instantiatesUriΣ0..1uri
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
groupIdentifierΣ0..1Identifier
partOfΣ I0..*Reference(Task)
statusS Σ ?!1..1codeBinding
statusReasonΣ0..1CodeableConcept
id0..1string
StatusReasonS I0..1Extension(CodeableConcept)
codingΣ0..*Coding
textΣ0..1string
intentS Σ1..1codeBindingPattern
priority0..1codeBinding
codeS Σ0..1CodeableConceptBinding
descriptionΣ0..1string
focusΣ I0..1Reference(Resource)
forΣ I0..1Reference(Resource)
encounterΣ I0..1Reference(Encounter)
executionPeriodΣ I0..1Period
authoredOnS I0..1dateTime
lastModifiedΣ I0..1dateTime
requesterΣ I0..1Reference(Device | Organization | Patient | Practitioner | PractitionerRole | RelatedPerson)
performerType0..*CodeableConceptBinding
id0..1string
extensionI0..*Extension
referenceS Σ I0..1string
typeΣ0..1uriBinding
id0..1string
extensionI0..*Extension
useΣ ?!0..1codeBinding
typeΣ0..1CodeableConceptBinding
systemS Σ1..1uri
valueS Σ1..1string
periodΣ I0..1Period
assignerΣ I0..1Reference(Organization)
displayΣ0..1string
locationΣ I0..1Reference(Location)
reasonCode0..1CodeableConcept
reasonReferenceI0..1Reference(Resource)
insuranceI0..*Reference(Coverage | ClaimResponse)
note0..*Annotation
relevantHistoryI0..*Reference(Provenance)
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
repetitions0..1positiveInt
periodI0..1Period
recipientI0..*Reference(Patient | Practitioner | PractitionerRole | RelatedPerson | Group | Organization)
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
type1..1CodeableConcept
valueBase64Binarybase64Binary
valueBooleanboolean
valueCanonicalcanonical()
valueCodecode
valueDatedate
valueDateTimedateTime
valueDecimaldecimal
valueIdid
valueInstantinstant
valueIntegerinteger
valueMarkdownmarkdown
valueOidoid
valuePositiveIntpositiveInt
valueStringstring
valueTimetime
valueUnsignedIntunsignedInt
valueUriuri
valueUrlurl
valueUuiduuid
valueAddressAddress
valueAgeAge
valueAnnotationAnnotation
valueAttachmentAttachment
valueCodeableConceptCodeableConcept
valueCodingCoding
valueContactPointContactPoint
valueCountCount
valueDistanceDistance
valueDurationDuration
valueHumanNameHumanName
valueIdentifierIdentifier
valueMoneyMoney
valuePeriodPeriod
valueQuantityQuantity
valueRangeRange
valueRatioRatio
valueSampledDataSampledData
valueSignatureSignature
valueTimingTiming
valueContactDetailContactDetail
valueContributorContributor
valueDataRequirementDataRequirement
valueExpressionExpression
valueParameterDefinitionParameterDefinition
valueRelatedArtifactRelatedArtifact
valueTriggerDefinitionTriggerDefinition
valueUsageContextUsageContext
valueDosageDosage
valueMetaMeta
valueReferenceReference()
id0..1string
extensionI0..*Extension
modifierExtensionΣ ?! I0..*Extension
type1..1CodeableConcept
valueReferenceReference(Communication)
Task..
Task.extension..
Task.extensionExtension0..1
Task.basedOnReference(ServiceRequest)1..1
Task.basedOn.reference..
Task.basedOn.identifier..
Task.basedOn.identifier.system1..
Task.basedOn.identifier.value1..
Task.status..
Task.businessStatus..
Task.businessStatus.extensionExtension0..1
Task.intent..
Task.code..
Task.authoredOn..
Task.ownerReference(PractitionerRole)..
Task.owner.reference..
Task.owner.identifier..
Task.owner.identifier.system1..
Task.owner.identifier.value1..
Task.output..
Task.output.value[x]Reference(Communication)..

{
    "resourceType": "StructureDefinition",
    "id": "CA-eReC-Task",
    "url": "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Task",
    "version": "1.0.0",
    "name": "Task",
    "title": "Task",
    "status": "draft",
    "description": "A task resource describes an activity that can be performed and tracks the state of completion of that activity. It is a representation that an activity should be or has been initiated, and eventually, represents the successful or unsuccessful completion of that activity.",
    "fhirVersion": "4.0.1",
    "kind": "resource",
    "abstract": false,
    "type": "Task",
    "baseDefinition": "http://hl7.org/fhir/StructureDefinition/Task",
    "derivation": "constraint",
    "differential": {
        "element":  [
            {
                "id": "Task.extension",
                "path": "Task.extension",
                "slicing": {
                    "discriminator":  [
                        {
                            "type": "value",
                            "path": "url"
                        }
                    ],
                    "ordered": false,
                    "rules": "open"
                }
            },
            {
                "id": "Task.extension:PatientNeedsToBeSeen",
                "path": "Task.extension",
                "sliceName": "PatientNeedsToBeSeen",
                "comment": "Used to support the eConsult use case where a patient is referred to a care provider. Used for when the care provider responds with an eConsult rather than accept the referral, but the patient wants a referral anyway.",
                "min": 0,
                "max": "1",
                "type":  [
                    {
                        "code": "Extension",
                        "profile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-patient-needs-to-be-seen-EXT"
                        ]
                    }
                ]
            },
            {
                "id": "Task.basedOn",
                "path": "Task.basedOn",
                "min": 1,
                "max": "1",
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-ServiceRequest"
                        ],
                        "aggregation":  [
                            "referenced"
                        ]
                    }
                ],
                "mustSupport": true
            },
            {
                "id": "Task.basedOn.reference",
                "path": "Task.basedOn.reference",
                "mustSupport": true
            },
            {
                "id": "Task.basedOn.identifier",
                "path": "Task.basedOn.identifier",
                "mustSupport": true
            },
            {
                "id": "Task.basedOn.identifier.system",
                "path": "Task.basedOn.identifier.system",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "Task.basedOn.identifier.value",
                "path": "Task.basedOn.identifier.value",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "Task.status",
                "path": "Task.status",
                "mustSupport": true
            },
            {
                "id": "Task.businessStatus",
                "path": "Task.businessStatus",
                "mustSupport": true,
                "binding": {
                    "strength": "extensible",
                    "valueSet": "http://fhir.infoway-inforoute.ca/io/CA-eReC/ValueSet/task-business-status"
                }
            },
            {
                "id": "Task.businessStatus.extension:StatusReason",
                "path": "Task.businessStatus.extension",
                "sliceName": "StatusReason",
                "min": 0,
                "max": "1",
                "type":  [
                    {
                        "code": "Extension",
                        "profile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-task-business-status-reason-EXT"
                        ]
                    }
                ],
                "mustSupport": true
            },
            {
                "id": "Task.intent",
                "path": "Task.intent",
                "patternCode": "proposal",
                "mustSupport": true
            },
            {
                "id": "Task.code",
                "path": "Task.code",
                "comment": "-",
                "mustSupport": true,
                "binding": {
                    "strength": "extensible",
                    "valueSet": "http://fhir.infoway-inforoute.ca/io/CA-eReC/ValueSet/task-code"
                }
            },
            {
                "id": "Task.authoredOn",
                "path": "Task.authoredOn",
                "mustSupport": true
            },
            {
                "id": "Task.owner",
                "path": "Task.owner",
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-PractitionerRole"
                        ]
                    }
                ],
                "mustSupport": true
            },
            {
                "id": "Task.owner.reference",
                "path": "Task.owner.reference",
                "mustSupport": true
            },
            {
                "id": "Task.owner.identifier",
                "path": "Task.owner.identifier",
                "mustSupport": true
            },
            {
                "id": "Task.owner.identifier.system",
                "path": "Task.owner.identifier.system",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "Task.owner.identifier.value",
                "path": "Task.owner.identifier.value",
                "min": 1,
                "mustSupport": true
            },
            {
                "id": "Task.output",
                "path": "Task.output",
                "mustSupport": true
            },
            {
                "id": "Task.output.value[x]",
                "path": "Task.output.value[x]",
                "type":  [
                    {
                        "code": "Reference",
                        "targetProfile":  [
                            "http://fhir.infoway-inforoute.ca/io/CA-eReC/StructureDefinition/CA-eReC-Communication"
                        ]
                    }
                ],
                "mustSupport": true
            }
        ]
    }
}

Usage

The Task resource is used as follows in this IG:

  • a "Process Request" Task ("Task.code": "process-request") SHALL be used by a Target System to track and communicate the status of a referral request to the Source System

  • a "Process Request Consult" Task ("Task.code": "process-request-consult") SHALL be used by a Target System to track and communicate the status of a consult request to the Source System

Each Task SHALL reference the ServiceRequest it is basedOn.

Notes

.id

  • used to uniquely identify the resource
  • if a persistent identity for the resource is not available to use when constructing a message Bundle for transmission via Direct Messaging, a UUID SHOULD be used in this element (with a corresponding value in Bundle.entry.fullUrl)

extension:PatientNeedsToBeSeen

  • Used in the Ontario iGuide to support the eConsult use case where a patient is referred to a care provider, the care provider responds with an eConsult rather than accept the referral, but the patient wants a referral anyway.

.basedOn

  • used to associate the Task with the ServiceRequest being performed
  • SHALL be populated with a reference to the ServiceRequest being performed
  • if the Task is being transmitted via messaging, this element SHALL either:
    • .reference a resource included in the message as a Bundle.entry, or
    • include an .identifier previously known to both systems

.status

  • for a "Process Request" Task, used to track the status of the ServiceRequest being performed as work progresses through to completion
  • for a "Request for Information" Task, used to track the status of the request for information

.businessStatus

  • used to convey the business status of the Task, which can be different from the .status. It can be more finegrained and is implementation-specific.

.businessStatus.extension:StatusReason

  • provides a coded reason for the .businessStatus

.intent

  • only "proposal" SHALL be supported
  • "plan" and "order" MAY be populated, and systems that do not understand "plan" or "order" codes will treat the value as "proposal"

.code

  • identifies the type of task
  • SHALL always be populated
    • with "process-request" for a "Process Request" Task
    • with "process-request-consult" for a "Process Request" eConsult Task

.authoredOn

  • indicates the dateTime that the eReferral was received
  • usually the same as ServiceRequest.authoredOn, except in cases when ServiceRequest.authoredOn is used to record that a request was signed by the requester before the transmission took place

.lastModified

  • indicates the dateTime when an update of note/significance was made to the referral (i.e., related resources such as ServiceRequest, patient, Task, Appointment, etc...)

.owner

  • a reference to the PractitionerRole responsible for handling the referral
  • if the Task is being transmitted via messaging, this element SHALL either:
    • .reference a resource included in the message as a Bundle.entry, or
    • include an .identifier previously known to both systems

.output

  • MAY to used to provide the outcome of a Referral
  • SHALL contain a reference to Communication when an eConsult is provided by a specialist