Web Assets

Delete several folders from one submission, asynchronously

Changed on

Accepts a list of folder paths and answers 202 with a job handle before any folder is deleted. The run is asynchronous, queued to the folderBulkDelete queue, and each folder's delete is recursive and permanent, exactly as the single-folder delete already is. Follow the run with GET /api/v1/jobs/{jobId}/status, cancel it with POST /api/v1/jobs/{jobId}/cancel, and watch it with GET /api/v1/jobs/{jobId}/monitor. The submitting author is notified on any terminal state.

One folder failing does not abort the run: every remaining folder is still attempted, and each failure is reported by path with a machine-readable reason.

post/api/v1/assets/folders/_bulkdelete

Request

Request body

assetPathsstring[]

The selected folders, in the same site-qualified path form the single-folder delete accepts

Example request

{
  "assetPaths": [
    "//demo.dotcms.com/old-projects/"
  ]
}

Response

Run queued

i18nMessagesMapobject
permissionsstring[]

Changes