<StructureDefinition xmlns="http://hl7.org/fhir">
  <url value="http://telus.com/fhir/patientChart/StructureDefinition/profile-my-care-plan" />
  <name value="CarePlan" />
  <status value="draft" />
  <fhirVersion value="4.0.1" />
  <kind value="resource" />
  <abstract value="false" />
  <type value="CarePlan" />
  <baseDefinition value="http://hl7.org/fhir/StructureDefinition/CarePlan" />
  <derivation value="constraint" />
  <differential>
    <element id="CarePlan">
      <path value="CarePlan" />
      <comment value="Usage:   DW is only implementing when care plan is documented in MA" />
    </element>
    <element id="CarePlan.id">
      <path value="CarePlan.id" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.meta">
      <path value="CarePlan.meta" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.meta.lastUpdated">
      <path value="CarePlan.meta.lastUpdated" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.meta.source">
      <path value="CarePlan.meta.source" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.meta.profile">
      <path value="CarePlan.meta.profile" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.text">
      <path value="CarePlan.text" />
      <comment value="Usage Note:   The visual representation, eg PDF can be included here.   &#xD;&#xA;&#xD;&#xA;Contained resources do not have narrative. Resources that are not contained SHOULD have a narrative. In some cases, a resource may only have text with little or no additional discrete data (as long as all minOccurs=1 elements are satisfied).  This may be necessary for data from legacy systems where information is captured as a &quot;text blob&quot; or where text is additionally entered raw or narrated and encoded information is added later." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.status">
      <path value="CarePlan.status" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.intent">
      <path value="CarePlan.intent" />
      <comment value="Usage Note:   Typically a value of plan will be used by the EMRs.  A draft plan that is returned from decision support, or a recommendation will be a proposal.   Order and option are rarely used.&#xD;&#xA;&#xD;&#xA;This element is labeled as a modifier because the intent alters when and how the resource is actually applicable." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.title">
      <path value="CarePlan.title" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.subject">
      <path value="CarePlan.subject" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.subject.reference">
      <path value="CarePlan.subject.reference" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.subject.display">
      <path value="CarePlan.subject.display" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.period">
      <path value="CarePlan.period" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.period.start">
      <path value="CarePlan.period.start" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.period.end">
      <path value="CarePlan.period.end" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.author">
      <path value="CarePlan.author" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.author.reference">
      <path value="CarePlan.author.reference" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.author.display">
      <path value="CarePlan.author.display" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.supportingInfo">
      <path value="CarePlan.supportingInfo" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.supportingInfo.reference">
      <path value="CarePlan.supportingInfo.reference" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.supportingInfo.display">
      <path value="CarePlan.supportingInfo.display" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.goal">
      <path value="CarePlan.goal" />
      <comment value="Usage Note:   MA does support structured goals; other EMRs do not&#xD;&#xA;&#xD;&#xA;Goal can be achieving a particular change or merely maintaining a current state or even slowing a decline." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.goal.reference">
      <path value="CarePlan.goal.reference" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.goal.display">
      <path value="CarePlan.goal.display" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity">
      <path value="CarePlan.activity" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.outcomeCodeableConcept">
      <path value="CarePlan.activity.outcomeCodeableConcept" />
      <comment value="Usage:   Used when the planned activity is completed&#xD;&#xA;Note:  This will be renamed in R5 to PerformedActivity&#xD;&#xA;&#xD;&#xA;Note that this should not duplicate the activity status (e.g. completed or in progress)." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.outcomeReference">
      <path value="CarePlan.activity.outcomeReference" />
      <comment value="Usage:   Used when the planned activity is completed &#xD;&#xA;Note:  Note:  This will be renamed in R5 to PerformedActivity with a codeableReference&#xD;&#xA;&#xD;&#xA;The activity outcome is independent of the outcome of the related goal(s).  For example, if the goal is to achieve a target body weight of 150 lbs and an activity is defined to diet, then the activity outcome could be calories consumed whereas the goal outcome is an observation for the actual body weight measured." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.outcomeReference.reference">
      <path value="CarePlan.activity.outcomeReference.reference" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.outcomeReference.display">
      <path value="CarePlan.activity.outcomeReference.display" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.reference">
      <path value="CarePlan.activity.reference" />
      <comment value="Usage Note:   This is used to record a Planned Activity Reference.  Alternatively, the activity.detail may be specified.   Either reference or detail are specified; not both.&#xD;&#xA;&#xD;&#xA;Standard extension exists ([resource-pertainsToGoal](extension-resource-pertainstogoal.html)) that allows goals to be referenced from any of the referenced resources in CarePlan.activity.reference.  &#xD;The goal should be visible when the resource referenced by CarePlan.activity.reference is viewed independently from the CarePlan.  Requests that are pointed to by a CarePlan using this element should *not* point to this CarePlan using the &quot;basedOn&quot; element.  i.e. Requests that are part of a CarePlan are not &quot;based on&quot; the CarePlan." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.detail">
      <path value="CarePlan.activity.detail" />
      <comment value="Usage Note:  Thsi will be used for planned activities, eg kind=task, rather than a reference&#xD;&#xA;In R5, this becomes CarePlan.activity.plannedActivityDetail" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.detail.kind">
      <path value="CarePlan.activity.detail.kind" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.detail.code">
      <path value="CarePlan.activity.detail.code" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.detail.code.text">
      <path value="CarePlan.activity.detail.code.text" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.activity.detail.status">
      <path value="CarePlan.activity.detail.status" />
      <comment value="Usage Note:   entered-in-error may only be used on an update.   MAIREAD - more details please&#xD;&#xA;&#xD;&#xA;Some aspects of status can be inferred based on the resources linked in actionTaken.  Note that &quot;status&quot; is only as current as the plan was most recently updated.  &#xA;The unknown code is not to be used to convey other statuses.  The unknown code should be used when one of the statuses applies, but the authoring system doesn't know the current state of the activity." />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.note">
      <path value="CarePlan.note" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.note.author[x]">
      <path value="CarePlan.note.author[x]" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.note.time">
      <path value="CarePlan.note.time" />
      <mustSupport value="true" />
    </element>
    <element id="CarePlan.note.text">
      <path value="CarePlan.note.text" />
      <mustSupport value="true" />
    </element>
  </differential>
</StructureDefinition>