cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
Want to learn some quick and useful tips to make your day easier? Check out how Calvin uses Replay to get feedback from other teams at Dropbox here.

Dropbox API Support & Feedback

Find help with the Dropbox API from other developers.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Andriod App to Only use short tokens

Andriod App to Only use short tokens

raymondc
New member | Level 2
Go to solution

Hello,

 

All this is quite new to me but I've read many post regarding new workflow. Thus, sorry if what I am saying makes no sense.

 

I've read that using startOAuth2PKCE uses the new flow. However, this uses refresh tokens as well. What happens if I just want to use short lived tokens and ask the user to re-authenticate when the short lived tokens expires. Is there another function to use for that purpose?

1 Accepted Solution

Accepted Solutions

Greg-DB
Dropbox Staff
Go to solution

No, the authorization functionality for Android in the Java SDK automatically requests "offline" access (i.e., to retrieve a refresh token), and doesn't offer the ability to configure that. I'll pass this along as a feature request, but I can't promise if or when that might be implemented.

 

(For reference, the DbxWebAuth functionality does offer the ability to specify the token type, but that's not meant or built for use on Android.)

View solution in original post

4 Replies 4

Greg-DB
Dropbox Staff
Go to solution

No, the authorization functionality for Android in the Java SDK automatically requests "offline" access (i.e., to retrieve a refresh token), and doesn't offer the ability to configure that. I'll pass this along as a feature request, but I can't promise if or when that might be implemented.

 

(For reference, the DbxWebAuth functionality does offer the ability to specify the token type, but that's not meant or built for use on Android.)

raymondc
New member | Level 2
Go to solution

Thank you for the quick reply.

 

One more question.

 

If I use this version of startOAuth2PKCE with scope set to null

public static void startOAuth2PKCE(Context context, String appKey,
DbxRequestConfig requestConfig) {

Would this gives all permissions to do anything in dropbox(upload, download,...)?

 

 

Greg-DB
Dropbox Staff
Go to solution

If you don't specify "scope", it will default to requesting the set of scopes enabled for your app (on the App Console) at the time of authorization.

raymondc
New member | Level 2
Go to solution

Thanks for the clarifications.

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    raymondc New member | Level 2
  • User avatar
    Greg-DB Dropbox Staff
What do Dropbox user levels mean?