If you are embedding GoodData in your App, one of the task that you need do is align login sessions. What does it mean? Your user log in to your application and on the background he is also logged in to the GoodData via SSO. Perfect. What happens if you are active in your App window, but inactive in the GoodData embedded window? The session expired. You would need to refresh your GoodData TT Token.
Once you are logged in (see the How to set up SSO Tutorial), There are two main Use cases:
- Application keeps GD session alive all the time when there is an active window with my application with embedded GD
- When I log out from my application, I log out also from GD
App keeps GD Session alive
My application keeps GD session alive all the time when there is an active window with my application with embedded GD
Doing this, your application will be aware of the user activity inside the iFrame (embedded GoodData Analytics).
Login session expiration
Prior to release 100 a login session expired after 14 days (36 hours for Single Sign On) or with closing the browser window. Since release 100 the Organization administrator has better control over session expiration. Session expiration can be tight to user activity. The Organization administrator may choose the maximum user inactivity time after which login session expires.
Let’s say that the Organization Administrator decide to set the maximum inactivity time to 15 minutes. If a user doesn’t actively work with GoodData for 15 minutes its login session will expire and user will have to login again.
Please contact GoodData support to activate this feature. There will be special REST API resource for this in the future.
User Log Out
When I log out from my application, I log out also from GD.
You need to logout the current user from GoodData as during the logout from your Application. Use following API calls:
GET the currently logged in user URI:
Log out user by sending DELETE request to the following resource:
Read also general article about our Dashboard Events API.