Hi everyone, I'm attempting to programmatically create a modern team site via Flow using the SharePoint Online REST API described here using the Send an HTTP Request to SharePoint action. This is the action I've started with, but I get the error "BadGateway". Any help would be much appreciated, thank you.
Hi @swhitmore ,
As far as I know, Send an HTTP request to SharePoint action needs to specify the Site in Site Address field and then do some operations on the existing site.
And your need is to create a new team site, it seems that this action is not applicable to your scenario.
You could consider using HTTP action to create a modern team site.
Please refer to following blog, and see if it helps:
Thanks @v-bacao-msft ,
I'm actually trying to provision the Group from flow, not just the team in Teams. So I'm looking for a HTTP REST API that would create the Group and SharePoint Modern Site
Thanks @anton-khrit. I was aware of this 3rd party action, however I was hoping to avoid it as I don't have administrator access for our SharePoint Tenancy and I'm not sure they will approve 3rd party tools and access.
Don't know if it's allowed to link my own website but I just wrote a blog about this: Create a new Team with Forms and Flow
I describe how to use forms and flow (and graph) to create a team. With this you also get the modern sharepoint team site. I'm also planning on writing a blog about creating a communication site with forms, flow and the sharepoint rest api...
Hi @swhitmore ,
Your app registration needs the Read and write all groups rights. And this right needs to be granted by an admin, see: https://docs.microsoft.com/en-us/graph/permissions-reference under Application permissions
How is your PowerShell? An alternative method which is becoming more common is to use Azure Automation, and to build your modern team site using PowerShell in an Azure Runbook. It will give you more control over what you do with the site as and when it's provisioned.
Just thought I'd throw an additional option into the ring