Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
I'm using "restClient.uploadFile(file, toPath: destPath, withParentRev: nil, fromPath: sourcePath)", where file="someFileName", destPath="somePathOnMyDropboxAccount", and sourcePath="someLocalFilePath". But instead of the file uploading to the designated path, it uploads to "file/file", creating a folder of the same name as the file on my Dropbox root folder.
What I wanted to happen was to upload my file to a specific folder (that may or may not exist). How do I do that?
Can you post your actual code, including the real values for these variables, and the output? It's hard to follow using the example values.
Also, there's some sample code for this in the tutorial:
Unfortunately, the example you cited in the tutorial shows how to upload to the root directory. That isn't the problem I'm having. I needed to know how to upload to something other than the root directory.
Through process of elimination, I figured out that I need to include the "/" prefix to my 'toPath:' parameter. Any path components before the "/" are apparently ignored.
Thanks for your help anyway.
Hi there!
If you need more help you can view your support options (expected response time for a ticket is 24 hours), or contact us on X or Facebook.
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!