diff --git a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/Common.kt b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/Common.kt index c4aff3be86..776e6580b6 100644 --- a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/Common.kt +++ b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/Common.kt @@ -191,6 +191,7 @@ const val customEmojiStickerSetNameField = "custom_emoji_sticker_set_name" const val iconCustomEmojiIdField = "icon_custom_emoji_id" const val hasMainWebAppField = "has_main_web_app" const val hasTopicsEnabledField = "has_topics_enabled" +const val allowUsersToCreateTopicsField = "allows_users_to_create_topics" const val canJoinGroupsField = "can_join_groups" const val canReadAllGroupMessagesField = "can_read_all_group_messages" const val canReplyField = "can_reply" diff --git a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Extended.kt b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Extended.kt index 499dd11d97..3f9b289a7d 100644 --- a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Extended.kt +++ b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Extended.kt @@ -506,6 +506,8 @@ data class ExtendedBot( val hasMainWebApp: Boolean = false, @SerialName(hasTopicsEnabledField) val hasTopicsEnabled: Boolean = false, + @SerialName(allowUsersToCreateTopicsField) + val allowUsersToCreateTopics: Boolean = false, @SerialName(acceptedGiftTypesField) override val acceptedGiftTypes: AcceptedGiftTypes = AcceptedGiftTypes(), ) : Bot(), ExtendedChat { diff --git a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Impls.kt b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Impls.kt index c541dd07f3..371348936a 100644 --- a/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Impls.kt +++ b/tgbotapi.core/src/commonMain/kotlin/dev/inmo/tgbotapi/types/chat/Impls.kt @@ -143,8 +143,6 @@ data class CommonBot( @Suppress("SERIALIZER_TYPE_INCOMPATIBLE") @SerialName(usernameField) override val username: Username? = null, - @SerialName(hasTopicsEnabledField) - val hasTopicsEnabled: Boolean = false, ) : PreviewBot() { @SerialName(isBotField) private val isBot = true