Using the workflow editor
Build, run, debug, and deploy workflows by using the workflow editor.
Building workflows
Workflows consist of a set of blocks that are processed in a logical sequence to return a result.
To build your workflow in the editor, you create variables and choose which blocks you want to use to manipulate them. You then configure the block sequence and logic to fulfill the goal of the workflow.
You can use internal code blocks that manipulate variables directly, such as the Assign or If blocks. You can also use integration blocks to submit API calls to external services, then evaluate the API response data in other blocks.
After your workflow is built, you can run, test, and refine it in the editor.
Opening the editor
In the dashboard, click Workflows.
- By creating a workflow.
- By clicking an existing workflow.
- By selecting an existing workflow and opening it via the Actions menu.
Layout types
- Flow layout
- A logical representation of the workflow structure that is similar to a flowchart.
- In this layout type, you must use the object editor to view and update block properties. For more information about the object editor, see Editing block properties.
- You can use the mini-map to go to any block by moving the mouse inside the map.
- Flat layout
- A sequential representation of the workflow structure, where the blocks are shown in the sequence that they are processed in the workflow.
- In this layout type, each block is numbered. This numbering represents the order in which the blocks are processed when the workflow runs.
Starting in 1.1.5, when you create a workflow, you can choose which layout type you want to use to show the workflow in the editor. In earlier versions, the flow layout type is used by default.
You can switch between these layout types at any time by clicking either the Flow layout or Flat layout buttons in the editor toolbar.
Workflow structure
In its most basic form, a workflow consists of a Start block, an Assign block, and an End block. This structure represents the beginning, middle, and end of the workflow.
The ‘Hello, World!’ workflow template uses this structure. In 1.1.4 and earlier versions, when you create a workflow, this template is used by default. Starting in 1.1.5, you can also choose other templates, which might include additional blocks in their structures.
Start block
In the Start block, you define the variables that you want to use in your workflow. When you define variables, you can indicate their type, default value, and whether they are input, output, or required variables.
The result variable is created by default. You might find this variable useful, for example, if you want to return a value from your workflow that indicates whether the workflow succeeded. In the System variables section, you can enable header and body variables, then use them in your workflow.
In the cURL section, you can view a sample of the RESTful endpoint for a workflow. You can use this sample to test an API call to the workflow from a remote system. In the Group field, you can select which worker group you want to use to complete the workflow. In the MET field, you can choose how to calculate the time that is saved by running this workflow. You can calculate it automatically or enter a manual value.
In the flow editor, by default, you cannot view the cURL, Group, or MET values. To view them, you must switch the editor view of this block by clicking the double-arrow icon.
For more information about this block, see Start.
Integration blocks
In the side panel, the list of integration blocks is shown. This list contains the default and installed blocks that you can use to build your workflow, including internal blocks that manipulate variables and blocks that submit API calls to external services.
- Click the deep search icon to search all subfolders and return all matching blocks and folders.
- Click Group deep search results by folders to organize the matching results by their origin folders.
You can also search for API endpoint paths, such as /v1/api-keys/.
After you find the block that you want, you can drag and drop it onto your chosen location in the workflow. Alternatively, in the block, click Take block, then click the location in the workflow where you want to drop the block. After you drop the block, you can view more information about its parameters by hovering your mouse over them.
You can store blocks and workflows that you use regularly in custom folders like Favorites, User, and Shared.
Block features and actions
- When you place a block into a workflow, the block is given a customizable name that is similar to its standard one. For example, if you drop an Assign block into your workflow, the block is given a name similar to Assign_1. To refer to this block elsewhere in the workflow, you must use this name.
- In the flow editor, under the block name, a message is shown that relates to the status and logic of the block. For example, if you use an Assign block to assign the string
‘Hello, World!’to theresultvariable, the text“$result = ‘Hello, World!’”is shown. - In some workflow blocks, you can view a list of output variables in the Output variables section.
- In 1.1.4 and earlier versions, you can view this section only in the flat layout, and you cannot view the lower-level variables of nested variables, such as objects and arrays.
- Starting in 1.1.5, you can view the Output variables section in both the flow and flat layouts. In addition, nested variables are shown in a tree structure that is expandable and searchable. You can expand the tree nodes to view lower-level variables and search the structure for particular variables. At all levels, you can copy variable names and view variable types.
- To see the block’s folder path in the list of integrations, for example, system folder/Common folder/Assign, hover the mouse over the block’s title.
- When you edit block variables, the built-in JSON editor is used. You can take advantage of language-specific shortcuts and features, such as auto-suggestion.
| Action | Steps |
|---|---|
| Copy a block | Click the block, then complete only one of these actions:
|
| Clone a block | Click the block’s overflow (three-dot) button, then click Clone. |
| Collapse or expand a block (flat editor only) | In the block header, click the chevron. |
| Cut a block | Click the block, then complete only one of these actions:
|
| Disable a block |
|
| Find a block in the integration list | Click the block’s overflow (three-dot) button, then click Locate. |
| Move a block |
|
| Paste a block |
|
| Remove a block |
|
| Reposition one or more blocks |
|
Editing block properties
To edit and view block properties more easily, use the object editor. In the flow layout, when you click a block, the object editor is shown by default. In the flat layout, you can access the editor by clicking Tools. Use the object editor to manage almost all block properties or add new ones from scratch. For more information, see Object editor.
Authentications
- By clicking Auth and creating an authentication.
- By adding an authentication variable in the Start block.
- By adding authentication key variables in other workflow blocks that use authentication.
For more information, see Using authentications in workflows.
Other editor features and actions
- YAML and JSON editors
-
In the editor toolbar, click Flow YAML/JSON to manage the entire workflow in built-in YAML and JSON editors. The YAML and JSON code blocks are shown in separate editor tabs.
- Quick access menu
-
To quickly access your favorite integration blocks or add a custom comment, hover the mouse between any two blocks and click the + icon. The quick access menu is shown.
- Keyboard shortcuts
-
To open a list of available keyboard shortcuts, click the main overflow (three-dot) menu, then click Shortcuts. View the shortcuts to perform several tasks, such as running, saving, and debugging workflows.
You can disable keyboard shortcuts. This setting persists only for your current device. If you restart your browser on the device, the shortcuts remain disabled.
- Workflow version control
-
Starting in 1.1.4, you can implement version control for your workflow configuration. Each time that you save your workflow, a new version is created. To view the list of saved versions, click the Versions toolbar button. The list of saved versions is shown.
From the list, you can open an old version, rename a version, restore a version to become the latest one, or save a version as a separate workflow.
You can deploy, tile, and schedule specific versions of workflows. For more information, see Workflow version control.
- Basic actions
-
You can also perform these actions:
Table 2. Editor actions Action Steps Rename the workflow Complete only one of these steps: - Click the workflow title, enter the new name, and click the tick icon.
- In the main overflow (three-dot) menu, click Rename, and specify the name and location.
Save a copy of the workflow In the main overflow (three-dot) menu, click Save as, and specify the name and location. Undo or redo an action In the toolbar, click the Undo or Redo buttons. Update the flow description - In the Start block, click the Description field and enter the description.
- Click outside the field to save the description.
View workflow metadata (1.1.4 and later versions) In the main overflow (three-dot) menu, click About workflow and view this information about the workflow: - Its hash value.
- Its creation date.
- The date when it was last modified and the user who modified it.
- The time that you save by using it, that is, the manual execution time (MET).
- The number of action blocks that it contains.
Running workflows
- By clicking Run to run the workflow with the default input values.
- By clicking the overflow (three-dot) menu, clicking Run with Custom Inputs to customize the input values that you defined for the workflow, and clicking Run.
For more information, see Running workflows.
Debugging workflows
If you need to investigate and resolve issues with your workflow, you can use the debugger by clicking Tools, then clicking the Debugger section. You can set debug breakpoints on workflow blocks, then click Debug to run the workflow in debugging mode.
For more information, see Debugging workflows.
Deploying workflows
When you are ready to deploy your workflow, save your updates and click Deploy workflow. In the Deploy Workflow page, link the workflow to an API, stage, and endpoint, and click Deploy.
For more information, see Deploying workflows.