Example configuration Microsoft Power Automate to automate routing based on Azure AD
Introduction
This example shows you how you can use Microsoft Power Automate to automate your UCC routing.
Prerequisites
For this scenario we will be using:
-
Power Automate
-
SharePoint Online
-
Azure AD
Configuration
-
From your Office Portal, go to your Power Automate App:
-
Click "My Flows":
-
Click "New" and "Scheduled- from Blank":
-
Set schedule, for example every day:
-
Add action "Get group members", from Azure AD.
-
Fill in the Group ID.
Note Group ID can be found on Azure AD portal, https://aad.portal.azure.com
-
-
Add action "Initialize variable".
-
Name = UCC Routing ID
-
Type = String
-
-
Add action "Apply to each"
-
Output = Group Members
-
-
Add action "Get Items", from SharePoint
-
Site Address = Your UCC's SharePoint Site
-
List = Routing
-
Filter Query:
wsp_ucc_routing_match_from eq '@{items('Apply_to_each')?['mail']}'
-
-
Add action "Set Variable"
-
Name = UCC Routing ID
-
Value:
first(body('Get_items')?['value'])?['id']
-
-
Add action "Condition"
-
Value 1:
@variables('UCC Routing ID')
-
Match = is equal to
-
Value 2 =
-
-
Add action "Create Item" of SharePoint, in if Yes.
-
Site Address = Your UCC's SharePoint Site
-
List = Routing
-
Title:
AD Routing - @{items('Apply_to_each')?['userPrincipalName']}
-
Match From: (can be any field in this example we use mail, to route on Microsoft Teams)
@{items('Apply_to_each')?['mail']}
-
Action Value = Skill (can be replaced with any other action)
-
Skill id = Name of the Skill you want to route to.
-
Action Value = Skill (can be replaced with any other action)
-
MatchEndpoint = All
-
Did you find this page helpful?
Yes No
Sorry about that
Why wasn't this helpful? (check all that apply)
Thank you for your feedback.
Want to tell us more?
Email your feedback to our documentation team.
Great!
Thanks for taking the time to give us some feedback.