Tip #1428: Replace Power Automate triggers without breaking too much, Part 1

Always stash trigger output into variables or compose before continuing with the flow. If your trigger output contains a record from the underlying storage (Dataverse, SharePoint, etc) get that record and use the output of the get step downstream.

Why? Because when you need to replace or recreate a trigger (happens more often than you think), you would have to recreate the reference in one place only. Have you used the trigger output throughout the flow, trigger deletion would mop it all up and break every single step where the output was used. Go fish!

Don’t do this:

Do something like this instead:

Why? Because when you delete the trigger in the first example, both compose steps will be broken. In the second example only Parse Json step will require a fixup but the rest of the flow will be fine.

Getting triggering record has additional advantage. Sometimes the triggers (looking at you, Microsoft Dataverse) tend to overlook certain properties like formatted values, @odata.id, etc. Getting the record as the first step ensures you get up to date values for all columns that you might be interested in.

In other words:

Do not use trigger output beyond the first step in your flow

Bitter Enabler

Cover image courtesy of Schäferle | Pixabay

Leave a Reply

Your email address will not be published. Required fields are marked *