Manage sequential approvals with Power Automate
Some workflows require pre-approval before the final approver is required to sign off. For example, a company may have a sequential approval policy that requires pre-approval for invoices over $1000.00 before they're approved by the Finance department.
Learn how to quickly and easily set up sequential approvals in Set up sequential approvals.
In this tutorial, you manually create a sequential approval flow that manages employee vacation requests. For detailed information about using SharePoint with Power Automate, go to the SharePoint documentation.
Learn more about using SharePoint with Power Automate in SharePoint documentation.
Note
SharePoint is used here only as an example. It isn't required to create approval flows. You can use any of the more than 200 services with which Power Automate integrates to drive your flows. If you're using SharePoint 2010, go to SharePoint 2010 workflow retirement.
Detailed steps in the flow
The flow:
- Starts when an employee creates vacation request in a SharePoint Online list.
- Adds the vacation request to the approval center and then emails the request to the pre-approver.
- Emails the pre-approval decision to the employee.
- Updates the SharePoint Online list with the pre-approver's decision and comments. Note: If the request is pre-approved, the flow continues with these steps:
- Sends the request to the final approver.
- Emails the final decision to the employee.
- Updates the SharePoint list with the final decision.
This image summarizes the preceding steps:
Prerequisites
- Power Automate.
- A SharePoint Online list.
- Office 365 Outlook and Office 365 Users account.
Note
While we use SharePoint Online and Office 365 Outlook in this walk-through, you can use other services such as Zendesk, Salesforce, or Gmail. If you are using SharePoint 2010, see SharePoint 2010 workflow retirement
Before you create the flow, create a SharePoint Online list. Later, we'll use this list to request approval for vacations.
For the purposes of this walkthrough, the SharePoint Online list that you create must include the following columns:
The SharePoint Online list you create must include the following columns:
Title | Single line of text |
---|---|
Vacation start date | Date and time |
Vacation end date | Date and time |
Comments | Single line Of text |
Approved | Yes/No |
Manager comments | Multiple lines Of text |
Modified | Date and time |
Created | Date and time |
Pre-approved | Yes/No |
Created By | Person or group |
Modified By | Person or group |
Make note of the name and URL of the SharePoint Online list. We use these items later when you configure the SharePoint - When a new item is created trigger.
Create your flow
Sign in to Power Automate.
Select My flows in the left-side navigation pane.
On the top-left menu, select New flow > Automated cloud flow.
Give your flow a name.
Under Choose your flow's trigger, select When an item is created - SharePoint, and then select Create.
On the When an item is created card, select the Site Address and the List Name for the SharePoint list that you created earlier.
- On the When an item is created card, select the Site Address and the List Name for the SharePoint list that you created earlier.
Get the manager for the person who created the vacation request
Select +New step, and then type get manager into the Choose an action search box.
Find, and then select the Get manager (V2) - Office 365 Users action.
Insert the Created By Email token into the User (UPN) box on the Get manager card.
This action gets the manager for the person who created the vacation request in SharePoint.
Note
It's a good idea to periodically save changes to your flow as you go.
Add an approval action for pre-approvals
Select New step.
Type approval into the Choose an action search box.
Select the Start and wait for an approval action.
Configure the Start and wait for an approval card to suit your needs.
Note
The Approval type, Title and Assigned To fields are required. You can use Markdown to format the Details field.
This action sends the pre-approval request to the email address in the Assigned To box.
Add a condition
Select New step, and then select Condition in the list of actions.
On the Condition card, select Choose a value on the left.
A list of dynamic values display.
Select Responses Approver response from the list of dynamic values.
Select the Choose a value box on the right, and then enter Approve into the box.
Note
The valid responses to the Approvals - Start an approval action are "Approve" and "Reject". These responses are case-sensitive.
Your Condition card should now show:
Note
This condition checks the response from the Start and wait for an approval action.
Add an email action for pre-approvals
Select Add an action on the If yes branch of the condition.
Enter send email into the search box on the Choose an action card.
Select the Send an email (V2) action.
Configure the email card to suit your needs.
Note
To, Subject, and Body are required.
This card is a template for the email that is sent when the status of the vacation request changes.
In the Body box on the Send an email (V2) card, use the Comments token from the Approvals - Start an approval action.
Add an update action for pre-approved requests
Select Add an action in the If yes branch.
Enter SharePoint in the search box on the Choose an action card, select the SharePoint filter, and then select the Update item action.
Configure the Update item card to suit your needs.
Get the pre-approver's manager
Use the Get the manager for the person who created the vacation request steps we did earlier to add, and then configure another Get manager action. This time we get the pre-approver's manager.
The Get manager 2 card should resemble this image when you're finished. Be sure to use the Email token from the Get manager category on the Add dynamic content from the apps and services used in this flow card.
Add the final approval action
Use the add an approval action for pre-approvals steps we did earlier to add, and then configure another Start and wait for an approval action. This action sends an email request for final approval.
When you're done, the card should resemble this image:
Add the final approval condition
Repeat the steps from add a condition to add, and then configure a Condition that checks the final approver's decision.
Send email with final approval
Use the steps from Add an email action for pre-approvals to add, and then configure an action that sends an email when vacation requests are approved.
When you're finished, your card should resemble this image:
Update SharePoint with approval
Use the steps from Add an update action for pre-approved requests to add, and then configure an action that updates SharePoint when the vacation request is approved.
When you're finished, the card should resemble this image:
Send email with pre-approval rejection
Select Add an action on the If no branch.
Enter Send into the search box of the Choose an action card, select Office 365 Outlook to filter the actions, and then select the Send an email (V2) - Office 365 Outlook action.
Configure the email card to suit your needs.
This card represents the template for the email that's sent when the status of a vacation request changes.
This action must be added to the IF NO, DO NOTHING branch below the Condition card.
Update SharePoint with pre-approval rejection
Select Add an action.
Enter update into the search box on the Choose an action card, and then select the Update item - SharePoint action.
Configure the card to suit your needs.
Send email with final rejection
Use the steps from Send email with pre-approval rejection to add, and then configure an action that sends an email when the vacation request is rejected by the final approver.
This action must be added to the IF NO, DO NOTHING branch below the Condition 2 card.
When you're finished, the card should resemble this image:
Update SharePoint with final rejection
Use the steps from Update SharePoint with pre-approval rejection to add, and then configure an action that updates SharePoint if the final approver rejects the vacation request.
When you're finished, the card should resemble this image:
Select Update flow to save the work we've done.
If you've followed along, your flow should resemble this image:
Now that you've created the flow, let's see it in action.
Request an approval
Create a vacation request in the SharePoint Online list you created earlier.
After you save this request, the flow triggers, and then:
- Creates a request in the approvals center.
- Sends an approval request email to the approvers.
Your request should resemble this image:
View pending approval requests
View all pending approval requests by following these steps:
Sign in to Power Automate.
On the left-side navigation pane, select Action items > Approvals.
Your pending approval requests appear on the Received tab.
Pre-approve a request
If you're an approver in an approval flow, you receive an email whenever someone creates a request. The approval request is also sent to the approvals center. You can then approve or reject requests from the email, the approvals center, or the Power Automate app.
To approve a request:
From email
Select Approve from the email you receive when an item is added to the SharePoint Online list.
Note: If you're using a mobile device with the Power Automate app installed, the Power Automate app launches, otherwise, the approvals center opens in your browser.
Enter a comment, and then select the Confirm button.
From the approvals center
Sign in to Power Automate.
Select Approvals in the left-side navigation pane.
Select Approve on the request you want to approve.
Add any comments, and then select Confirm at the bottom of the screen.
From the Power Automate app
On your mobile phone with the Power Automate app installed, select Approve from the request approval email.
Select Confirm in the upper right corner of the screen.
The success page shows, indicating that your approval has been recorded.
Note
The screens on Android, iOS and Windows Phone may differ slightly, however, the functionality is the same on all devices.
Approve the request
The steps to approve a request are identical to the steps to pre-approve a request
The final approver gets the vacation request only after the request has been pre-approved.
Reject a request
You can reject a request via email, the approvals center, or the Power Automate app. To reject a request, follow the steps for approving a request, but select Reject, instead of Approve.
After you confirm your decision (rejection of the request), the flow runs the following steps:
- Sends an email to the person who requested vacation.
- Updates the SharePoint Online list with the decision, and the comments from the approver.