Actions35
- File Actions
- Folder Actions
- Room Actions
- User Actions
Folder → Delete Folder
AI-generatedSummary
Deletes a folder in ONLYOFFICE DocSpace by its numeric ID and returns the folder's info as it was before deletion.
Inputs
- Authentication (required) — Credential type used for the request: API Key, Basic Auth, OAuth2, or Personal Access Token. The matching DocSpace credential must be configured.
- Folder ID (required) — Numeric ID of the folder to delete.
Output shape
One JSON item per input item, containing the folder's metadata (from GET api/2.0/files/folder/{id}) captured before deletion.
The node first fetches folder info, then sends DELETE with deleteAfter=false and immediately=false. It polls the file-operations endpoint up to 20 times at 100 ms intervals until the async delete finishes. It throws on reported operation errors or timeout. The immediately=false setting suggests the folder may go to trash rather than being permanently removed, but the source does not confirm this. With Continue On Fail enabled, a failed item returns {error: message} instead.
Examples
Example 1: Clean up a temporary folder after a workflow finishes processing its files.
Resource: Folder, Operation: Delete Folder, Folder ID: {{$json.folderId}} (from an earlier Create Folder step), Authentication: API Key.
Example 2: Delete a known folder and keep a record of what was removed.
Folder ID set to 12345. The output item holds the deleted folder's title, parent and other metadata, which you can log downstream.