Reserved keyword that gets workflow IDs similar to invoker #2078
nahiyan-yasaar-selise
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Currently there's no way to know if a workflow was triggered by a user or a particular workflow. We would like two reserved keywords, one that holds the current workflow's ID (
workflowID), another that holds the ID of the workflow that caused the trigger (triggerer?). If a user triggers a workflow due to an updateinvokerhas the userID, buttriggererwill benull, but if workflowA triggers workflowB, thentriggererin workflowB has the ID of workflowA whereasinvokershould benull.Possible benefits/use cases:
workflowID == triggererthat terminates early. Or if workflowA triggers workflowB and workflowB triggers workflowA, we can do a similar gateway condition.This effectively turns workflows into pseudo-subworkflows with a built-in parameter being pre-filled.
Beta Was this translation helpful? Give feedback.
All reactions