Quickly find the parent from the child flow in Power Automate

When you have used child flows and attempted to debug issues you will have come across the issue where you want to find the parent flow for the failing child flow.

Parent – Child flows

In this example I’ve created a simple set of flows. There is one parent flow and there is a child flow.

The parent flow calls my child flow using the Run a child flow action.

Simple Parent flow
Simple Parent flow

Then the Child flow has a manual trigger and does something before it responds back to the parent flow.

Simple Child Flow run
Simple Child Flow run

Flow runs

There are many flow runs of my parent flow after a while.

Parent flow runs
Parent flow runs

And I will also have quite a few runs for my child flow. At some point it will become very difficult to connect the two related flow runs together.

Child Flow runs
Child Flow runs

Making the Parent Flow run Url available

The first step now is to add an additional parameter to my child flow’s trigger step. I’m calling this parameter Parent Url. But you can call this something else if you prefer.

Parent URL in the child trigger
Parent URL in the child trigger

Then I update my parent flow to supply the Parent Flow url using a concat expression.

Parent URL available to the child flow
Parent URL available to the child flow

Do you remember the expression from the Try Catch pattern to generate the Flow run URL? Well this is just the same.

concat('https://make.powerautomate.com/environments/', workflow()?['tags']['environmentName'], '/flows/', workflow()?['name'], '/runs/', workflow()?['run']['name'])

Configuring the Flow Run View

Using the Edit Columns option I can now make the Parent URL available within my flow run overview.

Quickly find the parent from the child flow in Power Automate

This will make it possible to copy the url ( Sorry, it is not a clickable URL here!)

Quickly find the parent from the child flow in Power Automate

And within the flow run itself you can also find the Parent Url. This is especially useful if we received an email form your Try Catch pattern with the flow url.

Quickly find the parent from the child flow in Power Automate

And then of course you could also include this Parent Url in that email alerting you about a failure. Then you could click on a link in the email to show you the parent failing to call the child correctly.

Hopefully this pattern will make it a bit easier to look after your child and parent flows.

Avatar for Pieter Veenstra

By Pieter Veenstra

Business Applications Microsoft MVP working as the Head of Power Platform at Vantage 365. You can contact me using contact@sharepains.com

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from SharePains by Microsoft MVP Pieter Veenstra

Subscribe now to keep reading and get access to the full archive.

Continue reading