How to create an automated, chat-based team availability system using Power Automate and Microsoft Teams

Efficiently managing and communicating team availability in a hybrid world is crucial for smooth operations in any organization. This guide will show you how to create an automated yet interactive system for tracking and communicating the availability of general staff members using Power Automate, Microsoft Teams, and SharePoint.

Step 1: Understanding the Business Process

  • Weekly Availability Surveys: Each Friday, staff members receive a personalized survey through a Teams chat message to submit their availability for the following week.
  • Confirmation and Preview: Upon submission, staff members get a confirmation message and a preview showing the team’s availability as of the time they submitted their own.
  • Comprehensive Monday Update: On Monday, everyone receives a complete overview of the team’s availability for that week, helping them make the most of everyone’s availability.

Video demonstration

The following video will demonstrate steps 2-3 (building the SharePoint list, and walking you through the Power Automate flow).

Step 2: Setting Up SharePoint

  • Create a SharePoint List: Establish a SharePoint list for logging staff availability. Ensure it’s accessible to all staff members who will be participating and/or reviewing availability of teammates. It needs:
    • A person column type for Employee
    • 5 single line of text columns – one for each weekday. In my demo, I’ve repurposed and renamed the default Title column for Monday.
The supporting SharePoint list upon creation | Click to enlarge
  • Manage Permissions (optional): Assign appropriate permissions to staff members to view and edit the availability list. In order for someone to submit their availability via the chat request, they’ll need Contribute or Edit access at least. If you added the list to a site accessible to all relevant team members, they already have access to edit the list by default.

Step 3: Automating with Power Automate

  • In-Office Status Survey Flow:
    • Trigger: Schedule to run every Friday at 10:00 AM.
    • It should first gather data from the SharePoint list (Get items) to know whom to ask for their availability
    • Before asking an employee for their availability, I use the following in my Update item step’s Monday, Tuesday, Wednesday, Thursday, and Friday fields to reset them each week:
