Blue Digital Solution

Your guide thru digital transformation

Monitoring Power Automate with Application Insights

2025-11-23 Observability By Blue Digital Solution Team

At some point, every growing automation estate hits the same question: "Are our flows actually healthy?" Piping telemetry into Application Insights gives you a calm, honest view of what is happening so you can fix issues before they turn into noisy incidents.

Run history is for today, telemetry is for the big picture

The built-in run history view in Power Automate is perfect when you are debugging a single flow. But as your automation estate grows, you need a way to step back and see patterns across hundreds or thousands of runs.

That is where Application Insights comes in. It turns individual runs into a timeline you can explore with queries, charts, and alerts.

What to send from each run

You do not need to log everything, just enough to answer the questions you care about:

  • What flow ran, and why?
  • Did it succeed, fail, or time out?
  • How long did it take?
  • Which environment did it run in?

Useful fields include:

  • operationName: the flow name or a friendly business name.
  • correlationId: a GUID you reuse across related flows and apps.
  • status: Succeeded, Failed, TimedOut, or Skipped.
  • durationMs: the total runtime.
  • environment and triggerType.

Once these are flowing into Application Insights, you can slice and dice them however you like.

A simple way to send events

To keep things tidy:

  • Wrap your logging logic in a child flow that accepts the key fields.
  • Call that child flow from your main flows at the start and end (or on failure).
  • Inside the child flow, send a customEvent to Application Insights using the REST API.
  • Store the instrumentation key or connection string in environment variables, never in raw actions.

This keeps your main flows focused on business logic, while a reusable "telemetry helper" handles observability.

Asking better questions with Kusto

Once your events are in Application Insights, Kusto queries turn them into insights:

  • Top failing flows
    Group by operationName where status == "Failed" to see which automations need attention.

  • Slowest flows
    Look at average durationMs per flow to spot anything getting slower over time.

  • Noisy retries
    Filter on events where a retry flag is true to find flows that are just barely hanging on.

With a bit of practice, these queries become a comfortable way to check the "health" of your automation.

Why this makes life easier for humans

Good telemetry is not about numbers for their own sake. It is about reducing anxiety.

When something goes wrong, you can answer:

  • Is this a one-off glitch or a pattern?
  • Which flows, environments, and connectors are affected?
  • Who owns the flows that are failing most often?

Instead of chasing screenshots and anecdotes, you can have calm, data-backed conversations about what to improve next.