Support Topics Documentation Slack YouTube Blog

User token failure

Hi. Why do I get this error every time I run the app and have to log in again?

Not existing user token - AA809AE0-8C4D-4AA3-AB90-AA7A3280FE32. Relogin user to update your user token

This will happen when you make an API call with an expired user-token.

But once I log in, if I open the app again two minutes later, it will give this error.
Should the token be disabled each time you open the app?

I open and close the app three times and I get this error in logcat:

2021-04-07 21:12:46.379 303-303/? E/StoresRemote$fetchAll: error is:  Not existing user token - 
3FD2F31B-17F9-45AA-9982-E7F4DFA2862A. Relogin user to update your user token

2021-04-07 21:13:03.598 771-771/? E/StoresRemote$fetchAll: error is:  Not existing user token - 
73F7346B-1150-4ABB-9685-7F5F4A457895. Relogin user to update your user token

2021-04-07 21:13:17.276 771-771/? E/StoresRemote$fetchAll: error is:  Not existing user token - 
A64A0840-3DF2-4825-BD1C-F8F76539F20E. Relogin user to update your user token

Do you use the stayLoggedIn argument in the login API?

yes, i set true for this.

  Backendless.UserService.login(mobile, mobile, object : AsyncCallback<BackendlessUser> {
        override fun handleResponse(user: BackendlessUser) {
            loginState.value = Const.LOGIN_SUCCESS
        }

        override fun handleFault(fault: BackendlessFault) {
            loginState.value = Const.LOGIN_ERROR
        }
    }, true)

What version of Backendless SDK for Android do you use?

5.3.1

Please make sure to upgrade to the latest version: