Package-level declarations

Types

Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface AbleToAddInAttachmentMenuChat : Chat
Link copied to clipboard
@Serializable(with = UserSerializer::class)
sealed class Bot : User
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface BusinessChat : Chat
Link copied to clipboard
@Serializable
data class BusinessChatImpl(val id: BusinessChatId, val original: PreviewPrivateChat) : PreviewBusinessChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface ChannelChat : SuperPublicChat
Link copied to clipboard
@Serializable
data class ChannelChatImpl(val id: ChatId, val title: String, val username: Username? = null) : PreviewChannelChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface Chat
Link copied to clipboard
@Serializable
data class ChatBackground(val type: BackgroundType) : PublicChatEvent
Link copied to clipboard
@Serializable
data class ChatJoinRequest(val chat: PublicChat, val from: User, val userChatId: UserId, val date: TelegramDate, val inviteLink: ChatInviteLink? = null, val bio: String? = null) : FromUser

Represent a ChatJoinRequest

Link copied to clipboard
@Serializable
data class ChatMessageReactionsCountUpdated(val chat: PreviewChat, val messageId: MessageId, val date: TelegramDate, val reactions: List<ReactionsCount>) : WithPreviewChatAndMessageId
Link copied to clipboard
@Serializable(with = ChatPermissions.Companion::class)
interface ChatPermissions

Represents any type with common permissions list

