3 ways to create a SharePoint site with Power Automate (with NO admin role)

Creating SharePoint sites is extremely common from an admin perspective, but not that usual from a user point of view. However, it still possible if your administrators allow it.

If you (as an administrator) do allow it (because you have a solid governance in place!), users might go through the SharePoint interface (UI) on their SharePoint home page, and click on + Create site. But that’s not the only way they can do it.

So in this blog post, let’s go through 3 different ways a user with no admin role in your Microsoft 365 tenant can create a SharePoint site using Power Automate.

Prerequisites

For any of the following options, one setting from the SharePoint Admin Centre will need to be enabled.

In the admin center, navigate to Settings, and click on Site creation. The important setting to enable is users can create SharePoint sites.

Depending on where users will be creating flows from, another prerequisite is for them to have the environment maker role assigned if they’ll be creating flows from a different environment than their Default one.

Send an HTTP request to SharePoint

This action is very popular in the Power Automate scene. And therefore, very well documented.

Add the Send an HTTP request to SharePoint action in your flow, and fill in the following:

  • Site Address: Root site (i.e.: https://contoso.sharepoint.com)
  • Method: POST
  • Uri: _api/SPSiteManager/create
  • Headers: Accept – application/json
  • Body: All your desired configuration properties

When the flow runs successfully, the site is created we can access the SharePoint site.

Microsoft/Office 365 Groups connector

Our second way is to use the Office 365 Groups connector with the Send HTTP request V2 action. Using this connector means your users will need to be authorised to create Microsoft 365 groups (turned ON by default).

⚠️Please note that this action is currently in preview (at the time of writing this article) and has some known issues and limitations.

However, you can imagine what this action is going to do right? Thus you’ll need a good governance in place to avoid sprawling! But if you’re already letting users create groups, then I’m hopeful you’ve got one 😉

Choose the Send an HTTP request V2 under Office 365 Groups. If this is the first time using this action, you’ll need to authenticate to create a connection. Note there’s only one segment which is /groups.

For example:

{
    "displayName": "John Smith Test2",
    "description": "JS O365Groups HTTP request",
    "groupTypes": [
        "Unified"
    ],
    "mailEnabled": true,
    "mailNickname": "JohnSmithTest2",
    "securityEnabled": false
}

When the flow runs successfully, our Microsoft 365 group is created & SharePoint site provisioned 🙂

View from an admin perspective in the M365 Admin Centre

Entra ID connector

The Entra ID connector is not a premium connector. There’s a built-in action called Create an Office 365 group.

This one has only a few fields to fill, however when the group is created, it’ll be Public with no field to set the privacy setting from the get-go.

Others

There are other ways to create a site without admin roles, however they might either require a premium connector (HTTP), an App Registration, and/or potentially higher privileges. So be mindful and consider all options before implementing for your scenario.

Thanks for reading! 🙂

Discover more from Veronique's Blog

Subscribe now to keep reading and get access to the full archive.

Continue reading