This is likely simpler than it seems but the naming is hurting my brain.
When I think “Sub-Zap” I think “sub-function” - meaning I can build a function with fields and simply call the function from the sub (i.e. getNames(User.first, User.last) where “first” and “last” are variables in some other place called “User”).
Here’s the issue.
If your Trigger is what gives you the fields you need, I’m not seeing a way to “pass” that data over to Sub-Zap at all, and I suspect it’s simply the name of this that’s confusing.
Here’s the “Pseudo-code” for what I need to happen.
When a new item is detected in an RSS feed, get the fields you need, then call a series of Sub-Zaps that do different stuff with those fields.
It’s not a branch because there’s no conditional - in my mind. It’s delegating the work to separate Sub-Zaps where I can easily bolt on additional workers as needed for that same data. Which is what I assume is the benefit of this.
Getting the RSS part is a trigger - fine.
Action - call a Sub-Zap - fine.
But then on the other side, I don’t see a way to “give” that Sub-Zap the fields from the first Zap so it can do what it needs to do. It looks like what it instead wants to do is:
Based on whatever event, call a Sub-Zap that does whatever trigger it needs to get the data they need to work from.
The problem is, there’s no other event than the new item in RSS. Which has to be trigger, because the action doesn’t allow me to test to know when it’s there and it could be there at any point during the day, plus I need to avoid duplicate executes, which means it needs to trigger on new so it knows not to do that.
I CAN call the RSS again on each Sub-Zap, but that feels inefficient. That means I’m repeatedly calling the same RSS for information the system already is (or should be) aware of. I could do that now without Sub-Zap.
Is there no way to just pass fields to the Sub-Zap where that data comes directly from the first trigger?
Best answer by tina-feijooView original