Skip to content

setPassword

Function · TDLib 1.8.67 · d1085f9c

Changes the 2-step verification password for the current user. If a new recovery email address is specified, then the change will not be applied until the new recovery email address is confirmed

setPassword(
  old_password: string,
  new_password: string,
  new_hint: string,
  set_recovery_email_address: Bool,
  new_recovery_email_address: string
) → PasswordState

old_password

string

Previous 2-step verification password of the user

new_password

string

New 2-step verification password of the user; may be empty to remove the password

new_hint

string

New password hint; may be empty

set_recovery_email_address

Bool

Pass true to change also the recovery email address

new_recovery_email_address

string

New recovery email address; may be empty