1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2026-03-03 17:32:23 +00:00
This commit is contained in:
2026-02-15 13:53:41 +06:00
parent cea80ccee6
commit 44ce84cb84
10 changed files with 693 additions and 141 deletions

View File

@@ -347,10 +347,10 @@ public final class dev/inmo/tgbotapi/extensions/api/business/DeleteBusinessMessa
} }
public final class dev/inmo/tgbotapi/extensions/api/business/GetBusinessAccountGiftsKt { public final class dev/inmo/tgbotapi/extensions/api/business/GetBusinessAccountGiftsKt {
public static final fun getBusinessAccountGifts-LATcL_E (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/coroutines/Continuation;)Ljava/lang/Object; public static final fun getBusinessAccountGifts-ncRJlhg (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
public static synthetic fun getBusinessAccountGifts-LATcL_E$default (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/coroutines/Continuation;ILjava/lang/Object;)Ljava/lang/Object; public static synthetic fun getBusinessAccountGifts-ncRJlhg$default (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/coroutines/Continuation;ILjava/lang/Object;)Ljava/lang/Object;
public static final fun getBusinessAccountGiftsFlow-LATcL_E (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/jvm/functions/Function2;)Lkotlinx/coroutines/flow/Flow; public static final fun getBusinessAccountGiftsFlow-ncRJlhg (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/jvm/functions/Function2;)Lkotlinx/coroutines/flow/Flow;
public static synthetic fun getBusinessAccountGiftsFlow-LATcL_E$default (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/jvm/functions/Function2;ILjava/lang/Object;)Lkotlinx/coroutines/flow/Flow; public static synthetic fun getBusinessAccountGiftsFlow-ncRJlhg$default (Ldev/inmo/tgbotapi/bot/RequestsExecutor;Ljava/lang/String;ZZZZZZZZLjava/lang/String;Ljava/lang/Integer;Lkotlin/jvm/functions/Function2;ILjava/lang/Object;)Lkotlinx/coroutines/flow/Flow;
} }
public final class dev/inmo/tgbotapi/extensions/api/business/GetBusinessAccountStarBalanceKt { public final class dev/inmo/tgbotapi/extensions/api/business/GetBusinessAccountStarBalanceKt {

View File

@@ -14,8 +14,10 @@ public suspend fun TelegramBot.getBusinessAccountGifts(
excludeUnsaved: Boolean = false, excludeUnsaved: Boolean = false,
excludeSaved: Boolean = false, excludeSaved: Boolean = false,
excludeUnlimited: Boolean = false, excludeUnlimited: Boolean = false,
excludeLimited: Boolean = false, excludeLimitedUpgradable: Boolean = false,
excludeLimitedNonUpgradable: Boolean = false,
excludeUnique: Boolean = false, excludeUnique: Boolean = false,
excludeFromBlockchain: Boolean = false,
sortByPrice: Boolean = false, sortByPrice: Boolean = false,
offset: String? = null, offset: String? = null,
limit: Int? = null limit: Int? = null
@@ -25,8 +27,10 @@ public suspend fun TelegramBot.getBusinessAccountGifts(
excludeUnsaved, excludeUnsaved,
excludeSaved, excludeSaved,
excludeUnlimited, excludeUnlimited,
excludeLimited, excludeLimitedUpgradable,
excludeLimitedNonUpgradable,
excludeUnique, excludeUnique,
excludeFromBlockchain,
sortByPrice, sortByPrice,
offset, offset,
limit limit
@@ -43,8 +47,10 @@ public suspend fun TelegramBot.getBusinessAccountGifts(
* @param excludeUnsaved Whether to exclude unsaved gifts * @param excludeUnsaved Whether to exclude unsaved gifts
* @param excludeSaved Whether to exclude saved gifts * @param excludeSaved Whether to exclude saved gifts
* @param excludeUnlimited Whether to exclude unlimited gifts * @param excludeUnlimited Whether to exclude unlimited gifts
* @param excludeLimited Whether to exclude limited gifts * @param excludeLimitedUpgradable Whether to exclude limited upgradable gifts
* @param excludeLimitedNonUpgradable Whether to exclude limited non-upgradable gifts
* @param excludeUnique Whether to exclude unique gifts * @param excludeUnique Whether to exclude unique gifts
* @param excludeFromBlockchain Whether to exclude gifts from blockchain
* @param sortByPrice Whether to sort gifts by price * @param sortByPrice Whether to sort gifts by price
* @param initialOffset The initial offset to start fetching from. If null, starts from the beginning * @param initialOffset The initial offset to start fetching from. If null, starts from the beginning
* @param limit The maximum number of gifts to fetch per request * @param limit The maximum number of gifts to fetch per request
@@ -57,8 +63,10 @@ public fun TelegramBot.getBusinessAccountGiftsFlow(
excludeUnsaved: Boolean = false, excludeUnsaved: Boolean = false,
excludeSaved: Boolean = false, excludeSaved: Boolean = false,
excludeUnlimited: Boolean = false, excludeUnlimited: Boolean = false,
excludeLimited: Boolean = false, excludeLimitedUpgradable: Boolean = false,
excludeLimitedNonUpgradable: Boolean = false,
excludeUnique: Boolean = false, excludeUnique: Boolean = false,
excludeFromBlockchain: Boolean = false,
sortByPrice: Boolean = false, sortByPrice: Boolean = false,
initialOffset: String? = null, initialOffset: String? = null,
limit: Int? = null, limit: Int? = null,
@@ -72,8 +80,10 @@ public fun TelegramBot.getBusinessAccountGiftsFlow(
excludeUnsaved, excludeUnsaved,
excludeSaved, excludeSaved,
excludeUnlimited, excludeUnlimited,
excludeLimited, excludeLimitedUpgradable,
excludeLimitedNonUpgradable,
excludeUnique, excludeUnique,
excludeFromBlockchain,
sortByPrice, sortByPrice,
currentOffset, currentOffset,
limit limit

File diff suppressed because it is too large Load Diff

View File

@@ -8,7 +8,6 @@ import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
import dev.inmo.tgbotapi.types.excludeUnsavedField import dev.inmo.tgbotapi.types.excludeUnsavedField
import dev.inmo.tgbotapi.types.excludeSavedField import dev.inmo.tgbotapi.types.excludeSavedField
import dev.inmo.tgbotapi.types.excludeUnlimitedField import dev.inmo.tgbotapi.types.excludeUnlimitedField
import dev.inmo.tgbotapi.types.excludeLimitedField
import dev.inmo.tgbotapi.types.excludeLimitedUpgradableField import dev.inmo.tgbotapi.types.excludeLimitedUpgradableField
import dev.inmo.tgbotapi.types.excludeLimitedNonUpgradableField import dev.inmo.tgbotapi.types.excludeLimitedNonUpgradableField
import dev.inmo.tgbotapi.types.excludeUniqueField import dev.inmo.tgbotapi.types.excludeUniqueField
@@ -32,9 +31,6 @@ data class GetBusinessAccountGifts(
val excludeSaved: Boolean = false, val excludeSaved: Boolean = false,
@SerialName(excludeUnlimitedField) @SerialName(excludeUnlimitedField)
val excludeUnlimited: Boolean = false, val excludeUnlimited: Boolean = false,
@Deprecated("Use excludeLimitedUpgradable and excludeLimitedNonUpgradable instead")
@SerialName(excludeLimitedField)
val excludeLimited: Boolean = false,
@SerialName(excludeLimitedUpgradableField) @SerialName(excludeLimitedUpgradableField)
val excludeLimitedUpgradable: Boolean = false, val excludeLimitedUpgradable: Boolean = false,
@SerialName(excludeLimitedNonUpgradableField) @SerialName(excludeLimitedNonUpgradableField)

View File

@@ -656,6 +656,7 @@ const val mediaField = "media"
const val mainFrameTimestampField = "main_frame_timestamp" const val mainFrameTimestampField = "main_frame_timestamp"
const val paidMessageStarCountField = "paid_message_star_count" const val paidMessageStarCountField = "paid_message_star_count"
const val countField = "count"
const val ratingField = "rating" const val ratingField = "rating"
const val uniqueGiftColorsField = "unique_gift_colors" const val uniqueGiftColorsField = "unique_gift_colors"
const val paidStarCountField = "paid_star_count" const val paidStarCountField = "paid_star_count"
@@ -755,6 +756,12 @@ const val textColorField = "text_color"
const val nameColorField = "name_color" const val nameColorField = "name_color"
const val baseColorField = "base_color" const val baseColorField = "base_color"
const val linkColorField = "link_color" const val linkColorField = "link_color"
const val modelCustomEmojiIdField = "model_custom_emoji_id"
const val symbolCustomEmojiIdField = "symbol_custom_emoji_id"
const val lightThemeMainColorField = "light_theme_main_color"
const val lightThemeOtherColorsField = "light_theme_other_colors"
const val darkThemeMainColorField = "dark_theme_main_color"
const val darkThemeOtherColorsField = "dark_theme_other_colors"
const val baseNameField = "base_name" const val baseNameField = "base_name"
const val numberField = "number" const val numberField = "number"

View File

@@ -16,10 +16,11 @@ import kotlinx.serialization.encoding.Encoder
@Serializable(Gift.Companion::class) @Serializable(Gift.Companion::class)
sealed interface Gift { sealed interface Gift {
val id: GiftId?
val publisherChat: PreviewChat? val publisherChat: PreviewChat?
@Serializable(Regular.Companion::class) @Serializable(Regular.Companion::class)
sealed interface Regular : Gift { sealed interface Regular : Gift {
val id: GiftId override val id: GiftId
val sticker: Sticker val sticker: Sticker
val starCount: Int val starCount: Int
val totalCount: Int? val totalCount: Int?
@@ -175,7 +176,7 @@ sealed interface Gift {
@Serializable @Serializable
data class Unique( data class Unique(
@SerialName(giftIdField) @SerialName(giftIdField)
val id: GiftId? = null, override val id: GiftId? = null,
@SerialName(baseNameField) @SerialName(baseNameField)
val baseName: String, val baseName: String,
@SerialName(nameField) @SerialName(nameField)
@@ -195,7 +196,7 @@ sealed interface Gift {
@SerialName(isPremiumField2) @SerialName(isPremiumField2)
val isPremium: Boolean = false, val isPremium: Boolean = false,
@SerialName(colorsField) @SerialName(colorsField)
val colors: UniqueGiftColors = null val colors: UniqueGiftColors? = null
) : Gift ) : Gift
companion object : KSerializer<Gift> { companion object : KSerializer<Gift> {
@@ -257,7 +258,7 @@ sealed interface Gift {
value: Gift value: Gift
) { ) {
val surrogate = GiftSurrogate( val surrogate = GiftSurrogate(
id = (value as? Regular)?.id, id = value.id,
sticker = (value as? Regular)?.sticker, sticker = (value as? Regular)?.sticker,
star_count = (value as? Regular)?.starCount, star_count = (value as? Regular)?.starCount,
total_count = (value as? Regular.Limited)?.totalCount, total_count = (value as? Regular.Limited)?.totalCount,
@@ -275,7 +276,6 @@ sealed interface Gift {
model = (value as? Unique)?.model, model = (value as? Unique)?.model,
symbol = (value as? Unique)?.symbol, symbol = (value as? Unique)?.symbol,
backdrop = (value as? Unique)?.backdrop, backdrop = (value as? Unique)?.backdrop,
gift_id = (value as? Unique)?.id,
is_from_blockchain = (value as? Unique)?.isFromBlockchain ?: false, is_from_blockchain = (value as? Unique)?.isFromBlockchain ?: false,
colors = (value as? Unique)?.colors, colors = (value as? Unique)?.colors,
publisher_chat = value.publisherChat, publisher_chat = value.publisherChat,

View File

@@ -1,13 +1,19 @@
package dev.inmo.tgbotapi.types.gifts package dev.inmo.tgbotapi.types.gifts
import dev.inmo.tgbotapi.types.backgroundField import dev.inmo.tgbotapi.types.centerColorField
import dev.inmo.tgbotapi.types.files.PathedFile import dev.inmo.tgbotapi.types.edgeColorField
import dev.inmo.tgbotapi.types.textColorField
import dev.inmo.tgbotapi.utils.RGBColor
import kotlinx.serialization.SerialName import kotlinx.serialization.SerialName
import kotlinx.serialization.Serializable import kotlinx.serialization.Serializable
@Serializable @Serializable
data class GiftBackground( data class GiftBackground(
@SerialName(backgroundField) @SerialName(centerColorField)
val background: PathedFile val centerColor: RGBColor,
@SerialName(edgeColorField)
val edgeColor: RGBColor,
@SerialName(textColorField)
val textColor: RGBColor
) )

View File

@@ -1,8 +1,6 @@
package dev.inmo.tgbotapi.types.gifts.unique package dev.inmo.tgbotapi.types.gifts.unique
import dev.inmo.tgbotapi.types.baseColorField import dev.inmo.tgbotapi.types.*
import dev.inmo.tgbotapi.types.linkColorField
import dev.inmo.tgbotapi.types.nameColorField
import dev.inmo.tgbotapi.utils.RGBColor import dev.inmo.tgbotapi.utils.RGBColor
import kotlinx.serialization.SerialName import kotlinx.serialization.SerialName
import kotlinx.serialization.Serializable import kotlinx.serialization.Serializable
@@ -10,10 +8,16 @@ import kotlinx.serialization.Serializable
@Serializable @Serializable
data class UniqueGiftColors( data class UniqueGiftColors(
@SerialName(nameColorField) @SerialName(modelCustomEmojiIdField)
val nameColor: RGBColor, val modelCustomEmojiId: CustomEmojiId,
@SerialName(baseColorField) @SerialName(symbolCustomEmojiIdField)
val baseColor: RGBColor, val symbolCustomEmojiId: CustomEmojiId,
@SerialName(linkColorField) @SerialName(lightThemeMainColorField)
val linkColor: RGBColor val lightThemeMainColor: RGBColor,
@SerialName(lightThemeOtherColorsField)
val lightThemeOtherColors: List<RGBColor>,
@SerialName(darkThemeMainColorField)
val darkThemeMainColor: RGBColor,
@SerialName(darkThemeOtherColorsField)
val darkThemeOtherColors: List<RGBColor>
) )

View File

@@ -1991,6 +1991,8 @@ public final class dev/inmo/tgbotapi/extensions/utils/ClassCastsNewKt {
public static final fun ifPrivateEvent (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object; public static final fun ifPrivateEvent (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifPrivateEventMessage (Ldev/inmo/tgbotapi/types/message/abstracts/Message;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object; public static final fun ifPrivateEventMessage (Ldev/inmo/tgbotapi/types/message/abstracts/Message;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifPrivateForumChat (Ldev/inmo/tgbotapi/types/chat/Chat;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object; public static final fun ifPrivateForumChat (Ldev/inmo/tgbotapi/types/chat/Chat;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifPrivateForumContentMessage (Ldev/inmo/tgbotapi/abstracts/OptionallyWithUser;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifPrivateForumContentMessage (Ldev/inmo/tgbotapi/types/message/abstracts/Message;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifPrivateUserChat (Ldev/inmo/tgbotapi/types/chat/Chat;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object; public static final fun ifPrivateUserChat (Ldev/inmo/tgbotapi/types/chat/Chat;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifProximityAlertTriggered (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object; public static final fun ifProximityAlertTriggered (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
public static final fun ifPublicChat (Ldev/inmo/tgbotapi/types/chat/Chat;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object; public static final fun ifPublicChat (Ldev/inmo/tgbotapi/types/chat/Chat;Lkotlin/jvm/functions/Function1;)Ljava/lang/Object;
@@ -2513,6 +2515,10 @@ public final class dev/inmo/tgbotapi/extensions/utils/ClassCastsNewKt {
public static final fun privateEventOrThrow (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;)Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/PrivateEvent; public static final fun privateEventOrThrow (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;)Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/PrivateEvent;
public static final fun privateForumChatOrNull (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateForumChat; public static final fun privateForumChatOrNull (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateForumChat;
public static final fun privateForumChatOrThrow (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateForumChat; public static final fun privateForumChatOrThrow (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateForumChat;
public static final fun privateForumContentMessageOrNull (Ldev/inmo/tgbotapi/abstracts/OptionallyWithUser;)Ldev/inmo/tgbotapi/types/message/abstracts/PrivateForumContentMessage;
public static final fun privateForumContentMessageOrNull (Ldev/inmo/tgbotapi/types/message/abstracts/Message;)Ldev/inmo/tgbotapi/types/message/abstracts/PrivateForumContentMessage;
public static final fun privateForumContentMessageOrThrow (Ldev/inmo/tgbotapi/abstracts/OptionallyWithUser;)Ldev/inmo/tgbotapi/types/message/abstracts/PrivateForumContentMessage;
public static final fun privateForumContentMessageOrThrow (Ldev/inmo/tgbotapi/types/message/abstracts/Message;)Ldev/inmo/tgbotapi/types/message/abstracts/PrivateForumContentMessage;
public static final fun privateUserChatOrNull (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateUserChat; public static final fun privateUserChatOrNull (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateUserChat;
public static final fun privateUserChatOrThrow (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateUserChat; public static final fun privateUserChatOrThrow (Ldev/inmo/tgbotapi/types/chat/Chat;)Ldev/inmo/tgbotapi/types/chat/PrivateUserChat;
public static final fun proximityAlertTriggeredOrNull (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;)Ldev/inmo/tgbotapi/types/message/ChatEvents/ProximityAlertTriggered; public static final fun proximityAlertTriggeredOrNull (Ldev/inmo/tgbotapi/types/message/ChatEvents/abstracts/ChatEvent;)Ldev/inmo/tgbotapi/types/message/ChatEvents/ProximityAlertTriggered;

View File

@@ -344,6 +344,7 @@ import dev.inmo.tgbotapi.types.message.abstracts.PossiblyTopicMessage
import dev.inmo.tgbotapi.types.message.abstracts.PossiblyWithEffectMessage import dev.inmo.tgbotapi.types.message.abstracts.PossiblyWithEffectMessage
import dev.inmo.tgbotapi.types.message.abstracts.PotentiallyFromUserGroupContentMessage import dev.inmo.tgbotapi.types.message.abstracts.PotentiallyFromUserGroupContentMessage
import dev.inmo.tgbotapi.types.message.abstracts.PrivateContentMessage import dev.inmo.tgbotapi.types.message.abstracts.PrivateContentMessage
import dev.inmo.tgbotapi.types.message.abstracts.PrivateForumContentMessage
import dev.inmo.tgbotapi.types.message.abstracts.PublicContentMessage import dev.inmo.tgbotapi.types.message.abstracts.PublicContentMessage
import dev.inmo.tgbotapi.types.message.abstracts.SignedMessage import dev.inmo.tgbotapi.types.message.abstracts.SignedMessage
import dev.inmo.tgbotapi.types.message.abstracts.SuggestedChannelDirectMessagesContentMessage import dev.inmo.tgbotapi.types.message.abstracts.SuggestedChannelDirectMessagesContentMessage
@@ -801,6 +802,12 @@ public inline fun OptionallyWithUser.commonSuggestedChannelDirectMessagesContent
public inline fun <T> OptionallyWithUser.ifCommonSuggestedChannelDirectMessagesContentMessage(block: (CommonSuggestedChannelDirectMessagesContentMessage<MessageContent>) -> T): T? = commonSuggestedChannelDirectMessagesContentMessageOrNull() ?.let(block) public inline fun <T> OptionallyWithUser.ifCommonSuggestedChannelDirectMessagesContentMessage(block: (CommonSuggestedChannelDirectMessagesContentMessage<MessageContent>) -> T): T? = commonSuggestedChannelDirectMessagesContentMessageOrNull() ?.let(block)
public inline fun OptionallyWithUser.privateForumContentMessageOrNull(): PrivateForumContentMessage<MessageContent>? = this as? dev.inmo.tgbotapi.types.message.abstracts.PrivateForumContentMessage<dev.inmo.tgbotapi.types.message.content.MessageContent>
public inline fun OptionallyWithUser.privateForumContentMessageOrThrow(): PrivateForumContentMessage<MessageContent> = this as dev.inmo.tgbotapi.types.message.abstracts.PrivateForumContentMessage<dev.inmo.tgbotapi.types.message.content.MessageContent>
public inline fun <T> OptionallyWithUser.ifPrivateForumContentMessage(block: (PrivateForumContentMessage<MessageContent>) -> T): T? = privateForumContentMessageOrNull() ?.let(block)
public inline fun OptionallyWithUser.supergroupEventMessageOrNull(): SupergroupEventMessage<SupergroupEvent>? = this as? dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent> public inline fun OptionallyWithUser.supergroupEventMessageOrNull(): SupergroupEventMessage<SupergroupEvent>? = this as? dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent>
public inline fun OptionallyWithUser.supergroupEventMessageOrThrow(): SupergroupEventMessage<SupergroupEvent> = this as dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent> public inline fun OptionallyWithUser.supergroupEventMessageOrThrow(): SupergroupEventMessage<SupergroupEvent> = this as dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent>
@@ -2139,6 +2146,12 @@ public inline fun Message.chatEventMessageOrThrow(): ChatEventMessage<ChatEvent>
public inline fun <T> Message.ifChatEventMessage(block: (ChatEventMessage<ChatEvent>) -> T): T? = chatEventMessageOrNull() ?.let(block) public inline fun <T> Message.ifChatEventMessage(block: (ChatEventMessage<ChatEvent>) -> T): T? = chatEventMessageOrNull() ?.let(block)
public inline fun Message.privateForumContentMessageOrNull(): PrivateForumContentMessage<MessageContent>? = this as? dev.inmo.tgbotapi.types.message.abstracts.PrivateForumContentMessage<dev.inmo.tgbotapi.types.message.content.MessageContent>
public inline fun Message.privateForumContentMessageOrThrow(): PrivateForumContentMessage<MessageContent> = this as dev.inmo.tgbotapi.types.message.abstracts.PrivateForumContentMessage<dev.inmo.tgbotapi.types.message.content.MessageContent>
public inline fun <T> Message.ifPrivateForumContentMessage(block: (PrivateForumContentMessage<MessageContent>) -> T): T? = privateForumContentMessageOrNull() ?.let(block)
public inline fun Message.supergroupEventMessageOrNull(): SupergroupEventMessage<SupergroupEvent>? = this as? dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent> public inline fun Message.supergroupEventMessageOrNull(): SupergroupEventMessage<SupergroupEvent>? = this as? dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent>
public inline fun Message.supergroupEventMessageOrThrow(): SupergroupEventMessage<SupergroupEvent> = this as dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent> public inline fun Message.supergroupEventMessageOrThrow(): SupergroupEventMessage<SupergroupEvent> = this as dev.inmo.tgbotapi.types.message.abstracts.SupergroupEventMessage<dev.inmo.tgbotapi.types.message.ChatEvents.abstracts.SupergroupEvent>