Learn how to make the most out of the Dropbox Community here 💙.
Learn how to make the most out of the Dropbox Community here 💙.
Hi Greg-DB
Hey I really appreciate the effort you and the team have put in.
What I found was:
1. Yes, curl works with the url - I switched from Mac to Windows and curl worked. Bash both times.
2. Fiddler also works with the URL.
3. My published code fails using automatic redirect. It works for you - the difference may be that I'm using Microsoft Xamarin on Mac.
4. In the second redirect, Dropbox proposes https://uc012d2e25383f12de25c9db8029.dl.dropboxusercontent.com/cd/0/get/B-Dfp2veRgmAiBVuB2GBdOb2SPrjBQh9t0CkeebfBm8SdzO4_8rntEJaHCvdDqpc6-v3DZF5AGyupcRw9SOyfq8l_wlZmj63OWNOQpPgmBUcisawx6C0OptaJHDM9IoDPKvPtxaegRX8av8D36sJb1hcObvW7harZlcWcGjIqXz0aw/file?dl=1# -- which strictly speaking is not a valid url because of the trailing #.
5. I solved the problem by handling the redirects myself and url-encoding the #.
So, Xamarin could do better. But also, Dropbox really should not be sending invalid urls. 🙂
Code below fyi.
Cheers
Bill
----------------------
----------------------
----------------------
HairyWombat The "zsh: no matches found" error you're getting is because the URL contains the "?" character which has a special meaning in that shell. To avoid that, quote the URL, like this:
curl -L "https://www.dropbox.com/s/fzv989hz5mazhqw/ReplacementDatabase.dbf?dl=1" > Test1.dbf
I also put together your C# code and tried downloading the file from the shared link with that, and I did successfully get the expected 687752 bytes of the file back.
If you're getting back that HTML 400 error page, that may indicate that the HTTP request was malformed, causing the Dropbox servers to be unable to understand the request. Is there anything on your .NET environment or your network connection itself, such as a proxy, VPN, firewall, etc., that may be interfering with or modifying these requests?
Hi Greg-DB
Hey I really appreciate the effort you and the team have put in.
What I found was:
1. Yes, curl works with the url - I switched from Mac to Windows and curl worked. Bash both times.
2. Fiddler also works with the URL.
3. My published code fails using automatic redirect. It works for you - the difference may be that I'm using Microsoft Xamarin on Mac.
4. In the second redirect, Dropbox proposes https://uc012d2e25383f12de25c9db8029.dl.dropboxusercontent.com/cd/0/get/B-Dfp2veRgmAiBVuB2GBdOb2SPrjBQh9t0CkeebfBm8SdzO4_8rntEJaHCvdDqpc6-v3DZF5AGyupcRw9SOyfq8l_wlZmj63OWNOQpPgmBUcisawx6C0OptaJHDM9IoDPKvPtxaegRX8av8D36sJb1hcObvW7harZlcWcGjIqXz0aw/file?dl=1# -- which strictly speaking is not a valid url because of the trailing #.
5. I solved the problem by handling the redirects myself and url-encoding the #.
So, Xamarin could do better. But also, Dropbox really should not be sending invalid urls. 🙂
Code below fyi.
Cheers
Bill
----------------------
----------------------
----------------------
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 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!