Your workflow is unique 👨💻 - tell us how you use Dropbox here.
Forum Discussion
jmsalvador
8 years agoExplorer | Level 3
Upload a file via wininet with a POST
Hi Team,
we are using the Dropbox REST API with OAuth2. When attempting to upload a file I don't know where to put the file contents using the wininet for http way.
In the docs there is just...
Greg-DB
Dropbox Community Moderator
8 years agoThe /2/files/upload endpoint is a "content-upload" style endpoint, so it does expect the file data for the upload in the request body. That is what curl's "--data-binary" does. (I.e., in the example, that's how you specify what data or file curl should use for the request body.)
I can't offer support for and don't have a sample for WinINet/HttpSendRequest specifically unfortunately though, so you'll need to refer to the documentation for that for instructions on how to configure a request using that with the desired data in the body.
About Dropbox API Support and Feedback
Get help with the Dropbox API from fellow developers and experts.
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!