Jump to: navigation, search

Automatic logout

The iWD Manager server session expires after a time period set up in the configuration. Every http request sent to API resets the session expiration timer.

Method

  • GET
  • POST

Syntax

There is a special request just to keep the session alive:

GET /api/session/idle

Response

Result:

HTTP 204 No content

There is also another API request to automatic logout:

POST /api/session/autologout

Result:

HTTP 302 Found

Notes

  • The Location header redirects to the login page (with reason=sessionExpired).
  • The difference between automatic and the normal logout requests is in a logout reason responding back to the front-end. The automatic logout request redirects to the login screen with the reason "session expired" and the normal logout - with "logged out successfully".
  • In every response a special cookie "SESSIONLIFETIME=<timestamp>_<lifetime>" is applied where the front-end is able to find necessary information to use the automatic logout and keeping alive mechanism.

Feedback

Comment on this article:

blog comments powered by Disqus
This page was last modified on December 19, 2017, at 03:03.