Application

Workflow Trigger Node

The Workflow Trigger Node allows an Application Workflow to trigger another Application Workflow to run. It works by enabling one workflow to ‘press’ the Virtual Button of another workflow. Data from the payload can be sent between Workflows.

Workflow Trigger Node

Node Properties

Selecting Desired Behavior

First, select the desired node behavior. You may specify to run the target trigger immediately, schedule a future run, or cancel a scheduled future run.

Behavior Options

Selecting Scheduled Run Behavior

If you choose to schedule a workflow for a future date and time, you must select whether to run at a relative time in the future or at a specific date and time.

Scheduled Run Options

Seconds Template

If you choose to schedule a workflow run for a relative time in the future, you must enter the number of seconds in the future you would like the workflow to run. This field is templatable.

Date Template

If you choose to schedule a workflow run for a specific time in the future, you must enter when the workflow should be run. This field is templatable but must resolve to one of our supported time formats.

Run ID Template

When scheduling a future workflow run, you may optionally set a run ID. This ID is returned on the payload when a workflow run is successfully scheduled.

When canceling a future workflow run, the run ID is required. If the provided run ID resolves to the ID of a previously scheduled run, the run will be canceled. If no scheduled run matching the run ID can be found, an error object will be placed at this node’s result path if one is set.

This field is templatable.

Selecting the Virtual Button

When this node is configured to run a flow immediately or schedule a workflow run, you must specify which Application Workflow you want to trigger. To do so, you must select the workflow, workflow version, and Virtual Button to trigger. Each dropdown will be dynamically updated from the last to show your options.

For example, the “Workflow” dropdown shows all workflows in the current application, “Workflow Version” shows each version of the selected workflow, and “Virtual Button” shows each of the buttons in that version.

Optionally, you may enter a template for any of these values, however, the subsequent dropdowns will not dynamically populate if you do so.

Configuring the Payload

When this node is configured to run a flow immediately or schedule a workflow run, you have the ability to send data from the payload to the Application Workflow. Here you may define what data to send.

Configuring the payload is optional - if there is no payload specified, the default payload for the given workflow and Virtual Button will be used.

There are several ways to specify a payload:

Result Path

Optionally you may store the result of the selected operation at a given payload path. The data returned depends on which operation is performed.

  • Example result when workflow is immediately run
{
  "flowId": "605cb4bf26c934000781f549",
  "flowVersion": "default",
  "payload": {},
  "success": true,
  "virtualButtonId": "605cb4bf26c934000781
}
  • Example result when a workflow run is scheduled
{
  "flowId": "605cb4bf26c934000781f549",
  "flowVersion": "default",
  "newOrUpdate": "new",
  "payload": {},
  "runAt": "Thu Mar 25, 2021 15:40:37.081 GMT-04:00",
  "runId": "myRunId",
  "success": true,
  "virtualButtonId": "605cb4bf26c934000781f549-0H5_9s9mo2A4UfOX8iz48"
}
  • Example result when canceling a workflow run
{
  "runId": "myRunId",
  "success": true
}

Node Example

In the example below, the node is configured to schedule a future workflow run. It will schedule a future workflow run for 15 seconds from the time that this node is run.

Workflow Trigger Node Example

The runId is set to template to the payload value at working.id appended with a hyphen and the payload value at working.creationDate. The workflow that will be run is the default version of Send Report using the Virtual Button labeled Event Report.

Workflow Trigger Node Example

The payload that will be sent to the Virtual Button trigger is the payload at working.eventData on the current workflow, and the result of the scheduling operation will be placed on the current payload at working.result.

Workflow Trigger Node Example

Node Throttling And Limits

The Workflow Trigger Node has the same throttling rules as using the API to trigger a Virtual Button. It is limited to 100 calls in a 10-second window (per Virtual Button); on average, 10 calls per second.

Scheduled workflow runs are limited to 25 pending runs per Sandbox application or 1000 pending runs per Organization-owned application.