Retention values
File-level retention accepts:30d and 45d. A bucket-wide write-once (WORM) policy shorter than 90 days is not offered.
Retention is expressed as a period value, and the backend stores an expiry. Once active, the content is locked until that expiry.
Retention rules that affect your integration
A file with active retention cannot be changed or deleted
A file with active retention cannot be changed or deleted
Renaming, changing visibility, changing retention again, or deleting returns an error. Do not offer these actions in your UI when
isRetention is true.Bucket retention overrides per-file behavior
Bucket retention overrides per-file behavior
When a bucket has active retention, per-file retention changes are rejected, and files in that bucket cannot be soft- or hard-deleted even if they have no individual retention.
Retention cannot be shortened or cleared once active
Retention cannot be shortened or cleared once active
The lock is one-way until expiry. Plan retention at upload time rather than treating it as a toggle.
Legal hold blocks deletion independently
Legal hold blocks deletion independently
A legal hold can block deletion even when retention has expired. Legal hold is managed outside the public API.
Versions
When a file is uploaded again with the same name and extension in the same folder scope, the backend can create a new version instead of a separate file. The upload response then hasisUpdate: true.
Use GET /files/{fileId}/versions to list versions. Each entry includes the version identifier, size, creation time, action, author metadata when resolvable, and an isCurrent flag. The current live object is synthesized into the list even when it has no separate version row.
The nested version response
Version endpoints wrap a service result inside the normal controller envelope. The list response looks like this:data.data for the array. The inner status and message duplicate the outer values. This is current behavior, not a documentation error.
The same nesting applies to version restore, version delete, and file restore-from-trash.
Version operations
Deleting the current version through the version endpoint is rejected. Delete the file itself instead. A restore of the already-current version is also rejected as a no-op.
Restoring and deleting versions require write or delete capability. Downloading a version requires read capability.
Trash and restore
DELETE /files/delete/{fileId}?trash=soft marks the file deleted and starts the display window. trash=hard permanently removes it.
Restore a soft-deleted file with:
400. Restoring after the display window returns 410. The response payload is nested the same way as version operations.
Folders have their own trash endpoints: DELETE /folders/delete/{folderId} and POST /folders/restore-from-trash/{folderId}.
Recommended integration pattern
- Read
isRetentionandretentionPeriodbefore showing destructive actions. - Treat
trash=softas the default delete. - Require an explicit, user-confirmed action for
trash=hard. - Poll or refresh lists after mutations; do not assume local state matches server state.
- Handle
410as “too late to restore”, not as a transient error.