Add 'GetUserProfilePhotos' method support

This commit is contained in:
netkas 2024-11-05 19:19:14 -05:00
parent ee2dff1e31
commit 44260ccaee
2 changed files with 43 additions and 0 deletions

View file

@ -0,0 +1,40 @@
<?php
namespace TgBotLib\Methods;
use TgBotLib\Abstracts\Method;
use TgBotLib\Bot;
use TgBotLib\Enums\Methods;
use TgBotLib\Objects\UserProfilePhotos;
class GetUserProfilePhotos extends Method
{
/**
* @inheritDoc
*/
public static function execute(Bot $bot, array $parameters = []): UserProfilePhotos
{
return $bot->sendRequest(Methods::GET_USER_PROFILE_PHOTOS->value, $parameters);
}
/**
* @inheritDoc
*/
public static function getRequiredParameters(): ?array
{
return [
'user_id'
];
}
/**
* @inheritDoc
*/
public static function getOptionalParameters(): ?array
{
return [
'offset',
'limit'
];
}
}