Basic Zapier workflows only have 2 steps: 1 trigger and 1 action. For example, a new event in Google Calendar is my trigger and creating a new personal todo in Streamtime is the action.
However Zapier offers so much more and sometimes it's required to build workflows with more than 2 steps. Note that you'll need to be on a paid Zapier plan to create workflows with 4 or more steps. But you can rest assured that a higher level of automation will be worth the extra cost.
In this article we will highlight 2 Zapier functions that are key for advanced workflows: Filtering and Formatter
For some workflows you don't want to action all triggered events. E.g. what if I only want regular events to be pushed into Streamtime and not "all day" events?
The solution is to apply a filter so the workflow "continues only if" certain conditions are met.
To insert a filter, just press the + in-between 2 steps and choose "Filter"
In this example the action should only take place if the duration of my task is less than 24 hours.
Converting data: Lookup values using Formatter
Another useful step in Zapier is the Formatter. This is a workflow step that is native to Zapier and offers a wide range of functions, such as text, date and numbers conversions. But the key one here is the Utilities function that will allow us to search for a specific key in a list and return a corresponding value.
Let's explain this with an example:
I want to set up a workflow that posts a new Slack message every time a new task is created. But for each client I have a separate Slack channel. So our workflow needs to know which client the task is for and figure out which channel to send the message to.
Formatter is the perfect tool for the job. Zapier can search for the client name in a lookup table and return the channel code for Slack.
In-between the Streamtime trigger and the Slack action you need to insert a Formatter step:
To configure the formatter, choose to transform the input data using a Lookup Table and choose the Job Company Name as the Lookup Key.
Next, you need to set up a list of values to return:
You can't use the Slack channel names. Instead you need to use the channel code. You can find the code in the URL of the channel and the easiest way to get that is to do a right mouse click on the channel and copy it:
You need to use the last part of the URL as the value: https://mycompany.slack.com/messages/C5Q7PNV1L
So if a task is created for client "Mohawk Airlines" we need Formatter to return Slack channel code C5Q7PNV1L. If it's Apple, we want to return AAPL14WPR.
Finally, in the Slack action step you can choose to post a new channel message. But you don't choose a channel from the list. Instead you select "Use a Custom Value (advanced)".
In the step below you then ignore the data returned from step 1 (Streamtime) and instead pick the output from Step 2 (Formatter)
Finish the setup, configuring a suitable message format, and test the result.
Zapier now posts job updates to the correct channel in Slack.