Create a group and teamsite using REST API in Power Automate - CreateGroupEx

For a customer i was creating a project portal. On the project portal we have a list with all projects and when a new item is added to that list a power automate flow creates a new project site in SharePoint. 

For some projects the team members might want to create a Team in Microsoft Teams. That's why I choose to create a group using the REST API call CreateGroupEx

The site that gets created can easily be Teamified by the PM.

Here is the http action in Power Automate.



Headers:

{ "accept": "application/json;odata=verbose" }


Body:

  "displayName":"@{triggerOutputs()?['body/Project_x0020_number']}",

  "alias":"@{triggerOutputs()?['body/Project_x0020_number']}", "isPublic":false,

  "optionalParams":{  

    "Description":"",

    "Owners":["@{triggerOutputs()?['body/Editor/Email']}",""],

    "CreationOptions": 

      ["implicit_formula_292aa8a00786498a87a5ca52d9f4214a_b58944e9-5cb5-46fc-bb16-aa724e29f1cf",

      "SPSiteLanguage:1033",

      "HubSiteId:1b69fb82-dc44-4771-b5bc-f4789810c356"

    ]

  } 

}



Comments

Popular posts from this blog

100.000 contacts for TyT MD-2017

De Kunst van het gebruik van Prompts in ChatGPT en Bing Chat Enterprise

Show a users display name in a PnP Modern Search Results Web Part using handlebars helpers