I’m trying to login using Facebook on my Android app, using:
Auth0 auth0 = new Auth0(getString(R.string.auth0_client_id), getString(R.string.auth0_domain));
WebAuthProvider.init(auth0)
.withConnection("facebook")
.start(LoginActivity.this, new AuthCallback() {
@Override
public void onFailure(@NonNull Dialog dialog) {
…
}
@Override
public void onFailure(AuthenticationException exception) {
…
}
@Override
public void onSuccess(@NonNull Credentials credentials) {
…
}
});
When running the app I’m prompted to login with Facebook, and after that, instead of returning to the app, I’m redirected to a page with the error: Cannot GET /android/[package-name]/callback?code=…]&state=…]
The [package-name] is the same that’s in the Android manifest.
I’m experiencing this issue, but at some point I managed to get my test application working. Could it be that they are both using the same client?. Wondering if there are best places to debug other than just the callback URLs in auth0 and android manifest.
Figured out my issue. At some point I said use my browser as the default app for my application in dev. This caused it to not handle the callback properly.