Announcing Sub-Zap by Zapier

Announcing Sub-Zap by Zapier
Userlevel 5
Badge

TL;DW: Today we’re beta / soft launching a new “Sub-Zap” capability in Zapier. This makes it easy to build much more manageable Zaps whenever you find yourself reusing or recreating the same actions across many Zaps. You can define inputs and outputs, then use the same functionality across as many Zaps as you like. Try it in your Zaps today! https://zapier.com/apps/sub-zap-by-zapier/integrations

 

TL;DR: Watch the video demo showcasing 2 Zaps reusing a Sub-Zap that looks up a customer: https://www.youtube.com/watch?v=QsunZFwGIQM.

 

Hi folks! Over the years we’ve watched customers just like you build incredibly powerful and deeply interconnected systems of Zaps. In some cases, folks spent a lot of time updating the actions they share across those Zaps. For example, if a spreadsheet was used in a couple dozen Zaps, updating a single column might entail updating a couple dozen Zaps to match. That was incredibly tedious and totally counter to our mission to democratize automation.

So today we’re introducing a new primitive we hope will make it easier to share those actions and employ an “update once, use everywhere” sort of workflow. We call it “Sub-Zap by Zapier”. You can start using it today! Here’s how it works:

 

First, you’ll create a Sub-Zap using the “Start a Sub-Zap” trigger and the “Return from a Sub-Zap action.

In the Sub-Zap’s “Start a Sub-Zap” trigger, you’ll define the input fields like this:

In the Sub-Zap’s “Return from a Sub-Zap action, you’ll define the output fields like this:

 

Second, you’ll go to a different Zap and use the “Call a Sub-Zap” action.

You’ll be prompted for the input fields like this:

And you’ll receive the output fields like this:

 

Finally, you’ll enable both Zaps and let them run like normal!

 

If you’d like to see a live demo, check out our 10 minute example where I showcase a 3 Zap system where 2 Zaps reuse the functionality present in a single Sub-Zap: 

 

If you’d like to give it a try, we’ve opened it up to the public here: https://zapier.com/apps/sub-zap-by-zapier/integrations

 

If you have any feedback, feel free to respond here or email us at contact@zapier.com!


12 replies

Userlevel 7
Badge +10

@bryanhelmig This is great! Going to be super useful!

Userlevel 4
Badge +3

This is awesome!

Userlevel 5
Badge

I just pushed a couple improvements wherein the setup flow is a little less cranky (we had a bit of a chicken and the egg problem during testing steps which is less cranky now), a squashed bug around listing and selected Sub-Zaps when setting up the Call a Sub-ZAP action, and a few other quality of life improvements around error and help messages.

Userlevel 1

This is so awesome, but it does not seem to work yet or atleast not for me when i also have a loop in the sub zap.

Userlevel 5
Badge

This is so awesome, but it does not seem to work yet or atleast not for me when i also have a loop in the sub zap.

Multiple returns will not work properly @Jeff Thorns, I believe only the first Return From a Sub-Zap is expected to fire correctly. If folks think looping or multiple returns are really important, please let us know and we’ll see what we can do! Beyond that, if you have specifics of a Zap system you’re trying to get working, please email us contact@zapier.com and we’ll see what we can get going!

Userlevel 4
Badge +3

This is so awesome, but it does not seem to work yet or atleast not for me when i also have a loop in the sub zap.

@Jeff Thorns what you can do is fire the return only on the last iteration of the loop like I build in this Zap:

You would want to include a queue delay to avoid throttling plus a filter just before the return to make sure the return only fires on the last iteration of your loop

 

Userlevel 7
Badge +10

@Jeff Thorns 

To elaborate on what @MarijnVerdult mentioned, make sure to check this help article: https://zapier.com/help/doc/loop-your-zap-actions

 

How do I stop a loop from running in subsequent action steps?

All actions after the looping step will run for each iteration of the loop. If you don’t want an action step to loop:

  • After the last step you want to loop, add a filter step.
  • Set the filter to only continue if the value loop_iteration_is_last matches the (Boolean) Is True condition.

The filter will run in every loop but will only pass in the last loop. Any actions step after the filter will run once in the last loop and use only 1 task.

Userlevel 7
Badge +10

@bryanhelmig 

Perhaps a better UI solution to the required VS optional inputs/arguments list in the Sub-Zap Start trigger would be to have 2 separate sections (required and optional) for the Inputs/Arguments Lists.

 

Add the word "required" to the label if you would like it to be required in the calling Zap.

 

Thoughts?

 

 

Set up Action

 

Userlevel 5
Badge

@bryanhelmig

Perhaps a better UI solution to the required VS optional inputs/arguments list in the Sub-Zap Start trigger would be to have 2 separate sections (required and optional) for the Inputs/Arguments Lists.

@Troy Tessalone good suggestion! To clarify -- you can name it less awkwardly: “First Name (required)” is sufficient to trigger the required flag. You can use spaces and other characters. I’ll wait for more signal from other user before adding this though.

Userlevel 7
Badge +10

@bryanhelmig Thanks for considering. I think it’s valid to avoid typos/confusion and allow for cleaner naming conventions. Regardless, happy to have this capability in a Zap app.

Userlevel 7
Badge +10

@bryanhelmig 

When testing, if a Sub-Zap returns an output parameter with an empty value it comes thru with “missing sample data”, but should show as empty.

See example screenshot.

Q: Is this a bug?

 

 

Userlevel 5
Badge

@Troy Tessalone done! Thanks for the suggestion! 🙌

Reply