Update docs

This commit is contained in:
Daniil Gentili 2020-03-06 13:09:28 +01:00
parent 75d0676136
commit 1e1967391f
Signed by: danog
GPG Key ID: 8C1BE3B34B230CA7
41 changed files with 573 additions and 18 deletions

View File

@ -0,0 +1,40 @@
---
title: accessPointRule
description: Access point rule
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Constructor: accessPointRule
[Back to constructors index](index.md)
Access point rule
### Attributes:
| Name | Type | Required | Description |
|----------|---------------|----------|-------------|
|phone\_prefix\_rules|[string](../types/string.md) | Yes|Phone prefix rules|
|dc\_id|[int](../types/int.md) | Yes|DC ID|
|ips|Array of [IpPort](../types/IpPort.md) | Yes|Ips|
### Type: [AccessPointRule](../types/AccessPointRule.md)
### Example:
```php
$accessPointRule = ['_' => 'accessPointRule', 'phone_prefix_rules' => 'string', 'dc_id' => int, 'ips' => [IpPort, IpPort]];
```
Or, if you're into Lua:
```lua
accessPointRule={_='accessPointRule', phone_prefix_rules='string', dc_id=int, ips={IpPort}}
```

View File

@ -0,0 +1,37 @@
---
title: bankCardOpenUrl
description: bankCardOpenUrl attributes, type and example
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Constructor: bankCardOpenUrl
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|---------------|----------|
|url|[string](../types/string.md) | Yes|
|name|[string](../types/string.md) | Yes|
### Type: [BankCardOpenUrl](../types/BankCardOpenUrl.md)
### Example:
```php
$bankCardOpenUrl = ['_' => 'bankCardOpenUrl', 'url' => 'string', 'name' => 'string'];
```
Or, if you're into Lua:
```lua
bankCardOpenUrl={_='bankCardOpenUrl', url='string', name='string'}
```

View File

@ -0,0 +1,41 @@
---
title: help.configSimple
description: Config simple
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
redirect_from: /API_docs/constructors/help_configSimple.html
---
# Constructor: help.configSimple
[Back to constructors index](index.md)
Config simple
### Attributes:
| Name | Type | Required | Description |
|----------|---------------|----------|-------------|
|date|[int](../types/int.md) | Yes|Date|
|expires|[int](../types/int.md) | Yes|Expires|
|rules|Array of [AccessPointRule](../types/AccessPointRule.md) | Yes|Rules|
### Type: [help.ConfigSimple](../types/help.ConfigSimple.md)
### Example:
```php
$help.configSimple = ['_' => 'help.configSimple', 'date' => int, 'expires' => int, 'rules' => [AccessPointRule, AccessPointRule]];
```
Or, if you're into Lua:
```lua
help.configSimple={_='help.configSimple', date=int, expires=int, rules={AccessPointRule}}
```

View File

