---
sourceDocument: Brazil Customer Service Management
sourceDocumentLink: https://www.servicenow.com/docs/r/customer-service-management

 Release :

    - brazil

ft:locale :

    - en-US

ft:publication_title :

    - Brazil Customer Service Management

ft:clusterId :

    - csm

bundleId :

    - csm

workflow :

    - Customer and Industry


---

# Trigger a flow from a task plan template item

# Trigger a flow from a task plan template item {#ariaid-title1}

Release version: Brazil  
Updated September 10, 2026  
![](https://www.servicenow.com/docs/portal-asset/ico-clock) 2 minutes to read  
Configure a flow to run automatically when a task plan template item creates a record. A single step of a task plan can be completed by a flow, a subflow, or an AI agent.

## Before you begin

Role required: `sn_task_plan.admin` or `sn_task_plan.creator` role to configure the template item, and a role that allows you to create and activate flows in Workflow Studio.

* A task plan template with at least one template item. Note the number of the template item that the flow must run for, such as PI0001001.
* A reference field on the target table of the template item that points to the Template Item table `[sn_task_plan_template_item]`. This field is available by default on some tables. If the target table does not have it, create it before you start.

## About this task

Use this procedure when one step of a task plan needs work that the task plan template can't do on its own. Examples include validating data in an external system or handing the task to an AI agent.

You configure the template item to stamp its number on each record it creates, and then create a flow that uses that stamped value as its trigger condition. For more information, see [Flow-based automation for task plan template items](https://www.servicenow.com/docs/eW5LvdJkMmsWLkjbjunFFw "A task plan template item stamps its number on each record it creates. A flow can use that stamped value as a trigger condition, so the flow runs automatically for the records that one specific template item creates.").

## Procedure

1. Configure the template item to stamp its number on the records it creates.
   1. Navigate to AllTask Plan TemplatesDraft Task Plan Templates.
   2. Select a task plan template record number to display the record.
   3. Select the Template items tab and open the template item that the flow must run for.
   4. In the Template item field field, select the field on the target table that references the template item.  
      For more information about this field, see [Template item form](https://www.servicenow.com/docs/pAAIasyVJtmbs14710md~A "The Template item form displays details about a template item for a task plan template.").
   5. Select Save.
2. In Workflow Studio, create a flow.
3. Define the trigger for the flow.
   1. In the Trigger field, select Created.
   2. In the Table field, select the target table of the template item.
   3. Add a condition where the reference field that you selected in step 1 is the number of the template item.  
      For example, if the target table is the Task \[task\] table and the template item is PI0001001, the condition is \[Template Item\] \[is\] \[PI0001001\].
   4. Select Done.
4. Add the actions that the flow must perform, and then select Done.  
   The actions can update the record that triggered the flow, call an existing subflow, or call an AI agent. For example, a flow can set the Assigned to and Priority fields on the new task and then send an email notification to the assigned agent.

   To pass the new record to a subflow, map the task record from the trigger to the subflow input.
5. Save and activate the flow.
6. **Optional:** Repeat this procedure for each template item in the task plan template that needs its own flow.

## Result

When the task plan template is applied, the template item creates its record and the system stamps the template item number in the reference field on that record. The record then meets the trigger condition of the flow,
and the flow runs its actions.

## What to do next

To confirm that the flow ran, open the record that the template item created. The reference field displays the number of the template item, and the fields that the flow updates display their new values.

*[\>]: and then


