Inputs, Outputs, Parameters
In this section you will learn about Inputs, Outputs and Parameters
Last updated
In this section you will learn about Inputs, Outputs and Parameters
Last updated
Many cases that include workflows, especially the more complex ones, require you to be able to pass values from the app into the builder as well as pass values from the builder into the app.
A simple example would be a workflow that deletes a record and sends an email notification via Mailchimp:
To achieve that, we'll need to fetch the ID
(to identify what record to delete) and pass it into the "Orders - Delete" action in the workflow. We'll also need to pass the customer's email into the Mailchimp action (so that the notification is sent to the right person)
The ID (primary key), is a unique identifier of a record, which could be set in the data source, auto-generated by Jet, or set manually in Jet (depending on the data source). It is typically hidden in the table but available for fetching and referencing in other components
There are two ways we can fetch the ID
from the selected row (and other values and tokens):
Directly from the Step
Via Workflow Parameters and Inputs
Select the step
Click on the ID and click on Formula
All the inputs available will be listed in the configuration menu on the right for a given Step
Parameters allow you to receive and hold different values from the app so that they can be referenced and used in the workflow steps.
To add a parameter, either go to the trigger action menu:
Or open the workflow builder and click on the trigger action step there:
After that,
Go back to the trigger action menu (close the workflow builder) and select the created parameter
Reference any dynamic value from the app
This will put the referenced value into the parameter. Then, you can fetch the stored dynamic from the parameter within an action step:
After that, you can reference (fetch) workflow parameters from any step, be it an action or a rule.
For example, we can create a rule that will branch our sequence into two based on a condition: IF
a transaction amount from a selected row is >= $100
, the "Yes" branch will run, ELSE
, the "No" branch will run:
Outputs allow you to fetch and store the results from specific steps in the automation. You can later reference those outputs from within the app.
You can use the last step outputs (default) (1) or specify the outputs manually (2) so that you can get the results from the specific steps (3).
You can go futher and combine and transform results using the functions modal: