cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ezFlow
Helper II
Helper II

Automating Dataverse Team Group Creation

Hi Everyone,
AAD Security group can be assigned to Dataverse Team Group AAD manually.
Is there a way to automate the process? We have seperate Teams that Manage Azure Security and Dataverse Security. It would require some effort of coordinating to get/add create AAD SG --> Get the Security Identifier and have the other Teams use it when creating Dataverse Team Group?

1 ACCEPTED SOLUTION

Accepted Solutions
EricRegnier
Super User
Super User

Hi @ezFlow,

Yes you can automate with by script like with PowerShell, but my preference is with Power Automate. In Power Automate you can sync the teams on a schedule or when a group is created, depending on your needs. Use the Graph API to get the desired groups with the HTTP connector and use the Dataverse connector to create/set the team and group Object ID. You can use the Graph Explorer to build and test the query. 

You might initial need to work with the other team to get consent/right to use Graph if not already done. I use a service princpal to connect to graph via Power Automate. Here's a example:

 

EricRegnier_0-1649969960832.png

  1. Using the HTTP connector, to get the groups, here I get all the groups. I use Acticee Directory OAuth to authenticate. 
  2. Then I parsed the body from the reponse to get the intellisense and creating a new Team in Dataverse. I set the team name and Object ID from the response.

Hope this makes sense! 

View solution in original post

1 REPLY 1
EricRegnier
Super User
Super User

Hi @ezFlow,

Yes you can automate with by script like with PowerShell, but my preference is with Power Automate. In Power Automate you can sync the teams on a schedule or when a group is created, depending on your needs. Use the Graph API to get the desired groups with the HTTP connector and use the Dataverse connector to create/set the team and group Object ID. You can use the Graph Explorer to build and test the query. 

You might initial need to work with the other team to get consent/right to use Graph if not already done. I use a service princpal to connect to graph via Power Automate. Here's a example:

 

EricRegnier_0-1649969960832.png

  1. Using the HTTP connector, to get the groups, here I get all the groups. I use Acticee Directory OAuth to authenticate. 
  2. Then I parsed the body from the reponse to get the intellisense and creating a new Team in Dataverse. I set the team name and Object ID from the response.

Hope this makes sense! 

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Users online (5,626)