Zum Inhalt springen

login

Authenticates a user with username and password. Returns a JWT token and supports optional OTP and custom session lifetime.

Type: LoginResult!

Arguments

  • lifetime: Float! — default: 1440 — Minutes after the authentication token expires. Default 24 hours. Can not be greater than the setting “System.Auth.Providers.SwissMentor.sessionDurationMaxHours”.
  • otpToken: String — OTP (One Time Token) from authenticator app
  • password: String! — Password for authentication.
  • username: String! — Username of the user.
mutation($lifetime: Float!, $otpToken: String, $password: String!, $username: String!) {
login(lifetime: $lifetime, otpToken: $otpToken, password: $password, username: $username) {
authenticationToken
jwtToken
roSessionID
}
}