how could I react in my application (no matter which action is tried to be executed) on a 401 error code when application runs in a timeout in background?
in your Simplifier instance you can specify the lifetime of the user’s authentication token.
As soon as the token is expired the user will get a 401 error when he triggers any action where he needs to interact with the server. Hence, he is not authenticated anymore.
We created a Business Object (BO) which can help you to notify the user when his authentication is expired and tells him to reload the application.
You can find a detailed description how to use it and where to download the BO in the knowledge base article below: