Power Automate Create SharePoint List

In this Power Automate tutorial, we will discuss how to create a SharePoint list using Power Automate from different sources. And also we will discuss the below points:

  • Power automate create SharePoint list from template
  • Power Automate create SharePoint list item
  • Power Automate create SharePoint list from excel
  • Power automate create SharePoint list item with attachment
  • Power automate create SharePoint list from JSON
  • Power automate create SharePoint list columns
  • Power automate create SharePoint list from the form
  • Power automate create SharePoint list item from email

Power automate create SharePoint list from template

Here we will see how to create a SharePoint list dynamically using Power Automate.

In Power Automate, select the Manually triggered Flow, then click on the Next step.

 power automate create sharepoint list
power automate create SharePoint list

Now we will send an HTTP request to the SharePoint site, to create a list, so select Send an HTTP request to SharePoint action. Then provide the site address, where you want to create a List. Next select Method as Post, then provide the below information

Uri:_api/web/Lists/

Headers:
accept- application/json;odata=verbose
content-type-application/json;odata=verbose

Body
{ '__metadata': { 'type': 'SP.List' }, 'AllowContentTypes': true,
 'BaseTemplate': 100, 'ContentTypesEnabled': true, 'Description': 'My list description', 'Title': 'Contact' }
How power automate create sharepoint list
How power automate create SharePoint list

Now click on save and run the flow manually, and you can see an empty SharePoint list created.

Microsoft Flow create sharepoint list
Microsoft Flow create sharepoint list

This is how to create a SharePoint list in Power Automate from a list template.

Read Power Automate delete file from SharePoint

Power Automate create SharePoint list item

Here we will see how to create a SharePoint list item dynamically using Power Automate.

So we have a below SharePoint list is contact List where we will create item dynamically.

power automate create sharepoint list item
power automate create SharePoint list item

In Power Automate, select the Manually triggered Flow, then click on the Next step.

How power automate create sharepoint list item
How power automate create SharePoint list item

Now we will send an HTTP request to SharePoint to create an item, so click on the Next step and select Send an HTTP request to SharePoint action, then provide the variable name, Method as Post, and provide the below information:

Uri- _api/web/lists/GetByTitle('<ListName>')/Items

Headers:
Accept : application/json;odata=verbose
Content-Type : application/json;odata=verbose

Body:
{
  "__metadata": {
    "type": "SP.Data.<ListName>ListItem"
  },
  "Title": "John",
  "Contact_x0020_Number": "12345",
  "Address": "Canada"
}
Microsoft Flow create sharepoint list item
Microsoft Flow create SharePoint list item

Now click on save and run the flow manually, you can see items get created in the List.

MS Flow create sharepoint list item
MS Flow create SharePoint list item

This is an example of MS Flow create a SharePoint list item.

Check out, How do I restore removed files in SharePoint with Power Automate

Power Automate create SharePoint list from excel

Here we will see how to create a SharePoint list from Excel using Power Automate.

So here we will use the below excel file to create SharePoint list items using Power Automate.

power automate create sharepoint list from excel
Power Automate create SharePoint list from excel

To create SharePoint list items from excel, we need to create a SharePoint list containing columns. So we have created a Product list like below.

How power automate create sharepoint list from excel
How power automate create SharePoint list from excel

Now we will create a Flow to create a SharePoint list item from excel using Power Automate.

In Power Automate, select the Manually triggered Flow, then click on the Next step.

Microsoft Flow create sharepoint list from excel
Microsoft Flow create SharePoint list from excel

Next, we will get the rows from the excel table, so select List rows present in a table action. Then provide the Location, Document Library, File, and table of excel.

How power automate create sharepoint list from excel table
How power automate create SharePoint list from excel table

Next, we will create an item in the SharePoint list, so click on the Next step and select Apply to each action, then provide the value from List rows present in a table.

To store the number field, i.e. for Unit price and Quantity, we will create a compose action, so click on the Next step and select Compose action. Then in Input provide the Unit price from dynamic content. Similarly, create compose action for Quantity.