⏳ Requested
  • Post an Adaptive Card : The chat message to each employee uses the ‘Post an adaptive card and wait for a response’ action. For the Message of the adaptive card step, utilize the provided JSON below. The only thing you’d want to update is the company logo URL to include your own. You could also adjust things like ‘Telework’ to ‘Work from home’ or any other verbiage you choose.
{
    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
    "type": "AdaptiveCard",
    "version": "1.3",
    "msTeams": {
        "width": "full"
    },
    "body": [
        {
            "type": "ColumnSet",
            "columns": [
                {
                    "type": "Column",
                    "width": 5,
                    "items": [
                        {
                            "type": "TextBlock",
                            "text": "Good morning!",
                            "weight": "Bolder",
                            "size": "Medium",
                            "style": "heading"
                        },
                        {
                            "type": "TextBlock",
                            "text": "Let us know where you'll be working next week so we know how best to collaborate with you.",
                            "isSubtle": true,
                            "wrap": true
                        }
                    ]
                },
                {
                    "type": "Column",
                    "width": 1,
                    "items": [
                        {
                            "type": "Image",
                            "url": "https://i0.wp.com/natechamberlain.com/wp-content/uploads/2022/08/cropped-Nate-Chamberlain-logo-icon-e1661192398264.png",
                            "altText": "Company Logo",
                            "size": "auto"
                        }
                    ]
                }
            ]
        },
        {
            "type": "Container",
            "items": [
                {
                    "type": "ColumnSet",
                    "columns": [
                        {
                            "type": "Column",
                            "width": 33,
                            "items": [
                                {
                                    "type": "TextBlock",
                                    "text": "Monday",
                                    "wrap": true,
                                    "weight": "Bolder",
                                    "horizontalAlignment": "Center"
                                },
                                {
                                    "type": "Input.ChoiceSet",
                                    "choices": [
                                        {
                                            "title": "In office",
                                            "value": "🏢 In office"
                                        },
                                        {
                                            "title": "Telework",
                                            "value": "🏠 Telework"
                                        },
                                        {
                                            "title": "Leave",
                                            "value": "🌴 Out of office"
                                        }
                                    ],
                                    "placeholder": "Select",
                                    "style": "expanded",
                                    "id": "Monday",
                                    "isRequired": true,
                                    "errorMessage": "Please make a selection"
                                }
                            ]
                        },
                        {
                            "type": "Column",
                            "width": 33,
                            "items": [
                                {
                                    "type": "TextBlock",
                                    "text": "Tuesday",
                                    "wrap": true,
                                    "weight": "Bolder",
                                    "horizontalAlignment": "Center"
                                },
                                {
                                    "type": "Input.ChoiceSet",
                                    "choices": [
                                        {
                                            "title": "In office",
                                            "value": "🏢 In office"
                                        },
                                        {
                                            "title": "Telework",
                                            "value": "🏠 Telework"
                                        },
                                        {
                                            "title": "Leave",
                                            "value": "🌴 Out of office"
                                        }
                                    ],
                                    "placeholder": "Select",
                                    "style": "expanded",
                                    "id": "Tuesday",
                                    "isRequired": true,
                                    "errorMessage": "Please make a selection"
                                }
                            ]
                        },
                        {
                            "type": "Column",
                            "width": 33,
                            "items": [
                                {
                                    "type": "TextBlock",
                                    "text": "Wednesday",
                                    "wrap": true,
                                    "weight": "Bolder",
                                    "horizontalAlignment": "Center"
                                },
                                {
                                    "type": "Input.ChoiceSet",
                                    "choices": [
                                        {
                                            "title": "In office",
                                            "value": "🏢 In office"
                                        },
                                        {
                                            "title": "Telework",
                                            "value": "🏠 Telework"
                                        },
                                        {
                                            "title": "Leave",
                                            "value": "🌴 Out of office"
                                        }
                                    ],
                                    "placeholder": "Select",
                                    "style": "expanded",
                                    "id": "Wednesday",
                                    "isRequired": true,
                                    "errorMessage": "Please make a selection"
                                }
                            ]
                        }
                    ],
                    "bleed": true
                }
            ]
        },
        {
            "type": "Container",
            "items": [
                {
                    "type": "ColumnSet",
                    "columns": [
                        {
                            "type": "Column",
                            "width": 33,
                            "items": [
                                {
                                    "type": "TextBlock",
                                    "text": "Thursday",
                                    "wrap": true,
                                    "weight": "Bolder",
                                    "horizontalAlignment": "Center"
                                },
                                {
                                    "type": "Input.ChoiceSet",
                                    "choices": [
                                        {
                                            "title": "In office",
                                            "value": "🏢 In office"
                                        },
                                        {
                                            "title": "Telework",
                                            "value": "🏠 Telework"
                                        },
                                        {
                                            "title": "Leave",
                                            "value": "🌴 Out of office"
                                        }
                                    ],
                                    "placeholder": "Select",
                                    "style": "expanded",
                                    "id": "Thursday",
                                    "isRequired": true,
                                    "errorMessage": "Please make a selection"
                                }
                            ]
                        },
                        {
                            "type": "Column",
                            "width": 33,
                            "items": [
                                {
                                    "type": "TextBlock",
                                    "text": "Friday",
                                    "wrap": true,
                                    "weight": "Bolder",
                                    "horizontalAlignment": "Center"
                                },
                                {
                                    "type": "Input.ChoiceSet",
                                    "choices": [
                                        {
                                            "title": "In office",
                                            "value": "🏢 In office"
                                        },
                                        {
                                            "title": "Telework",
                                            "value": "🏠 Telework"
                                        },
                                        {
                                            "title": "Leave",
                                            "value": "🌴 Out of office"
                                        }
                                    ],
                                    "placeholder": "Select",
                                    "style": "expanded",
                                    "id": "Friday",
                                    "isRequired": true,
                                    "errorMessage": "Please make a selection"
                                }
                            ]
                        },
                        {
                            "type": "Column",
                            "width": 33
                        }
                    ]
                }
            ]
        }
    ],
    "actions": [
        {
            "type": "Action.Submit",
            "title": "Submit"
        }
    ]
}
  • Get the updated list of availability (Get items 2) including the new response, making sure to use the following filter query to only get rows where people have responded for the coming week:
Title ne '⏳ Requested' and Title ne null
  • After someone responds, they’ll get a chat preview of the whole team’s availability for the week.
  • In-Office Status Results Flow:
    • Trigger: Schedule to run every Monday at 9:00 AM.
    • This flow compiles survey responses into an HTML table (similar to how we did the first flow) and distributes it to the team via a Teams group chat message where they can ask follow-up questions, provide additional context, coordinate meetings, etc.
    • Important – Exclude the Sender: The sender/owner of the flow should not be included in the Monday communication to recipients (assuming they’re using their credential to connect for that step in the flow). Since they’re the one connecting to Teams via Power Automate, they’re already included in the eventual group chat. Attempting to include them will result in an error.

Conclusion

By following these steps, you can set up a streamlined and automated process to manage the availability of your team. This system not only saves time but also ensures clear and consistent communication among all staff members.

Use Power Automate to create a Planner task whenever an item is added to a SharePoint list

My newest video demonstrates how you can create a task in Planner whenever an item is added to a SharePoint list. In my example, I’m assigning Planner tasks whenever a new IT Support Request comes in.

For this to work, you’ll need:

  • A SharePoint list
  • A Planner plan for your team to share

How to automate Planner task creation based on SharePoint list additions

  1. Prepare your SharePoint list (any columns you’re tracking)
  2. Prepare your Planner plan (set up buckets, labels, etc. as you wish)
  3. Create the Power Automate flow following steps in my video.
    • Type and trigger: Automated when an item is created (SharePoint)
    • Second/last step: Create a task (Planner)
      • Expression used to set due date a week after creation: addDays(triggerOutputs()?[‘body/Created’],7)