@ -6,6 +6,9 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
# Constructors # Constructors
[Back to API documentation index](..) [Back to API documentation index](..)
***
<br><br>[$accessPointRule](../constructors/accessPointRule.md) = \['phone_prefix_rules' => [string](../types/string.md), 'dc_id' => [int](../types/int.md), 'ips' => \[[IpPort](../types/IpPort.md)\], \];<a name="accessPointRule"></a>
*** ***
<br><br>[$account.authorizationForm](../constructors/account.authorizationForm.md) = \['required_types' => \[[SecureRequiredType](../types/SecureRequiredType.md)\], 'values' => \[[SecureValue](../types/SecureValue.md)\], 'errors' => \[[SecureValueError](../types/SecureValueError.md)\], 'users' => \[[User](../types/User.md)\], 'privacy_policy_url' => [string](../types/string.md), \];<a name="account.authorizationForm"></a> <br><br>[$account.authorizationForm](../constructors/account.authorizationForm.md) = \['required_types' => \[[SecureRequiredType](../types/SecureRequiredType.md)\], 'values' => \[[SecureValue](../types/SecureValue.md)\], 'errors' => \[[SecureValueError](../types/SecureValueError.md)\], 'users' => \[[User](../types/User.md)\], 'privacy_policy_url' => [string](../types/string.md), \];<a name="account.authorizationForm"></a>
@ -108,6 +111,9 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$autoDownloadSettings](../constructors/autoDownloadSettings.md) = \['disabled' => [Bool](../types/Bool.md), 'video_preload_large' => [Bool](../types/Bool.md), 'audio_preload_next' => [Bool](../types/Bool.md), 'phonecalls_less_data' => [Bool](../types/Bool.md), 'photo_size_max' => [int](../types/int.md), 'video_size_max' => [int](../types/int.md), 'file_size_max' => [int](../types/int.md), 'video_upload_maxbitrate' => [int](../types/int.md), \];<a name="autoDownloadSettings"></a> <br><br>[$autoDownloadSettings](../constructors/autoDownloadSettings.md) = \['disabled' => [Bool](../types/Bool.md), 'video_preload_large' => [Bool](../types/Bool.md), 'audio_preload_next' => [Bool](../types/Bool.md), 'phonecalls_less_data' => [Bool](../types/Bool.md), 'photo_size_max' => [int](../types/int.md), 'video_size_max' => [int](../types/int.md), 'file_size_max' => [int](../types/int.md), 'video_upload_maxbitrate' => [int](../types/int.md), \];<a name="autoDownloadSettings"></a>
***
<br><br>[$bankCardOpenUrl](../constructors/bankCardOpenUrl.md) = \['url' => [string](../types/string.md), 'name' => [string](../types/string.md), \];<a name="bankCardOpenUrl"></a>
*** ***
<br><br>[$baseThemeArctic](../constructors/baseThemeArctic.md) = \[\];<a name="baseThemeArctic"></a> <br><br>[$baseThemeArctic](../constructors/baseThemeArctic.md) = \[\];<a name="baseThemeArctic"></a>
@ -615,6 +621,9 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$help.appUpdate](../constructors/help.appUpdate.md) = \['can_not_skip' => [Bool](../types/Bool.md), 'id' => [int](../types/int.md), 'version' => [string](../types/string.md), 'text' => [string](../types/string.md), 'entities' => \[[MessageEntity](../types/MessageEntity.md)\], 'document' => [Document](../types/Document.md), 'url' => [string](../types/string.md), \];<a name="help.appUpdate"></a> <br><br>[$help.appUpdate](../constructors/help.appUpdate.md) = \['can_not_skip' => [Bool](../types/Bool.md), 'id' => [int](../types/int.md), 'version' => [string](../types/string.md), 'text' => [string](../types/string.md), 'entities' => \[[MessageEntity](../types/MessageEntity.md)\], 'document' => [Document](../types/Document.md), 'url' => [string](../types/string.md), \];<a name="help.appUpdate"></a>
***
<br><br>[$help.configSimple](../constructors/help.configSimple.md) = \['date' => [int](../types/int.md), 'expires' => [int](../types/int.md), 'rules' => \[[AccessPointRule](../types/AccessPointRule.md)\], \];<a name="help.configSimple"></a>
*** ***
<br><br>[$help.deepLinkInfo](../constructors/help.deepLinkInfo.md) = \['update_app' => [Bool](../types/Bool.md), 'message' => [string](../types/string.md), 'entities' => \[[MessageEntity](../types/MessageEntity.md)\], \];<a name="help.deepLinkInfo"></a> <br><br>[$help.deepLinkInfo](../constructors/help.deepLinkInfo.md) = \['update_app' => [Bool](../types/Bool.md), 'message' => [string](../types/string.md), 'entities' => \[[MessageEntity](../types/MessageEntity.md)\], \];<a name="help.deepLinkInfo"></a>
@ -1122,6 +1131,12 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$invoice](../constructors/invoice.md) = \['test' => [Bool](../types/Bool.md), 'name_requested' => [Bool](../types/Bool.md), 'phone_requested' => [Bool](../types/Bool.md), 'email_requested' => [Bool](../types/Bool.md), 'shipping_address_requested' => [Bool](../types/Bool.md), 'flexible' => [Bool](../types/Bool.md), 'phone_to_provider' => [Bool](../types/Bool.md), 'email_to_provider' => [Bool](../types/Bool.md), 'currency' => [string](../types/string.md), 'prices' => \[[LabeledPrice](../types/LabeledPrice.md)\], \];<a name="invoice"></a> <br><br>[$invoice](../constructors/invoice.md) = \['test' => [Bool](../types/Bool.md), 'name_requested' => [Bool](../types/Bool.md), 'phone_requested' => [Bool](../types/Bool.md), 'email_requested' => [Bool](../types/Bool.md), 'shipping_address_requested' => [Bool](../types/Bool.md), 'flexible' => [Bool](../types/Bool.md), 'phone_to_provider' => [Bool](../types/Bool.md), 'email_to_provider' => [Bool](../types/Bool.md), 'currency' => [string](../types/string.md), 'prices' => \[[LabeledPrice](../types/LabeledPrice.md)\], \];<a name="invoice"></a>
***
<br><br>[$ipPort](../constructors/ipPort.md) = \['ipv4' => [int](../types/int.md), 'port' => [int](../types/int.md), \];<a name="ipPort"></a>
***
<br><br>[$ipPortSecret](../constructors/ipPortSecret.md) = \['ipv4' => [int](../types/int.md), 'port' => [int](../types/int.md), 'secret' => [bytes](../types/bytes.md), \];<a name="ipPortSecret"></a>
*** ***
<br><br>[$jsonArray](../constructors/jsonArray.md) = \['value' => \[[JSONValue](../types/JSONValue.md)\], \];<a name="jsonArray"></a> <br><br>[$jsonArray](../constructors/jsonArray.md) = \['value' => \[[JSONValue](../types/JSONValue.md)\], \];<a name="jsonArray"></a>
@ -1272,6 +1287,9 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$messageEmpty](../constructors/messageEmpty.md) = \['id' => [int](../types/int.md), \];<a name="messageEmpty"></a> <br><br>[$messageEmpty](../constructors/messageEmpty.md) = \['id' => [int](../types/int.md), \];<a name="messageEmpty"></a>
***
<br><br>[$messageEntityBankCard](../constructors/messageEntityBankCard.md) = \['offset' => [int](../types/int.md), 'length' => [int](../types/int.md), \];<a name="messageEntityBankCard"></a>
*** ***
<br><br>[$messageEntityBlockquote](../constructors/messageEntityBlockquote.md) = \['offset' => [int](../types/int.md), 'length' => [int](../types/int.md), \];<a name="messageEntityBlockquote"></a> <br><br>[$messageEntityBlockquote](../constructors/messageEntityBlockquote.md) = \['offset' => [int](../types/int.md), 'length' => [int](../types/int.md), \];<a name="messageEntityBlockquote"></a>
@ -1521,9 +1539,6 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$notifyUsers](../constructors/notifyUsers.md) = \[\];<a name="notifyUsers"></a> <br><br>[$notifyUsers](../constructors/notifyUsers.md) = \[\];<a name="notifyUsers"></a>
***
<br><br>[$null](../constructors/null.md) = \[\];<a name="null"></a>
*** ***
<br><br>[$page](../constructors/page.md) = \['part' => [Bool](../types/Bool.md), 'rtl' => [Bool](../types/Bool.md), 'v2' => [Bool](../types/Bool.md), 'url' => [string](../types/string.md), 'blocks' => \[[PageBlock](../types/PageBlock.md)\], 'photos' => \[[Photo](../types/Photo.md)\], 'documents' => \[[Document](../types/Document.md)\], \];<a name="page"></a> <br><br>[$page](../constructors/page.md) = \['part' => [Bool](../types/Bool.md), 'rtl' => [Bool](../types/Bool.md), 'v2' => [Bool](../types/Bool.md), 'url' => [string](../types/string.md), 'blocks' => \[[PageBlock](../types/PageBlock.md)\], 'photos' => \[[Photo](../types/Photo.md)\], 'documents' => \[[Document](../types/Document.md)\], \];<a name="page"></a>
@ -1653,6 +1668,9 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$paymentSavedCredentialsCard](../constructors/paymentSavedCredentialsCard.md) = \['id' => [string](../types/string.md), 'title' => [string](../types/string.md), \];<a name="paymentSavedCredentialsCard"></a> <br><br>[$paymentSavedCredentialsCard](../constructors/paymentSavedCredentialsCard.md) = \['id' => [string](../types/string.md), 'title' => [string](../types/string.md), \];<a name="paymentSavedCredentialsCard"></a>
***
<br><br>[$payments.bankCardData](../constructors/payments.bankCardData.md) = \['title' => [string](../types/string.md), 'open_urls' => \[[BankCardOpenUrl](../types/BankCardOpenUrl.md)\], \];<a name="payments.bankCardData"></a>
*** ***
<br><br>[$payments.paymentForm](../constructors/payments.paymentForm.md) = \['can_save_credentials' => [Bool](../types/Bool.md), 'password_missing' => [Bool](../types/Bool.md), 'bot_id' => [int](../types/int.md), 'invoice' => [Invoice](../types/Invoice.md), 'provider_id' => [int](../types/int.md), 'url' => [string](../types/string.md), 'native_provider' => [string](../types/string.md), 'native_params' => [DataJSON](../types/DataJSON.md), 'saved_info' => [PaymentRequestedInfo](../types/PaymentRequestedInfo.md), 'saved_credentials' => [PaymentSavedCredentials](../types/PaymentSavedCredentials.md), 'users' => \[[User](../types/User.md)\], \];<a name="payments.paymentForm"></a> <br><br>[$payments.paymentForm](../constructors/payments.paymentForm.md) = \['can_save_credentials' => [Bool](../types/Bool.md), 'password_missing' => [Bool](../types/Bool.md), 'bot_id' => [int](../types/int.md), 'invoice' => [Invoice](../types/Invoice.md), 'provider_id' => [int](../types/int.md), 'url' => [string](../types/string.md), 'native_provider' => [string](../types/string.md), 'native_params' => [DataJSON](../types/DataJSON.md), 'saved_info' => [PaymentRequestedInfo](../types/PaymentRequestedInfo.md), 'saved_credentials' => [PaymentSavedCredentials](../types/PaymentSavedCredentials.md), 'users' => \[[User](../types/User.md)\], \];<a name="payments.paymentForm"></a>
@ -1683,6 +1701,9 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
*** ***
<br><br>[$peerNotifySettings](../constructors/peerNotifySettings.md) = \['show_previews' => [Bool](../types/Bool.md), 'silent' => [Bool](../types/Bool.md), 'mute_until' => [int](../types/int.md), 'sound' => [string](../types/string.md), \];<a name="peerNotifySettings"></a> <br><br>[$peerNotifySettings](../constructors/peerNotifySettings.md) = \['show_previews' => [Bool](../types/Bool.md), 'silent' => [Bool](../types/Bool.md), 'mute_until' => [int](../types/int.md), 'sound' => [string](../types/string.md), \];<a name="peerNotifySettings"></a>
***
<br><br>[$peerSelfLocated](../constructors/peerSelfLocated.md) = \['expires' => [int](../types/int.md), \];<a name="peerSelfLocated"></a>
*** ***
<br><br>[$peerSettings](../constructors/peerSettings.md) = \['report_spam' => [Bool](../types/Bool.md), 'add_contact' => [Bool](../types/Bool.md), 'block_contact' => [Bool](../types/Bool.md), 'share_contact' => [Bool](../types/Bool.md), 'need_contacts_exception' => [Bool](../types/Bool.md), 'report_geo' => [Bool](../types/Bool.md), \];<a name="peerSettings"></a> <br><br>[$peerSettings](../constructors/peerSettings.md) = \['report_spam' => [Bool](../types/Bool.md), 'add_contact' => [Bool](../types/Bool.md), 'block_contact' => [Bool](../types/Bool.md), 'share_contact' => [Bool](../types/Bool.md), 'need_contacts_exception' => [Bool](../types/Bool.md), 'report_geo' => [Bool](../types/Bool.md), \];<a name="peerSettings"></a>

