We’re Still Here to Help (Even Over the Holidays!) - find out more here.
Forum Discussion
Charles R.5
8 years agoExplorer | Level 4
Cannot delete a folder with a '.' in the middle its name?
When I use the API to delete a folder with: https://api.dropboxapi.com/2/files/delete_v2 If the path to the folder is: /somepath/mydomain.com The folder will not delete. Interestingly, a...
Greg-DB
Dropbox Community Moderator
8 years agoThanks for the report. I can't seem to reproduce this issue though. The /2/files/delete_v2 endpoint is successfully deleting a folder with a period in the middle and returning the expected response for me.
Can you share a sample request/response that isn't working as expected, including response headers? Be sure to redact the access token of course. Thanks in advance!
Can you share a sample request/response that isn't working as expected, including response headers? Be sure to redact the access token of course. Thanks in advance!
- Charles R.58 years agoExplorer | Level 4Greg. Thanks for the reply.
When I try & delete:
/somepath/mydomain
It deletes successfully every time.
But, when I try & delete:
/somepath/mydomain.com
It does NOT delete the folder and returns an empty response string. Not even an error or 'status_code' is available, so it is very difficult to debug. Any ideas?
I have repeated the test, at least 50 times, using different folder names, with or without the '.' in the middle of the name, and the results are the same, each time.
So, the problem is, I cannot send you response, because there is none!
Thanks
Charlie - Charles R.58 years agoExplorer | Level 4Greg. This is my fault. Hidden somewhere in the custom API library, I created, I check for the existence of a filename, by using '.', as a file identifier. I created this library some time ago, and neglected to realise that I might be using folder names with '.' in them. Problem solved...
- Charles R.58 years agoExplorer | Level 4Just out of interest do you have an API directive that only deletes folders. So, that if a file path is sent in by mistake, the request fails?
- Greg-DB8 years ago
Dropbox Community Moderator
No, we don't have anything like that, but I'll pass that along as a feature request.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!