You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.
Forum Discussion
chacychavez
3 years agoExplorer | Level 4
Create empty file without uploading
Is it possible to create an empty file without having to upload a local file? I'm trying to make `/file/upload` endpoint work with .docx files but when i'm trying to check the file on the web, it ...
- 3 years ago
The Dropbox API doesn't offer a call specifically to just create an empty file, but you can call /file/upload with an empty body to make an empty file (that is, with a size of 0).
A file with a size of 0 isn't a valid .docx file though, so if you mean you want to upload a valid .docx document that just doesn't contain any content, you'd need to create that locally and then upload the (non-zero length) data.
Greg-DB
3 years agoDropbox Staff
The Dropbox API doesn't offer a call specifically to just create an empty file, but you can call /file/upload with an empty body to make an empty file (that is, with a size of 0).
A file with a size of 0 isn't a valid .docx file though, so if you mean you want to upload a valid .docx document that just doesn't contain any content, you'd need to create that locally and then upload the (non-zero length) data.
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
5,910 PostsLatest Activity: 3 days agoIf 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 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!