How do I authenticate in DropboxAPI v2 for Android?

前端 未结 2 533
生来不讨喜
生来不讨喜 2021-01-16 11:19

I\'ve just started out and I\'m following this tutorial

https://www.dropbox.com/developers/documentation/java#tutorial

But there\'s no login. Nothing asks yo

2条回答
  •  悲哀的现实
    2021-01-16 11:56

    To use the Dropbox API v2 in Android, you should use the API v2 Java SDK. There's an example Android app that uses it included with the SDK. You should refer to that as an example of how to implement the app authorization flow, which is accomplished via OAuth 2. That requires the user to authorize your app with Dropbox, by signing in to Dropbox if necessary. After that, your app can store and re-use the resulting access token for that user, as the example does here.

    Implementing it that way allows any user to connect their Dropbox account to your app. You can also handle multiple accounts per instance of your app if you want.

提交回复
热议问题