The flow I build in the video | Click to enlarge

How to Alternate Request Assignment to Responsible Persons for various categories

animals birds feathers flamingos

I had a unique challenge recently to alternate assignment of requests (tracked in a SharePoint list) to individuals as they were created. User #1 would get requests 1, 3, 5, etc. and User #2 would get requests 2, 4, 6, etc. To make it more interesting, different pairs of experts might be assigned to different request topics, and sometimes a single individual would be responsible for a particular topic. The overall idea, though, was a somewhat evenly dispersed workload given quickly and efficiently to those who were responsible for those request areas.

One (less than ideal) option to accomplish this is to use a Get Items (SharePoint) step on the requests list with a Top Count of 1 and Order By OData query (Created desc) for the most recently created request, see who the assignee is, and then assign to the other person in that category’s assignee field (when applicable). But I needed something that was better-performing, sophisticated, simpler in design, and not dependent on any historical items in case they were deleted, re-assigned, etc.

So, to determine the assignment as requests randomly trickle in over time, I decided to have Power Automate determine whether a new request’s ID number (auto-generated by SharePoint) is odd or even. Odd requests would go to the first assignee of a subcategory, and even would go to the last. If there was only one assignee in a category, they’re both the first and the last so it still works.

A general good practice when building flows is to make sure you don’t put a particular assignee’s identity explicitly in a variable, task, or email step. For example, you wouldn’t want to put user #1’s email directly in an Outlook email step’s To line. This makes sure that if an employee leaves the company, that the flow won’t need a revision. Instead, I created a list in the team’s SharePoint site with request categories, sub-categories, and responsible persons. My flow refers to this list each time it needs to make an assignment, making sure it has up-to-date contacts for each subcategory.

Example of a request categories list | Click to enlarge

The managers of the process keep this updated with no more than two assignees per subcategory. This way, when new employees join, the list gets an update for what subcategories they’ll be handling, and the flow continues without a hiccup.

What you’ll need to build this solution

Overall, for this process to work, you’ll need:

  • A list of request categories with these columns:
    • Category (choice)
    • Subcategory (text or choice)
    • Assignees/Responsible (person with multi-select enabled)
  • A list of requests (submitted via a SharePoint form, Microsoft Forms form via Power Automate, or Power Apps app via Power Automate)
    • I’d recommend Power Apps if you have the time and resources – this way your choices (categories and subcategories) in the form can be dynamic (only have to be managed in one place) and reference your categories list without granting access to the main request list, or even the SharePoint site, itself
    • Consider adding additional fields for your assignees like Notes, Status, Priority, etc. for them to add additional context, reminders, and status updates as they work the requests
  • The Power Automate flow for assignment determination

How to build a flow that assigns tasks evenly and by category

The following video will walk you through the necessary components to build this flow in Power Automate. The result will dynamically assign tasks to responsible persons based on categories they’re responsible for, as well as alternating tasks to help distribute workloads more evenly within each category.

Ideas to enhance your categories list with additional fields for different assignment scenarios

Consider taking this concept further by adding additional columns to your categories list. Things like:

  • Sequential assignment (Yes/No) – Assign to the first person in the multi-select person field and if they don’t mark it complete within 2-3 days, add the second person as an assignee.
  • Assign to all (Yes/No) – Maybe some subcategories should have all assignees involved in the resolution. A simple checkbox would have the flow assign to both (when applicable).
  • Request specific assignment (Yes/No) – Not everything can be randomly or evenly assigned. You may wish to choose on a case-by-case basis. Set your flow up to send an adaptive card to the process manager(s) asking for selection of an individual for each request that comes in with this Yes/No checked.

How to use the Mod function in a Power Automate expression to determine if a number is odd or even

Using the Mod function in an expression in Power Automate, you can quickly determine whether any numeric value is odd or even. In this post’s examples, I’ll be using a SharePoint item (or document) ID field as my numeric value, and I will determine if it is odd or even.

Did you know?
Every item and document in SharePoint is automatically assigned a unique ID number within its list or library. The field is called ID.

What is the Mod Function?

The Mod function takes two arguments: the number you want to divide and the divisor. It returns the remainder of the division. For example, Mod(5,2) returns 1, because 5 divided by 2 has a remainder of 1.

To check if a number is odd or even, you can use the Mod function with 2 as the divisor and compare the result (using the equals function) with 1. If the result is 1, then the number is odd. If the result is 0, then the number is even.

You can use the if and equals functions together to write this logic as a conditional expression. Here is an example using a SharePoint item ID as the number:

if(equals(Mod(outputs('Get_item')?['body/ID'],2),1),'Odd','Even')

