Removing an empty folder via rest-api
Hi,
I create some workbooks and remove them for some requirements. But, when I remove all the workbooks, the folder is still there even if it is empty. Is there a way to remove an empty folder structure via rest-api?
Thanks,
Tuğrul
-
Hello Tuğrul.
You could delete desired folder via the next REST API. This call doesn't return any response, thereby you could use -w"\n%{http_code}\n" property to get HTTP status code of the request. The code 204 means successful request.curl -u '<user>:<password>' -w"\n%{http_code}\n" -X DELETE 'http://<Datameer host>:<port>/api/filesystem/folders/<FolderID>'
To determine folder's ID you could use Read the Root Folder / Read the Folder REST CALLs.
Please sign in to leave a comment.
Comments
1 comment