For Power Automate engineers, monitoring flow status and failures is essential. Unfortunately, Microsoft Automate does not offer an out-of-the-box solution for this. As a result, many engineers resort to custom development to achieve this functionality. Some common methods involve creating a catch-all action in all flows that sends an email on flow failure..

I tried to find a solution that could monitor all flows without having to include additional steps in each individual flow. Additionally, I wanted my solution to check for recently disabled flows, such as those that may have been disabled after an unsuccessful update.

To address these needs, I created a generic flow that runs periodically (in my case, every 60 minutes) to check for recent flow failures or disablement. This flow is based on two Power Automate actions:

  1. “List flows as admin” action to obtain a list of all flows and their statuses
  2. “Invoke an HTTP request” action to call the “/runs” method of each flow to identify failed flows

When using the “Invoke an HTTP request (HTTP with Azure AD)” action, you’ll need to create the appropriate connection

Flow contents

This is how the “generic” flow looks like:







 

While this solution works well, there are a few considerations to keep in mind:

  • The exact error message for a failed flow is not returned by the flow runs. Instead, the message will always be “An action failed. No dependent actions succeeded.”
  • If you’re using Dynamics 365 Marketing, recently disabled Real-time Customer journeys may also be listed in the disabled flow list. You can filter them out by looking for names that don’t start with “CXP”

I welcome your feedback on any possible improvements you may have regarding this flow. You can reach me at elowy@powerpro.nl.

Best regards,
Elowy.

Laat het ons weten!

Neem gerust contact op als je wat meer van onze dienstverlening wilt weten.