This expression says: if the SharePoint item ID divided by 2 has a remainder of 1, then return ‘Odd’, otherwise return ‘Even.’

You can use any numeric field instead of the SharePoint item ID, as long as it is available in your flow.

You can learn more on the Mod function here.

And explore a real scenario in which I used this idea in my other blog post.

How to Add the Expression to Your Power Automate Flow

Tip: I have a video of these steps if you’d prefer.

First, to begin adding your expression, click within a step’s field where you want Odd or Even to be returned, such as a variable or condition statement. Then, in the dynamic content panel that pops out, select Expression and you’ll be provided with a formula bar.

How to add an expression to a Power Automate flow | Click to enlarge

In your expression formula bar, use the following formula (modifying the field reference to your own numeric field):

if(equals(Mod(outputs('Get_item')?['body/ID'],2),1),'Odd','Even')

This says if my numeric field divided by 2 has a remainder of 1 (making it an uneven quotient) then it’s odd, otherwise it’s even.

You can then use the result of this expression (Odd or Even) in further conditional expressions or condition blocks like this:

A condition block based on the result of odd/even expression | Click to enlarge

How to Insert a Dynamic Content Field into the Expression

If you are not sure how to find the reference for your numeric field, you can use the dynamic content panel to insert it into your expression. Here are the steps:

  1. Write your expression up until the point you need to enter the field name
