FHIR © HL7.org  |  Server Home  |  Health Intersections FHIR Server v1.0.287  |  FHIR Version 4.0.0  | User: ANONYMOUS (Unknown)  

Resource "PlanDefinition-apply" Version "1" (OperationDefinition)

Tags:

XML or JSON representation . provenance for this resource

Apply

OPERATION: Apply

The official URL for this operation definition is:

http://hl7.org/fhir/OperationDefinition/PlanDefinition-apply

The apply operation applies a PlanDefinition to a given context

URL: [base]/PlanDefinition/$apply

URL: [base]/PlanDefinition/[id]/$apply

Parameters

Use Name Cardinality Type Binding Documentation
IN planDefinition 0..1 PlanDefinition

The plan definition to be applied. If the operation is invoked at the instance level, this parameter is not allowed; if the operation is invoked at the type level, this parameter is required

IN subject 1..* string
( reference)

The subject(s) that is/are the target of the plan to be applied. The subject may be a Patient, Practitioner, Organization, Location, Device, or Group. Subjects provided in this parameter will be resolved as the subject of the PlanDefinition based on the type of the subject. If multiple subjects of the same type are provided, the behavior is implementation-defined

IN encounter 0..1 string
( reference)

The encounter in context, if any

IN practitioner 0..1 string
( reference)

The practitioner applying the plan definition

IN organization 0..1 string
( reference)

The organization applying the plan definition

IN userType 0..1 CodeableConcept

The type of user initiating the request, e.g. patient, healthcare provider, or specific type of healthcare provider (physician, nurse, etc.)

IN userLanguage 0..1 CodeableConcept

Preferred language of the person using the system

IN userTaskContext 0..1 CodeableConcept

The task the system user is performing, e.g. laboratory results review, medication list review, etc. This information can be used to tailor decision support outputs, such as recommended information resources

IN setting 0..1 CodeableConcept

The current setting of the request (inpatient, outpatient, etc.)

IN settingContext 0..1 CodeableConcept

Additional detail about the setting of the request, if any

OUT return 1..1 CarePlan

The CarePlan that is the result of applying the plan definition

The result of this operation is a CarePlan resource with a single activity represented by a RequestGroup. The RequestGroup will have actions for each of the applicable actions in the plan based on evaluating the applicability condition in context. For each applicable action, the definition is applied as described in the $apply operation of the ActivityDefinition resource, and the resulting resource is added as an activity to the CarePlan. If the ActivityDefinition includes library references, those libraries will be available to the evaluated expressions. If those libraries have parameters, those parameters will be bound by name to the parameters given to the operation. In addition, parameters to the $apply operation are available within dynamicValue expressions as context variables, accessible by the name of the parameter, prefixed with a percent (%) symbol. For a more detailed description, refer to the PlanDefinition and ActivityDefinition resource documentation


