From 50d6ddd152e02435cdfb1068d2340203448e15d6 Mon Sep 17 00:00:00 2001 From: netkas Date: Wed, 13 Nov 2024 15:46:17 -0500 Subject: [PATCH] Add GetMyShortDescription --- src/TgBotLib/Enums/Methods.php | 3 ++ .../Methods/GetMyShortDescription.php | 38 +++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 src/TgBotLib/Methods/GetMyShortDescription.php diff --git a/src/TgBotLib/Enums/Methods.php b/src/TgBotLib/Enums/Methods.php index e15bf45..3a65e77 100644 --- a/src/TgBotLib/Enums/Methods.php +++ b/src/TgBotLib/Enums/Methods.php @@ -41,6 +41,7 @@ use TgBotLib\Methods\GetMyCommands; use TgBotLib\Methods\GetMyDescription; use TgBotLib\Methods\GetMyName; + use TgBotLib\Methods\GetMyShortDescription; use TgBotLib\Methods\GetUpdates; use TgBotLib\Methods\GetUserChatBoosts; use TgBotLib\Methods\GetUserProfilePhotos; @@ -176,6 +177,7 @@ case SET_MY_DESCRIPTION = 'setMyDescription'; case GET_MY_DESCRIPTION = 'getMyDescription'; case SET_MY_SHORT_DESCRIPTION = 'setMyShortDescription'; + case GET_MY_SHORT_DESCRIPTION = 'getMyShortDescription'; /** * Executes a command on the provided bot with the given parameters. @@ -273,6 +275,7 @@ self::SET_MY_DESCRIPTION => SetMyDescription::execute($bot, $parameters), self::GET_MY_DESCRIPTION => GetMyDescription::execute($bot, $parameters), self::SET_MY_SHORT_DESCRIPTION => SetMyShortDescription::execute($bot, $parameters), + self::GET_MY_SHORT_DESCRIPTION => GetMyShortDescription::execute($bot, $parameters), }; } } diff --git a/src/TgBotLib/Methods/GetMyShortDescription.php b/src/TgBotLib/Methods/GetMyShortDescription.php new file mode 100644 index 0000000..532b311 --- /dev/null +++ b/src/TgBotLib/Methods/GetMyShortDescription.php @@ -0,0 +1,38 @@ +value, $parameters))); + } + + /** + * @inheritDoc + */ + public static function getRequiredParameters(): ?array + { + return null; + } + + /** + * @inheritDoc + */ + public static function getOptionalParameters(): ?array + { + return [ + 'language_code' + ]; + } + } \ No newline at end of file