Skip to content
CloudOps
Newsletter
All guides
AI for Microsoft Teams By James Joyner IV · · 9 min read

Power Automate for DevOps: Practical Workflows That Run in Teams

Power Automate is more capable than DevOps engineers give it credit for. Here are the flows I actually use for on-call, deploys, and approvals in Teams.

  • #microsoft-teams
  • #power-automate
  • #devops
  • #automation
  • #workflows
  • #chatops

Most DevOps engineers I know dismiss Power Automate as a low-code toy for the marketing team. I did too, for about a decade. Then I realized it’s already deployed, already authenticated against our tenant, and already wired into Teams — which makes it the path of least resistance for a whole class of glue work I’d otherwise build and babysit myself.

You don’t have to like clicking through a designer. But for the right jobs, Power Automate beats writing a service. Here’s where I use it.

When Power Automate is the right tool

Reach for it when the work is: triggered by a Microsoft-ecosystem event, mostly orchestration rather than computation, and would otherwise need its own auth, hosting, and on-call. The classic shape is “when X happens in Teams/Azure/email, do a few API calls and post a card.”

Reach for real code instead when you need heavy logic, tight latency, or version control as a first-class concern. Flows are exportable as JSON but they’re not a joy to diff.

Flow 1: on-call handoff summary

Every morning a scheduled flow pulls the overnight incidents (from a SharePoint list or an API), formats them into an adaptive card, and posts to the on-call channel with “here’s what happened, here’s what’s still open.” The outgoing engineer no longer writes a handoff by hand; they edit a draft.

The flow is four actions: Recurrence trigger → HTTP GET incidents → Compose card → Post card in channel. No server, no cron host, no secret rotation beyond an API key in a secure input.

Flow 2: deploy approval with a real audit trail

When a pipeline wants to deploy to prod, it calls a flow via an HTTP trigger. The flow posts an Adaptive Card with Approve/Reject buttons to the release channel, waits for a response, and returns the decision to the pipeline.

HTTP trigger (deploy request)
  → Post adaptive card with Action.Execute Approve / Reject
  → Wait for a response from the card
  → Branch: approved → return 200, rejected → return 403
  → Log decision + approver to a list

The win isn’t the buttons — it’s that the approver, timestamp, and decision land in a list automatically. When an auditor asks “who approved the Friday deploy,” it’s a query, not an archaeology dig through chat history.

Flow 3: triage-channel auto-creation

When a Sev1 fires, a flow creates a dedicated Teams channel, posts the incident card, @-mentions the on-call group, and pins the runbook. Spinning up the war room becomes one webhook call from your alerting stack instead of three minutes of manual setup while production burns. I cover the channel side of this more in the Microsoft Teams guides.

Working with adaptive cards in flows

The “Post adaptive card and wait for a response” action is the workhorse for anything interactive. Two things to know:

  • The card body is just JSON. Build it in the Adaptive Cards Designer, paste it into the action, and inject dynamic values with flow expressions.
  • The response comes back as data you can branch on. An Action.Submit with "data": {"decision": "approve"} lets you switch on body('Post_card')?['data']?['decision'].

Keep the JSON in source control even though the flow lives in the cloud — paste-from-repo beats editing in the browser.

Adding AI without losing control

Power Automate has AI Builder and direct connectors to language models. I use them for drafting and classification, never for authorizing changes. Two safe patterns:

  • Summarize before posting. A flow that posts an incident handoff first sends the raw incident list to a model and asks for a 3-bullet summary, then puts that in the card. The human reads a summary instead of a wall of rows.
  • Classify and route. Inbound requests get a severity/category from a model, which decides which channel gets the card — but a human still approves any action.

The line I hold, same as in incident response: AI shapes the message, humans approve the action. A flow should never let a model’s output trigger a deploy or a delete on its own. The prompt library has summarization prompts tuned for ops handoffs.

Operational discipline for flows

Flows rot quietly if you let them. What keeps mine healthy:

  • Owner is a service account, not a person. When Dave leaves, his personal flows die with his license. Shared/service ownership survives.
  • Configure failure notifications. Flows can fail silently. Set up the built-in “notify owner on failure” so a broken approval flow doesn’t strand a deploy.
  • Export and commit the JSON. Export → Package (.zip) periodically, drop it in a repo. It’s your only real backup and change history.
  • Name them like infrastructure. ops-deploy-approval-prod, not Test flow 3 (copy).

The honest tradeoff

Power Automate gives you Teams-native, tenant-authenticated automation with zero hosting. The cost is weaker version control, occasional connector quirks, and a designer you’ll grumble at. For glue work — approvals, handoffs, channel orchestration, notifications — that trade is usually worth it. For your core platform logic, write the service.

Start with one flow that removes one recurring chore. The on-call handoff summary is my recommended first build: high value, low risk, and it’ll change your mind about what this tool can do.

Flows can trigger real infrastructure actions. Keep state-changing steps behind human approval and audit every automated decision.

Free download · 368-page PDF

Download the Free 500-Prompt DevOps AI Toolkit

500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.

  • 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
  • Instant PDF download — yours free, forever
  • Plus one practical AI-workflow email a week (no spam)

Single opt-in · unsubscribe anytime · no spam.