Skip to content

Instantly share code, notes, and snippets.

Moving Files with SharePoint Online REST APIs in Microsoft Flow

About

This is an overview of how to move files with Microsoft Flow using the SharePoint - Send an HTTP request to SharePoint action and SharePoint Online REST APIs.

These SharePoint Online REST APIs can be used outside of Flow, but you will need to handle authentication and provide an X-RequestDigest header with any POST requests (as with any SP REST POST request).

In the case of Flow's SharePoint - Send an HTTP request to SharePoint action, authentication is handled for you and you do not need to provide the X-RequestDigest header.

Cross-site collection file copy with SharePoint Online REST APIs in Microsoft Flow

About

This is a follow up to my previous post: Moving Files with SharePoint Online REST APIs in Microsoft Flow, which explains how to move/copy files with Microsoft Flow using the SharePoint - Send an HTTP request to SharePoint action and the SharePoint Online SP.MoveCopyUtil REST API.

This post demonstrates using a similar approach, but using the CreateCopyJobs and GetCopyJobProgress APIs to copy files from one site collection to another.

I suggest reading the previous post first for context if you haven't already.