pnp / pnp/cli-microsoft365

New command: spo folder unarchive

Open
#7,182 1 comment 0 reactions 1 assignee View on GitHub

@Saurabh7019 is already working on this.

Since Apr 3, 2026.

feature request work in progress
Dominant language
TypeScript
Stars
1.5k
Forks
413
Avg merge
5d 6h
Merged PRs (30d)
21

Description

Usage

m365 spo folder unarchive [options]

Description

Unarchives a folder

Options
Option Description
-u, --webUrl <webUrl> The URL of the site where the folder is located.
--url [url] The server- or site-relative decoded URL of the folder to unarchive. Specify either url or id, but not both.
-i, --id [id] The UniqueId (GUID) of the folder to archive. Specify either url or id, but not both.
-f, --force Do not prompt for confirmation.
Examples

Unarchive a folder without prompting for confirmation

m365 spo folder unarchive --webUrl https://contoso.sharepoint.com/sites/Marketing --id 7a8c9207-7745-4cda-b0e2-be2618ee3030 --force

Unarchive a folder by URL with prompting for confirmation

m365 spo folder unarchive --webUrl https://contoso.sharepoint.com/sites/Marketing --url '/sites/Marketing/documents/general'
Default properties

No response

Additional Info
POST https://contoso.sharepoint.com/_api/Lists(guid'${listId}')/items(${itemId})/UnArchive`

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.