enable_cloud_password()
- Client.enable_cloud_password()
Enable the Two-Step Verification security feature (Cloud Password) on your account.
This password will be asked when you log-in on a new device in addition to the SMS code.
Usable by Users Bots
- Parameters:
password (
str
) – Your password.hint (
str
, optional) – A password hint.email (
str
, optional) – Recovery e-mail.
- Returns:
bool
– True on success.- Raises:
ValueError – In case there is already a cloud password enabled.
Example
# Enable password without hint and email await app.enable_cloud_password("password") # Enable password with hint and without email await app.enable_cloud_password("password", hint="hint") # Enable password with hint and email await app.enable_cloud_password("password", hint="hint", email="user@email.com")