Then click on Add an action inside Apply to each action, and select Create item action. Then provide the site address, List name, Then map the header with the value from dynamic content like below.

Microsoft Flow create sharepoint list from excel table
Microsoft Flow create SharePoint list from an excel table

Now click on Save and run the Flow manually and you can see the SharePoint list item get created automatically.

Microsoft Flow create sharepoint list from excel
Microsoft Flow create SharePoint list from excel

This is an example of Power automate create SharePoint list from excel.

Read How to convert word to pdf using Power Automate

Power Automate create SharePoint list item with attachment

Here we will see how to create a SharePoint list item with an attachment using Power Automate when a new email arrives.

So, we will use the below excel sheet to create a SharePoint list item with an email attachment.

power automate create sharepoint list item with attachment
power automate create SharePoint list item with attachment

Next, we will create an item in the SharePoint list i.e Product with attachments.

power automate create sharepoint list item with attachment
power automate create SharePoint list item with attachment

In Power Automate, select the trigger When a new email arrives(V3) action. Then provide the folder where an email will arrive in outlook.

Microsoft Flow create sharepoint list item with attachment
Microsoft Flow create SharePoint list item with attachment

Next, we will retrieve the data from the above excel sheet, so click on the Next step and select List rows present in a table action. Then provide the Location, library, File, and table from the drop-down.

How Microsoft Flow create sharepoint list item with attachment
How Microsoft Flow create SharePoint list item with attachment

Now we will create an item in the Sharepoint list, so to add number data to an item we need the help of Compose action. So click on the Next step and select 2 compose actions then provide the Unit price and Quantity from the dynamic content, it will automatically add Apply to each action.

Using Microsoft Flow create sharepoint list item with attachment
Using Microsoft Flow create a SharePoint list item with an attachment

To create an item in the SharePoint list, click on the Add an action inside Apply to each action then select Create item action. Then provide the site address, list name, Title. Unit price, category, and Quantity from dynamic content.

Using MS Flow create sharepoint list item with attachment
Using MS Flow create a SharePoint list item with an attachment

Next, we will add an attachment with Create item, so for this, we will get the attachment from email, click on the Add an action and select Get attachment(V2) action, then provide the Message-id and Attachment id, that will automatically add Apply to each action.

 MS Flow create sharepoint list item with attachment
MS Flow create SharePoint list item with attachment

Next, add an attachment, so click on the Next step and select Add attachment action. Then provide the SIte address, list name, Id, Filename, and file content from dynamic content.

How MS Flow create sharepoint list item with attachment
How MS Flow create SharePoint list item with attachment

Now click on save and send an email with an attachment, and you can see the in the SharePoint list items with attachment.

 Flow create sharepoint list item with attachment
Flow create SharePoint list item with attachment

This is an example of Power Automate create a SharePoint list item with an attachment.

Read Power Automate export SharePoint list to excel and send an email

Power Automate create SharePoint list from JSON

Here we will see how to create a SharePoint list in another SharePoint site from the existing SharePoint list using Power Automate.

So here we will do two API calls to SharePoint, one is to get all information from the below source list(from SharePoint site 1), and the other is to create a new list in the destination SharePoint site( SharePoint site 2).

power automate create sharepoint list from JSON
power automate create SharePoint list from JSON

In Power Automate, select the Manually triggered Flow, then click on the Next step.

How power automate create sharepoint list from JSON
How power automate create SharePoint list from JSON

Next, we will send an HTTP request to SharePoint to retrieve information from the source list, so select Send an HTTP request to SharePoint action. Then Provide the site address, and Method as Post. Then provide the below information:

Uri:_api/Microsoft.Sharepoint.Utilities.WebTemplateExtensions.SiteScriptUtility.GetSiteScriptFromList()

Headers:
accept- application/json;odata=verbose
content-type-application/json;odata=verbose

