Method: payments.getStarsStatus
Get the current Telegram Stars balance of the current account (with peer=inputPeerSelf), or the stars balance of the bot specified in peer
.
Parameters:
Name | Type | Description | Required |
---|---|---|---|
ton | Bool | Optional | |
peer | Username, chat ID, Update, Message or InputPeer | Peer of which to get the balance. | Optional |
Return type: payments.StarsStatus
Can userbots use this method: YES
Can bots use this method: NO
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();
$payments_StarsStatus = $MadelineProto->payments->getStarsStatus(ton: $Bool, peer: $InputPeer, );