Reassign Sways from a deleted user account - Admin Help

When a user is deleted from Azure Active Directory, their Sways enter into a holding state where they will get deleted later. During that period of time, the Sway won't be accessible to regular users. IT administrators have 30 days after a user is permanently deleted from the Azure Active Directory to reassign Sways that they owned to another user within their tenant.

Note: The Azure Active Directory also has a holding period before the user is permanently deleted.

Step 1: Download and install libraries

  1. Download libraries from PowerShell cmdlets for reassigning Sways 

  2. Extract the libraries:

    1. Microsoft.IdentityModel.Clients.ActiveDirectory

    2. Microsoft.Office.Story.PowerShell.ChangeOwnerClient.dll

    3. Microsoft.Office.Story.PowerShell.Protocol.dll

    4. Newtonsoft.Json

  3. Keep the folder structure intact and install them as modules using, follow the instruction here

    1. Example:

      1. Extract everything to ...\Documents\WindowsPowerShell\Modules\

  1. Ensure that downloaded files are not blocked by unblocking them via their properties settings

    1. Example:

Step 2: Import the Modules in PowerShell

  1. Open Windows PowerShell as an administrator:

    1. In your search bar, type Windows PowerShell.

    2. Right-click on Windows PowerShell or Windows PowerShell ISE and select Run as Administrator.

    3. Example

      1. Powershell

      2. The Windows PowerShell window will pop open.  The prompt C:\Windows\system32 means you've opened it as an administrator.

      3. powershell2

2. Import the modules previously downloaded.

Syntax:

Import-Module Microsoft.Office.Story.PowerShell.Protocol
Import-Module Microsoft.Office.Story.PowerShell.ChangeOwnerClient
Import-Module Microsoft.IdentityModel.Clients.ActiveDirectory
Import-Module Newtonsoft.Json

(Additional instructions on how to import modules)

Step 3 - Connect to the Sway Service and run the transfer script

Note: Only Sways that were previously owned by the deleted account can be transferred at this time, and only to a user within the same tenant. Only the tenant administrator may initiate a transfer. 

  1. Connect to the Sway Service via PowerShell

  2. Enter the credentials of the tenant administrator

Syntax:

	Connect-SwayService

Example:

	Connect-SwayService

Transfer a single Sway to another account

To transfer a single Sway that was previously owned by a deleted account to another account within the same tenant, you will need the following information:

  • Sway Lookup ID - ID found after the sway.com URL for any given Sway (e.g. "Ex: abc123 for https://sway.com/abc123")

  • New Email Address - email address of the account you are transferring the Sway to

Syntax:

	Start-ChangeSwayOwner -OriginalSwayLookupId <Sway Lookup ID> -DestinationOwner <New Email Address>

Example:

	Start-ChangeSwayOwner -OriginalSwayLookupId abc123 -DestinationOwner user@contoso.com

Bulk transfer all Sways from one account to another

To transfer all Sways previously owned by a deleted account to another account within the same tenant, you will need the following information:

  • Deleted Account Email Address - email address of the account that was deleted from the Azure Active Directory

  • New Account Email Address - email address of the account you are transferring the Sway to

Syntax:

	Start-BulkChangeSwayOwner <Deleted Account Email Address> <New Account Email Address>

Example:

	Start-BulkChangeSwayOwner deleteduser@contoso.com activeuser@contoso.com

Step 4 - Verify that the Sways were reassigned

  1. View a Sway that was reassigned.

  2. Notify the user who the Sways were transferred to and ask them to verify that they now own the Sways.

Things to Know

  • You have up to 30 days of the account being permanently deleted from the Azure Active Directory to reassign any Sways that were owned by that account

  • After successfully running the reassignment script, it could take up to 1 hour for the reassigned Sways to appear in the new account.

  • Some settings associated with the reassigned Sway won't be preserved. This includes:

    • Sway Analytics (view count)

    • Share settings

      • If a Sway was shared with specific people, it will be reset back to the default settings in the reassigned Sway

      • For Sways that were shared for editing, the new owner will need to re-share a new link to any coauthors who still need edit access

    • Last edited date

    • Settings previously set on the Sway. For example: removal of the Sway banner and Autoplay.

Expand your Office skills
Explore training
Get new features first
Join Office Insiders

Was this information helpful?

Thank you for your feedback!

Thank you for your feedback! It sounds like it might be helpful to connect you to one of our Office support agents.

×