MoveAuthState
MOVE Models
Last updated
MOVE Models
Last updated
Returns the current MOVE SDK Authentication State.
If the MoveAuthState is invalid the MOVE backend no longer accepts MOVE SDK requests from this host app.
MoveAuth is session-based, hence it expires and requires to be renewed. For simplicity, the MOVE SDK handles refreshing the token for the host app whenever it expires.
In case the MOVE SDK fails to refresh authentication, because of a conflicting login on another device, or because the user was blocked on the backend, it will trigger MoveAuthState.invalid
. The host app is expected to logout the user and callshutdown(force: true)
(Android / iOS).
The host app is responsible for monitoring MoveAuthState
updates and handling its state updates by:
.invalid
: The MOVE SDK has invalidated its internal user token at once. e.g. User has logged in on multiple devices. If necessary the host app has to register the user again (see register - MOVE Admin API).
MoveAuthState
expired(MoveAuth)
Latest MoveAuth expired and the MOVE SDK can't refresh it. Deprecated in SDK v2.6.7.
valid
Authentication is valid.
invalid
Authentication is invalid. e.g. User has logged in on multiple devices. New since SDK v2.4
unknown
MOVE SDK auth state is pending, and will be updated when the server is contacted. The app should ignore this state.
MoveAuthState related APIs
Block to be invoked every time MoveAuthState changes.