View File

@ -0,0 +1,39 @@
---
title: ipPort
description: Ip port
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Constructor: ipPort
[Back to constructors index](index.md)
Ip port
### Attributes:
| Name | Type | Required | Description |
|----------|---------------|----------|-------------|
|ipv4|[int](../types/int.md) | Yes|Ipv4|
|port|[int](../types/int.md) | Yes|Port|
### Type: [IpPort](../types/IpPort.md)
### Example:
```php
$ipPort = ['_' => 'ipPort', 'ipv4' => int, 'port' => int];
```
Or, if you're into Lua:
```lua
ipPort={_='ipPort', ipv4=int, port=int}
```

View File

@ -0,0 +1,40 @@
---
title: ipPortSecret
description: Ip port secret
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Constructor: ipPortSecret
[Back to constructors index](index.md)
Ip port secret
### Attributes:
| Name | Type | Required | Description |
|----------|---------------|----------|-------------|
|ipv4|[int](../types/int.md) | Yes|Ipv4|
|port|[int](../types/int.md) | Yes|Port|
|secret|[bytes](../types/bytes.md) | Yes|Secret|
### Type: [IpPort](../types/IpPort.md)
### Example:
```php
$ipPortSecret = ['_' => 'ipPortSecret', 'ipv4' => int, 'port' => int, 'secret' => 'bytes'];
```
Or, if you're into Lua:
```lua
ipPortSecret={_='ipPortSecret', ipv4=int, port=int, secret='bytes'}
```

