mirror of
https://github.com/danog/MadelineProtoDocs.git
synced 2024-12-11 00:30:26 +01:00
1.8 KiB
1.8 KiB
title | description | grand_parent | parent | image | redirect_from |
---|---|---|---|---|---|
auth.bindTempAuthKey | You cannot use this method directly, instead modify the PFS and default_temp_auth_key_expires_in settings, see https://docs.madelineproto.xyz/docs/SETTINGS.html for more info | Telegram RPC API | Methods | https://docs.madelineproto.xyz/favicons/android-chrome-256x256.png | /API_docs/methods/auth_bindTempAuthKey.html |
Method: auth.bindTempAuthKey
You cannot use this method directly, instead modify the PFS and default_temp_auth_key_expires_in settings, see https://docs.madelineproto.xyz/docs/SETTINGS.html for more info
Parameters:
Name | Type | Description | Required |
---|---|---|---|
perm_auth_key_id | long | Permanent auth_key_id to bind to | Yes |
nonce | long | Random long from Binding message contents | Yes |
expires_at | int | Unix timestamp to invalidate temporary key, see Binding message contents | Optional |
encrypted_message | bytes | See Generating encrypted_message | Yes |
Return type: Bool
Can bots use this method: YES
MadelineProto Example (now async for huge speed and parallelism!):
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->auth->bindTempAuthKey(perm_auth_key_id: $long, nonce: $long, expires_at: $int, encrypted_message: 'bytes', );