<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="9ea2ad10-76be-4fc9-b38f-05704c73f845" />
  <meta>
    <lastUpdated value="2019-01-08T15:38:23.41+00:00" />
  </meta>
  <url value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinition" />
  <version value="1" />
  <name value="PlanDefinition" />
  <title value="Plan Definition" />
  <status value="draft" />
  <date value="2019-01-08T14:16:13.642073+00:00" />
  <publisher value="Philips" />
  <description value="The (reusable) definition of a care plan. Making this applicable to a Patient is done by creating a CarePlan resource." />
  <fhirVersion value="3.0.1" />
  <kind value="resource" />
  <abstract value="false" />
  <type value="PlanDefinition" />
  <baseDefinition value="http://hl7.org/fhir/StructureDefinition/PlanDefinition" />
  <derivation value="constraint" />
  <differential>
    <element id="PlanDefinition">
      <path value="PlanDefinition" />
      <short value="The (reusable) definition of a care plan. Making this applicable to a Patient is done by creating a CarePlan resource." />
      <definition value="This resource allows for the definition of a self-management care plan that can be delivered by the HealthyMe solution." />
    </element>
    <element id="PlanDefinition.extension">
      <path value="PlanDefinition.extension" />
      <slicing>
        <discriminator>
          <type value="value" />
          <path value="url" />
        </discriminator>
        <rules value="open" />
      </slicing>
    </element>
    <element id="PlanDefinition.extension:category">
      <path value="PlanDefinition.extension" />
      <sliceName value="category" />
      <max value="1" />
      <type>
        <code value="Extension" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinitionCategory" />
      </type>
    </element>
    <element id="PlanDefinition.extension:duration">
      <path value="PlanDefinition.extension" />
      <sliceName value="duration" />
      <short value="Duration of plan execution" />
      <definition value="Duration of plan execution (e.g., 90 days, 2 years, …)" />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Extension" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinitionDuration" />
      </type>
    </element>
    <element id="PlanDefinition.extension:price">
      <path value="PlanDefinition.extension" />
      <sliceName value="price" />
      <short value="The amount to be paid by the patient" />
      <definition value="The amount to be paid by the patient (absent means free)" />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Extension" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinitionPrice" />
      </type>
    </element>
    <element id="PlanDefinition.extension:rating">
      <path value="PlanDefinition.extension" />
      <sliceName value="rating" />
      <short value="Average rating in the reviews" />
      <definition value="The average rating in the reviews (absent in case of no rated reviews)" />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Extension" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinitionRating" />
      </type>
    </element>
    <element id="PlanDefinition.extension:review">
      <path value="PlanDefinition.extension" />
      <sliceName value="review" />
      <short value="Reviews for the care plan" />
      <definition value="A list of reviews for the care plan each consisting of a rating (integer 1-5) and a string" />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Extension" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinitionReview" />
      </type>
    </element>
    <element id="PlanDefinition.extension:review.extension">
      <path value="PlanDefinition.extension.extension" />
      <slicing>
        <discriminator>
          <type value="value" />
          <path value="url" />
        </discriminator>
        <rules value="open" />
      </slicing>
    </element>
    <element id="PlanDefinition.extension:review.extension:rating">
      <path value="PlanDefinition.extension.extension" />
      <sliceName value="rating" />
      <slicing>
        <discriminator>
          <type value="value" />
          <path value="url" />
        </discriminator>
        <description value="Extensions are always sliced by (at least) url" />
        <rules value="open" />
      </slicing>
      <short value="Rating (1-5) for care plan" />
      <definition value="A rating (an integer between 1 and 5) for the care plan" />
      <max value="1" />
    </element>
    <element id="PlanDefinition.extension:review.extension:text">
      <path value="PlanDefinition.extension.extension" />
      <sliceName value="text" />
      <slicing>
        <discriminator>
          <type value="value" />
          <path value="url" />
        </discriminator>
        <description value="Extensions are always sliced by (at least) url" />
        <rules value="open" />
      </slicing>
      <short value="Text of the review" />
      <definition value="Text of the review" />
      <max value="1" />
    </element>
    <element id="PlanDefinition.extension:image">
      <path value="PlanDefinition.extension" />
      <sliceName value="image" />
      <short value="Image illustrating the care plan" />
      <definition value="An image illustrating the care plan definition" />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Extension" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/PlanDefinitionImage" />
      </type>
    </element>
    <element id="PlanDefinition.title">
      <path value="PlanDefinition.title" />
      <min value="1" />
    </element>
    <element id="PlanDefinition.publisher">
      <path value="PlanDefinition.publisher" />
      <short value="Organization that manages the care plans based on this definition" />
      <definition value="The name of the individual or organization that manages the care plans based on this definition." />
      <min value="1" />
    </element>
    <element id="PlanDefinition.description">
      <path value="PlanDefinition.description" />
      <min value="1" />
    </element>
    <element id="PlanDefinition.useContext">
      <path value="PlanDefinition.useContext" />
      <short value="Criteria defining for whom this care plan is applicable" />
      <definition value="This provides inclusion criteria based on gender, age, or clinical condition (code=focus). A clinical condition can be specified as an exclusion criterion by specifying code 77765009 (Exclude) from system http://snomed.info/sct." />
    </element>
    <element id="PlanDefinition.useContext.code">
      <path value="PlanDefinition.useContext.code" />
      <binding>
        <extension url="http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName">
          <valueString value="UsageContextType" />
        </extension>
        <strength value="required" />
        <valueSetUri value="http://healthyme.philips.com/fhir/ValueSet/CarePlan-UseContext" />
      </binding>
    </element>
    <element id="PlanDefinition.relatedArtifact">
      <path value="PlanDefinition.relatedArtifact" />
      <short value="Consent policy to enroll" />
      <definition value="A Consent Policy describing the consent needed in order to enrol in a care plan. Any associated Care Plan can only become active after the patient has expressed (active) Consent towards the associated Consent Policy" />
      <max value="1" />
      <type>
        <code value="RelatedArtifact" />
        <profile value="http://healthyme.philips.com/fhir/StructureDefinition/ConsentPolicy" />
      </type>
    </element>
    <element id="PlanDefinition.action.definition">
      <path value="PlanDefinition.action.definition" />
      <min value="1" />
      <type>
        <code value="Reference" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/ActivityDefinition" />
      </type>
    </element>
  </differential>
</StructureDefinition>