Link copied to clipboard
object ChatSerializer : KSerializer<Chat>
Link copied to clipboard
@Serializable(with = ChatTypeSerializer::class)
sealed class ChatType
Link copied to clipboard
object ChatTypeSerializer : KSerializer<ChatType>
Link copied to clipboard
@Serializable
data class CommonBot(val id: UserId, val firstName: String, val lastName: String = "", val username: Username? = null) : PreviewBot
Link copied to clipboard
@Serializable
data class CommonUser(val id: UserId, val firstName: String, val lastName: String = "", val username: Username? = null, val ietfLanguageCode: IetfLang? = null, val isPremium: Boolean = false, val addedToAttachmentMenu: Boolean = false) : PreviewUser, WithOptionalLanguageCode, PossiblyPremiumChat, AbleToAddInAttachmentMenuChat
Link copied to clipboard
@Serializable
data class ExtendedBot(val id: UserId, val firstName: String, val lastName: String = "", val username: Username? = null, val canJoinGroups: Boolean = false, val canReadAllGroupMessages: Boolean = false, val supportsInlineQueries: Boolean = false, val canConnectToBusiness: Boolean = false, val chatPhoto: ChatPhoto? = null, val accentColorId: ColorId = ColorId(0), val profileAccentColorId: ColorId? = null, val backgroundCustomEmojiId: CustomEmojiId? = null, val profileBackgroundCustomEmojiId: CustomEmojiId? = null, val maxReactionsCount: Int = 3, val hasMainWebApp: Boolean = false) : Bot, ExtendedChat
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
@Serializable
data class ExtendedChannelChatImpl(val id: ChatId, val title: String, val username: Username? = null, val activeUsernames: List<Username> = emptyList(), val chatPhoto: ChatPhoto? = null, val description: String = "", val inviteLink: String? = null, val pinnedMessage: Message? = null, val canSendPaidMedia: Boolean = false, val linkedGroupChatId: IdChatIdentifier? = null, val membersHidden: Boolean = false, val availableReactions: List<Reaction>? = null, val statusEmojiId: CustomEmojiId? = null, val statusEmojiExpiration: TelegramDate? = null, val accentColorId: ColorId = ColorId(0), val profileAccentColorId: ColorId? = null, val backgroundCustomEmojiId: CustomEmojiId? = null, val profileBackgroundCustomEmojiId: CustomEmojiId? = null, val newMembersSeeHistory: Boolean = false, val maxReactionsCount: Int = 3) : ExtendedChannelChat
Link copied to clipboard
sealed interface ExtendedChat : Chat
Link copied to clipboard
sealed class ExtendedChatSerializer : KSerializer<ExtendedChat>
Link copied to clipboard
Link copied to clipboard
@Serializable
data class ExtendedForumChatImpl(val id: IdChatIdentifier, val title: String, val username: Username? = null, val activeUsernames: List<Username> = emptyList(), val chatPhoto: ChatPhoto? = null, val permissions: ChatPermissions, val description: String = "", val inviteLink: String? = null, val pinnedMessage: Message? = null, val stickerSetName: StickerSetName? = null, val slowModeDelay: Long? = null, val canSetStickerSet: Boolean = false, val linkedChannelChatId: IdChatIdentifier? = null, val location: ChatLocation? = null, val requiresJoinForMessaging: Boolean = false, val requireAdminApproveToJoin: Boolean = false, val isAggressiveAntiSpamEnabled: Boolean = false, val membersHidden: Boolean = false, val availableReactions: List<Reaction>? = null, val statusEmojiId: CustomEmojiId? = null, val statusEmojiExpiration: TelegramDate? = null, val accentColorId: ColorId = ColorId(0), val profileAccentColorId: ColorId? = null, val backgroundCustomEmojiId: CustomEmojiId? = null, val profileBackgroundCustomEmojiId: CustomEmojiId? = null, val newMembersSeeHistory: Boolean = false, val unrestrictBoostsCount: Int? = null, val customEmojiStickerSetName: StickerSetName? = null, val maxReactionsCount: Int = 3) : ExtendedForumChat
Link copied to clipboard
Link copied to clipboard
@Serializable
data class ExtendedGroupChatImpl(val id: ChatId, val title: String, val chatPhoto: ChatPhoto? = null, val permissions: ChatPermissions, val description: String = "", val inviteLink: String? = null, val pinnedMessage: Message? = null, val membersHidden: Boolean = false, val availableReactions: List<Reaction>? = null, val statusEmojiId: CustomEmojiId? = null, val statusEmojiExpiration: TelegramDate? = null, val accentColorId: ColorId = ColorId(0), val profileAccentColorId: ColorId? = null, val backgroundCustomEmojiId: CustomEmojiId? = null, val profileBackgroundCustomEmojiId: CustomEmojiId? = null, val newMembersSeeHistory: Boolean = false, val maxReactionsCount: Int = 3) : ExtendedGroupChat
Link copied to clipboard
Link copied to clipboard
@Serializable
data class ExtendedPrivateChatImpl(val id: UserId, val chatPhoto: ChatPhoto? = null, val username: Username? = null, val activeUsernames: List<Username> = emptyList(), val firstName: String = "", val lastName: String = "", val bio: String = "", val hasPrivateForwards: Boolean = false, val hasRestrictedVoiceAndVideoMessages: Boolean = false, val statusEmojiId: CustomEmojiId? = null, val statusEmojiExpiration: TelegramDate? = null, val accentColorId: ColorId = ColorId(0), val profileAccentColorId: ColorId? = null, val backgroundCustomEmojiId: CustomEmojiId? = null, val profileBackgroundCustomEmojiId: CustomEmojiId? = null, val businessIntro: BusinessIntro? = null, val businessLocation: BusinessLocation? = null, val businessOpeningHours: BusinessOpeningHours? = null, val birthdate: Birthdate? = null, val personalChat: PreviewChannelChat? = null, val maxReactionsCount: Int = 3) : ExtendedPrivateChat
Link copied to clipboard
Link copied to clipboard
@Serializable
data class ExtendedSupergroupChatImpl(val id: ChatId, val title: String, val username: Username? = null, val activeUsernames: List<Username> = emptyList(), val chatPhoto: ChatPhoto? = null, val permissions: ChatPermissions, val description: String = "", val inviteLink: String? = null, val pinnedMessage: Message? = null, val stickerSetName: StickerSetName? = null, val slowModeDelay: Long? = null, val canSetStickerSet: Boolean = false, val linkedChannelChatId: IdChatIdentifier? = null, val location: ChatLocation? = null, val requiresJoinForMessaging: Boolean = false, val requireAdminApproveToJoin: Boolean = false, val isAggressiveAntiSpamEnabled: Boolean = false, val membersHidden: Boolean = false, val availableReactions: List<Reaction>? = null, val statusEmojiId: CustomEmojiId? = null, val statusEmojiExpiration: TelegramDate? = null, val accentColorId: ColorId = ColorId(0), val profileAccentColorId: ColorId? = null, val backgroundCustomEmojiId: CustomEmojiId? = null, val profileBackgroundCustomEmojiId: CustomEmojiId? = null, val newMembersSeeHistory: Boolean = false, val unrestrictBoostsCount: Int? = null, val customEmojiStickerSetName: StickerSetName? = null, val maxReactionsCount: Int = 3) : ExtendedSupergroupChat
Link copied to clipboard
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface ForumChat : SupergroupChat
Link copied to clipboard
@Serializable
data class ForumChatImpl(val id: IdChatIdentifier, val title: String, val username: Username? = null) : PreviewForumChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface GroupChat : PublicChat
Link copied to clipboard
@Serializable
data class GroupChatImpl(val id: ChatId, val title: String) : PreviewGroupChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface PossiblyPremiumChat : Chat
Link copied to clipboard
@Serializable(with = UserSerializer::class)
sealed class PreviewBot : PreviewUser
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
@Serializable(with = PreviewChatSerializer::class)
sealed interface PreviewChat : Chat
Link copied to clipboard
object PreviewChatSerializer : KSerializer<PreviewChat>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
@Serializable(with = PreviewChatSerializer::class)
sealed interface PreviewPublicChat : PreviewChat, PublicChat
Link copied to clipboard
@Serializable(with = UserSerializer::class)
sealed class PreviewUser : User, PreviewPrivateChat
Link copied to clipboard
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface PrivateChat : Chat, UsernameChat
Link copied to clipboard
@Serializable
data class PrivateChatImpl(val id: UserId, val username: Username? = null, val firstName: String = "", val lastName: String = "") : PreviewPrivateChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface PublicChat : Chat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface SupergroupChat : GroupChat, SuperPublicChat
Link copied to clipboard
@Serializable
data class SupergroupChatImpl(val id: ChatId, val title: String, val username: Username? = null) : PreviewSupergroupChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface SuperPublicChat : PublicChat, UsernameChat
Link copied to clipboard
data class UnknownChatType(val id: IdChatIdentifier, val raw: String, val rawJson: JsonObject) : Chat, PreviewChat
Link copied to clipboard
data class UnknownExtendedChat(val id: IdChatIdentifier, val raw: String, val rawJson: JsonObject) : ExtendedChat
Link copied to clipboard
@Serializable(with = UserSerializer::class)
sealed class User : PrivateChat
Link copied to clipboard
@Serializable(with = ChatSerializer::class)
sealed interface UsernameChat : Chat
Link copied to clipboard
object UserSerializer : KSerializer<User>