Approval timeouts in Microsoft Power Automate
Petter Skodvin-Hvammen
I build apps and enable change | Advisor, Architect and Developer
How do you handle approval requests that are forgotten or otherwise not responded to within the due date? You probably don't. Here's what you should do!
When you automate an approval process you should plan for any possible outcome!
If you are using Microsoft 365, an approver will most likely approve or reject the request. But, (s)he may also cancel the request, reasign it to another approver, or simply ignore or forget about it until it's too late. It's also a common scenario that approvers are out of office; for vacation, sick leave or other reasons.
Let's dive into the details and look at how you can handle approval timeouts in Microsoft Power Automate.
The workflow below is the implementation of a document approval process in a quality management system (QRM) I've been working on recently.
If the changes to the document are approved, the status should be updated and file published as a new major version. The approver has 7 days to respond to the request.
If you don't specify a timeout for the approval, then Power Automate will wait for an approval for 30 days. This is the same timeout as for the entire flow. Maximum run duration for a cloud flow in Power Automate is 30 days. Your flow may therefore time out before the approval step times out, so you will not be able to automate any clean-up steps.
?? This is why you should always specify a shorter timeout duration for your approvals!
To specify timeout duration for your approval, select Settings for your "Start and wait for an approval" or "Wait for an approval" step in your flow.
Timeout duration is specified using ISO 8601 format, see https://en.wikipedia.org/wiki/ISO_8601#:~:text=Durations
TL;DR
Here's the format:
P[n]Y[n]M[n]DT[n]H[n]M[n]S or P[n]W
领英推荐
Here are a few useful examples:
In my process I want an email to be sent in case the approval is responded to within 7 days. I also want document status to be reset to Draft.
First I specified timeout duration to P7D on the "Wait for an approval in 7 days" step.
Then I added a scope action as parallel branch.
As you may notice in the screenshot above, there's a dotted arrow pointing down to the Approval timed out step, indicating that the action scope is not run in case of a timeout of the previous action.
The final piece in the puzzle is to configure run after for the scope and make sure to select when the previous step "has timed out".
Now you know how to configure timoute for approvals in Microsoft Power Automate. Make sure you use it in your flows going forward.
One final thing! How do you test timeouts?
Yes, you have to wait. So, to make your life easier, change the timeout duration to 1 minute (or less). To wait 1 minute, specify PT1M or PT60S.
Project Manager | Scrum Master | Business Analyst | PMP | Prácticas ágiles | PMO Expert | SharePoint & Power Platform lover | Inglés C level
5 个月Petter Skodvin-Hvammen Thank you very much for your post, it helped me a lot. I have a question about the first approval that the flow sent. How to cancel or disable it so that the user does not respond if he or she has already responded to the reminder? I understand that the first one will be active, right?
Microsoft 365 consultant/ Machinist [Recruiters be gone!]
11 个月Shouldn't the "5 hours ?? PT10H" be PT5H?
Finan?ní Controller & Analytik finan?ních systém? ve spole?nosti PPF a.s
1 年For anyone who could read this and need this.? If you have flow with approval and if the time has passed out and you want to properly end the flow, you have to add Terminate to the end Otherwise, the Approval timed out will still work but the flow ends with status Failed. In terminate you can set the outcome of the flow to Succeed. But again thanks Peter for the awesome tutorial.
Digital Learning Manager at De Montfort University
1 年Hi Petter, are there options so that only working days are counted within the timeout period i.e. Monday to Friday