Office 365 Migration API

 Office 365 Migration API

Data to the CloudEarlier this year, Microsoft launched a new API for migrating content from Microsoft SharePoint On-Premises to SharePoint Online.

Prior to the new Office 365 migration API, you had the choice of either manually migrating content to SPO or using 3rd party tools to migrate the content. Either way, you would be using CSOM SharePoint Online APIs to migrate the content which caused performance issues for Microsoft. Therefore, Microsoft have begun to discourage the use of CSOM to migrate content to SharePoint Online and have begun to throttle migrations that do use CSOM.

The process using the new Office 365 Migration API is to export the content that you wish to migrate as a package (folder containing file and manifest information). The package is submitted to an Azure storage account temporarily, and then copied via the local area network of your data centre from Azure to the Target SharePoint Online List or Library.

Currently, Microsoft are focused mainly on content from SharePoint On-Premises and File Shares. Web Part configurations, Workflows and such like are currently not migrated and the focus is on content. However, permissions and meta data are migrated.

Using the new Office 365 Migration API, you will create a package which contains the content that you wish to migrate to SharePoint Online. The package contains a number of .DAT files along with several .XML files describing the package, environment you are migrating from, requirements, views and groups.

image
Created Package from a SharePoint On-Premises document library.

Once the package is created, it is submitted to an Azure Storage blob account. Before you perform the migration therefore, it would be required for you to login to your Azure portal and create an Azure Storage account.

image
Creating a Azure Storage Account

After submitting the package to Azure, you will be able to view the Blob within the queue whilst the data is migrated to the SharePoint online list or library.

image
Blob selected within Azure Storage.

Once the Package is submitted to the Azure Blob Storage, a CSOM call is made to your SharePoint Online environment allowing the content to be copied to the target lists or library using the local network within your Microsoft data centre.

The Microsoft SharePoint Online Management Shell must be installed providing the PowerShell cmdlets used to Export the package, and submit the package to Azure.

PowerShell Migration cmdlets

The PowerShell cmdlets used to create the package, submit the package, and submit the migration job can be found below:

New-SPOMigrationPackage

Creates a new migration package based on source files in a local or network shared folder.

ConvertTo-SPOMigrationTargetedPackage

Re-maps a previously created file share based package or exported SharePoint package to accurately describe objects in a target web.

Set-SPOMigrationPackageAzureSource

Creates Azure containers, upload migration package files into the appropriate containers, and snapshot the uploaded content.

Submit-SPOMigrationJob

Submits a new migration job referenced to a previously uploaded package in Azure Blob storage into to a site collection.

Remove-SPOMigrationJob

Removes a previously created migration job from the specified site collection.

Get-SPOMigrationJobProgress

Views the progress of a submitted SPO Migration job.

Get-SPOMigrationJobStatus

Cmdlet to monitor the status of a submitted SPO Migration job.

Lightning Tools have been busy this year working on a tool that will perform the entire process for you. That way, you get the best of both worlds. You can migrate the content from a SharePoint On-Premises environment to SharePoint Online without the complexity of the PowerShell commands.