View File

@ -0,0 +1,37 @@
---
title: messageEntityBankCard
description: messageEntityBankCard attributes, type and example
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Constructor: messageEntityBankCard
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|---------------|----------|
|offset|[int](../types/int.md) | Yes|
|length|[int](../types/int.md) | Yes|
### Type: [MessageEntity](../types/MessageEntity.md)
### Example:
```php
$messageEntityBankCard = ['_' => 'messageEntityBankCard', 'offset' => int, 'length' => int];
```
Or, if you're into Lua:
```lua
messageEntityBankCard={_='messageEntityBankCard', offset=int, length=int}
```

View File

@ -0,0 +1,38 @@
---
title: payments.bankCardData
description: payments.bankCardData attributes, type and example
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
redirect_from: /API_docs/constructors/payments_bankCardData.html
---
# Constructor: payments.bankCardData
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|---------------|----------|
|title|[string](../types/string.md) | Yes|
|open\_urls|Array of [BankCardOpenUrl](../types/BankCardOpenUrl.md) | Yes|
### Type: [payments.BankCardData](../types/payments.BankCardData.md)
### Example:
```php
$payments.bankCardData = ['_' => 'payments.bankCardData', 'title' => 'string', 'open_urls' => [BankCardOpenUrl, BankCardOpenUrl]];
```
Or, if you're into Lua:
```lua
payments.bankCardData={_='payments.bankCardData', title='string', open_urls={BankCardOpenUrl}}
```

View File

@ -0,0 +1,36 @@
---
title: peerSelfLocated
description: peerSelfLocated attributes, type and example
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Constructor: peerSelfLocated
[Back to constructors index](index.md)
### Attributes:
| Name | Type | Required |
|----------|---------------|----------|
|expires|[int](../types/int.md) | Yes|
### Type: [PeerLocated](../types/PeerLocated.md)
### Example:
```php
$peerSelfLocated = ['_' => 'peerSelfLocated', 'expires' => int];
```
Or, if you're into Lua:
```lua
peerSelfLocated={_='peerSelfLocated', expires=int}
```

View File

@ -1,9 +1,9 @@
--- ---
title: MadelineProto API documentation (layer 109) title: MadelineProto API documentation (layer 110)
description: MadelineProto API documentation (layer 109) description: MadelineProto API documentation (layer 110)
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
--- ---
# MadelineProto API documentation (layer 109) # MadelineProto API documentation (layer 110)
[Back to main documentation](..) [Back to main documentation](..)

View File