Beginning of conditional Mod expression in Power Automate | Click to enlarge
  1. With your cursor active where you want to enter the field name (right after Mod( in my example), select Dynamic content, then select the numeric field you are using. In my case, it’s the ID field from a SharePoint list item.
Insertion of dynamic content in a Power Automate expression | Click to enlarge
  1. The selected field reference will automatically appear in your formula where your cursor was at the time of insert.
  2. Finish your expression. It might resemble this if you’re referencing a SharePoint item’s ID from a trigger like When an item is created:
if(equals(Mod(triggerOutputs()?['body/ID'],2),1),'Odd','Even')

Video: How to determine if a number is odd or even in Power Automate using the Mod function

That’s it! You have learned how to use the Mod function in Power Automate to determine if a numeric value is odd or even. I hope this helps you create more powerful and sophisticated flows. Good luck!

How to create a link to a specific approval request in Power Automate

Do you want to send someone a direct link to an approval request in Power Automate? This can be useful if you want to remind them via chat or email or assign them a task in Planner or To Do. In this blog post, I’ll show you how to get a link to a specific approval request’s link that you can use in different Power Automate flow concepts.

Note

If you’re looking for how to send a link to ALL a user’s pending approvals (rather than a specific approval request), check out my recent post on how to create a link to open the Approvals app in Teams.

You may already know that Power Automate has three approval related actionsStart and wait for an approvalWait for an approval, and Create an approval. Each of these actions has different dynamic content available for later steps. To get a link to a specific approval request, we need to use the Create an approval action because it gives us access to the Respond link dynamic content. This is the link that will take users directly to the approval board in Power Automate with their approval task open awaiting response.

Respond link dynamic content | Click to enlarge

How can you use this link? For example, imagine you want to create a flow that runs when a new request is created in SharePoint and creates a Planner task for the approver with the link to the approval request.

Illustration of the overall concept here – a link to an approval request | Click to enlarge

Here are the steps for this particular request scenario:

How to create a Power Automate flow that assigns Planner tasks containing links to approval requests

Note: For sensitive information, like leave requests, you’ll want to be mindful of PII and privacy and consider email or chat or other ways to use the link so only individuals who should see sensitive content can. This is merely an example of how you might use Planner tasks for any request scenario.

  1. For your flow’s trigger, search for SharePoint and select When an item is created. Configure the trigger by selecting the site and list where you want to monitor new items. For example, you might choose your HR site and the Leave request list.
  2. Click Add an action and search for Create an approval. Configure the approval details as you need. In our example, you might want to request approval from the employee’s manager and set the title to “Leave request approval.” If you intend to send custom notifications via email, planner tasks, etc., click Show advanced options and set Enable notifications to No. This will prevent approvers from receiving multiple notifications about the same approval request.
The first three steps of our approval flow | Click to enlarge
  1. Click Add an action and search for Create a task (Planner). Select the plan and bucket where you want to create the task. For example, you might choose your specific team’s plan and the Pending tasks bucket.
Planner task configuration | Click to enlarge
  1. Click Add an action and search for Update task details (Planner). Select the task ID from the previous Planner action. In the References section, fill in the following fields: References Alias is the text that will be clickable. References Resource will be the Respond link dynamic content from the Approval step. And References Type will be Other.
Update task details configuration | Click to enlarge
  1. Optionally, you can add more actions after creating the approval and updating the task details. For example, you could add a Wait for an approval action to take the outcome of the approval request and perform conditional actions based on it. Or you could add an Update item action (SharePoint) to set the original request’s Approval status from Pending to Approved or Rejected. Or you could add a Send an email action (Outlook) to notify the requestor, copying the approver and HR, with the final outcome of the request.
Optional final steps ideas | Click to enlarge
  1. Save your flow and test it.

That’s it! Now whenever a new request is created in SharePoint, a Planner task will be created for the approver with a direct link to the approval request.

You can apply this technique in other scenarios as well. For example, you could send chat messages or emails with links to approvals using Teams or Outlook actions. Or you could create personal To Do tasks with links using Microsoft To Do actions.

How might you be able to use direct links to specific approval requests in your business processes?

References and further reading

Looking for a deeper dive and more ideas? Look no further.

Power Automate approval actions: A comparison of Start and wait, Create, and Wait for an approval


If you’re responsible for building flows in Power Automate, you’re certain to be asked to create an approval process at some point. This blog post will cover:

  • Comparison of the three approval action types, descriptions, and business use cases
  • How to create a basic approval flow using Power Automate
  • Dynamic content differences between Power Automate approval actions

Let’s start by comparing your three approval action options.

Comparison of Power Automate approval actions

One of the actions available in Power Automate is the Start and wait for an approval action. This action starts the approval process and waits for it to be completed before executing any additional actions. Actions that follow are typically response-dependent, such as creating an item or updating a status if approved or rejected.

Another action available in Power Automate is the Create an approval action. This action starts the approval process but does not wait for it to be completed. Instead, you can use the Wait for an approval action to wait for the approval to complete that was started by the Create an approval action. You might use these actions…

  • …if you want to have steps between creation and waiting. For example, if you wanted to customize the email that is sent to approvers, you would disable Enable notifications on the Create an approval step, then add a Send an email action afterwards but before the Wait for an approval step. This gives you complete control over the look and feel of the email request, rather than sticking to the default Power Automate branded message.
  • …if your approval process will take more than 30 days and your flow will time out before it’s finished. Create an approval creates the approval in Microsoft Teams (or Power Automate) and approvers can approve it there when they’re ready. Your flow won’t fail as You may not necessarily wait for an approval in the flow itself.

Here is a table that summarizes the differences between the various actions:

ActionDescriptionBusiness Use Case Example
Start and wait for an approvalStarts the approval process and waits for it to be completed.A manager wants to automate the approval process for leave requests. They use the Start and wait for an approval action to ensure that the request is approved before the employee’s calendar is updated.
Create an approvalStarts the approval process but does not wait for it to be completed.A team lead wants to automate the approval process for expense reports. They use the Create an approval action to create the approval record and send notifications, but they don’t want to wait for the approval to complete before executing the next step in the flow. In this case, the approval response may not affect the following steps, but just needed to be requested and logged.
Wait for an approvalUsed to wait for an approval to complete that was started by the Create an approval action.A project manager wants to automate the approval process for project proposals. They use the Create an approval action to create the approval record, send their own custom notifications as a Planner task, an email, or a chat message, and then use the Wait for an approval action to wait for the approval to complete before executing the next step(s) in the flow.

Create an approval and Wait for an approval can be used consecutively to achieve the same result as only using the all-in-one action of Start and wait for an approval. For example, let’s say you use Microsoft Teams to manage your team’s projects. You can use Power Automate to automate the approval process for project proposals. You can create a flow that uses the Create an approval action to create the approval record and send notifications to the approvers. Once the approvers have approved the proposal, you can use the Wait for an approval action to wait for the approval to complete before executing the next step in the flow. This ensures that the project proposal is approved before any additional actions are taken but also gives you the added benefits of flexibility down the road like adding steps between creation and waiting, as well as additional dynamic content that may be helpful (see the dynamic content section below).

How to create a basic approval flow using Power Automate

Here is a step-by-step guide for creating a basic approval flow in Power Automate using reimbursement requests as an example:

  1. Select the When an item is created trigger for SharePoint. This trigger will start the flow when a new reimbursement request is created in the list.
  2. Add the Start and wait for an approval action to your flow. This action will start the approval process and wait for it to be completed before executing any additional actions.
  3. Configure the Start and wait for an approval action by specifying the approvers, the approval type, and any other relevant details. For example, you can specify that the approval should be sent to the employee’s manager and the Accounting department, and that the approval type should be Approve/Reject – Everyone must approve.
  4. Add any additional actions that you want to execute after the approval process has been completed. You’ll almost always have a Condition control that checks to see if the response was Approve or Reject. Then, for example, you might use the Send an email action to notify the employee that their reimbursement request has been approved, and maybe Update item to set the SharePoint item’s status as Approved.

Here is a side-by-side comparison that shows the steps for a flow that uses start and wait for an approval, and a different one that shows using create an approval, send an email, then wait for an approval:

Start and wait for an approvalCreate an approval, send an email, then wait for an approval
1. Add the Start and wait for an approval action to your flow.1. Add the Create an approval action to your flow.
2. Configure the Start and wait for an approval action by specifying the approvers, the approval type, and any other relevant details.2. Configure the Create an approval action by specifying the approvers, the approval type, and any other relevant details. In this example, we would disable the Enable notifications setting so we can send a custom notification.
3. Add any additional actions that you want to execute after the approval process has been completed such as a response-dependent (Condition control) secondary level of approvals.3. Add the Send an email action to your flow to notify the requestor and/or approver(s) of the request details and action required.
4. Add the Wait for an approval action to your flow.
5. Configure the Wait for an approval action to wait for the approval to complete before executing any additional actions like a response-dependent (Condition control) status column update.
Table comparing the steps added to an approval flow using two different approaches

Not only do you use these approval actions in different scenarios, but your choice also affects the dynamic content you can use later in the flow. Let’s take a look at that next.

Dynamic content differences between Power Automate approval actions

The choices you make for which approval actions affect which dynamic content is available to you in later steps. Here’s an example of the dynamic content panel for a step following Create an approval:

A screenshot of selecting dynamic content from a Create an approval step | Click to enlarge

Here’s a listing of all the dynamic content alphabetically listed and which actions provide it for you.

Dynamic contentDescriptionStart and wait for an approvalCreate an approvalWait for an approval
Approval IDThe name of the approval
ApproversAll of the approvers   
Approvers Approver emailThe email address of the approver  
Approvers Approver IDThe ID of the approver  
Approvers Approver nameThe name of the approver  
Approvers Approver tenant IDThe tenant ID of the approver  
Approvers Approver user principal nameThe principal name of the approver  
Approvers Item   
body 
Completion dateDate the approval was completed 
DetailsAdditional details about the request
Item linkA link to the item to approve
Item link descriptionDescription of the link to the item
OutcomeThe outcome of the approval 
Request dateDate the approval request was sent
Respond linkThe link to respond to the approval  
Response summaryA summary of the responses 
ResponsesAll of the responses 
Responses Approver emailThe email address of the approver 
Responses Approver IDThe ID of the approver 
Responses Approver nameThe name of the approver 
Responses Approver responseThe response from the approver 
Responses Approver tenant IDThe tenant ID of the approver 
Responses Approver user principal nameThe principal name of the approver 
Responses CommentsComments added by the approver 
Responses Item  
Responses Request dateDate the approval request was sent 
Responses responder  
Responses Response dateDate the approval response was sent 
Teams Adaptive CardAn adaptive card that can be posted to users to respond from within Microsoft Teams  
TitleThe title of the approval
Table comparing dynamic content for different approval actions in Power Automate

One of the most valuable differences here, in my opinion, is the inclusion of Respond link. It’s only available for the Create an approval action. This allows you to send custom reminders with links that take users directly to the item(s) they still need to approve. You could also consider just sending users directly to the Approvals app in Microsoft Teams to put eyes on all their outstanding requests.

Conclusion

As you can see, a simple action choice comes with a lot of potential for creating rich processes. And with all of the options provided through dynamic content, we can customize the approval process quite a bit. In most cases, you’ll probably use Start and wait for an approval. But as you develop more flows, you may find yourself wanting a greater degree of customization and flexibility so you opt for the Create an approval + Wait for an approval approach.

What sort of approval processes are you working on automating with Power Automate? Let me know in the comments or on LinkedIn.

References and further reading

How to create a direct link to the Approvals app in Microsoft Teams

yellow arrow led signage

If you want to create a direct hyperlink in an email or chat message that takes a user directly to the Approvals app within Microsoft Teams, it’s luckily pretty straightforward. You might do this if you want to remind users to review any pending/open approvals on a regular basis, nudge a specific person to complete an approval, or create a custom approval request email for a Power Automate flow.

In this blog post I’ll highlight how you can get a direct link to Approvals for enterprise and GCC subscriptions in both Microsoft Teams and Power Automate.

How to create a direct link to the Approvals app in Microsoft Teams

To send users directly to the Approvals app in Microsoft Teams, your URL may be exactly the same as one of these. That’s right, no modification needed! That’s because the alphanumeric content in the URL is the app ID and it stays the same from one organization to the next.

However, the app ID does differ for different versions of the Approvals app. For instance:

Approvals app in Microsoft Teams: https://teams.microsoft.com/l/entity/7c316234-ded0-4f95-8a83-8453d0876592/approvals

US GCC Approvals app in Microsoft Teams: https://teams.microsoft.com/l/entity/2d4edd75-5a69-41da-bead-44c3a268ece8/approvals

As you can see the structure is similar:

  1. Begin your URL with https://teams.microsoft.com/l/entity/
  2. Replace the alphanumeric id before /approvals with the app ID specific to your Approvals app

How to find your app ID

If neither of the examples above (normal Approvals or GCC Approvals) works for you, you may have a different Approvals app or the ID may have changed or been copied incorrectly. To find your app ID:

  1. Go to Manage Apps in the Microsoft Teams Admin Center
  2. Search for and select the Approvals app
  3. Find its ID under App ID
An app details page in the Microsoft Teams admin center | Click to enlarge

How to create a direct link to the Approvals page of Power Automate

If you prefer users complete approvals via the browser using Power Automate (same approvals, different interface), you may instead go to Power Automate in your browser and click on Approvals from the left navigation menu then copy that entire URL. It will be the same for all users in your organization.

It might resemble something like the following:

Approvals page in Power Automate: https://make.powerautomate.com/environments/Default-a1b2c3d4-e5f6-7h8i-9j0k-l1m2n3o4p5q6/approvals/received

US GCC Approvals page in Power Automate: https://make.gov.powerautomate.us/environments/Default-g7h8i9j0-k1l2-m3n4-o5p6-q7r8s9t0u1v2/approvals/received

You can, alternatively, copy one of my fake URLs above and replace everything between Default- and /approvals with your organization’s ID. To get this, visit Power Automate in your browser and copy the ID out of its URL.

Power Automate URL’s ID location | Click to enlarge

References

Deep link to an application – Teams | Microsoft Learn

Service principals vs service accounts: Which one should you use for Power Automate flows?

colorful toothed wheels

Power Automate allows you to automate workflows across various applications and services. However, when you create a flow, you need to decide how to authenticate and authorize it to access the data sources and actions it needs. This is where service principals and service accounts come in.

Service principals are special types of users that represent an Azure AD application. They have a system administrator role and use a client secret (a permanent password) to connect to data sources such as Dataverse. Service accounts are regular user accounts that have a username and password. They can be assigned different roles and licenses depending on the flow’s needs.

Recently, I posted How to use service accounts in Power Automate flows and avoid common pitfalls. Check it out to do a deeper dive on just service accounts.

So which one should you use for your Power Automate flows: service principals or service accounts? Here are some pros and cons of each option:

Service PrincipalsService Accounts
Pros:Pros:
– More secure as they do not expose username or password– Easier to set up and manage
– Do not consume a license as they use an application user account– Can be assigned different roles and licenses for different flows
– Can perform actions on behalf of organization users who trigger the flow– Can access more data sources and actions than service principals
Cons:Cons:
– More complex to configure and troubleshoot– Less secure as they expose username or password
– Limited to data sources that support Azure AD authentication– Consume a license for each service account used in a flow
Table comparing the pros and cons of Service Principals and Service Accounts

As you can see, there is no definitive answer to which option is better for your Power Automate flows. It depends on your specific scenario, requirements, and preferences. However, some general guidelines are:

  • Use service principals if you want more security, less licensing costs, and more flexibility in performing actions on behalf of other users.
  • Use service accounts if you want more simplicity, more data source options, and more control over roles and licenses.

This post has explained the high-level differences between service principals and service accounts to consider when building flows in Power Automate. For more information, please refer to these resources:

How to use service accounts in Power Automate flows and avoid common pitfalls

Do you want to automate your workflows with Power Automate and make sure they can last for years to come? If so, you need to pay attention to how you share your flows and how you sign into the services that you use in them. Using your own user account may seem convenient, but it can also cause trouble if your account gets changed or deleted. In this post, I will show you two examples of what can go wrong when you use personal accounts in Power Automate flows and how to avoid them by using a service account instead.

Consider these two scenarios involving Power Automate flows that connect to different services:

  • Bob creates a flow that triggers when a new item is added to a SharePoint list and sends an email alert to his team. He uses his own user account to create the flow and does not share it with anyone else. A few months later, Bob quits his job and his account is disabled. The flow stops functioning because the connection is lost and no one can access or edit it. The team does not receive any email notifications and has to manually monitor the SharePoint list for new items.
  • Carol creates a similar flow as Bob but she shares it with her colleague Dave as a co-owner. However, she still uses her own user account to authenticate to some connectors or actions within the flow, such as sending emails from her Outlook account. A few months later, Carol resigns from her job and her account is deactivated. The flow still runs but some connectors or actions fail because they rely on Carol’s credentials. The team receives incomplete or erroneous email notifications.

These examples demonstrate the risks of using personal accounts in Power Automate flows. And both scenarios could have been avoided if Bob and Carol had used a service account to create their flows and connect to the various services used in the flow. You may end up with broken connections, failed actions, or loss of access otherwise.

So what exactly is a service account? A service account is a special user account that has a fixed license and does not belong to any individual person. Multiple users may know/share the credentials to use the account for building flows. You’ll treat it much like a user account as you provision a license for it then add it to teams, groups, and roles so that it can perform actions a normal user would.

By using a service account, you can make sure that your flows run reliably and securely no matter what happens in your organization or team. Just be careful, as with any shared security asset, not to share a service account’s credentials with too many flow makers. 2-3 users would be the max I would personally consider for redundancy as people take leave and the organization experiences turnover.

Tips for building sturdier flows in Power Automate by using service accounts

  • Create a dedicated service account with a fixed license and assign it the appropriate roles and permissions (site or team membership, shared mailbox member, security group member, etc.)
  • Consider creating multiple service accounts that have access to different environments, teams, sites, etc. to ensure you don’t have one service account with access to absolutely everything
  • Creating the flow
    • Use a service account to create the flow or
    • Use a service account to create the flow and share it with other users as co-owners for more convenient edit access or
    • Share a flow you have already created with the service account as a co-owner (co-owners keep flows after other co-owners leave an organization)
  • Use the service account to authenticate the connectors or actions that you use in your flows, such as SharePoint, Outlook, or Teams. If any single step’s connection belongs to an individual, there is risk that the step will fail if that person’s account is disabled or even if they have authentication issues.
  • Test your flows regularly and monitor their performance and status using the service account
  • Document your flows and their connections and keep track of any changes or updates using the service account

References

How to reset a SharePoint column value to blank using Power Automate

In Power Automate, setting an already-populated SharePoint list or library field to blank isn’t as simple as leaving the field blank in your flow. Luckily, it’s just a couple extra steps to make it possible.

In this post I’ll cover multiple column types as they’re a bit different.

  • How to set text, date, number, and yes/no column values to blank
  • How to set single choice column values to blank
  • How to reset multi-choice column values to blank
  • How to reset person column values to blank

How to set SharePoint text, date, number, and yes/no column values to blank

The steps in this section will work for these column types:

  • Single line of text
  • Multiline text
  • Date
  • Number
  • Yes/No
  1. Click into the field you want to reset to blank
  2. Select Expression
  3. Type Null in the expression box (not case-sensitive)
  4. Click OK
Adding a Null expression in Power Automate | Click to enlarge

Test your flow and it should reset the field value(s) to blank wherever you used the Null expression.

Showing the fields that were reset using Power Automate | Click to enlarge

How to set SharePoint single choice field values to blank

To set a choice field back to blank (no selection) follow these steps:

  1. Add a step before updating the item that initializes a variable. The step is called Initialize Variable.
  2. Set the variable name to Blank, and the type to String. Do not set a value.
  3. In your update action, set the choice field value to the new variable from dynamic content.
Creating a blank variable in Power Automate | Click to enlarge

Test your flow, and you should see your single choice field reset to no choice.

Result of a Power Automate flow resetting a choice field | Click to enlarge

How to reset SharePoint multi-choice column values to blank

A normal choice column in SharePoint has more options that allow it to be set to multiple choice.

Multiple selection option for a choice field in SharePoint | Click to enlarge

Changing a single-select choice column to a multi-choice field alters how Power Automate resets the field, but it’s still similar to the steps involved for a single choice field.

To set a multiple-choice field back to blank (no selections) follow these steps:

  1. Add a step before updating the item that initializes a variable. The step is called Initialize Variable.
  2. Set the variable name to BlankArray, and the type to Array. Do not set a value.
  3. In your update action, select the T icon next to your multiple-choice field.
  1. Set the multi-choice field value to the new variable from dynamic content.
Power Automate actions resetting a multiple-choice field to blank | Click to enlarge

Test your flow and your multi-choice fields should now reset to blank.

Result of a Power Automate flow resetting multiple-choice fields to blank | Click to enlarge

How to reset SharePoint person column values to blank

Perhaps one of the more complicated column types to reset, a person field takes a bit more work to reset. To accomplish this, we can use an HTTP request. Follow these steps to empty a SharePoint person column’s value.

  1. Add the Send an HTTP request to SharePoint step
  2. Following the screenshot below, set the fields as follows (you must replace all red items with your own values):
    • Site Address (select your site)
    • Method: POST
    • Uri: _api/web/lists/getbytitle(‘YOUR LIST TITLE‘)/items(YOUR ITEM ID FROM DYNAMIC CONTENT)
    • Headers
      • IF-MATCH | *
      • X-HTTP-Method | MERGE
      • Content-Type | application/json;odata=verbose
      • Accept | application/json;odata=verbose
    • Body:
      {
      “__metadata”:{
      “type”:”SP.Data.YOUR_x0020_LIST_x0020_TITLEListItem”
      },
      YOURPERSONFIELDId”:”-1″
      }

Important notes for the Body field

If your list name has a space, replace it with _x0020_ such as Null_x0020_demo.

Field names are different than display names. Even if your field displays with a space (Person field) it is likely Personfield on the backend. You can verify your column’s actual name by going to List settings (gear icon) and selecting your column from the Columns section. Your field’s actual name will be displayed in your browser’s URL.

How your HTTP request should look when finished | Click to enlarge

Test your flow and you’ll find that your person column has been reset.