Qiscus Sdk Android Versions Save

Qiscus provide everything you need to power up your app with chats. And it's now made simple.

1.6.3

1 year ago

Changelog :

  • Support enableJetifier = false

1.6.2

1 year ago

Changelog :

  • Improve library realtime, and remove permission SCHEDULE_EXACT_ALARM.

Note :

  • in this version you don't need to set permission SCHEDULE_EXACT_ALARM to support realtime, if you was set this permission, you can remove this permission from your code

1.6.1

1 year ago

Changelog :

  • Prevent crash when accessing lib jupukData in some device

1.6.0

1 year ago

Changelog :

  • New Flow expired token

implementation call API refresh token if the auto-refresh token is false from BE (by default is true), request contact us for setting auto-refresh false

for implementation manually calling the API refresh token, can use this code.

@Subscribe
    public void onRefreshToken(QiscusRefreshTokenEvent event) {
        if (event.isTokenExpired()) {
             if auto refresh token false from be, you need to call api refresh token manually
            //callRefreshToken();
        } else if (event.isUnauthorized()) {
            //need to force logout
            logoutUser();
        } else {
            // do somethings
        }
    }
    
 private void callRefreshToken() {
        QiscusCore.refreshToken(new QiscusCore.SetRefreshTokenListener() {
            @Override
            public void onSuccess(QiscusRefreshToken refreshToken) {
            
            }

            @Override
            public void onError(Throwable throwable) {
            
            }
        });
    }

    private void logoutUser() {
        if (QiscusCore.hasSetupUser()) {
            Qiscus.clearUser();
        }
    }

***Note :

  • Please contact us, if you want to implement the flow expired token and manually or automatic call the API refresh token

1.5.1

1 year ago

Changelog :

  • Try to Fix crash EncryptedSharedPreference

1.5.0

1 year ago

Changelog :

  • Support ExpiredToken

for example :

  • if you get error when call API qiscusCore with error code 403, please call api refreshToken
 QiscusAccount account = QiscusCore.getQiscusAccount();
        QiscusApi.getInstance().refreshToken(account.getEmail(), account.getRefreshToken())
                .subscribeOn(Schedulers.io())
                .observeOn(AndroidSchedulers.mainThread())
                .subscribe(QiscusCore::saveRefreshToken, throwable -> {
                    QiscusErrorLogger.print(throwable);
                });
 

1.4.4

1 year ago

Changelog :

  • Prevent crash android.permission.SCHEDULE_EXACT_ALARM set false from user

Note:

  • Please show the popup customer to enable SCHEDULE_EXACT_ALARM permission, because Qiscus Core SDK (Application) can't create a popup, only from activity can create the popup
  • If SCHEDULE_EXACT_ALARM permission is set to false, new messages will be delayed (only from sync and PN for realtime new messages)

for example to show popup :

AlarmManager alarmMgr = (AlarmManager) this.getSystemService(Context.ALARM_SERVICE);
        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
            if (!alarmMgr.canScheduleExactAlarms()) {

                AlertDialog.Builder alertBuilder = new AlertDialog.Builder(this);
                alertBuilder.setCancelable(true);
                alertBuilder.setTitle("Permission necessary");
                alertBuilder.setMessage("Schedule Exact Alarm permission is necessary for realtime");
                alertBuilder.setPositiveButton(android.R.string.yes, (dialog, which) -> {
                    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S) {
                        Intent intent = new Intent(
                                ACTION_REQUEST_SCHEDULE_EXACT_ALARM,
                                Uri.parse("package:" + this.getPackageName())
                        );

                        intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
                        this.getApplicationContext().startActivity(intent);
                    }
                });

                AlertDialog alert = alertBuilder.create();
                alert.show();

            }
        }

1.4.3

1 year ago
  • Migration lib JCenter

1.4.2

1 year ago
  • Prevent qiscusComment time is null when save to DB

1.4.1

1 year ago

Improve appConfig Sync and SyncEvent