@ -49,6 +49,7 @@ Bool = account.updateNotifySettings({peer=InputNotifyPeer, settings=InputPeerNot
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup| |400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup|
|400|MSG_ID_INVALID|Invalid message ID provided|
|400|PEER_ID_INVALID|The provided peer id is invalid| |400|PEER_ID_INVALID|The provided peer id is invalid|
|400|SETTINGS_INVALID|Invalid settings were provided| |400|SETTINGS_INVALID|Invalid settings were provided|

View File

@ -52,6 +52,7 @@ User = account.updateProfile({first_name='string', last_name='string', about='st
|400|ABOUT_TOO_LONG|About string too long| |400|ABOUT_TOO_LONG|About string too long|
|400|FIRSTNAME_INVALID|The first name is invalid| |400|FIRSTNAME_INVALID|The first name is invalid|
|406|AUTH_KEY_DUPLICATED|An auth key with the same ID was already generated| |406|AUTH_KEY_DUPLICATED|An auth key with the same ID was already generated|
|401|SESSION_PASSWORD_NEEDED|2FA is enabled, use a password to login|
|-503|Timeout|Timeout while fetching data| |-503|Timeout|Timeout while fetching data|

View File

@ -548,7 +548,7 @@ $MadelineProto->[contacts->getContacts](contacts.getContacts.md)(\['hash' => [in
*** ***
<br><br> <br><br>
$MadelineProto->[contacts->getLocated](contacts.getLocated.md)(\['geo_point' => [InputGeoPoint](../types/InputGeoPoint.md), \]) === [$Updates](../types/Updates.md)<a name="contacts.getLocated"></a> $MadelineProto->[contacts->getLocated](contacts.getLocated.md)(\['background' => [Bool](../types/Bool.md), 'geo_point' => [InputGeoPoint](../types/InputGeoPoint.md), 'self_expires' => [int](../types/int.md), \]) === [$Updates](../types/Updates.md)<a name="contacts.getLocated"></a>
*** ***
<br><br> <br><br>
@ -1178,6 +1178,10 @@ $MadelineProto->[messages->startBot](messages.startBot.md)(\['bot' => [InputUser
<br><br> <br><br>
$MadelineProto->[messages->toggleDialogPin](messages.toggleDialogPin.md)(\['pinned' => [Bool](../types/Bool.md), 'peer' => [InputDialogPeer](../types/InputDialogPeer.md), \]) === [$Bool](../types/Bool.md)<a name="messages.toggleDialogPin"></a> $MadelineProto->[messages->toggleDialogPin](messages.toggleDialogPin.md)(\['pinned' => [Bool](../types/Bool.md), 'peer' => [InputDialogPeer](../types/InputDialogPeer.md), \]) === [$Bool](../types/Bool.md)<a name="messages.toggleDialogPin"></a>
***
<br><br>
$MadelineProto->[messages->toggleStickerSets](messages.toggleStickerSets.md)(\['uninstall' => [Bool](../types/Bool.md), 'archive' => [Bool](../types/Bool.md), 'unarchive' => [Bool](../types/Bool.md), 'stickersets' => \[[InputStickerSet](../types/InputStickerSet.md)\], \]) === [$Bool](../types/Bool.md)<a name="messages.toggleStickerSets"></a>
*** ***
<br><br> <br><br>
$MadelineProto->[messages->uninstallStickerSet](messages.uninstallStickerSet.md)(\['stickerset' => [InputStickerSet](../types/InputStickerSet.md), \]) === [$Bool](../types/Bool.md)<a name="messages.uninstallStickerSet"></a> $MadelineProto->[messages->uninstallStickerSet](messages.uninstallStickerSet.md)(\['stickerset' => [InputStickerSet](../types/InputStickerSet.md), \]) === [$Bool](../types/Bool.md)<a name="messages.uninstallStickerSet"></a>
@ -1198,6 +1202,10 @@ $MadelineProto->[messages->uploadMedia](messages.uploadMedia.md)(\['peer' => [In
<br><br> <br><br>
$MadelineProto->[payments->clearSavedInfo](payments.clearSavedInfo.md)(\['credentials' => [Bool](../types/Bool.md), 'info' => [Bool](../types/Bool.md), \]) === [$Bool](../types/Bool.md)<a name="payments.clearSavedInfo"></a> $MadelineProto->[payments->clearSavedInfo](payments.clearSavedInfo.md)(\['credentials' => [Bool](../types/Bool.md), 'info' => [Bool](../types/Bool.md), \]) === [$Bool](../types/Bool.md)<a name="payments.clearSavedInfo"></a>
***
<br><br>
$MadelineProto->[payments->getBankCardData](payments.getBankCardData.md)(\['number' => [string](../types/string.md), \]) === [$payments.BankCardData](../types/payments.BankCardData.md)<a name="payments.getBankCardData"></a>
*** ***
<br><br> <br><br>
$MadelineProto->[payments->getPaymentForm](payments.getPaymentForm.md)(\['msg_id' => [int](../types/int.md), \]) === [$payments.PaymentForm](../types/payments.PaymentForm.md)<a name="payments.getPaymentForm"></a> $MadelineProto->[payments->getPaymentForm](payments.getPaymentForm.md)(\['msg_id' => [int](../types/int.md), \]) === [$payments.PaymentForm](../types/payments.PaymentForm.md)<a name="payments.getPaymentForm"></a>

View File

@ -48,6 +48,7 @@ DataJSON = bots.sendCustomRequest({custom_method='string', params=DataJSON, })
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|METHOD_INVALID|The specified method is invalid|
|400|USER_BOT_INVALID|This method can only be called by a bot| |400|USER_BOT_INVALID|This method can only be called by a bot|

View File

@ -52,6 +52,7 @@ Updates = channels.editAdmin({channel=InputChannel, user_id=InputUser, admin_rig
|------|----------|---------------| |------|----------|---------------|
|400|ADMINS_TOO_MUCH|There are too many admins| |400|ADMINS_TOO_MUCH|There are too many admins|
|400|BOT_CHANNELS_NA|Bots can't edit admin privileges| |400|BOT_CHANNELS_NA|Bots can't edit admin privileges|
|400|BOTS_TOO_MUCH|There are too many bots in this chat/channel|
|400|CHANNEL_INVALID|The provided channel is invalid| |400|CHANNEL_INVALID|The provided channel is invalid|
|400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup| |400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup|
|400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this| |400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this|

View File

@ -23,7 +23,7 @@ Get the participants of a channel
### Return type: [channels.ChannelParticipants](../types/channels.ChannelParticipants.md) ### Return type: [channels.ChannelParticipants](../types/channels.ChannelParticipants.md)
### Can bots use this method: **YES** ### Can bots use this method: **NO**
### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): ### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)):

View File

@ -47,6 +47,7 @@ Updates = contacts.acceptContact({id=InputUser, })
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|CONTACT_ADD_MISSING||
|400|CONTACT_REQ_MISSING|Missing contact request| |400|CONTACT_REQ_MISSING|Missing contact request|

View File

@ -14,7 +14,9 @@ Get contacts near you
| Name | Type | Description | Required | | Name | Type | Description | Required |
|----------|---------------|-------------|----------| |----------|---------------|-------------|----------|
|background|[Bool](../types/Bool.md) | | Optional|
|geo\_point|[InputGeoPoint](../types/InputGeoPoint.md) | Geolocation | Optional| |geo\_point|[InputGeoPoint](../types/InputGeoPoint.md) | Geolocation | Optional|
|self\_expires|[int](../types/int.md) | | Optional|
### Return type: [Updates](../types/Updates.md) ### Return type: [Updates](../types/Updates.md)
@ -34,12 +36,12 @@ include 'madeline.php';
$MadelineProto = new \danog\MadelineProto\API('session.madeline'); $MadelineProto = new \danog\MadelineProto\API('session.madeline');
$MadelineProto->start(); $MadelineProto->start();
$Updates = $MadelineProto->contacts->getLocated(['geo_point' => InputGeoPoint, ]); $Updates = $MadelineProto->contacts->getLocated(['background' => Bool, 'geo_point' => InputGeoPoint, 'self_expires' => int, ]);
``` ```
Or, if you're into Lua: Or, if you're into Lua:
```lua ```lua
Updates = contacts.getLocated({geo_point=InputGeoPoint, }) Updates = contacts.getLocated({background=Bool, geo_point=InputGeoPoint, self_expires=int, })
``` ```

View File

@ -43,5 +43,6 @@ help.TermsOfServiceUpdate = help.getTermsOfServiceUpdate({})
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|406|AUTH_KEY_DUPLICATED|An auth key with the same ID was already generated| |406|AUTH_KEY_DUPLICATED|An auth key with the same ID was already generated|
|401|SESSION_PASSWORD_NEEDED|2FA is enabled, use a password to login|

View File

@ -48,6 +48,7 @@ Bool = messages.editChatAbout({peer=InputPeer, about='string', })
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|CHANNEL_INVALID|The provided channel is invalid|
|400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup| |400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup|
|400|CHAT_ABOUT_NOT_MODIFIED|About text has not changed| |400|CHAT_ABOUT_NOT_MODIFIED|About text has not changed|
|400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this| |400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this|

View File

@ -76,6 +76,7 @@ Updates = messages.forwardMessages({silent=Bool, background=Bool, with_my_score=
|403|CHAT_SEND_POLL_FORBIDDEN|You can't send polls in this chat| |403|CHAT_SEND_POLL_FORBIDDEN|You can't send polls in this chat|
|403|CHAT_SEND_STICKERS_FORBIDDEN|You can't send stickers in this chat.| |403|CHAT_SEND_STICKERS_FORBIDDEN|You can't send stickers in this chat.|
|403|CHAT_WRITE_FORBIDDEN|You can't write in this chat| |403|CHAT_WRITE_FORBIDDEN|You can't write in this chat|
|420|P0NY_FLOODWAIT||
|420|SLOWMODE_WAIT_X|Slowmode is enabled in this chat: you must wait for the specified number of seconds before sending another message to the chat.| |420|SLOWMODE_WAIT_X|Slowmode is enabled in this chat: you must wait for the specified number of seconds before sending another message to the chat.|
|-503|Timeout|Timeout while fetching data| |-503|Timeout|Timeout while fetching data|

View File

@ -45,3 +45,10 @@ Or, if you're into Lua:
messages.VotesList = messages.getPollVotes({peer=InputPeer, id=int, option='bytes', offset='string', limit=int, }) messages.VotesList = messages.getPollVotes({peer=InputPeer, id=int, option='bytes', offset='string', limit=int, })
``` ```
### Errors
| Code | Type | Description |
|------|----------|---------------|
|403|POLL_VOTE_REQUIRED|Cast a vote in the poll before calling this method|

View File

@ -48,6 +48,7 @@ messages.Messages = messages.getScheduledHistory({peer=InputPeer, hash={int}, })
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this|
|400|PEER_ID_INVALID|The provided peer id is invalid| |400|PEER_ID_INVALID|The provided peer id is invalid|

View File

@ -44,3 +44,10 @@ Or, if you're into Lua:
messages.Messages = messages.getScheduledMessages({peer=InputPeer, id={int}, }) messages.Messages = messages.getScheduledMessages({peer=InputPeer, id={int}, })
``` ```
### Errors
| Code | Type | Description |
|------|----------|---------------|
|400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this|

View File

@ -50,6 +50,7 @@ messages.AffectedMessages = messages.readHistory({peer=InputPeer, max_id=int, })
|------|----------|---------------| |------|----------|---------------|
|400|MSG_ID_INVALID|Invalid message ID provided| |400|MSG_ID_INVALID|Invalid message ID provided|
|400|PEER_ID_INVALID|The provided peer id is invalid| |400|PEER_ID_INVALID|The provided peer id is invalid|
|406|AUTH_KEY_DUPLICATED|An auth key with the same ID was already generated|
|-503|Timeout|Timeout while fetching data| |-503|Timeout|Timeout while fetching data|

View File

@ -29,7 +29,7 @@ Sends a message to a chat
### Return type: [Updates](../types/Updates.md) ### Return type: [Updates](../types/Updates.md)
### Can bots use this method: **YES** ### Can bots use this method: **NO**
### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)): ### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)):

View File

@ -0,0 +1,46 @@
---
title: messages.toggleStickerSets
description: messages.toggleStickerSets parameters, return type and example
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
redirect_from: /API_docs/methods/messages_toggleStickerSets.html
---
# Method: messages.toggleStickerSets
[Back to methods index](index.md)
### Parameters:
| Name | Type | Required |
|----------|---------------|----------|
|uninstall|[Bool](../types/Bool.md) | Optional|
|archive|[Bool](../types/Bool.md) | Optional|
|unarchive|[Bool](../types/Bool.md) | Optional|
|stickersets|Array of [InputStickerSet](../types/InputStickerSet.md) | Yes|
### Return type: [Bool](../types/Bool.md)
### Can bots use this method: **YES**
### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)):
```php
if (!file_exists('madeline.php')) {
copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php');
}
include 'madeline.php';
$MadelineProto = new \danog\MadelineProto\API('session.madeline');
$MadelineProto->start();
$Bool = $MadelineProto->messages->toggleStickerSets(['uninstall' => Bool, 'archive' => Bool, 'unarchive' => Bool, 'stickersets' => [InputStickerSet, InputStickerSet], ]);
```
Or, if you're into Lua:
```lua
Bool = messages.toggleStickerSets({uninstall=Bool, archive=Bool, unarchive=Bool, stickersets={InputStickerSet}, })
```

View File

@ -49,6 +49,7 @@ Updates = messages.updatePinnedMessage({silent=Bool, peer=InputPeer, id=int, })
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|CHANNEL_PRIVATE|You haven't joined this channel/supergroup|
|400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this| |400|CHAT_ADMIN_REQUIRED|You must be an admin in this chat to do this|
|400|CHAT_NOT_MODIFIED|The pinned message wasn't modified| |400|CHAT_NOT_MODIFIED|The pinned message wasn't modified|
|400|MESSAGE_ID_INVALID|The provided message id is invalid| |400|MESSAGE_ID_INVALID|The provided message id is invalid|

View File

@ -0,0 +1,43 @@
---
title: payments.getBankCardData
description: payments.getBankCardData parameters, return type and example
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
redirect_from: /API_docs/methods/payments_getBankCardData.html
---
# Method: payments.getBankCardData
[Back to methods index](index.md)
### Parameters:
| Name | Type | Required |
|----------|---------------|----------|
|number|[string](../types/string.md) | Yes|
### Return type: [payments.BankCardData](../types/payments.BankCardData.md)
### Can bots use this method: **YES**
### MadelineProto Example ([now async for huge speed and parallelism!](https://docs.madelineproto.xyz/docs/ASYNC.html)):
```php
if (!file_exists('madeline.php')) {
copy('https://phar.madelineproto.xyz/madeline.php', 'madeline.php');
}
include 'madeline.php';
$MadelineProto = new \danog\MadelineProto\API('session.madeline');
$MadelineProto->start();
$payments.BankCardData = $MadelineProto->payments->getBankCardData(['number' => 'string', ]);
```
Or, if you're into Lua:
```lua
payments.BankCardData = payments.getBankCardData({number='string', })
```

View File

@ -52,5 +52,6 @@ photos.Photos = photos.getUserPhotos({user_id=InputUser, offset=int, max_id=long
|------|----------|---------------| |------|----------|---------------|
|400|MAX_ID_INVALID|The provided max ID is invalid| |400|MAX_ID_INVALID|The provided max ID is invalid|
|400|USER_ID_INVALID|The provided user ID is invalid| |400|USER_ID_INVALID|The provided user ID is invalid|
|406|AUTH_KEY_DUPLICATED|An auth key with the same ID was already generated|

View File

@ -51,7 +51,9 @@ upload.File = upload.getFile({precise=Bool, cdn_supported=Bool, location=InputFi
| Code | Type | Description | | Code | Type | Description |
|------|----------|---------------| |------|----------|---------------|
|400|CHANNEL_INVALID|The provided channel is invalid|
|400|FILE_ID_INVALID|The provided file id is invalid| |400|FILE_ID_INVALID|The provided file id is invalid|
|400|FILE_REFERENCE_EXPIRED|File reference expired, it must be refetched as described in https://core.telegram.org/api/file_reference|
|400|INPUT_FETCH_FAIL|Failed deserializing TL payload| |400|INPUT_FETCH_FAIL|Failed deserializing TL payload|
|400|LIMIT_INVALID|The provided limit is invalid| |400|LIMIT_INVALID|The provided limit is invalid|
|400|LOCATION_INVALID|The provided location is invalid| |400|LOCATION_INVALID|The provided location is invalid|

View File

@ -1,16 +1,16 @@
--- ---
title: Null title: AccessPointRule
description: constructors and methods of type Null description: constructors and methods of type AccessPointRule
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
--- ---
# Type: Null # Type: AccessPointRule
[Back to types index](index.md) [Back to types index](index.md)
### Possible values (constructors): ### Possible values (constructors):
[null](../constructors/null.md) [accessPointRule](../constructors/accessPointRule.md)

View File

@ -0,0 +1,20 @@
---
title: BankCardOpenUrl
description: constructors and methods of type BankCardOpenUrl
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Type: BankCardOpenUrl
[Back to types index](index.md)
### Possible values (constructors):
[bankCardOpenUrl](../constructors/bankCardOpenUrl.md)
### Methods that return an object of this type (methods):

View File

@ -0,0 +1,22 @@
---
title: IpPort
description: constructors and methods of type IpPort
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
---
# Type: IpPort
[Back to types index](index.md)
### Possible values (constructors):
[ipPort](../constructors/ipPort.md)
[ipPortSecret](../constructors/ipPortSecret.md)
### Methods that return an object of this type (methods):

View File

@ -46,6 +46,8 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[messageEntityBlockquote](../constructors/messageEntityBlockquote.md) [messageEntityBlockquote](../constructors/messageEntityBlockquote.md)
[messageEntityBankCard](../constructors/messageEntityBankCard.md)
### Methods that return an object of this type (methods): ### Methods that return an object of this type (methods):

View File

@ -12,6 +12,8 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[peerLocated](../constructors/peerLocated.md) [peerLocated](../constructors/peerLocated.md)
[peerSelfLocated](../constructors/peerSelfLocated.md)
### Methods that return an object of this type (methods): ### Methods that return an object of this type (methods):

View File

@ -0,0 +1,21 @@
---
title: help.ConfigSimple
description: constructors and methods of type help.ConfigSimple
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
redirect_from: /API_docs/types/help_ConfigSimple.html
---
# Type: help.ConfigSimple
[Back to types index](index.md)
### Possible values (constructors):
[help.configSimple](../constructors/help.configSimple.md)
### Methods that return an object of this type (methods):

View File

@ -7,12 +7,16 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[Back to API documentation index](..) [Back to API documentation index](..)
[AccessPointRule](AccessPointRule.md)<a name="AccessPointRule"></a>
[AccountDaysTTL](AccountDaysTTL.md)<a name="AccountDaysTTL"></a> [AccountDaysTTL](AccountDaysTTL.md)<a name="AccountDaysTTL"></a>
[Authorization](Authorization.md)<a name="Authorization"></a> [Authorization](Authorization.md)<a name="Authorization"></a>
[AutoDownloadSettings](AutoDownloadSettings.md)<a name="AutoDownloadSettings"></a> [AutoDownloadSettings](AutoDownloadSettings.md)<a name="AutoDownloadSettings"></a>
[BankCardOpenUrl](BankCardOpenUrl.md)<a name="BankCardOpenUrl"></a>
[BaseTheme](BaseTheme.md)<a name="BaseTheme"></a> [BaseTheme](BaseTheme.md)<a name="BaseTheme"></a>
[Bool](Bool.md)<a name="Bool"></a> [Bool](Bool.md)<a name="Bool"></a>
@ -217,6 +221,8 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[Invoice](Invoice.md)<a name="Invoice"></a> [Invoice](Invoice.md)<a name="Invoice"></a>
[IpPort](IpPort.md)<a name="IpPort"></a>
[JSONObjectValue](JSONObjectValue.md)<a name="JSONObjectValue"></a> [JSONObjectValue](JSONObjectValue.md)<a name="JSONObjectValue"></a>
[JSONValue](JSONValue.md)<a name="JSONValue"></a> [JSONValue](JSONValue.md)<a name="JSONValue"></a>
@ -255,8 +261,6 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[NotifyPeer](NotifyPeer.md)<a name="NotifyPeer"></a> [NotifyPeer](NotifyPeer.md)<a name="NotifyPeer"></a>
[Null](Null.md)<a name="Null"></a>
[Page](Page.md)<a name="Page"></a> [Page](Page.md)<a name="Page"></a>
[PageBlock](PageBlock.md)<a name="PageBlock"></a> [PageBlock](PageBlock.md)<a name="PageBlock"></a>
@ -467,6 +471,8 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[help.AppUpdate](help.AppUpdate.md)<a name="help.AppUpdate"></a> [help.AppUpdate](help.AppUpdate.md)<a name="help.AppUpdate"></a>
[help.ConfigSimple](help.ConfigSimple.md)<a name="help.ConfigSimple"></a>
[help.DeepLinkInfo](help.DeepLinkInfo.md)<a name="help.DeepLinkInfo"></a> [help.DeepLinkInfo](help.DeepLinkInfo.md)<a name="help.DeepLinkInfo"></a>
[help.InviteText](help.InviteText.md)<a name="help.InviteText"></a> [help.InviteText](help.InviteText.md)<a name="help.InviteText"></a>
@ -545,6 +551,8 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
[messages.VotesList](messages.VotesList.md)<a name="messages.VotesList"></a> [messages.VotesList](messages.VotesList.md)<a name="messages.VotesList"></a>
[payments.BankCardData](payments.BankCardData.md)<a name="payments.BankCardData"></a>
[payments.PaymentForm](payments.PaymentForm.md)<a name="payments.PaymentForm"></a> [payments.PaymentForm](payments.PaymentForm.md)<a name="payments.PaymentForm"></a>
[payments.PaymentReceipt](payments.PaymentReceipt.md)<a name="payments.PaymentReceipt"></a> [payments.PaymentReceipt](payments.PaymentReceipt.md)<a name="payments.PaymentReceipt"></a>

View File

@ -0,0 +1,23 @@
---
title: payments.BankCardData
description: constructors and methods of type payments.BankCardData
image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
redirect_from: /API_docs/types/payments_BankCardData.html
---
# Type: payments.BankCardData
[Back to types index](index.md)
### Possible values (constructors):
[payments.bankCardData](../constructors/payments.bankCardData.md)
### Methods that return an object of this type (methods):
[$MadelineProto->payments->getBankCardData](../methods/payments.getBankCardData.md)

View File

@ -7,7 +7,7 @@ image: https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png
There are simplifications for many, if not all of, these methods. There are simplifications for many, if not all of, these methods.
A list of all of the methods that can be called with MadelineProto can be found here: [here (layer 109)](https://docs.madelineproto.xyz/API_docs/). A list of all of the methods that can be called with MadelineProto can be found here: [here (layer 110)](https://docs.madelineproto.xyz/API_docs/).
[Now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html) [Now fully async!](https://docs.madelineproto.xyz/docs/ASYNC.html)

View File

@ -42,3 +42,4 @@ description: Documentation of old mtproto layers
[Layer v35](API_docs_v35/) [Layer v35](API_docs_v35/)
[Layer v36](API_docs_v36/) [Layer v36](API_docs_v36/)
[Layer v37](API_docs_v37/) [Layer v37](API_docs_v37/)
[Layer v38](API_docs_v38/)