Overview Of Azure Logic Apps

With no code solutions being advocated for and lauded these days, features like Azure Logic Apps and Microsoft Flow are the go-to solutions to orchestrate a workflow of tasks that encompass various applications. In this article, I will discuss the process of creating a workflow using Azure Logic Apps to keep Azure Blob Storage and a SharePoint Document Library in sync.

As we know, both Azure Blob Storage and SharePoint Document Libraries could be used to store files of any types. Follow the below steps to design a workflow using Azure Logic Apps to transfer the files from Azure blob storage container to a SharePoint document library.

  1. Log in to the Azure portal.

  2. Create a new storage account and a blob container.

  3. Upload a couple of files in the container, as shown below.

    Overview Of Azure Logic Apps
  1. Create a new Azure Logic App to sync the blob files with a SharePoint document library.

  2. Go to Logic App Designer and click on Blank Logic App, as shown below.

    Overview Of Azure Logic Apps
  1. Click on the Schedule trigger as shown below to configure the workflow to get triggered in a pre-defined interval,

    Overview Of Azure Logic Apps

  2. Here I have configured the schedule to run every 1 hour,

    Overview Of Azure Logic Apps
  1. Click on New Step and select Azure Blob Storage and click on List blobs from the available options. The List blob action will retrieve all the blobs from the container.

  2. Give the connection name and select the storage account that you have created and hit on the Create button. This will create a new API Connection.

    Overview Of Azure Logic Apps
  1. Once created, select the blob container that you have created in you storage account
  1. Click on New Step and search and add the “For Each” action.

    Overview Of Azure Logic Apps
  1. Select the “value” output from the List blobs action as the collection for the “For each” action to loop. The “value” will contain the metadata all the blobs retrieved.

    Overview Of Azure Logic Apps
  1. Search for and add a new action called “Get blob content using path” and choose the “path” output from the List blobs action as the value for Blob path. This action will load the content of the blob which will later be used to create the file in SharePoint.

    Overview Of Azure Logic Apps

  2. Add a new action called “Create File” from the SharePoint connector. Fill in the site URL and choose the folder name which is nothing but the document library name to which you want the files copied.

  3. For the “File Name” parameter choose the “Display Name” output value from the List Blobs action and for “File Content” parameter choose the “File Content” output value from the Get blob content action as shown below.

    Overview Of Azure Logic Apps
  1. That’s it, the logic app should now look like below.

    Overview Of Azure Logic Apps
  1. Save the app and click on Run. All the files in your blob storage should now be copied over to your SharePoint document library.

    Overview Of Azure Logic Apps

    Overview Of Azure Logic Apps