Export planner or onenote from SharePoint online using powershell or pnp

Praveen Mittapalli 36 Reputation points
2020-12-16T15:56:43.87+00:00

Need Export planner or onenote from SharePoint online using powershell or pnp. Actually we are provisioning SharePoint online site in that we have a requirement like this.

Could you please help me on it.

Thanks in advance.

Microsoft 365 and Office | SharePoint | For business | Windows
Windows for business | Windows Server | User experience | PowerShell
Microsoft 365 and Office | OneNote | For business | Windows
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Chelsea Wu 6,341 Reputation points Moderator
    2020-12-17T06:16:11.92+00:00

    You can refer to the document here for a tutorial on how to Export user data from Microsoft Planner.
    The exporting process is done through Windows PowerShell as following:

    1. Download and unzip the Planner user data export files on your local drive. Make sure the files are unblocked in the folder.
    2. Run Windows PowerShell as Administrator and then execute the following cmdlets one by one:
      PS> Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope Process > Type Y
      PS> Import-module "<location of the .psm1 file>"
      PS> Export-PlannerUserContent -UserAadIdOrPrincipalName <user's AADId or UPN> -ExportDirectory <output location>
      Make sure you use a Global Admin account for the prompted credential.

    As for OneNote, there is currently no PowerShell/PnP PowerShell cmdlets from Microsoft to export OneNote notebooks or pages.
    You can take a look at an article here for a sample to Bulk export OneNote 2013/2016 pages as HTML.
    *Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link. *


    If an Answer is helpful, please click "Accept Answer" and upvote it.
    **Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. **


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.