Skip to content
🎉 Launch sale:50% off everything over $22 — automatically applied at checkout· ends Aug 2Shop the sale →
DevOps AI ToolKit
Newsletter
All prompts
AI for Microsoft Teams Difficulty: Intermediate ClaudeChatGPT

Power Automate Error Handling and Retry Scope Design Prompt

Add structured error handling, run-after branches, and idempotent retries to a Teams alerting or approval flow

Target user
engineers building Microsoft Teams Power Automate flows
Difficulty
Intermediate
Tools
Claude, ChatGPT

The prompt

You are a senior platform engineer who builds Microsoft Teams Power Automate flows and has debugged enough silent flow failures to design for them deliberately.

I will provide:
- A description or export of the flow (trigger, actions, connectors, the Teams post/approval steps)
- Which actions are critical (must not be lost) versus best-effort
- Any observed failure modes (timeouts, 429s, duplicate Teams messages)

Your job:

1. **Classify failures** — for each action, list how it can fail (transient, throttling, auth, bad data) and whether a retry is safe or would duplicate side effects.
2. **Try/Catch scopes** — propose a Scope structure (Try / Catch / Finally) using configure-run-after so failures are caught instead of silently terminating the run.
3. **Retry policy** — set per-action retry counts, intervals, and exponential vs fixed strategy, and flag actions where automatic retry must be disabled to avoid duplicate Teams posts.
4. **Idempotency** — design dedupe keys or guard checks so a re-run or retried action does not post the same alert or trigger the same approval twice.
5. **Failure surface** — define the Catch behavior: notify a fallback Teams channel, write to a log, and return a non-silent failure with enough context to debug.

Output as: (a) failure classification table, (b) the scope/run-after structure described step by step, (c) per-action retry settings, (d) the Catch-branch notification design.

When in doubt about whether a retry is safe, treat the action as non-idempotent and gate it behind a dedupe check rather than risking duplicate notifications.

Run this prompt with AI

Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.

Related prompts

More Microsoft Teams prompts & error guides

Browse every Microsoft Teams prompt and troubleshooting guide in one place.

Free download · 368-page PDF

Reading prompts? Get all 500 in one free PDF

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.