mirror of
https://github.com/danog/MadelineProto.git
synced 2024-12-14 04:07:20 +01:00
1.1 KiB
1.1 KiB
title | description |
---|---|
get_full_info | get_full_info parameters, return type and example |
Method: get_full_info
Parameters:
Name | Type |
---|---|
id | A username, a bot API chat id, a tg-cli chat id, a Chat, a User, an InputPeer, an InputUser, an InputChannel, a Peer, or a Chat object |
Return type: FullInfo
Example:
$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);
}
$Chat = $MadelineProto->get_full_info($id);
Or, if you're into Lua:
Chat = get_full_info(id)