2.5.1.6 Export and Import Site Content

This use case describes how a client application can export and import site content. Client applications export and import site content to migrate content from one site to another.

The following diagram illustrates the export and import process.

Process for exporting and importing site content

Figure 8: Process for exporting and importing site content

Preconditions

  • The client application can communicate with the SharePoint site.

  • The client application has been authenticated to the server, has open Web permissions and manage Web permissions for the source site, and has site creation permissions for the target site.

Steps

  1. The client application calls the method to export the site and passes the URL of the site to export, the file name for the content migration package, and the directory in which to place the package.

  2. The server packages the site content and places the content migration package in the specified directory.

  3. The client application calls the method to import the site and passes the URL for the resulting site and the URL of the content migration package.

  4. The server imports the content from the content migration package to the specified URL.

Errors

  • If a site at a specified URL is not accessible, the server will return an error.

  • If the directory from which to write and read the content migration package is not accessible, the server will return an error.

  • If the client application lacks sufficient permissions to export or import the site, the server will return an error.

Post-conditions

  • The destination site contains all the content from the content migration package.

  • The content is not exported or imported, because an error occurred.