Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
jdwileymon
8 years agoExplorer | Level 3
Audio files uploaded give "audio error has occurred" and the files are corrupted
As in the title, more details here: https://stackoverflow.com/questions/50223863/uploaded-wav-audio-file-is-unreadable-corrupted?noredirect=1#comment87465268_50223863
jdwileymon
8 years agoExplorer | Level 3
To your question of "req.body.file" - that's the data I'm passing, either File object, blob, etc.
Greg-DB
Dropbox Community Moderator
8 years agoWhat is the type and size of "req.body.file" before you modify it though, and what does it contain?
It's hard to offer insight as I don't know exactly what you're working with. Are you using Express or something? Is `req.body.file` getting set by some middleware? What, if so? It might be more helpful if you can provide a full sample.
Also, in Node, `console.log(response)` will just show you the type in this case, but you can access the different properties, e.g., `response.size`.
By the way, I linked to the browser JavaScript upload example, but here's the Node JavaScript upload example:
https://github.com/dropbox/dropbox-sdk-js/blob/master/examples/javascript/node/upload.js#L17
It's hard to offer insight as I don't know exactly what you're working with. Are you using Express or something? Is `req.body.file` getting set by some middleware? What, if so? It might be more helpful if you can provide a full sample.
Also, in Node, `console.log(response)` will just show you the type in this case, but you can access the different properties, e.g., `response.size`.
By the way, I linked to the browser JavaScript upload example, but here's the Node JavaScript upload example:
https://github.com/dropbox/dropbox-sdk-js/blob/master/examples/javascript/node/upload.js#L17
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!