Dōrvis

Sign in

Logging out

To end the Dorvis session as well, redirect the user to the logout endpoint with the ID token and the URL to return to.

Logout request

HTTPGET
https://dorvis.eu/oidc/oauth2/sessions/logout
  ?id_token_hint=eyJhbGciOiJSUzI1NiIs…
  &post_logout_redirect_uri=https%3A%2F%2Fexample.lv%2F
  &state=c81d2e…
ParameterMeaning
id_token_hintThe ID token you received at login
post_logout_redirect_uriWhere to send the user back, it must be registered in the portal
stateOptional value that comes back with the user

Express example

JavaScriptapp.js
app.get('/logout', (req, res, next) => {
  const idToken = req.session.idToken;
  req.logout((err) => {
    if (err) return next(err);
    const url = new URL('https://dorvis.eu/oidc/oauth2/sessions/logout');
    url.searchParams.set('id_token_hint', idToken);
    url.searchParams.set('post_logout_redirect_uri', 'https://example.lv/');
    res.redirect(url.toString());
  });
});

What happens to the methods

Dorvis ends its own session, so users must confirm their identity again at the next login. This does not affect their online banking session or the Smart-ID app.

Did not find the answer?

Write to us and a developer will reply.

Ask a question
Loading complete

We use cookies to make this website easier to use. Read our Privacy and Cookie Policy.