Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
A few years ago I used the HTTP API to generate email links to folders. It suddenly stopped working and I discovered that there is a new API and the old one has been deprecated. I had not heard about the change until now. At any rate simple request I have been using looks like:
"https://api.dropbox.com/1/shares/dropbox/myFolder" & "?access_token=<REDACTED>"
Instead of returning a link, I get an error message of "
{"error": {"path": "The root path (\"/\") is not allowed."}}"
Would someone please tell me how to change the request to work with the new API? I'm under a time crunch and I'm not sure where to start. Thanks in advance.
@jonro API v1 was deprecated last year, and is no longer supported and is being retired very soon. I'm sorry to hear this caught you by surprise. We sent out emails notifying developers, but unfortunately it sounds like those didn't make it to you.
For reference though, /1/shares should still be working for now, and shouldn't have changed recently. I just tried a request like what you posted, and it worked for me. Based on the error message, it looks like your actual code isn't passing in the folder/file name (in your example, "myFolder"). If you want to get that working again for now, you should check why that value isn't getting filled (or is itself empty).
In any case, you will need migrate to API v2. The API v2 equivalent of /1/shares is /2/sharing/create_shared_link_with_settings to create a new shared link, or /2/sharing/list_shared_links (with direct_only=true) to retrieve an existing shared link. There are curl examples for each of those that show how to make the HTTP request.
Hi there!
If you need more help you can view your support options (expected response time for a 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!