Showing results for 
Search instead for 
Did you mean: 
0 Kudos

Add additional precondition rules to "For a selected SharePoint [file / item]" triggers to show in SharePoint

As we expand our SharePoint sites with new functionality added through Power Automate, we get more and more Power Automate actions being added into the right-click menus of our SharePoint sites.


Unfortunately the current "For a selected SharePoint [file / item]" triggers can only be configured on a per-library / per-list level - so once they are set against that library / list, they appear for every single item and content type in that libray, and we end up with an ever-growing list of Power Automate flows that you can trigger against every single content type and every single situation - even those where it makes no sense to have that action available.  And so we have to build in error-checking to every workflow, after it is triggered, to ensure that the right content type was selected in the first place.


For example, if you have an action "Convert Word Document to PDF" flow, then it shouldn't be available for anything other than files with a ".docx" extension - let alone show up as an option on a folder.


Wouldn't it be so much better better if we could add filters into this trigger that will make each flow only show against items / content types that we can configure are appropriate for the flow?  Ideally these could be set against every available column (like the "Filter" string in the SharePoint Get Items action), including content type, file name, and any other columns in the list/library.


Note that idea is related to, but distinct from the SharePoint "Conditional Trigger" at since the flows shown in the right-click list on an item / file in the SharePoint list or library are already dynamically generated after you right-click the list item - those flows you don't have permission to run are already filtered out, so it should be trivial to add in additional rules that determine whether each flow is appropriate and shown for that particular item, since it's already dynamic.  The way that the filters would work in practice are very different to the conditional trigger, because the conditions determine if the flow is shown as shown as available to run against the item / file - rather than whether it will be triggered at all.  The trigger type is also different - the conditional trigger suggestion is in relation to automatic triggers, whereas this request is for instant triggers.

Status: New