Layer 220
AccountSendVerifyEmailCode
Send an email verification code.
method
Users
account.sendVerifyEmailCode#98e037bb purpose:EmailVerifyPurpose email:string = account.SentEmailCode;
Parameters
| Name | Type | Description |
|---|---|---|
| Purpose | EmailVerifyPurpose | Verification purpose. |
| string | The email where to send the code. |
Returns
account.SentEmailCodePossible Errors
| Code | Type | Description |
|---|---|---|
| 400 | EMAIL_INVALID | The specified email is invalid. |
| 400 | EMAIL_NOT_ALLOWED | The specified email cannot be used to complete the operation. |
| 400 | EMAIL_NOT_SETUP | In order to change the login email with email Verify Purpose Login Change, an existing login email must already be set using email Verify Purpose Login Setup. |
| 400 | PHONE_HASH_EXPIRED | An invalid or expired phone_code_hash was provided. |
| 400 | PHONE_NUMBER_INVALID | The phone number is invalid. |
Gogram Example
// AccountSendVerifyEmailCode - positional arguments result, err := client.AccountSendVerifyEmailCode(&tg.EmailVerifyPurpose{}, "...") if err != nil { // handle error } // result is *tg.AccountSentEmailCode