tgbotlib/src/TgBotLib/Methods/GetMe.php
2024-10-02 00:18:12 -04:00

19 lines
No EOL
389 B
PHP

<?php
namespace TgBotLib\Methods;
use TgBotLib\Abstracts\Method;
use TgBotLib\Bot;
use TgBotLib\Enums\Methods;
use TgBotLib\Objects\User;
class GetMe extends Method
{
/**
* @inheritDoc
*/
public static function execute(Bot $bot, array $parameters=[]): User
{
return User::fromArray(self::executeCurl(self::buildPost($bot, Methods::GET_ME->value)));
}
}