Creating a subroutine
To create a new subroutine, start by opening the subroutine catalog by either clicking the link at the top left of the automation editor, or by clicking or dragging the catalog's vertical splitter on the left side of the screen:
Then click the Create button above the catalog at the top left:
The editor creates a skeleton subroutine with the needed input trigger and output action:
Edit the trigger and add the needed input data fields for the subroutine:
When done adding fields, click the Fetch button to configure the trigger with those fields:
Now you can optionally add any needed trigger filters. Click the Save button when done.
For this example, we'll just use two actions to uppercase both the input title and description. Their input values are mapped to the two subroutine inputs:
Edit the subroutine output action and add two output fields:
Then click the Fetch button to configure those fields:
The output fields are then mapped to the two uppercased values from the preceding actions:
This is the finished subroutine that is ready to save:
Give the subroutine a name and description that will appear in the subroutine catalog.
Accounts having the "Public content" permission can optionally save the subroutine as public. Otherwise it will be private to your account.
Now the subroutine can either be tested or used within an automation:
Subroutines can be nested, but don't nest the same routine within itself. Otherwise an infinite loop will occur!