Restore a recently deleted file
POST/files/:fileKey/restoration
Restores a soft-deleted file back to the live project. If the file's original parent folder was also deleted, the file is restored into a new wrapper folder at the project root. The file cannot be restored if its containing project has been deleted. Only a file that is the root of its own deletion can be restored via this endpoint; a file that was soft-deleted as part of an ancestor folder, project, or workspace's deletion event must be restored through the corresponding ancestor restoration endpoint instead.
Request
Responses
- 200
- 401
- 403
- 404
- 409
- 500
The file was restored successfully. Returns the restored file.
The request lacks valid authentication credentials.
Response Headers
Forbidden. The request is not allowed.
The recently deleted file was not found, or is not the root of its own deletion.
The file cannot be restored because its project has been deleted.
An internal error occurred while processing the request.