Example #1
0
  public boolean FinishAuthorization() {
    AndroidAuthSession session = dropboxApi.getSession();
    if (!session.isLinked() && session.authenticationSuccessful()) {
      // Mandatory call to complete the auth
      session.finishAuthentication();

      // Store it locally in our app for later use
      TokenPair tokens = session.getAccessTokenPair();
      storeKeys(tokens.key, tokens.secret);
      return true;
    }

    return false;
  }