Close Menu
    DevStackTipsDevStackTips
    • Home
    • News & Updates
      1. Tech & Work
      2. View All

      The Case For Minimal WordPress Setups: A Contrarian View On Theme Frameworks

      June 5, 2025

      How To Fix Largest Contentful Paint Issues With Subpart Analysis

      June 5, 2025

      How To Prevent WordPress SQL Injection Attacks

      June 5, 2025

      CodeSOD: Integral to a Database Read

      June 5, 2025

      Players aren’t buying Call of Duty’s “error” excuse for the ads Activision started forcing into the game’s menus recently

      June 4, 2025

      In Sam Altman’s world, the perfect AI would be “a very tiny model with superhuman reasoning capabilities” for any context

      June 4, 2025

      Sam Altman’s ouster from OpenAI was so dramatic that it’s apparently becoming a movie — Will we finally get the full story?

      June 4, 2025

      One of Microsoft’s biggest hardware partners joins its “bold strategy, Cotton” moment over upgrading to Windows 11, suggesting everyone just buys a Copilot+ PC

      June 4, 2025
    • Development
      1. Algorithms & Data Structures
      2. Artificial Intelligence
      3. Back-End Development
      4. Databases
      5. Front-End Development
      6. Libraries & Frameworks
      7. Machine Learning
      8. Security
      9. Software Engineering
      10. Tools & IDEs
      11. Web Design
      12. Web Development
      13. Web Security
      14. Programming Languages
        • PHP
        • JavaScript
      Featured

      Enable Flexible Pattern Matching with Laravel’s Case-Insensitive Str::is Method

      June 5, 2025
      Recent

      Enable Flexible Pattern Matching with Laravel’s Case-Insensitive Str::is Method

      June 5, 2025

      Laravel OpenRouter

      June 5, 2025

      This Week in Laravel: Starter Kits, Alpine, PDFs and Roles/Permissions

      June 5, 2025
    • Operating Systems
      1. Windows
      2. Linux
      3. macOS
      Featured

      FOSS Weekly #25.23: Helwan Linux, Quarkdown, Konsole Tweaks, Keyboard Shortcuts and More Linux Stuff

      June 5, 2025
      Recent

      FOSS Weekly #25.23: Helwan Linux, Quarkdown, Konsole Tweaks, Keyboard Shortcuts and More Linux Stuff

      June 5, 2025

      Grow is a declarative website generator

      June 5, 2025

      Raspberry Pi 5 Desktop Mini PC: Benchmarking

      June 5, 2025
    • Learning Resources
      • Books
      • Cheatsheets
      • Tutorials & Guides
    Home»Development»Part 1: Capture and Monitor Critical Power Automate Workflows History through Child Flow

    Part 1: Capture and Monitor Critical Power Automate Workflows History through Child Flow

    January 29, 2025

    Introduction:

    In today’s digital landscape, organizations increasingly rely on automated workflows to enhance efficiency and streamline processes. However, as these workflows grow in complexity, tracking their execution history becomes essential for ensuring reliability and facilitating troubleshooting.

    This blog explores a powerful approach to logging workflow running history using child flows in Power Automate. By leveraging child flows, users can capture critical data such as flow names, statuses, and execution URLs, storing this information in SharePoint or Dataverse tables for easy access and analysis.

    In this Blog Series, you will be briefly seeing these topics in two parts:

    • Part 1: Step-by-Step Guide — Creating a child flow to capture the necessary data for tracking your workflow execution history
    • Part 2: Step-by-Step Guide — Integrating Child flow to the Parent Flow & How to Access this child flow as a reusable template across the different projects or Teams.

    In this Part, you will introduce the concept of creating a child flow to get the necessary data.

    Prerequisites:

      • SharePoint or Dataverse: Ensure you have access to either SharePoint or Dataverse to store and manage your data.
      • Power Automate: A valid account to access Power Automate for creating and managing your workflows.

    Step-by-Step Guide:

    Now, let’s dive into the detailed process for creating flows in Power Automate.

    Setting Up in SharePoint or Dataverse

    1. Create a List or Table named “Log Workflow Histories.”
    2. Add the Following Columns:
    Column Name Data Type
    Flow Name Single Line of Text
    Flow Run URL Link / Hyperlink or Picture
    Flow Start Time Date and Time
    Flow End Time Date and Time
    Flow Status Single Line of Text

     

    Creating a Child Flow:

    1. Access Power Automate at Power Automate.
    2. Select “Solutions” from the left navigation pane.
    3. Open Your Existing Solution or create a new one by clicking “New Solution.”
    4. Create a Child Flow by navigating to:
      • All > New > Automation > Cloud Flow > Instant.
        1childflownav

    Step 1: Provide a Flow Name and Select the Manual Trigger

    Choose a descriptive name for your flow that clearly indicates its purpose. This helps in identifying the flow later.
    2flowhistory

    Step 2: Set Inputs in the Manual Trigger

    Input Source: The inputs for this flow will be provided by the parent flow. Ensure that the following inputs are configured to receive data from the parent flow:

    • Input 1: Workflow Object (Type: Text)
    • Input 2: Start Date and Time (Type: Text)
    • Input 3: End Date and Time (Type: Text)
    • Input 4: Workflow Status (Type: Text)

    3flowhistory

    4flowhistory

    Step 3: Add a Compose Action to Convert the Workflow Object to JSON Format.

    The Workflow Object we receive from the parent flow is in JSON format but is treated as a string in the manual trigger input. By converting it into a JSON object, we can easily extract specific information and manipulate the data as needed in subsequent steps of the flow.

    • Add a Compose Action:
      • Click on “+ New Step.”
      • Search for and select “Compose.”
    • Configure the Compose Action:
      • In the Inputs field of the Compose action, enter the following expression to convert the Workflow Object to JSON format: json(triggerBody()?['Workflow Object'])
        5flowhistory
        6flowhistory
        7flowhistory
        8flowhistory
    • Name the Compose Action (Optional but Best Practice):
      • You can rename the action to something descriptive, like “Convert Workflow Obj to JSON.” In this example, I have named “Convert to Obj”.

    Step 4: Add a Compose Action to Extract the Workflow Link

    This Compose action allows us to isolate and extract the workflow link from the previously converted JSON object. This makes it easier to use the link in further actions within the flow.

    • Add Another Compose Action:
      • Click on “+ New Step.”
      • Search for and select “Compose.”
    • Configure the Compose Action:
      • In the Inputs field of this Compose action, enter the expression to extract the workflow link.
      • The expression would be: concat('https://make.powerautomate.com/environments/',outputs('Convert_to_Obj')?['tags']?['environmentName'],'/flows/',outputs('Convert_to_Obj')?['name'],'/runs/',outputs('Convert_to_Obj')?['run']?['name'])
        ‘Convert_to_Obj’ – replace it with the name of your previous compose action.
        9flowhistory10flowhistory

    Step 5: Add another Compose Action to Extract the Flow Name

    Please revisit Step 4 and replace the current expression with the following. Additionally, rename the Compose action to “Workflow Name.”

    The Expression would be:outputs('Convert_to_Obj')?['tags']?['flowDisplayName']
    11childflownav
    12childflownav

    The extraction from the workflow object is now complete. Next, it’s time to add the item to either a SharePoint list or a Dataverse table.

    Step 6: Add an Item to SharePoint List

    • Add a New Step:
      • Click on “+ New Step.”
      • Search for and select “SharePoint” from the list of connectors.
        13childflownav
    • Choose Action:
      • Select the action “Create Item.”
        14childflownav
    • Configure the Create Item Action:
      • Site Address: Choose the SharePoint site where your list is located.
      • List Name: Select the “Log Workflow Histories” list you created earlier.
    • Map the Fields:
      Fill in the fields using the outputs from previous steps:
      • Workflow Name: Use the output from the “Workflow Name” Compose action.
      • Start Date and Time: Map this to the corresponding input from the manual trigger.
      • End Date and Time: Map this to the corresponding input from the manual trigger.
      • Workflow Status: Map this to the corresponding input from the manual trigger.
      • Workflow Link: Use the output from the Compose action that extracted the workflow link.
        15flowhistory

    You can follow either Step 6 or Step 7 based on your chosen data source—SharePoint or Dataverse. If you’re using SharePoint, refer to Step 6 for adding an item to the SharePoint list. If you’re using Dataverse, follow Step 7 to add a row to the Dataverse table.

    Step 7: Add an Item to Dataverse Table

    • Add a New Step:
      • Click on “+ New Step.”
      • Search for and select “Dataverse” from the list of connectors.
    • Choose Action:
      • Select the action “Add a Row.”
        16flowhistory
    • Configure the Add a Row Action:
      • Table Name: Select the Dataverse table where you want to add the item (e.g., “Log Workflow Histories”).
    • Map the Fields:
      Fill in the fields using outputs from previous steps:
      • Workflow Name: Use the output from the “Workflow Name” Compose action.
      • Start Date and Time: Map this to the corresponding input from the manual trigger.
      • End Date and Time: Map this to the corresponding input from the manual trigger.
      • Workflow Status: Map this to the corresponding input from the manual trigger.
      • Workflow Link: Use the output from the Compose action that extracted the workflow link.

    Conclusion:

    “In the first part, we’ve explored how to create the child flow. In the next part of this series, we’ll show you how to integrate this child flow into a parent flow and start capturing the history for your critical flows. “

    Source: Read More 

    Facebook Twitter Reddit Email Copy Link
    Previous ArticlePart 2: Capture and Monitor Critical Power Automate Workflows History through Child Flow
    Next Article The Art of Writing Test Classes in Salesforce Apex

    Related Posts

    Security

    Cisco Warns of Credential Vuln on AWS, Azure, Oracle Cloud

    June 5, 2025
    Security

    How Falcon Next-Gen SIEM Protects Enterprises from VMware vCenter Attacks

    June 5, 2025
    Leave A Reply Cancel Reply

    Continue Reading

    I wanted to love this Deadpool mobile controller, but it couldn’t replace my go-to

    I wanted to love this Deadpool mobile controller, but it couldn’t replace my go-to

    News & Updates

    VMware NSX XSS Vulnerability Allows Attackers to Inject Malicious Code

    Security

    Microsoft Edge will auto-update PDF to Adobe Engine, won’t kill off legacy PDF until 2026

    Operating Systems

    Meet Wisdom AI: An AI Startup that Bring Insights at your Fingertips with AI-Powered Analytics

    Development

    Highlights

    CVE-2025-5172 – Econtrata SQL Injection Vulnerability

    May 26, 2025

    CVE ID : CVE-2025-5172

    Published : May 26, 2025, 6:17 a.m. | 2 hours, 55 minutes ago

    Description : A vulnerability, which was classified as critical, was found in Econtrata up to 20250516. Affected is an unknown function of the file /valida. The manipulation of the argument usuario leads to sql injection. It is possible to launch the attack remotely. The exploit has been disclosed to the public and may be used. The vendor was contacted early about this disclosure but did not respond in any way.

    Severity: 7.3 | HIGH

    Visit the link for more details, such as CVSS details, affected products, timeline, and more…

    Develop Frontend Without a Backend Using Mock Service Worker

    April 14, 2025

    Researchers Observe Hackers Exploiting Vulnerability in End-of-Life D-Link DIR-859 Routers

    July 2, 2024

    CVE-2025-25045 – IBM InfoSphere Information Server Information Disclosure

    April 23, 2025
    © DevStackTips 2025. All rights reserved.
    • Contact
    • Privacy Policy

    Type above and press Enter to search. Press Esc to cancel.