Body:
{
  "listUrl": "https://<xxx>.sharepoint.com/sites/<sourceSiteName>/Lists/<sourceListName>/"
}
Microsoft Flow create sharepoint list from JSON
Microsoft Flow create sharepoint list from JSON

Now click on Save and run the flow, you will get JSON code from the body, which will help later to create a SharePoint list.

How Microsoft Flow create sharepoint list from JSON
How Microsoft Flow create SharePoint list from JSON

Now we got the JSON code, it’s time to create a new SharePoint list with Parse JSON action. So click on the Next step and select Parse JSON action.

Next, generate the schema using the above JSON code and in content write the below expression:

outputs('Send_an_HTTP_request_to_SharePoint')?['body']?['d']?['GetSiteScriptFromList']
MS Flow create sharepoint list from JSON
MS Flow create SharePoint list from JSON

Now we will send an HTTP request to the destination Sharepoint site, so click on the next step and select Send an HTTP request to SharePoint action. Then provide the source SharePoint list and select Method is Post. Next, provide the below information:

Uri:_api/Microsoft.Sharepoint.Utilities.WebTemplateExtensions.SiteScriptUtility.ExecuteTemplateScript()

Header:
accept- application/json;odata=verbose
content-type -application/json;odata=verbose

Body:
{"script": "{\"actions\":@{replace(replace(string(body('Parse_JSON')?['actions']),'\','\\'),'"','\"')}}"}
How MS Flow create sharepoint list from JSON
How MS Flow create a SharePoint list from JSON

Now click on Save and run the Flow manually, you can see the new list get created in Destination SharePoint site.

Flow create sharepoint list from JSON
Flow create SharePoint list from JSON

This is an example of Power Automate create SharePoint list from JSON

Read Power Automate delete all items in SharePoint list

Power Automate create Sharepoint list columns

Here we will see how to create a column in the SharePoint list dynamically using Power Automate.

In Power Automate, select the Manually triggered Flow, then click on the Next step

power automate create sharepoint list columns
power automate create SharePoint list columns

Now we will send an HTTP request to the SharePoint site create a SharePoint list using Power Automate.

So select Send an HTTP request to SharePoint, then provide the site address where you will create SharePoint List and Method as Post. Then provide the below information:

Uri:_api/web/Lists/

Headers:
accept- application/json;odata=verbose
content-type-application/json;odata=verbose

Body
{ '__metadata': { 'type': 'SP.List' }, 'AllowContentTypes': true,
 'BaseTemplate': 100, 'ContentTypesEnabled': true, 'Description': 'My list description', 'Title': 'Contact' }
How power automate create sharepoint list columns
How power automate create SharePoint list columns

Now click on Save and run the flow manually, then copy the JSON code from the body of Send an HTTP request to SharePoint.

Next, we will parse that JSON code to get the Uri, so click on the Next step and select the Parse JSON action. Then generate the schema using JSON code and in content add the body of HTTP request action.

Microsoft Flow create sharepoint list columns
Microsoft Flow create SharePoint list columns

Next, initialize string variable which will store the end API point of the site, so click on the Next step and select Initialize variable action. Then provide the variable name, type as a string, and in value write the below expression:

[email protected]{split(body('Parse_JSON')?['d']?['__metadata']?['id'],'_api')[1]}
How Microsoft Flow create sharepoint list columns
How Microsoft Flow create SharePoint list columns

Next, we will create two-column, one is the contact number which is a number field, and the Address column which is a single line of text via an HTTP request to SharePoint.

So click on the Next step and select Send an HTTP request action. Then provide the site address, Method as Post. Then Provide the below information

  1. For Contact Number
Uri :@{variables('LIst Uri')}/Fields

Headers:
accept- application/json;odata=verbose
content-type-application/json;odata=verbose

Body:

{ '__metadata': { 'type': 'SP.Field' }, 'Title':'Contact Number','FieldTypeKind':9}

2. For Address Field

Uri :@{variables('LIst Uri')}/Fields

