Skip to main content
Folders are optional containers inside a bucket. They form a tree with a maximum depth of 8.

Endpoints

Create a folder

Unknown fields are rejected. The server also rejects:
  • a duplicate name under the same parent (400),
  • a parent in a different bucket (400),
  • a deleted parent (400),
  • a tree deeper than 8 levels (400).
The response is the created folder object inside the normal envelope.

List root folders

Each item includes hasSubfolders, totalSubfolders, sharedUsersCount, and an active sharedLink summary when one exists.

Folder details

Values are illustrative. totalFiles and totalSubfolders are direct counts, not recursive. totalSizeByte sums non-deleted files directly in the folder.

Subfolders

Returns:
Subfolders are not paginated by this endpoint; total reflects the filtered list length.

Folder content

Response:
Subfolders are placed before files in the combined array. totalFiles and totalFolders reflect the filtered totals, not just the current page.

Rename or reparent

Both fields are optional, but at least one should be present. Unknown fields are rejected. Setting parentId to null makes the folder a root folder. The server rejects cycles, self-parenting, and depth violations.
Prefer POST /folders/move/{folderId} for moves. It returns a move summary and validates destination rules explicitly. PUT /folders/update is intended for renames and simple reparenting.

Move a folder

Use null to move the folder to the bucket root. A missing field is rejected. A folder cannot move into itself or into one of its descendants. Response:

Copy a folder

destinationBucketId is required. The copy includes the entire subtree: child folders and non-deleted files. Source files that are in trash are excluded. Storage capacity must cover the duplicated bytes. Response:
foldersCopied counts the root plus descendants.

Delete and restore

trash is soft (default) or hard. Soft delete cascades to descendant folders and files. Hard delete is permanent. The delete response has data: null on success. Restore with:
Restoring a folder that is not in trash returns HTTP 200 with the message “Folder is not in trash” and the folder ID in data. An elapsed display window returns 410. A missing folder returns 404.
Deleting a folder is a subtree operation. Confirm the child count with folder details before offering delete in your UI.

Common errors