Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
Wookiee
2 years agoExplorer | Level 4
API delete by id:# via CURL
In one script in my FileMaker database solution, I upload a file to a constructed path, then save the unique id:xxxxxxxxxxxxxxxx number for that record, to tie the record to the file in the DropBox d...
- 2 years ago
Wookiee, The question of mine was rhetoric! I hoped it'll direct you. Ok... can you see the difference of your 2 posts and figure out alone what's different and wrong or...?
PS: Everywhere some path can be used, the equivalent id can be used too. Even more a hybrid form may be used too: id of a folder followed by a relative path. In all cases that's NOT the issue (I assume the id is correct).
Здравко
2 years agoLegendary | Level 20
Hi Wookiee,
Are you sure, you have executed exactly that curl command you posted and not something else? 🤔 Why do I ask? The error message states that you have passed "Dropbox-Api-Arg" header, but it's missing on your post! 😉😀
Hope this helps.
Wookiee
2 years agoExplorer | Level 4
I just took the code section from the dev API example... here are the args that is getting sent by FileMaker using it's "Insert from URL" script step:
-X POST
--header "Content-Type: application/json"
--header "Authorization: Bearer <redacted>"
--header "Dropbox-API-Arg: {\"path\":\"id:m5ktIrz8BXoAAAAbAAAASg\"}"
--dump-header
- Здравко2 years agoLegendary | Level 20
Wookiee, The question of mine was rhetoric! I hoped it'll direct you. Ok... can you see the difference of your 2 posts and figure out alone what's different and wrong or...?
PS: Everywhere some path can be used, the equivalent id can be used too. Even more a hybrid form may be used too: id of a folder followed by a relative path. In all cases that's NOT the issue (I assume the id is correct).
- Wookiee2 years agoExplorer | Level 4
Not quite there yet, but you have me on the right path, I think...
- iNeil2 years ago
Dropbox Community Moderator
Hello Wookiee,
The error "Unexpected HTTP headers: 'Dropbox-Api-Arg'" indicates that the HTTP request you sent includes a header that the server is not expecting or does not recognize, as mentioned by Здравко. For example, --header "Dropbox-API-Arg: {\"path\":\"id:m5ktIrz8BXoAAAAbAAAASg\"}".
Please note that the /2/files/upload and /2/files/delete_v2 endpoints have different formats when including parameters. The /2/files/upload endpoint uses the header "Dropbox-API-Arg," while the /2/files/delete_v2 endpoint uses the request body data. Below is an example of how to implement the /2/files/delete_v2 endpoint using the request body data via cURL.curl -X POST \ --header "Authorization: Bearer " \ --header "Content-Type: application/json" \ --data "{\"path\":\"id:m5ktIrz8BXoAAAAbAAAASg\"}" \ https://api.dropboxapi.com/2/files/delete_v2
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!