Headers:
accept- application/json;odata=verbose
content-type-application/json;odata=verbose

Body:
{ '__metadata': { 'type': 'SP.Field' }, 'Title':'Address','FieldTypeKind':2}
MS Flow create sharepoint list columns
MS Flow create SharePoint list columns

Now click on Save and run the Flow Manually. Then go to SharePoint and add a column to the SharePoint list from Show/ hide.

How MS Flow create sharepoint list columns
How does MS Flow create SharePoint list columns

This is an example of Power Automate creating sharepoint list columns.

Read Convert SharePoint list item to PDF using Flow or Power Automate

Power Automate create SharePoint list from form

Here we will see how to create a SharePoint list item from Form using Power Automate.

So here we have created a Microsoft Form called Feedback like below:

power automate create sharepoint list from form
power automate create SharePoint list from the form

And also we have created a SharePoint list to store the data like below.

How power automate create sharepoint list from form
How power automate create SharePoint list from the form

In Power, Automate select the, ‘When a new response is submitted’ trigger. Then provide the Form id of the Form.

MS Flow create sharepoint list from form
MS Flow create SharePoint list from form

Next, we will retrieve the response details from the Form, So click on the Next step and select Get response details action. Then provide the form id and response id from dynamic content.

How MS Flow create sharepoint list from form
How MS Flow create a SharePoint list from the form

Next, we will create an item, so click on the next step and select Create item action. Then provide the Site address, list name, and then map the value from dynamic content.

 Flow create sharepoint list from form
Flow create SharePoint list from the form

Now click on Save and to run the flow, fill and submit the form. Then, items get created in the SharePoint list.

Microsoft Flow create sharepoint list from form
Microsoft Flow create a SharePoint list from the form

This is how to create a SharePoint list from a form in Power Automate or Microsoft flow.

Read How to update SharePoint Multiselect column in Power Automate

Power Automate create SharePoint list item from email

Here we will see how to create a SharePoint list item from email using power Automate.

When a new email receives in the below format, we will parse the email and extract the value, then create a list item in SharePoint.

power automate create sharepoint list item from email
power automate create SharePoint list item from email

Then we have a SharePoint list called Contact, where we will store the data from email.

How power automate create sharepoint list item from email
How power automate create SharePoint list item from email

In Power Automate, select the ‘When a new email arrives’ trigger. Then provide the folder where an email will arrive.

Microsoft Flow create sharepoint list item from email
Microsoft Flow create SharePoint list item from email

Now we will convert the email body from Html to text, so click on the Next step and select HTML to text action. Then provide the body content from dynamic content.

How Microsoft Flow create sharepoint list item from email
How Microsoft Flow create SharePoint list item from email

Now we will split the output of Html to text, to get the value, so click on the Next step and select compose action. Then in Input provide the below expression:

split(body('Html_to_text'),'|')
MS Flow create sharepoint list item from email
MS Flow create SharePoint list item from email

Now we will add an item to the SharePoint list, so click on the Next step and select Create item. Then provide the site address, list name then map the value with the below expression:

Title- outputs('Compose')[1]
Contact Number - outputs('Compose')[3]
Address- outputs('Compose')[5]
How MS Flow create sharepoint list item from email
How MS Flow create SharePoint list items from email

Now click on Save and to run the flow send an email with the above format, and you can see item get created in the SharePoint list.

Using MS Flow create sharepoint list item from email
Using MS Flow create SharePoint list item from email

This is an example of Power Automate creating a SharePoint list item from email.

Related Power Automate articles:

In this Power Automate tutorial, we learned about steps to create a SharePoint list in Power Automate. And also we will discuss the below points:

  • Power automate create SharePoint list from template
  • Power Automate create SharePoint list item
  • Power Automate create SharePoint list from excel
  • Power automate create SharePoint list item with attachment
  • Power automate create SharePoint list from JSON
  • Power automate create SharePoint list columns
  • Power automate create SharePoint list from the form
  • Power automate create SharePoint list item from email
>