{
  "resourceType" : "OperationDefinition",
  "id" : "PlanDefinition-apply",
  "meta" : {
    "versionId" : "1",
    "lastUpdated" : "2018-12-14T02:02:44.301Z"
  },
  "text" : {
    "status" : "generated",
    "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n <h2>Apply</h2>\n <p>OPERATION: Apply</p>\n <p>The official URL for this operation definition is: </p>\n <pre>http://hl7.org/fhir/OperationDefinition/PlanDefinition-apply</pre>\n <div>\n <p>The apply operation applies a PlanDefinition to a given context</p>\n\n </div>\n <p>URL: [base]/PlanDefinition/$apply</p>\n <p>URL: [base]/PlanDefinition/[id]/$apply</p>\n <p>Parameters</p>\n <table class=\"grid\">\n <tr>\n <td>\n <b>Use</b>\n </td>\n <td>\n <b>Name</b>\n </td>\n <td>\n <b>Cardinality</b>\n </td>\n <td>\n <b>Type</b>\n </td>\n <td>\n <b>Binding</b>\n </td>\n <td>\n <b>Documentation</b>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>planDefinition</td>\n <td>0..1</td>\n <td>\n <a href=\"plandefinition.html\">PlanDefinition</a>\n </td>\n <td/>\n <td>\n <div>\n <p>The plan definition to be applied. If the operation is invoked at the instance level, this parameter is not allowed; if the operation is invoked at the type level, this parameter is required</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>subject</td>\n <td>1..*</td>\n <td>\n <a href=\"datatypes.html#string\">string</a>\n <br/>(\n <a href=\"search.html#reference\">reference</a>)\n </td>\n <td/>\n <td>\n <div>\n <p>The subject(s) that is/are the target of the plan to be applied. The subject may be a Patient, Practitioner, Organization, Location, Device, or Group. Subjects provided in this parameter will be resolved as the subject of the PlanDefinition based on the type of the subject. If multiple subjects of the same type are provided, the behavior is implementation-defined</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>encounter</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#string\">string</a>\n <br/>(\n <a href=\"search.html#reference\">reference</a>)\n </td>\n <td/>\n <td>\n <div>\n <p>The encounter in context, if any</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>practitioner</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#string\">string</a>\n <br/>(\n <a href=\"search.html#reference\">reference</a>)\n </td>\n <td/>\n <td>\n <div>\n <p>The practitioner applying the plan definition</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>organization</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#string\">string</a>\n <br/>(\n <a href=\"search.html#reference\">reference</a>)\n </td>\n <td/>\n <td>\n <div>\n <p>The organization applying the plan definition</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>userType</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#CodeableConcept\">CodeableConcept</a>\n </td>\n <td/>\n <td>\n <div>\n <p>The type of user initiating the request, e.g. patient, healthcare provider, or specific type of healthcare provider (physician, nurse, etc.)</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>userLanguage</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#CodeableConcept\">CodeableConcept</a>\n </td>\n <td/>\n <td>\n <div>\n <p>Preferred language of the person using the system</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>userTaskContext</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#CodeableConcept\">CodeableConcept</a>\n </td>\n <td/>\n <td>\n <div>\n <p>The task the system user is performing, e.g. laboratory results review, medication list review, etc. This information can be used to tailor decision support outputs, such as recommended information resources</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>setting</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#CodeableConcept\">CodeableConcept</a>\n </td>\n <td/>\n <td>\n <div>\n <p>The current setting of the request (inpatient, outpatient, etc.)</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>IN</td>\n <td>settingContext</td>\n <td>0..1</td>\n <td>\n <a href=\"datatypes.html#CodeableConcept\">CodeableConcept</a>\n </td>\n <td/>\n <td>\n <div>\n <p>Additional detail about the setting of the request, if any</p>\n\n </div>\n </td>\n </tr>\n <tr>\n <td>OUT</td>\n <td>return</td>\n <td>1..1</td>\n <td>\n <a href=\"careplan.html\">CarePlan</a>\n </td>\n <td/>\n <td>\n <div>\n <p>The CarePlan that is the result of applying the plan definition</p>\n\n </div>\n </td>\n </tr>\n </table>\n <div>\n <p>The result of this operation is a CarePlan resource with a single activity represented by a RequestGroup. The RequestGroup will have actions for each of the applicable actions in the plan based on evaluating the applicability condition in context. For each applicable action, the definition is applied as described in the $apply operation of the ActivityDefinition resource, and the resulting resource is added as an activity to the CarePlan. If the ActivityDefinition includes library references, those libraries will be available to the evaluated expressions. If those libraries have parameters, those parameters will be bound by name to the parameters given to the operation. In addition, parameters to the $apply operation are available within dynamicValue expressions as context variables, accessible by the name of the parameter, prefixed with a percent (%) symbol. For a more detailed description, refer to the PlanDefinition and ActivityDefinition resource documentation</p>\n\n </div>\n </div>"
  },
  "extension" : [
    {
      "url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
      "valueInteger" : 2
    },
    {
      "url" : "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
      "valueCode" : "trial-use"
    }
  ],
  "url" : "http://hl7.org/fhir/OperationDefinition/PlanDefinition-apply",
  "version" : "4.0.0",
  "name" : "Apply",
  "status" : "draft",
  "kind" : "operation",
  "date" : "2018-12-14T01:14:32+00:00",
  "publisher" : "HL7 (FHIR Project)",
  "contact" : [
    {
      "telecom" : [
        {
          "system" : "url",
          "value" : "http://hl7.org/fhir"
        },
        {
          "system" : "email",
          "value" : "fhir@lists.hl7.org"
        }
      ]
    }
  ],
  "description" : "The apply operation applies a PlanDefinition to a given context",
  "code" : "apply",
  "comment" : "The result of this operation is a CarePlan resource with a single activity represented by a RequestGroup. The RequestGroup will have actions for each of the applicable actions in the plan based on evaluating the applicability condition in context. For each applicable action, the definition is applied as described in the $apply operation of the ActivityDefinition resource, and the resulting resource is added as an activity to the CarePlan. If the ActivityDefinition includes library references, those libraries will be available to the evaluated expressions. If those libraries have parameters, those parameters will be bound by name to the parameters given to the operation. In addition, parameters to the $apply operation are available within dynamicValue expressions as context variables, accessible by the name of the parameter, prefixed with a percent (%) symbol. For a more detailed description, refer to the PlanDefinition and ActivityDefinition resource documentation",
  "resource" : [
    "PlanDefinition"
  ],
  "system" : false,
  "type" : true,
  "instance" : true,
  "parameter" : [
    {
      "name" : "planDefinition",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The plan definition to be applied. If the operation is invoked at the instance level, this parameter is not allowed; if the operation is invoked at the type level, this parameter is required",
      "type" : "PlanDefinition"
    },
    {
      "name" : "subject",
      "use" : "in",
      "min" : 1,
      "max" : "*",
      "documentation" : "The subject(s) that is/are the target of the plan to be applied. The subject may be a Patient, Practitioner, Organization, Location, Device, or Group. Subjects provided in this parameter will be resolved as the subject of the PlanDefinition based on the type of the subject. If multiple subjects of the same type are provided, the behavior is implementation-defined",
      "type" : "string",
      "searchType" : "reference"
    },
    {
      "name" : "encounter",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The encounter in context, if any",
      "type" : "string",
      "searchType" : "reference"
    },
    {
      "name" : "practitioner",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The practitioner applying the plan definition",
      "type" : "string",
      "searchType" : "reference"
    },
    {
      "name" : "organization",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The organization applying the plan definition",
      "type" : "string",
      "searchType" : "reference"
    },
    {
      "name" : "userType",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The type of user initiating the request, e.g. patient, healthcare provider, or specific type of healthcare provider (physician, nurse, etc.)",
      "type" : "CodeableConcept"
    },
    {
      "name" : "userLanguage",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "Preferred language of the person using the system",
      "type" : "CodeableConcept"
    },
    {
      "name" : "userTaskContext",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The task the system user is performing, e.g. laboratory results review, medication list review, etc. This information can be used to tailor decision support outputs, such as recommended information resources",
      "type" : "CodeableConcept"
    },
    {
      "name" : "setting",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "The current setting of the request (inpatient, outpatient, etc.)",
      "type" : "CodeableConcept"
    },
    {
      "name" : "settingContext",
      "use" : "in",
      "min" : 0,
      "max" : "1",
      "documentation" : "Additional detail about the setting of the request, if any",
      "type" : "CodeableConcept"
    },
    {
      "name" : "return",
      "use" : "out",
      "min" : 1,
      "max" : "1",
      "documentation" : "The CarePlan that is the result of applying the plan definition",
      "type" : "CarePlan"
    }
  ]
}