Auth.getOAuth2Token() returns null
See original GitHub issueI am using dropbox-sdk-java v2 for android. If I try to authenticate the flow from browser, I always get NULL. Issues related to this kind of question are #71 and #161 and they are already closed but none helpful.
My manifest looks like:
android:name="com.dropbox.core.android.AuthActivity"
android:configChanges="orientation|keyboard"
android:screenOrientation="portrait"
android:launchMode="singleTask"
<intent-filter>
<data android:scheme="db-XXXXXXXXXXXXX"/>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
Issue Analytics
- State:
- Created 4 years ago
- Comments:10 (5 by maintainers)
Top Results From Across the Web
Android: Auth.getOAuth2Token() always returns null #71
I think the reason getOAuth2Token() is returning null is because there is no Dropbox app installed on the device in question.
Read more >Where should I locate the 'startOAuth2Authentication'?
The getOAuth2Token method retrieves the access token, but only when the user is actually going through the app authorization flow. If they are...
Read more >How can the Dropbox API alert when a token is received?
The only problem is on first run when a token is requested and the Dropbox app/website is launched - I have to run...
Read more >com.dropbox.core.android.Auth.getOAuth2Token java code ...
public void completeAuth() { try { String authToken = Auth.getOAuth2Token(); if (startedAuth && authToken != null) { try { MyPreferences.
Read more >Auth (Official Dropbox Java SDK 4.0.1 API)
Constructor and Description. Auth() ... String, getOAuth2Token() ... official app (AKA DAuth) or web browser if dropbox official app is not available.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The problem is with Firefox Android Browser. later I tried the authorization process on Chrome Android browser and it worked perfectly. So if it worked for chrome then why not on firefox?
fully noted, and thanks