Looks like there have been no responses for quite a while.
I have created an Android DocumentsProvider supporting the Storage Access Framework that supports DropBox. After having read through the three links posted above, the one question I can't get answered is whether it is considered OK to programmatically (and within the TOS) do the following:
1. Get a token for accessing a user's public folder (this appears to be ok, no credentials being stored by the app)
2. Utilize the token in the API to access a file (this appears to be ok)
3. Utilize the token in the API to generate a publicly shareable link to the file
4. Use the link generated to then have the app stream the file directly from DropBox to the app
Note that all of this is only possible when the user authenticates using the DropBox mechanism for authentication (i.e. outside the app), and then utilizes the resulting token.
Is that flow 1-4 considered ok for an app to perform?
I'm asking because while I have written a custom DocumentsProvider for DropBox, what I want to do is use it to allow the user to choose a file from their personal dropbox, then persist the direct shareable http link into a local DB for use in streaming the content from DropBox at a later date by the app. I want the streaming to be handled by components OTHER THAN the custom DocumentsProvider that are included in the app (i.e. Glide for images, ExoPlayer for video, etc.).
Essentially - I want to use the custom DocumentsProvider to allow the user to locate the file, then I want the other components in charge of streaming it down (which they do a great job of - no need for me to reinvent the wheel).
Is such use of the DropBox API:
1. Create Shareable Link
2. Pass link to Glide and/or ExoPlayer
Supported by the terms of service?
@tfrysinger We can't provide any absolute guarantee of compliance based on a description like this, so you should be sure to review all the guidelines and terms before developing code to use the Dropbox API:
Apps are reviewed for compliance during their production review.
That said, it sounds like you're just using the official API and are not attempting to mislead users, so I wouldn't expect any issues.
As far as I understood, Dropbox doesn't support
So, what's the official way to use files from Dropbox while on Android? A custom picker UI + the official SDK?
Dropbox doesn't supply their own DocumentsProvider implementation that integrates with the SAF, but they do have a plethora of APIs to use if you want to roll your own. That's what I did.
My DocumentsProvider uses those APIs to implement the methods that the SAF calls. I based it off of an article Ian Lake wrote some time ago, located here: https://medium.com/androiddevelopers/building-a-documentsprovider-f7f2fb38e86a. There are some tricky parts to this (correctly implementing threading to deal with directories that have lots of entries, getting media metadata in a performant manner, etc.), but you can search StackOverflow for posts from me and see how I solved many of them.
Have a question? Our Dropbox Community is here to help you find an answer!
You won’t have to wait too long for a reply, but why not learn more about the Community while you’re here.
Not the right discussion for you? Find out what else our Community has to say about API Support.
Or, search our Help Center for even more.