April 30, 2025

SamTech 365

PowerPlatform, Power Apps, Power Automate, PVA, SharePoint, C#, .Net, SQL, Azure News, Tips ….etc

Automating SharePoint Site Creation with Power Automate

Recently, I had the opportunity to work on an exciting project for one of my clients. They required an automated process for creating SharePoint sites dedicated to their projects. The goal was to streamline the site creation process while ensuring consistency and governance across all project sites.

The Requirement

The client wanted a self-service approach where users could request a new SharePoint site through an MS Form. Once the request was submitted and approved, a Power Automate flow would create the SharePoint site with the necessary details provided in the form.

Solution Overview

To achieve this, I implemented the following approach:

  1. MS Forms for Site Requests – Users fill out a form with required details (e.g., Site Title, URL, Description, Owner, etc.).
  2. Approval Process – The request triggers an approval workflow.
  3. Power Automate for Site Creation – Once approved, Power Automate creates the SharePoint site automatically.

Step-by-Step Implementation

Step 1: Create an MS Form for Site Requests

  • In Microsoft Forms, create a new form with fields for Project Name, Site URL, Site Owner, Site Description, and any other metadata.
  • Share the form with users who will request project sites.

Step 2: Configure Power Automate to Trigger on Form Submission

  1. Navigate to Power Automate and create a new flow.
  2. Use the “When a new response is submitted” trigger for Microsoft Forms.
  3. Add the “Get response details” action to retrieve form responses.

Step 3: Implement an Approval Workflow

  1. Add an “Start and wait for an approval” action.
  2. Configure the approval process so that a designated manager or admin must approve the request.
  3. If approved, proceed with site creation. If rejected, notify the requester via email.

Step 4: Create a SharePoint Site Automatically

  1. Add the “Send an HTTP request to SharePoint” action.
  2. Configure the request to create a site using the SharePoint REST API:
{
    "request": {
        "Title": "Site Title from Form",
        "Url": "Site URL from Form",
        "Owner": "Site Owner from Form",
        "Description": "Site Description from Form",
        "Template": "STS#3"  // Use the appropriate template for your needs
    }
}

PS: For the WebTemplate, I have used a custom template which was saved from a SharePoint site, the template provisions different document libraries and folders’ structure for the purposes of project management.

Step 5: Notify the Requester

  • After successful site creation, send a confirmation email with the site URL and owner details.
  • If the site creation fails, notify the requester and admin for further review.
1