Fixed a few bugs, switched to traits for MTProtoTools modules, written documentation creator and added documentation

This commit is contained in:
danogentili 2016-12-19 18:56:52 +03:00
parent 1611c0f8ec
commit 04a2504c17
824 changed files with 19728 additions and 43 deletions

4
Caddyfile Normal file
View File

@ -0,0 +1,4 @@
http://localhost {
root docs/
markdown
}

View File

@ -12,6 +12,7 @@ Also note that MadelineProto will perform better if a big math extension like gm
This project is in beta state.
The API documentation can be found [here](https://daniil.it/MadelineProto/API_docs/).
## Usage
@ -171,7 +172,7 @@ var_dump($MadelineProto->API->settings);
### Calling mtproto methods and available wrappers
A list of mtproto methods can be found [here](https://tjhorner.com/tl-schema/#functions).
The API documentation can be found [here](https://daniil.it/MadelineProto/API_docs/).
To call an MTProto method simply call it as if it is a method of the API class, substitute namespace sepators (.) with -> if needed:
```
$MadelineProto = new \danog\MadelineProto\API();
@ -225,6 +226,7 @@ MadelineProto can throw three different exceptions:
You can use this scheme of the structure of this project to help yourself:
```
build_docs.php - Builds API docs from TL scheme files
src/danog/MadelineProto/
MTProtoTools/
AckHandler - Handles acknowledgement of incoming and outgoing mtproto messages
@ -249,8 +251,7 @@ src/danog/MadelineProto/
DebugTools - Various debugging tools
Exception - Handles exceptions and PHP errors
RPCErrorException - Handles RPC errors
MTProto - Extends MTProtoTools, handles initial connection, generation of authorization keys, instantiation of classes, writing of client info
MTProtoTools - Extends all of the classes in MTProtoTools/
MTProto - Handles initial connection, generation of authorization keys, instantiation of classes, writing of client info
Logger - Static logging class
prime.py and getpq.py - prime module (python) for p and q generation
PrimeModule.php - prime module (php) for p and q generation by wrapping the python module, using wolfram alpha or a built in PHP engine

365
build_docs.php Executable file
View File

@ -0,0 +1,365 @@
#!/usr/bin/env php
<?php
/*
Copyright 2016 Daniil Gentili
(https://daniil.it)
This file is part of MadelineProto.
MadelineProto is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
MadelineProto is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Affero General Public License for more details.
You should have received a copy of the GNU General Public License along with MadelineProto.
If not, see <http://www.gnu.org/licenses/>.
*/
require_once 'vendor/autoload.php';
$mode = 3;
\danog\MadelineProto\Logger::constructor($mode);
$TL = new \danog\MadelineProto\TL\TL([
//'mtproto' => __DIR__.'/src/danog/MadelineProto/TL_mtproto_v1.json', // mtproto TL scheme
'telegram' => __DIR__.'/src/danog/MadelineProto/TL_telegram_v57.json', // telegram TL scheme
]);
\danog\MadelineProto\Logger::log('Copying readme...');
copy('README.md', 'docs/index.md');
chdir(__DIR__.'/docs/API_docs');
\danog\MadelineProto\Logger::log('Generating documentation index...');
file_put_contents('index.md', '# MadelineProto API documentation (layer 57)
[Methods](methods/)
[Constructors](constructors/)
[Types](types/)
');
foreach (glob('methods/*') as $unlink) {
unlink($unlink);
}
if (file_exists('methods')) {
rmdir('methods');
}
mkdir('methods');
$methods = [];
$types = [];
\danog\MadelineProto\Logger::log('Generating methods documentation...');
foreach ($TL->methods->method as $key => $method) {
$type = str_replace(['.', '<', '>'], ['_', '_of_', ''], $TL->methods->type[$key]);
$real_type = preg_replace('/.*_of_/', '', $type);
$params = '';
foreach ($TL->methods->params[$key] as $param) {
if ($param['name'] == 'flags') continue;
$stype = 'type';
$link_type = 'types';
if (isset($param['subtype'])) {
$stype = 'subtype';
if ($param['type'] == 'vector') {
$link_type = 'constructors';
}
}
$ptype = str_replace('.', '_', $param[$stype]);
switch ($ptype) {
case 'true':
case 'false':
$ptype = 'Bool';
}
$params .= "'".$param['name'] . "' => ";
$params .= (isset($param['subtype']) ? '[' : '') . '['.$ptype.'](../'.$link_type.'/'.$ptype.'.md)'.(isset($param['subtype']) ? ']' : '').', ';
}
$methods [$method]= str_replace(['_', '\[\]'],['\_', ''], '$MadelineProto->['.str_replace('.', '->', $method).']('.$method.'.md)(\['.$params.'\]) == [$'.$type.'](../types/'.$real_type.'.md);
');
$params = '';
$table = '| Name | Type | Required |
|----------|:-------------:|---------:|
';
foreach ($TL->methods->params[$key] as $param) {
if ($param['name'] == 'flags') continue;
$ptype = str_replace('.', '_', $param[isset($param['subtype']) ? 'subtype' : 'type']);
switch ($ptype) {
case 'true':
case 'false':
$ptype = 'Bool';
}
$table .= '|'.$param['name'] . '|' . (isset($param['subtype']) ? 'Array of ' : ''). '['.$ptype.'](../types/'.$ptype.'.md) | '.($param['flag'] ? 'Optional' : 'Required').'|
';
$params .= "'".$param['name'] . "' => ";
$params .= (isset($param['subtype']) ? '['.$ptype.']' : $ptype).', ';
}
$example = str_replace('[]', '', '
```
$MadelineProto = new \danog\MadelineProto\API();
if (isset($token)) {
$this->bot_login($token);
}
if (isset($number)) {
$sentCode = $MadelineProto->phone_login($number);
echo \'Enter the code you received: \';
$code = \'\';
for ($x = 0; $x < $sentCode[\'type\'][\'length\']; $x++) {
$code .= fgetc(STDIN);
}
$MadelineProto->complete_phone_login($code);
}
$'.$type.' = $MadelineProto->'.str_replace('.', '->', $method).'(['.$params.']);
```');
$header = str_replace('_', '\_', '## Method: '.$method.'
### Parameters:
'.$table.'
### Return type: ['.$type.'](../types/'.$real_type.'.md)
### Example:
');
file_put_contents('methods/'.$method.'.md', $header.$example);
}
\danog\MadelineProto\Logger::log('Generating methods index...');
ksort($methods);
file_put_contents('methods/index.md', '# Methods
<style>
.container {
width: auto;
overflow-x: auto;
white-space: nowrap;
background: #ecf3f8;
padding: 10px;
}
</style>
<div class="container">
'.join('', $methods).'</div>');
foreach (glob('constructors/*') as $unlink) {
unlink($unlink);
}
if (file_exists('constructors')) {
rmdir('constructors');
}
mkdir('constructors');
$constructors = [];
\danog\MadelineProto\Logger::log('Generating constructors documentation...');
foreach ($TL->constructors->predicate as $key => $constructor) {
$constructor = str_replace('.', '_', $constructor);
$type = str_replace(['.', '<', '>'], ['_', '_of_', ''], $TL->constructors->type[$key]);
$real_type = preg_replace('/.*_of_/', '', $type);
$params = '';
foreach ($TL->constructors->params[$key] as $param) {
if ($param['name'] == 'flags') continue;
$stype = 'type';
$link_type = 'types';
if (isset($param['subtype'])) {
$stype = 'subtype';
if ($param['type'] == 'vector') {
$link_type = 'constructors';
}
}
$ptype = str_replace('.', '_', $param[$stype]);
switch ($ptype) {
case 'true':
case 'false':
$ptype = 'Bool';
}
$params .= "'".$param['name'] . "' => ";
$params .= (isset($param['subtype']) ? '[' : '') . '['.$ptype.'](../'.$link_type.'/'.$ptype.'.md)'.(isset($param['subtype']) ? ']' : '').', ';
}
$constructors [$constructor]= str_replace(['_', '\[\]'],['\_', ''], '[$'.$real_type.'](../types/'.$real_type.'.md)\[\'['.str_replace('.', '->', $constructor).']('.$constructor.'.md)\'\] = \['.$params.'\]
');
if (!isset($types[$real_type])) {
$types[$real_type] = [];
}
if (!in_array($key, $types[$real_type])) {
$types[$real_type][] = $key;
}
$params = '';
$table = '| Name | Type | Required |
|----------|:-------------:|---------:|
';
foreach ($TL->constructors->params[$key] as $param) {
if ($param['name'] == 'flags') continue;
$ptype = str_replace('.', '_', $param[isset($param['subtype']) ? 'subtype' : 'type']);
$link_type = 'types';
if (isset($param['subtype'])) {
if ($param['type'] == 'vector') {
$link_type = 'constructors';
}
}
switch ($ptype) {
case 'true':
case 'false':
$ptype = 'Bool';
}
$table .= '|'.$param['name'] . '|' . (isset($param['subtype']) ? 'Array of ' : ''). '['.$ptype.'](../'.$link_type.'/'.$ptype.'.md) | '.($param['flag'] ? 'Optional' : 'Required').'|
';
$params .= "'".$param['name'] . "' => ";
$params .= (isset($param['subtype']) ? '['.$ptype.']' : $ptype).', ';
}
$example = str_replace('[]', '', '
```
$'.$constructor.' = ['.$params.'];
```');
$header = str_replace('_', '\_', '## Constructor: '.$constructor.'
### Attributes:
'.$table.'
### Type: ['.$real_type.'](../types/'.$real_type.'.md)
### Example:
');
file_put_contents('constructors/'.$constructor.'.md', $header.$example);
}
\danog\MadelineProto\Logger::log('Generating constructors index...');
ksort($constructors);
file_put_contents('constructors/index.md', '# Constructors
<style>
.container {
width: auto;
overflow-x: auto;
white-space: nowrap;
background: #ecf3f8;
padding: 10px;
}
</style>
<div class="container">
'.join('', $constructors).'</div>');
foreach (glob('types/*') as $unlink) {
unlink($unlink);
}
if (file_exists('types')) {
rmdir('types');
}
mkdir('types');
ksort($types);
$index = '';
\danog\MadelineProto\Logger::log('Generating types documentation...');
foreach ($types as $type => $keys) {
$index .= '['.$type.']('.$type.'.md)
';
$constructors = '';
foreach ($keys as $key) {
$predicate = str_replace('.', '_', $TL->constructors->predicate[$key]);
$constructors .= '['.$predicate.'](../constructors/'.$predicate.'.md)
';
}
$header = str_replace('_', '\_', '## Type: '.$type.'
### Constructors:
<style>
.container {
width: auto;
overflow-x: auto;
white-space: nowrap;
background: #ecf3f8;
padding: 10px;
}
</style>
<div class="container">
'.$constructors.'</div>');
file_put_contents('types/'.$type.'.md', $header);
}
\danog\MadelineProto\Logger::log('Generating additional types...');
file_put_contents('types/string.md', '## Type: string
A string of variable length.');
file_put_contents('types/bytes.md', '## Type: bytes
A string of variable length.');
file_put_contents('types/int.md', '## Type: int
A 32 bit signed integer ranging from -2147483647 to 2147483647.');
file_put_contents('types/long.md', '## Type: long
A 64 bit signed integer ranging from -9223372036854775807 to 9223372036854775807.');
file_put_contents('types/double.md', '## Type: double
A double precision number, single precision can also be used (float).');
file_put_contents('types/!X.md', '## Type: !X
Represents a TL serialized payload.');
file_put_contents('types/X.md', '## Type: X
Represents a TL serialized payload.');
\danog\MadelineProto\Logger::log('Generating types index...');
file_put_contents('types/index.md', '# Types
<style>
.container {
width: auto;
overflow-x: auto;
white-space: nowrap;
background: #ecf3f8;
padding: 10px;
}
</style>
<div class="container">
'.$index.'</div>');
\danog\MadelineProto\Logger::log('Done!');

View File

@ -0,0 +1,17 @@
## Constructor: accountDaysTTL
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|days|[int](../types/int.md) | Required|
### Type: [AccountDaysTTL](../types/AccountDaysTTL.md)
### Example:
```
$accountDaysTTL = ['days' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: account\_authorizations
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|authorizations|Array of [Authorization](../types/Authorization.md) | Required|
### Type: [account\_Authorizations](../types/account\_Authorizations.md)
### Example:
```
$account_authorizations = ['authorizations' => [Authorization], ];
```

View File

@ -0,0 +1,18 @@
## Constructor: account\_noPassword
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|new\_salt|[bytes](../types/bytes.md) | Required|
|email\_unconfirmed\_pattern|[string](../types/string.md) | Required|
### Type: [account\_Password](../types/account\_Password.md)
### Example:
```
$account_noPassword = ['new_salt' => bytes, 'email_unconfirmed_pattern' => string, ];
```

View File

@ -0,0 +1,21 @@
## Constructor: account\_password
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|current\_salt|[bytes](../types/bytes.md) | Required|
|new\_salt|[bytes](../types/bytes.md) | Required|
|hint|[string](../types/string.md) | Required|
|has\_recovery|[Bool](../types/Bool.md) | Required|
|email\_unconfirmed\_pattern|[string](../types/string.md) | Required|
### Type: [account\_Password](../types/account\_Password.md)
### Example:
```
$account_password = ['current_salt' => bytes, 'new_salt' => bytes, 'hint' => string, 'has_recovery' => Bool, 'email_unconfirmed_pattern' => string, ];
```

View File

@ -0,0 +1,20 @@
## Constructor: account\_passwordInputSettings
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|new\_salt|[bytes](../types/bytes.md) | Optional|
|new\_password\_hash|[bytes](../types/bytes.md) | Optional|
|hint|[string](../types/string.md) | Optional|
|email|[string](../types/string.md) | Optional|
### Type: [account\_PasswordInputSettings](../types/account\_PasswordInputSettings.md)
### Example:
```
$account_passwordInputSettings = ['new_salt' => bytes, 'new_password_hash' => bytes, 'hint' => string, 'email' => string, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: account\_passwordSettings
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|email|[string](../types/string.md) | Required|
### Type: [account\_PasswordSettings](../types/account\_PasswordSettings.md)
### Example:
```
$account_passwordSettings = ['email' => string, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: account\_privacyRules
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|rules|Array of [PrivacyRule](../types/PrivacyRule.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [account\_PrivacyRules](../types/account\_PrivacyRules.md)
### Example:
```
$account_privacyRules = ['rules' => [PrivacyRule], 'users' => [User], ];
```

View File

@ -0,0 +1,18 @@
## Constructor: auth\_authorization
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|tmp\_sessions|[int](../types/int.md) | Optional|
|user|[User](../types/User.md) | Required|
### Type: [auth\_Authorization](../types/auth\_Authorization.md)
### Example:
```
$auth_authorization = ['tmp_sessions' => int, 'user' => User, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: auth\_checkedPhone
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|phone\_registered|[Bool](../types/Bool.md) | Required|
### Type: [auth\_CheckedPhone](../types/auth\_CheckedPhone.md)
### Example:
```
$auth_checkedPhone = ['phone_registered' => Bool, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: auth\_codeTypeCall
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [auth\_CodeType](../types/auth\_CodeType.md)
### Example:
```
$auth_codeTypeCall = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: auth\_codeTypeFlashCall
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [auth\_CodeType](../types/auth\_CodeType.md)
### Example:
```
$auth_codeTypeFlashCall = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: auth\_codeTypeSms
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [auth\_CodeType](../types/auth\_CodeType.md)
### Example:
```
$auth_codeTypeSms = ;
```

View File

@ -0,0 +1,18 @@
## Constructor: auth\_exportedAuthorization
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[int](../types/int.md) | Required|
|bytes|[bytes](../types/bytes.md) | Required|
### Type: [auth\_ExportedAuthorization](../types/auth\_ExportedAuthorization.md)
### Example:
```
$auth_exportedAuthorization = ['id' => int, 'bytes' => bytes, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: auth\_passwordRecovery
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|email\_pattern|[string](../types/string.md) | Required|
### Type: [auth\_PasswordRecovery](../types/auth\_PasswordRecovery.md)
### Example:
```
$auth_passwordRecovery = ['email_pattern' => string, ];
```

View File

@ -0,0 +1,21 @@
## Constructor: auth\_sentCode
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|phone\_registered|[Bool](../types/Bool.md) | Optional|
|type|[auth\_SentCodeType](../types/auth\_SentCodeType.md) | Required|
|phone\_code\_hash|[string](../types/string.md) | Required|
|next\_type|[auth\_CodeType](../types/auth\_CodeType.md) | Optional|
|timeout|[int](../types/int.md) | Optional|
### Type: [auth\_SentCode](../types/auth\_SentCode.md)
### Example:
```
$auth_sentCode = ['phone_registered' => Bool, 'type' => auth_SentCodeType, 'phone_code_hash' => string, 'next_type' => auth_CodeType, 'timeout' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: auth\_sentCodeTypeApp
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|length|[int](../types/int.md) | Required|
### Type: [auth\_SentCodeType](../types/auth\_SentCodeType.md)
### Example:
```
$auth_sentCodeTypeApp = ['length' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: auth\_sentCodeTypeCall
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|length|[int](../types/int.md) | Required|
### Type: [auth\_SentCodeType](../types/auth\_SentCodeType.md)
### Example:
```
$auth_sentCodeTypeCall = ['length' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: auth\_sentCodeTypeFlashCall
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|pattern|[string](../types/string.md) | Required|
### Type: [auth\_SentCodeType](../types/auth\_SentCodeType.md)
### Example:
```
$auth_sentCodeTypeFlashCall = ['pattern' => string, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: auth\_sentCodeTypeSms
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|length|[int](../types/int.md) | Required|
### Type: [auth\_SentCodeType](../types/auth\_SentCodeType.md)
### Example:
```
$auth_sentCodeTypeSms = ['length' => int, ];
```

View File

@ -0,0 +1,28 @@
## Constructor: authorization
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|hash|[long](../types/long.md) | Required|
|device\_model|[string](../types/string.md) | Required|
|platform|[string](../types/string.md) | Required|
|system\_version|[string](../types/string.md) | Required|
|api\_id|[int](../types/int.md) | Required|
|app\_name|[string](../types/string.md) | Required|
|app\_version|[string](../types/string.md) | Required|
|date\_created|[int](../types/int.md) | Required|
|date\_active|[int](../types/int.md) | Required|
|ip|[string](../types/string.md) | Required|
|country|[string](../types/string.md) | Required|
|region|[string](../types/string.md) | Required|
### Type: [Authorization](../types/Authorization.md)
### Example:
```
$authorization = ['hash' => long, 'device_model' => string, 'platform' => string, 'system_version' => string, 'api_id' => int, 'app_name' => string, 'app_version' => string, 'date_created' => int, 'date_active' => int, 'ip' => string, 'country' => string, 'region' => string, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: boolFalse
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [Bool](../types/Bool.md)
### Example:
```
$boolFalse = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: boolTrue
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [Bool](../types/Bool.md)
### Example:
```
$boolTrue = ;
```

View File

@ -0,0 +1,18 @@
## Constructor: botCommand
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|command|[string](../types/string.md) | Required|
|description|[string](../types/string.md) | Required|
### Type: [BotCommand](../types/BotCommand.md)
### Example:
```
$botCommand = ['command' => string, 'description' => string, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: botInfo
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|description|[string](../types/string.md) | Required|
|commands|Array of [BotCommand](../types/BotCommand.md) | Required|
### Type: [BotInfo](../types/BotInfo.md)
### Example:
```
$botInfo = ['user_id' => int, 'description' => string, 'commands' => [BotCommand], ];
```

View File

@ -0,0 +1,23 @@
## Constructor: botInlineMediaResult
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[string](../types/string.md) | Required|
|type|[string](../types/string.md) | Required|
|photo|[Photo](../types/Photo.md) | Optional|
|document|[Document](../types/Document.md) | Optional|
|title|[string](../types/string.md) | Optional|
|description|[string](../types/string.md) | Optional|
|send\_message|[BotInlineMessage](../types/BotInlineMessage.md) | Required|
### Type: [BotInlineResult](../types/BotInlineResult.md)
### Example:
```
$botInlineMediaResult = ['id' => string, 'type' => string, 'photo' => Photo, 'document' => Document, 'title' => string, 'description' => string, 'send_message' => BotInlineMessage, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: botInlineMessageMediaAuto
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|caption|[string](../types/string.md) | Required|
|reply\_markup|[ReplyMarkup](../types/ReplyMarkup.md) | Optional|
### Type: [BotInlineMessage](../types/BotInlineMessage.md)
### Example:
```
$botInlineMessageMediaAuto = ['caption' => string, 'reply_markup' => ReplyMarkup, ];
```

View File

@ -0,0 +1,20 @@
## Constructor: botInlineMessageMediaContact
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|phone\_number|[string](../types/string.md) | Required|
|first\_name|[string](../types/string.md) | Required|
|last\_name|[string](../types/string.md) | Required|
|reply\_markup|[ReplyMarkup](../types/ReplyMarkup.md) | Optional|
### Type: [BotInlineMessage](../types/BotInlineMessage.md)
### Example:
```
$botInlineMessageMediaContact = ['phone_number' => string, 'first_name' => string, 'last_name' => string, 'reply_markup' => ReplyMarkup, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: botInlineMessageMediaGeo
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|geo|[GeoPoint](../types/GeoPoint.md) | Required|
|reply\_markup|[ReplyMarkup](../types/ReplyMarkup.md) | Optional|
### Type: [BotInlineMessage](../types/BotInlineMessage.md)
### Example:
```
$botInlineMessageMediaGeo = ['geo' => GeoPoint, 'reply_markup' => ReplyMarkup, ];
```

View File

@ -0,0 +1,22 @@
## Constructor: botInlineMessageMediaVenue
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|geo|[GeoPoint](../types/GeoPoint.md) | Required|
|title|[string](../types/string.md) | Required|
|address|[string](../types/string.md) | Required|
|provider|[string](../types/string.md) | Required|
|venue\_id|[string](../types/string.md) | Required|
|reply\_markup|[ReplyMarkup](../types/ReplyMarkup.md) | Optional|
### Type: [BotInlineMessage](../types/BotInlineMessage.md)
### Example:
```
$botInlineMessageMediaVenue = ['geo' => GeoPoint, 'title' => string, 'address' => string, 'provider' => string, 'venue_id' => string, 'reply_markup' => ReplyMarkup, ];
```

View File

@ -0,0 +1,20 @@
## Constructor: botInlineMessageText
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|no\_webpage|[Bool](../types/Bool.md) | Optional|
|message|[string](../types/string.md) | Required|
|entities|Array of [MessageEntity](../types/MessageEntity.md) | Optional|
|reply\_markup|[ReplyMarkup](../types/ReplyMarkup.md) | Optional|
### Type: [BotInlineMessage](../types/BotInlineMessage.md)
### Example:
```
$botInlineMessageText = ['no_webpage' => Bool, 'message' => string, 'entities' => [MessageEntity], 'reply_markup' => ReplyMarkup, ];
```

View File

@ -0,0 +1,28 @@
## Constructor: botInlineResult
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[string](../types/string.md) | Required|
|type|[string](../types/string.md) | Required|
|title|[string](../types/string.md) | Optional|
|description|[string](../types/string.md) | Optional|
|url|[string](../types/string.md) | Optional|
|thumb\_url|[string](../types/string.md) | Optional|
|content\_url|[string](../types/string.md) | Optional|
|content\_type|[string](../types/string.md) | Optional|
|w|[int](../types/int.md) | Optional|
|h|[int](../types/int.md) | Optional|
|duration|[int](../types/int.md) | Optional|
|send\_message|[BotInlineMessage](../types/BotInlineMessage.md) | Required|
### Type: [BotInlineResult](../types/BotInlineResult.md)
### Example:
```
$botInlineResult = ['id' => string, 'type' => string, 'title' => string, 'description' => string, 'url' => string, 'thumb_url' => string, 'content_url' => string, 'content_type' => string, 'w' => int, 'h' => int, 'duration' => int, 'send_message' => BotInlineMessage, ];
```

View File

@ -0,0 +1,36 @@
## Constructor: channel
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|creator|[Bool](../types/Bool.md) | Optional|
|kicked|[Bool](../types/Bool.md) | Optional|
|left|[Bool](../types/Bool.md) | Optional|
|editor|[Bool](../types/Bool.md) | Optional|
|moderator|[Bool](../types/Bool.md) | Optional|
|broadcast|[Bool](../types/Bool.md) | Optional|
|verified|[Bool](../types/Bool.md) | Optional|
|megagroup|[Bool](../types/Bool.md) | Optional|
|restricted|[Bool](../types/Bool.md) | Optional|
|democracy|[Bool](../types/Bool.md) | Optional|
|signatures|[Bool](../types/Bool.md) | Optional|
|min|[Bool](../types/Bool.md) | Optional|
|id|[int](../types/int.md) | Required|
|access\_hash|[long](../types/long.md) | Optional|
|title|[string](../types/string.md) | Required|
|username|[string](../types/string.md) | Optional|
|photo|[ChatPhoto](../types/ChatPhoto.md) | Required|
|date|[int](../types/int.md) | Required|
|version|[int](../types/int.md) | Required|
|restriction\_reason|[string](../types/string.md) | Optional|
### Type: [Chat](../types/Chat.md)
### Example:
```
$channel = ['creator' => Bool, 'kicked' => Bool, 'left' => Bool, 'editor' => Bool, 'moderator' => Bool, 'broadcast' => Bool, 'verified' => Bool, 'megagroup' => Bool, 'restricted' => Bool, 'democracy' => Bool, 'signatures' => Bool, 'min' => Bool, 'id' => int, 'access_hash' => long, 'title' => string, 'username' => string, 'photo' => ChatPhoto, 'date' => int, 'version' => int, 'restriction_reason' => string, ];
```

View File

@ -0,0 +1,21 @@
## Constructor: channelForbidden
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|broadcast|[Bool](../types/Bool.md) | Optional|
|megagroup|[Bool](../types/Bool.md) | Optional|
|id|[int](../types/int.md) | Required|
|access\_hash|[long](../types/long.md) | Required|
|title|[string](../types/string.md) | Required|
### Type: [Chat](../types/Chat.md)
### Example:
```
$channelForbidden = ['broadcast' => Bool, 'megagroup' => Bool, 'id' => int, 'access_hash' => long, 'title' => string, ];
```

View File

@ -0,0 +1,33 @@
## Constructor: channelFull
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|can\_view\_participants|[Bool](../types/Bool.md) | Optional|
|can\_set\_username|[Bool](../types/Bool.md) | Optional|
|id|[int](../types/int.md) | Required|
|about|[string](../types/string.md) | Required|
|participants\_count|[int](../types/int.md) | Optional|
|admins\_count|[int](../types/int.md) | Optional|
|kicked\_count|[int](../types/int.md) | Optional|
|read\_inbox\_max\_id|[int](../types/int.md) | Required|
|read\_outbox\_max\_id|[int](../types/int.md) | Required|
|unread\_count|[int](../types/int.md) | Required|
|chat\_photo|[Photo](../types/Photo.md) | Required|
|notify\_settings|[PeerNotifySettings](../types/PeerNotifySettings.md) | Required|
|exported\_invite|[ExportedChatInvite](../types/ExportedChatInvite.md) | Required|
|bot\_info|Array of [BotInfo](../types/BotInfo.md) | Required|
|migrated\_from\_chat\_id|[int](../types/int.md) | Optional|
|migrated\_from\_max\_id|[int](../types/int.md) | Optional|
|pinned\_msg\_id|[int](../types/int.md) | Optional|
### Type: [ChatFull](../types/ChatFull.md)
### Example:
```
$channelFull = ['can_view_participants' => Bool, 'can_set_username' => Bool, 'id' => int, 'about' => string, 'participants_count' => int, 'admins_count' => int, 'kicked_count' => int, 'read_inbox_max_id' => int, 'read_outbox_max_id' => int, 'unread_count' => int, 'chat_photo' => Photo, 'notify_settings' => PeerNotifySettings, 'exported_invite' => ExportedChatInvite, 'bot_info' => [BotInfo], 'migrated_from_chat_id' => int, 'migrated_from_max_id' => int, 'pinned_msg_id' => int, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: channelMessagesFilter
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|exclude\_new\_messages|[Bool](../types/Bool.md) | Optional|
|ranges|Array of [MessageRange](../types/MessageRange.md) | Required|
### Type: [ChannelMessagesFilter](../types/ChannelMessagesFilter.md)
### Example:
```
$channelMessagesFilter = ['exclude_new_messages' => Bool, 'ranges' => [MessageRange], ];
```

View File

@ -0,0 +1,16 @@
## Constructor: channelMessagesFilterEmpty
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelMessagesFilter](../types/ChannelMessagesFilter.md)
### Example:
```
$channelMessagesFilterEmpty = ;
```

View File

@ -0,0 +1,18 @@
## Constructor: channelParticipant
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChannelParticipant](../types/ChannelParticipant.md)
### Example:
```
$channelParticipant = ['user_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: channelParticipantCreator
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
### Type: [ChannelParticipant](../types/ChannelParticipant.md)
### Example:
```
$channelParticipantCreator = ['user_id' => int, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: channelParticipantEditor
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|inviter\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChannelParticipant](../types/ChannelParticipant.md)
### Example:
```
$channelParticipantEditor = ['user_id' => int, 'inviter_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: channelParticipantKicked
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|kicked\_by|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChannelParticipant](../types/ChannelParticipant.md)
### Example:
```
$channelParticipantKicked = ['user_id' => int, 'kicked_by' => int, 'date' => int, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: channelParticipantModerator
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|inviter\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChannelParticipant](../types/ChannelParticipant.md)
### Example:
```
$channelParticipantModerator = ['user_id' => int, 'inviter_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: channelParticipantSelf
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|inviter\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChannelParticipant](../types/ChannelParticipant.md)
### Example:
```
$channelParticipantSelf = ['user_id' => int, 'inviter_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: channelParticipantsAdmins
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantsFilter](../types/ChannelParticipantsFilter.md)
### Example:
```
$channelParticipantsAdmins = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: channelParticipantsBots
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantsFilter](../types/ChannelParticipantsFilter.md)
### Example:
```
$channelParticipantsBots = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: channelParticipantsKicked
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantsFilter](../types/ChannelParticipantsFilter.md)
### Example:
```
$channelParticipantsKicked = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: channelParticipantsRecent
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantsFilter](../types/ChannelParticipantsFilter.md)
### Example:
```
$channelParticipantsRecent = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: channelRoleEditor
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantRole](../types/ChannelParticipantRole.md)
### Example:
```
$channelRoleEditor = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: channelRoleEmpty
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantRole](../types/ChannelParticipantRole.md)
### Example:
```
$channelRoleEmpty = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: channelRoleModerator
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChannelParticipantRole](../types/ChannelParticipantRole.md)
### Example:
```
$channelRoleModerator = ;
```

View File

@ -0,0 +1,18 @@
## Constructor: channels\_channelParticipant
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|participant|[ChannelParticipant](../types/ChannelParticipant.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [channels\_ChannelParticipant](../types/channels\_ChannelParticipant.md)
### Example:
```
$channels_channelParticipant = ['participant' => ChannelParticipant, 'users' => [User], ];
```

View File

@ -0,0 +1,19 @@
## Constructor: channels\_channelParticipants
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|count|[int](../types/int.md) | Required|
|participants|Array of [ChannelParticipant](../types/ChannelParticipant.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [channels\_ChannelParticipants](../types/channels\_ChannelParticipants.md)
### Example:
```
$channels_channelParticipants = ['count' => int, 'participants' => [ChannelParticipant], 'users' => [User], ];
```

View File

@ -0,0 +1,29 @@
## Constructor: chat
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|creator|[Bool](../types/Bool.md) | Optional|
|kicked|[Bool](../types/Bool.md) | Optional|
|left|[Bool](../types/Bool.md) | Optional|
|admins\_enabled|[Bool](../types/Bool.md) | Optional|
|admin|[Bool](../types/Bool.md) | Optional|
|deactivated|[Bool](../types/Bool.md) | Optional|
|id|[int](../types/int.md) | Required|
|title|[string](../types/string.md) | Required|
|photo|[ChatPhoto](../types/ChatPhoto.md) | Required|
|participants\_count|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
|version|[int](../types/int.md) | Required|
|migrated\_to|[InputChannel](../types/InputChannel.md) | Optional|
### Type: [Chat](../types/Chat.md)
### Example:
```
$chat = ['creator' => Bool, 'kicked' => Bool, 'left' => Bool, 'admins_enabled' => Bool, 'admin' => Bool, 'deactivated' => Bool, 'id' => int, 'title' => string, 'photo' => ChatPhoto, 'participants_count' => int, 'date' => int, 'version' => int, 'migrated_to' => InputChannel, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: chatEmpty
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[int](../types/int.md) | Required|
### Type: [Chat](../types/Chat.md)
### Example:
```
$chatEmpty = ['id' => int, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: chatForbidden
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[int](../types/int.md) | Required|
|title|[string](../types/string.md) | Required|
### Type: [Chat](../types/Chat.md)
### Example:
```
$chatForbidden = ['id' => int, 'title' => string, ];
```

View File

@ -0,0 +1,22 @@
## Constructor: chatFull
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[int](../types/int.md) | Required|
|participants|[ChatParticipants](../types/ChatParticipants.md) | Required|
|chat\_photo|[Photo](../types/Photo.md) | Required|
|notify\_settings|[PeerNotifySettings](../types/PeerNotifySettings.md) | Required|
|exported\_invite|[ExportedChatInvite](../types/ExportedChatInvite.md) | Required|
|bot\_info|Array of [BotInfo](../types/BotInfo.md) | Required|
### Type: [ChatFull](../types/ChatFull.md)
### Example:
```
$chatFull = ['id' => int, 'participants' => ChatParticipants, 'chat_photo' => Photo, 'notify_settings' => PeerNotifySettings, 'exported_invite' => ExportedChatInvite, 'bot_info' => [BotInfo], ];
```

View File

@ -0,0 +1,24 @@
## Constructor: chatInvite
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|channel|[Bool](../types/Bool.md) | Optional|
|broadcast|[Bool](../types/Bool.md) | Optional|
|public|[Bool](../types/Bool.md) | Optional|
|megagroup|[Bool](../types/Bool.md) | Optional|
|title|[string](../types/string.md) | Required|
|photo|[ChatPhoto](../types/ChatPhoto.md) | Required|
|participants\_count|[int](../types/int.md) | Required|
|participants|Array of [User](../types/User.md) | Optional|
### Type: [ChatInvite](../types/ChatInvite.md)
### Example:
```
$chatInvite = ['channel' => Bool, 'broadcast' => Bool, 'public' => Bool, 'megagroup' => Bool, 'title' => string, 'photo' => ChatPhoto, 'participants_count' => int, 'participants' => [User], ];
```

View File

@ -0,0 +1,17 @@
## Constructor: chatInviteAlready
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|chat|[Chat](../types/Chat.md) | Required|
### Type: [ChatInvite](../types/ChatInvite.md)
### Example:
```
$chatInviteAlready = ['chat' => Chat, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: chatInviteEmpty
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ExportedChatInvite](../types/ExportedChatInvite.md)
### Example:
```
$chatInviteEmpty = ;
```

View File

@ -0,0 +1,17 @@
## Constructor: chatInviteExported
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|link|[string](../types/string.md) | Required|
### Type: [ExportedChatInvite](../types/ExportedChatInvite.md)
### Example:
```
$chatInviteExported = ['link' => string, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: chatParticipant
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|inviter\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChatParticipant](../types/ChatParticipant.md)
### Example:
```
$chatParticipant = ['user_id' => int, 'inviter_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: chatParticipantAdmin
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|inviter\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ChatParticipant](../types/ChatParticipant.md)
### Example:
```
$chatParticipantAdmin = ['user_id' => int, 'inviter_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: chatParticipantCreator
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
### Type: [ChatParticipant](../types/ChatParticipant.md)
### Example:
```
$chatParticipantCreator = ['user_id' => int, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: chatParticipants
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|chat\_id|[int](../types/int.md) | Required|
|participants|Array of [ChatParticipant](../types/ChatParticipant.md) | Required|
|version|[int](../types/int.md) | Required|
### Type: [ChatParticipants](../types/ChatParticipants.md)
### Example:
```
$chatParticipants = ['chat_id' => int, 'participants' => [ChatParticipant], 'version' => int, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: chatParticipantsForbidden
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|chat\_id|[int](../types/int.md) | Required|
|self\_participant|[ChatParticipant](../types/ChatParticipant.md) | Optional|
### Type: [ChatParticipants](../types/ChatParticipants.md)
### Example:
```
$chatParticipantsForbidden = ['chat_id' => int, 'self_participant' => ChatParticipant, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: chatPhoto
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|photo\_small|[FileLocation](../types/FileLocation.md) | Required|
|photo\_big|[FileLocation](../types/FileLocation.md) | Required|
### Type: [ChatPhoto](../types/ChatPhoto.md)
### Example:
```
$chatPhoto = ['photo_small' => FileLocation, 'photo_big' => FileLocation, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: chatPhotoEmpty
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ChatPhoto](../types/ChatPhoto.md)
### Example:
```
$chatPhotoEmpty = ;
```

View File

@ -0,0 +1,39 @@
## Constructor: config
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|date|[int](../types/int.md) | Required|
|expires|[int](../types/int.md) | Required|
|test\_mode|[Bool](../types/Bool.md) | Required|
|this\_dc|[int](../types/int.md) | Required|
|dc\_options|Array of [DcOption](../types/DcOption.md) | Required|
|chat\_size\_max|[int](../types/int.md) | Required|
|megagroup\_size\_max|[int](../types/int.md) | Required|
|forwarded\_count\_max|[int](../types/int.md) | Required|
|online\_update\_period\_ms|[int](../types/int.md) | Required|
|offline\_blur\_timeout\_ms|[int](../types/int.md) | Required|
|offline\_idle\_timeout\_ms|[int](../types/int.md) | Required|
|online\_cloud\_timeout\_ms|[int](../types/int.md) | Required|
|notify\_cloud\_delay\_ms|[int](../types/int.md) | Required|
|notify\_default\_delay\_ms|[int](../types/int.md) | Required|
|chat\_big\_size|[int](../types/int.md) | Required|
|push\_chat\_period\_ms|[int](../types/int.md) | Required|
|push\_chat\_limit|[int](../types/int.md) | Required|
|saved\_gifs\_limit|[int](../types/int.md) | Required|
|edit\_time\_limit|[int](../types/int.md) | Required|
|rating\_e\_decay|[int](../types/int.md) | Required|
|stickers\_recent\_limit|[int](../types/int.md) | Required|
|tmp\_sessions|[int](../types/int.md) | Optional|
|disabled\_features|Array of [DisabledFeature](../types/DisabledFeature.md) | Required|
### Type: [Config](../types/Config.md)
### Example:
```
$config = ['date' => int, 'expires' => int, 'test_mode' => Bool, 'this_dc' => int, 'dc_options' => [DcOption], 'chat_size_max' => int, 'megagroup_size_max' => int, 'forwarded_count_max' => int, 'online_update_period_ms' => int, 'offline_blur_timeout_ms' => int, 'offline_idle_timeout_ms' => int, 'online_cloud_timeout_ms' => int, 'notify_cloud_delay_ms' => int, 'notify_default_delay_ms' => int, 'chat_big_size' => int, 'push_chat_period_ms' => int, 'push_chat_limit' => int, 'saved_gifs_limit' => int, 'edit_time_limit' => int, 'rating_e_decay' => int, 'stickers_recent_limit' => int, 'tmp_sessions' => int, 'disabled_features' => [DisabledFeature], ];
```

View File

@ -0,0 +1,18 @@
## Constructor: contact
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|mutual|[Bool](../types/Bool.md) | Required|
### Type: [Contact](../types/Contact.md)
### Example:
```
$contact = ['user_id' => int, 'mutual' => Bool, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: contactBlocked
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|date|[int](../types/int.md) | Required|
### Type: [ContactBlocked](../types/ContactBlocked.md)
### Example:
```
$contactBlocked = ['user_id' => int, 'date' => int, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: contactLinkContact
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ContactLink](../types/ContactLink.md)
### Example:
```
$contactLinkContact = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: contactLinkHasPhone
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ContactLink](../types/ContactLink.md)
### Example:
```
$contactLinkHasPhone = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: contactLinkNone
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ContactLink](../types/ContactLink.md)
### Example:
```
$contactLinkNone = ;
```

View File

@ -0,0 +1,16 @@
## Constructor: contactLinkUnknown
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [ContactLink](../types/ContactLink.md)
### Example:
```
$contactLinkUnknown = ;
```

View File

@ -0,0 +1,18 @@
## Constructor: contactStatus
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|user\_id|[int](../types/int.md) | Required|
|status|[UserStatus](../types/UserStatus.md) | Required|
### Type: [ContactStatus](../types/ContactStatus.md)
### Example:
```
$contactStatus = ['user_id' => int, 'status' => UserStatus, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: contacts\_blocked
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|blocked|Array of [ContactBlocked](../types/ContactBlocked.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_Blocked](../types/contacts\_Blocked.md)
### Example:
```
$contacts_blocked = ['blocked' => [ContactBlocked], 'users' => [User], ];
```

View File

@ -0,0 +1,19 @@
## Constructor: contacts\_blockedSlice
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|count|[int](../types/int.md) | Required|
|blocked|Array of [ContactBlocked](../types/ContactBlocked.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_Blocked](../types/contacts\_Blocked.md)
### Example:
```
$contacts_blockedSlice = ['count' => int, 'blocked' => [ContactBlocked], 'users' => [User], ];
```

View File

@ -0,0 +1,18 @@
## Constructor: contacts\_contacts
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|contacts|Array of [Contact](../types/Contact.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_Contacts](../types/contacts\_Contacts.md)
### Example:
```
$contacts_contacts = ['contacts' => [Contact], 'users' => [User], ];
```

View File

@ -0,0 +1,16 @@
## Constructor: contacts\_contactsNotModified
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [contacts\_Contacts](../types/contacts\_Contacts.md)
### Example:
```
$contacts_contactsNotModified = ;
```

View File

@ -0,0 +1,19 @@
## Constructor: contacts\_found
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|results|Array of [Peer](../types/Peer.md) | Required|
|chats|Array of [Chat](../types/Chat.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_Found](../types/contacts\_Found.md)
### Example:
```
$contacts_found = ['results' => [Peer], 'chats' => [Chat], 'users' => [User], ];
```

View File

@ -0,0 +1,19 @@
## Constructor: contacts\_importedContacts
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|imported|Array of [ImportedContact](../types/ImportedContact.md) | Required|
|retry\_contacts|Array of [long](../types/long.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_ImportedContacts](../types/contacts\_ImportedContacts.md)
### Example:
```
$contacts_importedContacts = ['imported' => [ImportedContact], 'retry_contacts' => [long], 'users' => [User], ];
```

View File

@ -0,0 +1,19 @@
## Constructor: contacts\_link
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|my\_link|[ContactLink](../types/ContactLink.md) | Required|
|foreign\_link|[ContactLink](../types/ContactLink.md) | Required|
|user|[User](../types/User.md) | Required|
### Type: [contacts\_Link](../types/contacts\_Link.md)
### Example:
```
$contacts_link = ['my_link' => ContactLink, 'foreign_link' => ContactLink, 'user' => User, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: contacts\_resolvedPeer
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|peer|[Peer](../types/Peer.md) | Required|
|chats|Array of [Chat](../types/Chat.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_ResolvedPeer](../types/contacts\_ResolvedPeer.md)
### Example:
```
$contacts_resolvedPeer = ['peer' => Peer, 'chats' => [Chat], 'users' => [User], ];
```

View File

@ -0,0 +1,19 @@
## Constructor: contacts\_topPeers
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|categories|Array of [TopPeerCategoryPeers](../types/TopPeerCategoryPeers.md) | Required|
|chats|Array of [Chat](../types/Chat.md) | Required|
|users|Array of [User](../types/User.md) | Required|
### Type: [contacts\_TopPeers](../types/contacts\_TopPeers.md)
### Example:
```
$contacts_topPeers = ['categories' => [TopPeerCategoryPeers], 'chats' => [Chat], 'users' => [User], ];
```

View File

@ -0,0 +1,16 @@
## Constructor: contacts\_topPeersNotModified
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [contacts\_TopPeers](../types/contacts\_TopPeers.md)
### Example:
```
$contacts_topPeersNotModified = ;
```

View File

@ -0,0 +1,22 @@
## Constructor: dcOption
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|ipv6|[Bool](../types/Bool.md) | Optional|
|media\_only|[Bool](../types/Bool.md) | Optional|
|tcpo\_only|[Bool](../types/Bool.md) | Optional|
|id|[int](../types/int.md) | Required|
|ip\_address|[string](../types/string.md) | Required|
|port|[int](../types/int.md) | Required|
### Type: [DcOption](../types/DcOption.md)
### Example:
```
$dcOption = ['ipv6' => Bool, 'media_only' => Bool, 'tcpo_only' => Bool, 'id' => int, 'ip_address' => string, 'port' => int, ];
```

View File

@ -0,0 +1,24 @@
## Constructor: dialog
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|peer|[Peer](../types/Peer.md) | Required|
|top\_message|[int](../types/int.md) | Required|
|read\_inbox\_max\_id|[int](../types/int.md) | Required|
|read\_outbox\_max\_id|[int](../types/int.md) | Required|
|unread\_count|[int](../types/int.md) | Required|
|notify\_settings|[PeerNotifySettings](../types/PeerNotifySettings.md) | Required|
|pts|[int](../types/int.md) | Optional|
|draft|[DraftMessage](../types/DraftMessage.md) | Optional|
### Type: [Dialog](../types/Dialog.md)
### Example:
```
$dialog = ['peer' => Peer, 'top_message' => int, 'read_inbox_max_id' => int, 'read_outbox_max_id' => int, 'unread_count' => int, 'notify_settings' => PeerNotifySettings, 'pts' => int, 'draft' => DraftMessage, ];
```

View File

@ -0,0 +1,18 @@
## Constructor: disabledFeature
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|feature|[string](../types/string.md) | Required|
|description|[string](../types/string.md) | Required|
### Type: [DisabledFeature](../types/DisabledFeature.md)
### Example:
```
$disabledFeature = ['feature' => string, 'description' => string, ];
```

View File

@ -0,0 +1,25 @@
## Constructor: document
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[long](../types/long.md) | Required|
|access\_hash|[long](../types/long.md) | Required|
|date|[int](../types/int.md) | Required|
|mime\_type|[string](../types/string.md) | Required|
|size|[int](../types/int.md) | Required|
|thumb|[PhotoSize](../types/PhotoSize.md) | Required|
|dc\_id|[int](../types/int.md) | Required|
|version|[int](../types/int.md) | Required|
|attributes|Array of [DocumentAttribute](../types/DocumentAttribute.md) | Required|
### Type: [Document](../types/Document.md)
### Example:
```
$document = ['id' => long, 'access_hash' => long, 'date' => int, 'mime_type' => string, 'size' => int, 'thumb' => PhotoSize, 'dc_id' => int, 'version' => int, 'attributes' => [DocumentAttribute], ];
```

View File

@ -0,0 +1,16 @@
## Constructor: documentAttributeAnimated
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeAnimated = ;
```

View File

@ -0,0 +1,21 @@
## Constructor: documentAttributeAudio
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|voice|[Bool](../types/Bool.md) | Optional|
|duration|[int](../types/int.md) | Required|
|title|[string](../types/string.md) | Optional|
|performer|[string](../types/string.md) | Optional|
|waveform|[bytes](../types/bytes.md) | Optional|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeAudio = ['voice' => Bool, 'duration' => int, 'title' => string, 'performer' => string, 'waveform' => bytes, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: documentAttributeFilename
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|file\_name|[string](../types/string.md) | Required|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeFilename = ['file_name' => string, ];
```

View File

@ -0,0 +1,16 @@
## Constructor: documentAttributeHasStickers
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeHasStickers = ;
```

View File

@ -0,0 +1,18 @@
## Constructor: documentAttributeImageSize
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|w|[int](../types/int.md) | Required|
|h|[int](../types/int.md) | Required|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeImageSize = ['w' => int, 'h' => int, ];
```

View File

@ -0,0 +1,20 @@
## Constructor: documentAttributeSticker
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|mask|[Bool](../types/Bool.md) | Optional|
|alt|[string](../types/string.md) | Required|
|stickerset|[InputStickerSet](../types/InputStickerSet.md) | Required|
|mask\_coords|[MaskCoords](../types/MaskCoords.md) | Optional|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeSticker = ['mask' => Bool, 'alt' => string, 'stickerset' => InputStickerSet, 'mask_coords' => MaskCoords, ];
```

View File

@ -0,0 +1,19 @@
## Constructor: documentAttributeVideo
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|duration|[int](../types/int.md) | Required|
|w|[int](../types/int.md) | Required|
|h|[int](../types/int.md) | Required|
### Type: [DocumentAttribute](../types/DocumentAttribute.md)
### Example:
```
$documentAttributeVideo = ['duration' => int, 'w' => int, 'h' => int, ];
```

View File

@ -0,0 +1,17 @@
## Constructor: documentEmpty
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|id|[long](../types/long.md) | Required|
### Type: [Document](../types/Document.md)
### Example:
```
$documentEmpty = ['id' => long, ];
```

View File

@ -0,0 +1,21 @@
## Constructor: draftMessage
### Attributes:
| Name | Type | Required |
|----------|:-------------:|---------:|
|no\_webpage|[Bool](../types/Bool.md) | Optional|
|reply\_to\_msg\_id|[int](../types/int.md) | Optional|
|message|[string](../types/string.md) | Required|
|entities|Array of [MessageEntity](../types/MessageEntity.md) | Optional|
|date|[int](../types/int.md) | Required|
### Type: [DraftMessage](../types/DraftMessage.md)
### Example:
```
$draftMessage = ['no_webpage' => Bool, 'reply_to_msg_id' => int, 'message' => string, 'entities' => [MessageEntity], 'date' => int, ];
```

Some files were not shown because too many files have changed in this diff Show More