Create/Edit State
Esta página aún no se encuentra traducida al español.
States are the different moments or statuses through which a task could pass by in its lifecycle within the workflow.
How to Create a State
To create a new state, press the + icon (circled in red in the image below) in the states section of the create/edit workflow settings panel.

- New states can only be created when editing an existing workflow.
- To add states to your workflow, they must previously exist as elements in a collection assigned to the workflow.
- The collection is assigned through the State list field in the workflow settings panel.
How to Edit a State
Choose from the table in states section of the create/edit workflow settings panelthe state you wish to edit.

Settings Panel Layot
After choosing to create or edit a state, you will be taken to the following settings panel:

Options:
- Save: save the current configuration
Settings:
A. General information

Indicates the state type. Options are: new (connects with start), in progress (connects to other states), or closed (connects to end).
The state should already exist as an element in the collection selected previously in the State list field in the States section.
B. State changes

Creates an action button in the workflow's channel that indicates how a state change can be triggered. Options are:
- None: The action button is not created. Use this option to change states through other means, like: survey trigger, task view, a routine-stage bot, or through API.
- Survey: A survey is added as an option in the actions button. The start form field appears. There you can indicate which survey should be summoned.
- Manual: Adds the state itself as an option in the actions button.
Click here to see where to find the actions button in the channel and how the options appear in it.
Appears when survey is chosen in Can change. Indicates that a survey will change the workflow's state. Remember to previously create the survey and choose it from the dropdown menu where all existing surveys will appear as options.
Go to Start Forms for more setup information.
Users are assigned permissions through their access roles.
Click here to learn more about routines.
C. Subtask
See section below for more information about subtasks.

Click here to learn more about routines.
D. Survey triggers

Go to State Start Form for setup information.
Click here to learn more about routines.
Best Practices
Task State Names
State names should begin with a number or individual letter corresponding to their order in the group panel and task view. For example: "1. Backlog", "2. Doing", "3. Finished", "4. Unable to Complete". Since states are elements within collections, their names are configured and edited from the settings panel in the Database panel.
Routines associated with state changes.
A task can change from one state to another through different means, e.g., a state start form, a survey trigger, the task view, a routine-stage bot, the action button, or an API request. If a routine is to be associated with the state change, it is highly recommended to add the routine in the State Change and not through other means, like a survey or a routine-stage bot.
State Change Notification
When a state change occurs, a notification should be sent in the task's chat channel to notify users of the change. The notification can be programmed to appear through the routines associated with state changes. It is recommended that notifications should include a title, referencing the action taken, and a body indicating what can be done in the new state.
State Change Survey Trigger
Use survey triggers when the answer to a survey question determines the next state. For example, if a user is asked to validate a job, whether it gets validated or not will affect the status of the task.
Surveys Associated to Task States
If a survey is to be made available only within a specific task state, the element that represents the state must be associated with the survey. In case the survey has to be available in more than one task state, a collection with elements that are to be required to view the survey should be created.
For example, you can use an element to make a survey available in a channel at a specific moment. First, create the element and associate it manually to the survey. Then you can associate the element to the desired channel through a routine. Afterward, when the state has changed, the associated element can be taken off the channel through another routine to make the survey no longer visible.
More About Subtask States
- Subtask states are intertwined with their parent workflow. Since a workflow can have diverse subtasks depending on its state, a workflow's state affects subtasks, i.e., it defines its subtasks.
- A change of workflow state must allow subtasks to change state as well. If the initial and succeeding states have the same subtask, this is not required.
- If a workflow is changing to a closed type state, all of its subtasks must also be closed. This is not done automatically since it is an irreversible change. Therefore, before changing to the closed state, all the subtasks must be manually closed.