mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2025-09-15 21:29:25 +00:00
add choose_sticker
This commit is contained in:
@@ -36,6 +36,7 @@ object BotActionSerializer: KSerializer<BotAction> {
|
||||
FindLocationAction.actionName -> FindLocationAction
|
||||
RecordVideoNoteAction.actionName -> RecordVideoNoteAction
|
||||
UploadVideoNoteAction.actionName -> UploadVideoNoteAction
|
||||
ChooseStickerAction.actionName -> ChooseStickerAction
|
||||
else -> CustomBotAction(actionName)
|
||||
}
|
||||
}
|
||||
@@ -151,6 +152,17 @@ inline val uploadVideoNote
|
||||
get() = UploadVideoNoteAction
|
||||
inline fun BotAction.asUploadVideoNote() = this as? UploadVideoNoteAction
|
||||
|
||||
/**
|
||||
* Will notify user that bot is uploading video note
|
||||
*/
|
||||
@Serializable(BotActionSerializer::class)
|
||||
object ChooseStickerAction : BotAction {
|
||||
override val actionName: String = "choose_sticker"
|
||||
}
|
||||
inline val chooseSticker
|
||||
get() = ChooseStickerAction
|
||||
inline fun BotAction.asChooseStickerAction() = this as? ChooseStickerAction
|
||||
|
||||
@Serializable(BotActionSerializer::class)
|
||||
@Warning("Use this action only in case you are pretty sure that there are no other action for your needs")
|
||||
class CustomBotAction @RiskFeature("Usage of this action may lead to errors") constructor(
|
||||
|
Reference in New Issue
Block a user