User.reset_totp_key - REST API


Changes a user's TOTP key and its accompanying label. If key is not given on input, one is generated and returned on output.

Regular users may change their own keys only. Super-users may change any other user's keys.

  • HTTP method: PATCH
  • URL path: /zato/sso/user/totp


uststring---Current user's session token (UST)
current_appstring---Name of application that the call is attempted from
user_idstringYesID of a user to change the key of. May be provided only if input ust belongs to a super-user.
totp_keystringYesUser's TOTP key, one will be auto-generated for user if it is not given on input, even if is_totp_enabled is False
totp_labelstringYesAn arbitrary label assigned to user's TOTP key for convenience


cidstring---Correlation ID assigned to request
statusstring---Overall status code
sub_statuslistYesReturned only if status is not "ok", a list of error or warning codes
totp_keystringYesIf there was no key given on input and one was generated, this is its value


$ curl -XPATCH localhost:17010/zato/sso/user -d '
    "ust":        "gAAAAABalYT1hsvrBVcr...",
    "user_id":    "zusrx2efj1q1h98n9q00tgx8scefv",
    "totp_key":   "G7WSZQ3JKCM6D",
    "totp_label": "My SSO key"

    "cid": "de00deb0471188dcdd9913a8",
    "status": "ok"