Skip to content
This repository was archived by the owner on Sep 2, 2025. It is now read-only.

Commit 27aef19

Browse files
committed
Implements DeleteStickerFromSet
Fixes #43
1 parent ca56917 commit 27aef19

File tree

1 file changed

+39
-0
lines changed

1 file changed

+39
-0
lines changed
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<?php
2+
3+
declare(strict_types = 1);
4+
5+
namespace unreal4u\TelegramAPI\Telegram\Methods;
6+
7+
use Psr\Log\LoggerInterface;
8+
use unreal4u\TelegramAPI\Abstracts\TelegramMethods;
9+
use unreal4u\TelegramAPI\Abstracts\TelegramTypes;
10+
use unreal4u\TelegramAPI\InternalFunctionality\TelegramRawData;
11+
use unreal4u\TelegramAPI\Telegram\Types\Custom\ResultBoolean;
12+
13+
/**
14+
* Use this method to delete a sticker from a set created by the bot. Returns True on success
15+
*
16+
* Objects defined as-is july 2017
17+
*
18+
* @see https://core.telegram.org/bots/api#deletestickerfromset
19+
*/
20+
class DeleteStickerFromSet extends TelegramMethods
21+
{
22+
/**
23+
* File identifier of the sticker
24+
* @var string
25+
*/
26+
public $sticker = '';
27+
28+
public static function bindToObject(TelegramRawData $data, LoggerInterface $logger): TelegramTypes
29+
{
30+
return new ResultBoolean($data->getResultBoolean(), $logger);
31+
}
32+
33+
public function getMandatoryFields(): array
34+
{
35+
return [
36+
'sticker',
37+
];
38+
}
39+
}

0 commit comments

Comments
 (0)