You might see that the Dropbox Community team have been busy working on some major updates to the Community itself! So, here is some info on what’s changed, what’s staying the same and what you can expect from the Dropbox Community overall.

Forum Discussion

OPunktSchmidt's avatar
OPunktSchmidt
Explorer | Level 3
4 years ago

Java SDK - No refresh token?

Hey,

 

i try to get the refresh token with the Java SDK (Android App).

 

I start authentication with this:

 

Auth.startOAuth2Authentication(getContext(), "abc");

And then in onResume:

 

@Override
public void onResume() {
super.onResume();

if (_isCloudAuthFlow) {

_isCloudAuthFlow = false;

String token = Auth.getOAuth2Token();
String refresh = Auth.getDbxCredential().getRefreshToken();
_businessLogic.getSharedPreferences().edit().putString(getString(R.string.all_settings_dropbox_authtoken), token).apply();
}
}

 I get a authToken but the refresh token is always null.

 

Can you help?

About Dropbox API Support & Feedback

Node avatar for Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

5,895 PostsLatest Activity: 12 days ago
328 Following

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!