5

I have been doing some research, and for the life of me, I cannot find any documentation on how to use the android dropbox SDK. I have authenticated the user, but now I cannot figure out how the get the metadata (file entries) of a folder. I have looked at the Web docs, but the arguments in java are turned around, flipped over, and then some.

In objective-c, the methods are straight forward, and I understand what is going on. Must I port the code from objective-c to java?

Mogsdad
  • 44,709
  • 21
  • 151
  • 275
Richard J. Ross III
  • 55,009
  • 24
  • 135
  • 201
  • 1
    Looks like Android Dropbox SDK documentation has been added now. One can see the 'Tutorial' and 'Docs' for Android (and other platforms) [here](https://www.dropbox.com/developers/reference/sdk). – Atul Goyal Feb 18 '12 at 10:26
  • @AtulGoyal Haha, finally, took them what, 9 months? Anyways, I don't need it anymore, I have ditched the project I was working on for other reasons. – Richard J. Ross III Feb 18 '12 at 14:10

3 Answers3

2

As far as I can tell as of Sep 20, 2011, Dropbox still hasn't put the Android SDK documentation. Here are some workarounds:

[EDIT by anotheranon user] My friend stumbled upon this official documentation from Dropbox. Don't even know how he found it. Since this thread is also where I gave up I would like to share!

Community
  • 1
  • 1
U Avalos
  • 6,538
  • 7
  • 48
  • 81
0

You should be to find your answer here: https://www.dropbox.com/developers. Looks like the SDK is undocumented.

Try making the calls to the API directly.

  • I meant the sdk, sorry. That is not what I was looking for. I have ditched that project because of it, I really dont like calling web API's directly from code – Richard J. Ross III Jun 10 '11 at 14:04
0

In the SDK (DropboxSample), this will list the files in the Public folder of the user account:

In DropboxSample.java add:

public void displayFiles(DropboxAPI.Account account) {
        if (account != null) {
            DropboxAPI.Entry dbe = api.metadata("dropbox", "/Public", 10000, null, true);
            List<Entry> contents = dbe.contents;
            if (contents != null) {
            for (Entry ent:contents) {
                Toast.makeText(this, ent.fileName(), Toast.LENGTH_SHORT).show();
            }
            }
    }
    }

In LoginAsyncTask.java add:

mDropboxSample.displayFiles(mAccount);

below mDropboxSample.displayAccountInfo(mAccount);

Giulio Prisco
  • 941
  • 9
  • 16