MadelineProto/docs/TD_docs/constructors/authStateWaitCode.md

48 lines
1.4 KiB
Markdown
Raw Normal View History

---
title: authStateWaitCode
description: TDLib needs user authentication code to finish authorization
---
## Constructor: authStateWaitCode
[Back to constructors index](index.md)
TDLib needs user authentication code to finish authorization
### Attributes:
| Name | Type | Required | Description |
|----------|:-------------:|:--------:|------------:|
|is\_registered|[Bool](../types/Bool.md) | Yes|True, if user is already registered|
|code\_type|[AuthCodeType](../types/AuthCodeType.md) | Yes|Describes the way, code was sent to the user|
|next\_code\_type|[AuthCodeType](../types/AuthCodeType.md) | Yes|Describes the way, next code will be sent to the user, nullable|
|timeout|[int](../types/int.md) | Yes|Timeout in seconds before code should be resent by calling resendAuthCode|
### Type: [AuthState](../types/AuthState.md)
### Example:
```
2017-07-23 16:33:46 +02:00
$authStateWaitCode = ['_' => 'authStateWaitCode', 'is_registered' => Bool, 'code_type' => AuthCodeType, 'next_code_type' => AuthCodeType, 'timeout' => int];
```
2017-07-23 16:11:02 +02:00
[PWRTelegram](https://pwrtelegram.xyz) json-encoded version:
```
2017-07-23 16:33:46 +02:00
{"_": "authStateWaitCode", "is_registered": Bool, "code_type": AuthCodeType, "next_code_type": AuthCodeType, "timeout": int}
2017-07-23 16:11:02 +02:00
```
Or, if you're into Lua:
```
2017-07-23 16:33:46 +02:00
authStateWaitCode={_='authStateWaitCode', is_registered=Bool, code_type=AuthCodeType, next_code_type=AuthCodeType, timeout=int}
```