1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2025-09-05 08:09:21 +00:00

ChatIdWithThreadId, all chats ids now value classes, update chats ids hierarchy

This commit is contained in:
2022-11-10 16:24:20 +06:00
parent 1ec4507891
commit 925c4dae6c
48 changed files with 445 additions and 457 deletions

View File

@@ -7,12 +7,13 @@ import dev.inmo.tgbotapi.types.MessageId
import dev.inmo.tgbotapi.types.MessageThreadId
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.message.abstracts.Message
import dev.inmo.tgbotapi.types.threadId
suspend fun TelegramBot.forwardMessage(
fromChatId: ChatIdentifier,
toChatId: ChatIdentifier,
messageId: MessageId,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false
) = execute(
@@ -23,7 +24,7 @@ suspend fun TelegramBot.forwardMessage(
fromChat: Chat,
toChatId: ChatIdentifier,
messageId: MessageId,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false
) = forwardMessage(fromChat.id, toChatId, messageId, threadId, disableNotification, protectContent)
@@ -32,7 +33,7 @@ suspend fun TelegramBot.forwardMessage(
fromChatId: ChatIdentifier,
toChat: Chat,
messageId: MessageId,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false
) = forwardMessage(fromChatId, toChat.id, messageId, threadId, disableNotification, protectContent)
@@ -41,7 +42,7 @@ suspend fun TelegramBot.forwardMessage(
fromChat: Chat,
toChat: Chat,
messageId: MessageId,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false
) = forwardMessage(fromChat.id, toChat.id, messageId, threadId, disableNotification, protectContent)
@@ -49,7 +50,7 @@ suspend fun TelegramBot.forwardMessage(
suspend fun TelegramBot.forwardMessage(
toChatId: ChatIdentifier,
message: Message,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false
) = forwardMessage(message.chat, toChatId, message.messageId, threadId, disableNotification, protectContent)
@@ -57,7 +58,7 @@ suspend fun TelegramBot.forwardMessage(
suspend fun TelegramBot.forwardMessage(
toChat: Chat,
message: Message,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false
) = forwardMessage(message.chat, toChat, message.messageId, threadId, disableNotification, protectContent)

View File

@@ -41,7 +41,7 @@ suspend fun TelegramBot.handleLiveLocation(
chatId: ChatIdentifier,
locationsFlow: Flow<EditLiveLocationInfo>,
liveTimeMillis: Long = defaultLivePeriodDelayMillis,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -98,7 +98,7 @@ suspend fun TelegramBot.handleLiveLocation(
chatId: ChatIdentifier,
locationsFlow: Flow<Location>,
liveTimeMillis: Long = defaultLivePeriodDelayMillis,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -135,7 +135,7 @@ suspend fun TelegramBot.handleLiveLocation(
chatId: ChatIdentifier,
locationsFlow: Flow<Pair<Double, Double>>,
liveTimeMillis: Long = defaultLivePeriodDelayMillis,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -15,6 +15,7 @@ import dev.inmo.tgbotapi.types.location.StaticLocation
import dev.inmo.tgbotapi.types.message.abstracts.ContentMessage
import dev.inmo.tgbotapi.types.message.abstracts.Message
import dev.inmo.tgbotapi.types.message.content.LocationContent
import dev.inmo.tgbotapi.utils.extensions.threadIdOrNull
import io.ktor.utils.io.core.Closeable
import kotlinx.coroutines.CoroutineScope
import kotlinx.coroutines.launch
@@ -90,7 +91,7 @@ suspend fun TelegramBot.startLiveLocation(
initHorizontalAccuracy: Meters? = null,
initHeading: Degrees? = null,
initProximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -137,7 +138,7 @@ suspend fun TelegramBot.startLiveLocation(
initHorizontalAccuracy: Meters? = null,
initHeading: Degrees? = null,
initProximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -172,7 +173,7 @@ suspend fun TelegramBot.startLiveLocation(
initHorizontalAccuracy: Meters? = null,
initHeading: Degrees? = null,
initProximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -207,7 +208,7 @@ suspend fun TelegramBot.startLiveLocation(
initHorizontalAccuracy: Meters? = null,
initHeading: Degrees? = null,
initProximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -243,7 +244,7 @@ suspend inline fun TelegramBot.replyWithLiveLocation(
initHorizontalAccuracy: Meters? = null,
initHeading: Degrees? = null,
initProximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = to.threadIdOrNull,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -277,7 +278,7 @@ suspend inline fun TelegramBot.replyWithLiveLocation(
initHorizontalAccuracy: Meters? = null,
initHeading: Degrees? = null,
initProximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = to.threadIdOrNull,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,

View File

@@ -10,6 +10,7 @@ import dev.inmo.tgbotapi.types.message.ParseMode
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.message.abstracts.Message
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -21,7 +22,7 @@ suspend inline fun TelegramBot.copyMessage(
toChatId: ChatIdentifier,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -53,7 +54,7 @@ suspend inline fun TelegramBot.copyMessage(
toChatId: ChatIdentifier,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -71,7 +72,7 @@ suspend inline fun TelegramBot.copyMessage(
toChat: Chat,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -89,7 +90,7 @@ suspend inline fun TelegramBot.copyMessage(
toChat: Chat,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -107,7 +108,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
toChatId: ChatIdentifier,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -137,7 +138,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
toChatId: ChatIdentifier,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -154,7 +155,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
toChat: Chat,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -171,7 +172,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
toChat: Chat,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -188,7 +189,7 @@ suspend inline fun TelegramBot.copyMessage(
message: Message,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -205,7 +206,7 @@ suspend inline fun TelegramBot.copyMessage(
message: Message,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -221,7 +222,7 @@ suspend inline fun TelegramBot.copyMessage(
toChatId: ChatIdentifier,
message: Message,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -237,7 +238,7 @@ suspend inline fun TelegramBot.copyMessage(
toChat: Chat,
message: Message,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -255,7 +256,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -287,7 +288,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -317,7 +318,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -347,7 +348,7 @@ suspend inline fun TelegramBot.copyMessage(
messageId: MessageId,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -377,7 +378,7 @@ suspend inline fun TelegramBot.copyMessage(
fromChatId: ChatIdentifier,
messageId: MessageId,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -407,7 +408,7 @@ suspend inline fun TelegramBot.copyMessage(
fromChat: Chat,
messageId: MessageId,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -435,7 +436,7 @@ suspend inline fun TelegramBot.copyMessage(
fromChatId: ChatIdentifier,
messageId: MessageId,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -463,7 +464,7 @@ suspend inline fun TelegramBot.copyMessage(
fromChat: Chat,
messageId: MessageId,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -47,7 +47,7 @@ suspend inline fun TelegramBot.reply(
phoneNumber: String,
firstName: String,
lastName: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -73,7 +73,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
contact: Contact,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -100,7 +100,7 @@ suspend inline fun TelegramBot.replyWithDice(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
animationType: DiceAnimationType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -115,7 +115,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
animationType: DiceAnimationType,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -134,7 +134,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -159,7 +159,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
location: StaticLocation,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -188,7 +188,7 @@ suspend inline fun TelegramBot.reply(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -215,7 +215,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -241,7 +241,7 @@ suspend fun TelegramBot.reply(
toMessageId: MessageId,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -258,7 +258,7 @@ suspend fun TelegramBot.reply(
toMessageId: MessageId,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -284,7 +284,7 @@ suspend inline fun TelegramBot.reply(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -317,7 +317,7 @@ suspend inline fun TelegramBot.reply(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -344,7 +344,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
venue: Venue,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -367,7 +367,7 @@ suspend inline fun TelegramBot.replyWithGame(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
gameShortName: String,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -380,7 +380,7 @@ suspend inline fun TelegramBot.replyWithGame(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
game: Game,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -393,7 +393,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
game: Game,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -413,7 +413,7 @@ suspend inline fun TelegramBot.replyWithAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -444,7 +444,7 @@ suspend inline fun TelegramBot.reply(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -460,7 +460,7 @@ suspend inline fun TelegramBot.replyWithAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -489,7 +489,7 @@ suspend inline fun TelegramBot.reply(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -509,7 +509,7 @@ suspend inline fun TelegramBot.replyWithAudio(
duration: Long? = null,
performer: String? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -523,7 +523,7 @@ suspend inline fun TelegramBot.reply(
text: String? = null,
parseMode: ParseMode? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -539,7 +539,7 @@ suspend inline fun TelegramBot.replyWithAudio(
duration: Long? = null,
performer: String? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -552,7 +552,7 @@ suspend inline fun TelegramBot.reply(
audio: AudioFile,
entities: TextSourcesList,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -569,7 +569,7 @@ suspend inline fun TelegramBot.replyWithDocument(
thumb: InputFile? = null,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -583,7 +583,7 @@ suspend inline fun TelegramBot.reply(
document: DocumentFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -597,7 +597,7 @@ suspend inline fun TelegramBot.replyWithDocument(
document: InputFile,
thumb: InputFile? = null,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -610,7 +610,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
document: DocumentFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -626,7 +626,7 @@ suspend inline fun TelegramBot.replyWithMediaGroup(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
media: List<MediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -636,7 +636,7 @@ suspend inline fun TelegramBot.replyWithPlaylist(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
media: List<AudioMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -646,7 +646,7 @@ suspend inline fun TelegramBot.replyWithDocuments(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
media: List<DocumentMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -656,7 +656,7 @@ suspend inline fun TelegramBot.replyWithGallery(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
media: List<VisualMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -671,7 +671,7 @@ suspend inline fun TelegramBot.replyWithPhoto(
fileId: InputFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -684,7 +684,7 @@ suspend inline fun TelegramBot.reply(
photo: Photo,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -697,7 +697,7 @@ suspend inline fun TelegramBot.reply(
photoSize: PhotoSize,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -710,7 +710,7 @@ suspend inline fun TelegramBot.replyWithPhoto(
toMessageId: MessageId,
fileId: InputFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -722,7 +722,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
photo: Photo,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -734,7 +734,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
photoSize: PhotoSize,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -748,7 +748,7 @@ suspend inline fun TelegramBot.replyWithSticker(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
sticker: InputFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -759,7 +759,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
sticker: Sticker,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -779,7 +779,7 @@ suspend inline fun TelegramBot.replyWithVideo(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -792,7 +792,7 @@ suspend inline fun TelegramBot.reply(
video: VideoFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -808,7 +808,7 @@ suspend inline fun TelegramBot.replyWithVideo(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -820,7 +820,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
video: VideoFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -837,7 +837,7 @@ suspend inline fun TelegramBot.replyWithVideoNote(
thumb: InputFile? = null,
duration: Long? = null,
size: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -848,7 +848,7 @@ suspend inline fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
videoNote: VideoNoteFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -865,7 +865,7 @@ suspend inline fun TelegramBot.replyWithVoice(
text: String? = null,
parseMode: ParseMode? = null,
duration: Long? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -878,7 +878,7 @@ suspend inline fun TelegramBot.reply(
voice: VoiceFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -892,7 +892,7 @@ suspend inline fun TelegramBot.replyWithVoice(
voice: InputFile,
entities: TextSourcesList,
duration: Long? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -904,7 +904,7 @@ suspend inline fun TelegramBot.reply(
toMessageId: MessageId,
voice: VoiceFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -938,7 +938,7 @@ suspend inline fun TelegramBot.reply(
shouldSendPhoneNumberToProvider: Boolean = false,
shouldSendEmailToProvider: Boolean = false,
priceDependOnShipAddress: Boolean = false,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -957,7 +957,7 @@ suspend inline fun TelegramBot.reply(
isClosed: Boolean = false,
allowMultipleAnswers: Boolean = false,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -974,7 +974,7 @@ suspend inline fun TelegramBot.reply(
isAnonymous: Boolean = poll.isAnonymous,
allowMultipleAnswers: Boolean = poll.allowMultipleAnswers,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -992,7 +992,7 @@ suspend inline fun TelegramBot.reply(
explanation: String? = null,
parseMode: ParseMode? = null,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1011,7 +1011,7 @@ suspend inline fun TelegramBot.reply(
explanation: String? = null,
parseMode: ParseMode? = null,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1028,7 +1028,7 @@ suspend inline fun TelegramBot.reply(
isAnonymous: Boolean = true,
isClosed: Boolean = false,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1046,7 +1046,7 @@ suspend inline fun TelegramBot.reply(
correctOptionId: Int = quizPoll.correctOptionId ?: error("Correct option ID must be provided by income QuizPoll or by developer"),
isAnonymous: Boolean = quizPoll.isAnonymous,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1063,7 +1063,7 @@ suspend inline fun TelegramBot.reply(
options: List<String> = poll.options.map { it.text },
isAnonymous: Boolean = poll.isAnonymous,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1112,7 +1112,7 @@ suspend inline fun TelegramBot.reply(
messageId: MessageId,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1138,7 +1138,7 @@ suspend inline fun TelegramBot.reply(
messageId: MessageId,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1151,7 +1151,7 @@ suspend inline fun TelegramBot.reply(
copy: Message,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1162,7 +1162,7 @@ suspend fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
content: MessageContent,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1191,7 +1191,7 @@ suspend fun TelegramBot.reply(
toMessageId: MessageId,
locationsFlow: Flow<EditLiveLocationInfo>,
liveTimeMillis: Long = defaultLivePeriodDelayMillis,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -1218,7 +1218,7 @@ suspend fun TelegramBot.reply(
toMessageId: MessageId,
locationsFlow: Flow<Location>,
liveTimeMillis: Long = defaultLivePeriodDelayMillis,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -1247,7 +1247,7 @@ suspend fun TelegramBot.reply(
toMessageId: MessageId,
locationsFlow: Flow<Pair<Double, Double>>,
liveTimeMillis: Long = defaultLivePeriodDelayMillis,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null
@@ -1268,7 +1268,7 @@ suspend fun TelegramBot.reply(
toChatId: IdChatIdentifier,
toMessageId: MessageId,
mediaFile: TelegramMediaFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1374,7 +1374,7 @@ suspend fun TelegramBot.reply(
content: TextedMediaContent,
text: String?,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -1461,7 +1461,7 @@ suspend fun TelegramBot.reply(
toMessageId: MessageId,
content: TextedMediaContent,
entities: List<TextSource>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = toChatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,

View File

@@ -15,7 +15,7 @@ suspend fun TelegramBot.sendContact(
phoneNumber: String,
firstName: String,
lastName: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -34,7 +34,7 @@ suspend fun TelegramBot.sendContact(
suspend fun TelegramBot.sendContact(
chatId: ChatIdentifier,
contact: Contact,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -55,7 +55,7 @@ suspend fun TelegramBot.sendContact(
phoneNumber: String,
firstName: String,
lastName: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -72,7 +72,7 @@ suspend fun TelegramBot.sendContact(
suspend fun TelegramBot.sendContact(
chat: Chat,
contact: Contact,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -8,6 +8,7 @@ import dev.inmo.tgbotapi.types.MessageThreadId
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.dice.DiceAnimationType
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -16,7 +17,7 @@ import dev.inmo.tgbotapi.types.dice.DiceAnimationType
suspend fun TelegramBot.sendDice(
chatId: ChatIdentifier,
animationType: DiceAnimationType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -33,7 +34,7 @@ suspend fun TelegramBot.sendDice(
suspend fun TelegramBot.sendDice(
chat: Chat,
animationType: DiceAnimationType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -19,7 +19,7 @@ suspend fun TelegramBot.sendLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -54,7 +54,7 @@ suspend fun TelegramBot.sendLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -88,7 +88,7 @@ suspend fun TelegramBot.sendLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -121,7 +121,7 @@ suspend fun TelegramBot.sendLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -155,7 +155,7 @@ suspend fun TelegramBot.sendLiveLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -174,7 +174,7 @@ suspend fun TelegramBot.sendLiveLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -194,7 +194,7 @@ suspend fun TelegramBot.sendLiveLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -213,7 +213,7 @@ suspend fun TelegramBot.sendLiveLocation(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -20,7 +20,7 @@ suspend fun TelegramBot.sendMessage(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -50,7 +50,7 @@ suspend fun TelegramBot.sendTextMessage(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -69,7 +69,7 @@ suspend fun TelegramBot.sendTextMessage(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -87,7 +87,7 @@ suspend fun TelegramBot.sendMessage(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -103,7 +103,7 @@ suspend fun TelegramBot.sendMessage(
chatId: ChatIdentifier,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -121,7 +121,7 @@ suspend fun TelegramBot.sendMessage(
chatId: ChatIdentifier,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -139,7 +139,7 @@ suspend fun TelegramBot.sendMessage(
chatId: ChatIdentifier,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -156,7 +156,7 @@ suspend fun TelegramBot.sendTextMessage(
chatId: ChatIdentifier,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -174,7 +174,7 @@ suspend fun TelegramBot.sendTextMessage(
chatId: ChatIdentifier,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -192,7 +192,7 @@ suspend fun TelegramBot.sendTextMessage(
chatId: ChatIdentifier,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -209,7 +209,7 @@ suspend fun TelegramBot.sendMessage(
chat: Chat,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -225,7 +225,7 @@ suspend fun TelegramBot.sendMessage(
chat: Chat,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -243,7 +243,7 @@ suspend fun TelegramBot.sendMessage(
chat: Chat,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -261,7 +261,7 @@ suspend fun TelegramBot.sendTextMessage(
chat: Chat,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -277,7 +277,7 @@ suspend fun TelegramBot.sendTextMessage(
chat: Chat,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -295,7 +295,7 @@ suspend fun TelegramBot.sendTextMessage(
chat: Chat,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -8,6 +8,7 @@ import dev.inmo.tgbotapi.types.MessageThreadId
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.location.Location
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -17,7 +18,7 @@ suspend fun TelegramBot.sendLocation(
chatId: ChatIdentifier,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -44,7 +45,7 @@ suspend fun TelegramBot.sendLocation(
suspend fun TelegramBot.sendLocation(
chatId: ChatIdentifier,
location: Location,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -70,7 +71,7 @@ suspend fun TelegramBot.sendLocation(
chat: Chat,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -95,7 +96,7 @@ suspend fun TelegramBot.sendLocation(
suspend fun TelegramBot.sendLocation(
chat: Chat,
location: Location,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -121,7 +122,7 @@ suspend fun TelegramBot.sendStaticLocation(
chatId: ChatIdentifier,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -136,7 +137,7 @@ suspend fun TelegramBot.sendStaticLocation(
suspend fun TelegramBot.sendStaticLocation(
chatId: ChatIdentifier,
location: Location,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -152,7 +153,7 @@ suspend fun TelegramBot.sendStaticLocation(
chat: Chat,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -167,7 +168,7 @@ suspend fun TelegramBot.sendStaticLocation(
suspend fun TelegramBot.sendStaticLocation(
chat: Chat,
location: Location,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,

View File

@@ -22,7 +22,7 @@ suspend fun TelegramBot.sendVenue(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -62,7 +62,7 @@ suspend fun TelegramBot.sendVenue(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -99,7 +99,7 @@ suspend fun TelegramBot.sendVenue(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -136,7 +136,7 @@ suspend fun TelegramBot.sendVenue(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -167,7 +167,7 @@ suspend fun TelegramBot.sendVenue(
suspend fun TelegramBot.sendVenue(
chatId: ChatIdentifier,
venue: Venue,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -193,7 +193,7 @@ suspend fun TelegramBot.sendVenue(
suspend fun TelegramBot.sendVenue(
chat: Chat,
venue: Venue,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -59,7 +59,7 @@ suspend fun TelegramBot.send(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -80,7 +80,7 @@ suspend fun TelegramBot.send(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -100,7 +100,7 @@ suspend fun TelegramBot.send(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -120,7 +120,7 @@ suspend fun TelegramBot.send(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -139,7 +139,7 @@ suspend fun TelegramBot.send(
text: String? = null,
parseMode: ParseMode? = null,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -158,7 +158,7 @@ suspend fun TelegramBot.send(
text: String? = null,
parseMode: ParseMode? = null,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -176,7 +176,7 @@ suspend inline fun TelegramBot.send(
audio: AudioFile,
entities: TextSourcesList,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -194,7 +194,7 @@ suspend inline fun TelegramBot.send(
audio: AudioFile,
entities: TextSourcesList,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -212,7 +212,7 @@ suspend fun TelegramBot.send(
phoneNumber: String,
firstName: String,
lastName: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -228,7 +228,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
contact: Contact,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -246,7 +246,7 @@ suspend fun TelegramBot.send(
phoneNumber: String,
firstName: String,
lastName: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -262,7 +262,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
contact: Contact,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -278,7 +278,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
animationType: DiceAnimationType,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -294,7 +294,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
animationType: DiceAnimationType,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -312,7 +312,7 @@ suspend fun TelegramBot.send(
document: DocumentFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -331,7 +331,7 @@ suspend fun TelegramBot.send(
document: DocumentFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -349,7 +349,7 @@ suspend inline fun TelegramBot.send(
chatId: ChatIdentifier,
document: DocumentFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -367,7 +367,7 @@ suspend inline fun TelegramBot.send(
chat: Chat,
document: DocumentFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -384,7 +384,7 @@ suspend inline fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
game: Game,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -400,7 +400,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
game: Game,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -432,7 +432,7 @@ suspend fun TelegramBot.send(
shouldSendPhoneNumberToProvider: Boolean = false,
shouldSendEmailToProvider: Boolean = false,
priceDependOnShipAddress: Boolean = false,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -464,13 +464,12 @@ suspend fun TelegramBot.send(
shouldSendPhoneNumberToProvider: Boolean = false,
shouldSendEmailToProvider: Boolean = false,
priceDependOnShipAddress: Boolean = false,
threadId: MessageThreadId? = null,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
allowSendingWithoutReply: Boolean? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = sendInvoice(user, title, description, payload, providerToken, currency, prices, maxTipAmount, suggestedTipAmounts, startParameter, providerData, requireName, requirePhoneNumber, requireEmail, requireShippingAddress, shouldSendPhoneNumberToProvider, shouldSendEmailToProvider, priceDependOnShipAddress, threadId, disableNotification, protectContent, replyToMessageId, allowSendingWithoutReply, replyMarkup)
) = sendInvoice(user, title, description, payload, providerToken, currency, prices, maxTipAmount, suggestedTipAmounts, startParameter, providerData, requireName, requirePhoneNumber, requireEmail, requireShippingAddress, shouldSendPhoneNumberToProvider, shouldSendEmailToProvider, priceDependOnShipAddress, disableNotification, protectContent, replyToMessageId, allowSendingWithoutReply, replyMarkup)
/**
* Will execute [sendStaticLocation] request
@@ -481,7 +480,7 @@ suspend fun TelegramBot.send(
chatId: ChatIdentifier,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -497,7 +496,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
location: StaticLocation,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -514,7 +513,7 @@ suspend fun TelegramBot.send(
chat: Chat,
latitude: Double,
longitude: Double,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -530,7 +529,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
location: StaticLocation,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
allowSendingWithoutReply: Boolean? = null,
@@ -548,7 +547,7 @@ suspend fun TelegramBot.send(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -566,7 +565,7 @@ suspend fun TelegramBot.send(
text: String,
parseMode: ParseMode? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -583,7 +582,7 @@ suspend fun TelegramBot.send(
chatId: ChatIdentifier,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -599,7 +598,7 @@ suspend fun TelegramBot.send(
chatId: ChatIdentifier,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -617,7 +616,7 @@ suspend fun TelegramBot.send(
chatId: ChatIdentifier,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -636,7 +635,7 @@ suspend fun TelegramBot.send(
chat: Chat,
entities: TextSourcesList,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -652,7 +651,7 @@ suspend fun TelegramBot.send(
chat: Chat,
separator: TextSource? = null,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -670,7 +669,7 @@ suspend fun TelegramBot.send(
chat: Chat,
separator: String,
disableWebPagePreview: Boolean? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -689,7 +688,7 @@ suspend fun TelegramBot.send(
photo: Photo,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -707,7 +706,7 @@ suspend fun TelegramBot.send(
photo: Photo,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -725,7 +724,7 @@ suspend fun TelegramBot.send(
photoSize: PhotoSize,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -743,7 +742,7 @@ suspend fun TelegramBot.send(
photoSize: PhotoSize,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -760,7 +759,7 @@ suspend inline fun TelegramBot.send(
chatId: ChatIdentifier,
photo: Photo,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -777,7 +776,7 @@ suspend inline fun TelegramBot.send(
chat: Chat,
photo: Photo,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -794,7 +793,7 @@ suspend inline fun TelegramBot.send(
chatId: ChatIdentifier,
photoSize: PhotoSize,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -811,7 +810,7 @@ suspend inline fun TelegramBot.send(
chat: Chat,
photoSize: PhotoSize,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -832,7 +831,7 @@ suspend fun TelegramBot.send(
isClosed: Boolean = false,
allowMultipleAnswers: Boolean = false,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -854,7 +853,7 @@ suspend fun TelegramBot.send(
isAnonymous: Boolean = poll.isAnonymous,
allowMultipleAnswers: Boolean = poll.allowMultipleAnswers,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -875,7 +874,7 @@ suspend fun TelegramBot.send(
isClosed: Boolean = false,
allowMultipleAnswers: Boolean = false,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -897,7 +896,7 @@ suspend fun TelegramBot.send(
isAnonymous: Boolean = poll.isAnonymous,
allowMultipleAnswers: Boolean = poll.allowMultipleAnswers,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -920,7 +919,7 @@ suspend fun TelegramBot.send(
explanation: String? = null,
parseMode: ParseMode? = null,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -943,7 +942,7 @@ suspend fun TelegramBot.send(
explanation: String? = null,
parseMode: ParseMode? = null,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -967,7 +966,7 @@ suspend fun TelegramBot.send(
explanation: String? = null,
parseMode: ParseMode? = null,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -993,7 +992,7 @@ suspend fun TelegramBot.send(
explanation: String? = null,
parseMode: ParseMode? = null,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1015,7 +1014,7 @@ suspend inline fun TelegramBot.send(
isClosed: Boolean = false,
entities: TextSourcesList,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1037,7 +1036,7 @@ suspend inline fun TelegramBot.send(
isClosed: Boolean = false,
entities: TextSourcesList,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1060,7 +1059,7 @@ suspend inline fun TelegramBot.send(
isAnonymous: Boolean = quizPoll.isAnonymous,
entities: TextSourcesList,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1083,7 +1082,7 @@ suspend inline fun TelegramBot.send(
isAnonymous: Boolean = quizPoll.isAnonymous,
entities: TextSourcesList,
closeInfo: ScheduledCloseInfo? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1099,7 +1098,7 @@ suspend inline fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
sticker: Sticker,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1115,7 +1114,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
sticker: Sticker,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1137,7 +1136,7 @@ suspend fun TelegramBot.send(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1171,7 +1170,7 @@ suspend fun TelegramBot.send(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1194,7 +1193,7 @@ suspend fun TelegramBot.send(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1216,7 +1215,7 @@ suspend fun TelegramBot.send(
horizontalAccuracy: Meters? = null,
heading: Degrees? = null,
proximityAlertRadius: Meters? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1241,7 +1240,7 @@ suspend fun TelegramBot.send(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1264,7 +1263,7 @@ suspend fun TelegramBot.send(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1286,7 +1285,7 @@ suspend fun TelegramBot.send(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1308,7 +1307,7 @@ suspend fun TelegramBot.send(
foursquareType: FoursquareType? = null,
googlePlaceId: GooglePlaceId? = null,
googlePlaceType: GooglePlaceType? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1324,7 +1323,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
venue: Venue,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1340,7 +1339,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
venue: Venue,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1358,7 +1357,7 @@ suspend fun TelegramBot.send(
video: VideoFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1376,7 +1375,7 @@ suspend fun TelegramBot.send(
video: VideoFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1393,7 +1392,7 @@ suspend inline fun TelegramBot.send(
chatId: ChatIdentifier,
video: VideoFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1410,7 +1409,7 @@ suspend inline fun TelegramBot.send(
chat: Chat,
video: VideoFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1426,7 +1425,7 @@ suspend inline fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
videoNote: VideoNoteFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1442,7 +1441,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
videoNote: VideoNoteFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1460,7 +1459,7 @@ suspend fun TelegramBot.send(
voice: VoiceFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1478,7 +1477,7 @@ suspend fun TelegramBot.send(
voice: VoiceFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1495,7 +1494,7 @@ suspend inline fun TelegramBot.send(
chatId: ChatIdentifier,
voice: VoiceFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1512,7 +1511,7 @@ suspend inline fun TelegramBot.send(
chat: Chat,
voice: VoiceFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1528,7 +1527,7 @@ suspend inline fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<MediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1543,7 +1542,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<MediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1558,7 +1557,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<MediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1573,7 +1572,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<MediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1587,7 +1586,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<AudioMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1601,7 +1600,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<AudioMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1615,7 +1614,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<AudioContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1629,7 +1628,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<AudioContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1643,7 +1642,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<DocumentMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1657,7 +1656,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<DocumentMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1671,7 +1670,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<DocumentContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1685,7 +1684,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<DocumentContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1699,7 +1698,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<VisualMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1713,7 +1712,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<VisualMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1727,7 +1726,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chatId: ChatIdentifier,
media: List<VisualMediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -1741,7 +1740,7 @@ suspend fun TelegramBot.send(
suspend fun TelegramBot.send(
chat: Chat,
media: List<VisualMediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -8,6 +8,7 @@ import dev.inmo.tgbotapi.types.MessageThreadId
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.games.Game
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -16,7 +17,7 @@ import dev.inmo.tgbotapi.types.games.Game
suspend fun TelegramBot.sendGame(
chatId: ChatIdentifier,
gameShortName: String,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -35,7 +36,7 @@ suspend fun TelegramBot.sendGame(
suspend fun TelegramBot.sendGame(
chat: Chat,
gameShortName: String,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -52,7 +53,7 @@ suspend fun TelegramBot.sendGame(
suspend fun TelegramBot.sendGame(
chatId: ChatIdentifier,
game: Game,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -69,7 +70,7 @@ suspend fun TelegramBot.sendGame(
suspend fun TelegramBot.sendGame(
chat: Chat,
game: Game,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -11,6 +11,7 @@ import dev.inmo.tgbotapi.types.message.ParseMode
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.AnimationFile
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -25,7 +26,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -62,7 +63,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -85,7 +86,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -105,7 +106,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -126,7 +127,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -161,7 +162,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -183,7 +184,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -202,7 +203,7 @@ suspend fun TelegramBot.sendAnimation(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -11,6 +11,7 @@ import dev.inmo.tgbotapi.types.message.ParseMode
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.AudioFile
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -25,7 +26,7 @@ suspend fun TelegramBot.sendAudio(
duration: Long? = null,
performer: String? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -63,7 +64,7 @@ suspend fun TelegramBot.sendAudio(
duration: Long? = null,
performer: String? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -81,7 +82,7 @@ suspend fun TelegramBot.sendAudio(
text: String? = null,
parseMode: ParseMode? = null,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -99,7 +100,7 @@ suspend fun TelegramBot.sendAudio(
text: String? = null,
parseMode: ParseMode? = null,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -120,7 +121,7 @@ suspend inline fun TelegramBot.sendAudio(
duration: Long? = null,
performer: String? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -156,7 +157,7 @@ suspend inline fun TelegramBot.sendAudio(
duration: Long? = null,
performer: String? = null,
title: String? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -173,7 +174,7 @@ suspend inline fun TelegramBot.sendAudio(
audio: AudioFile,
entities: TextSourcesList,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -190,7 +191,7 @@ suspend inline fun TelegramBot.sendAudio(
audio: AudioFile,
entities: TextSourcesList,
title: String? = audio.title,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -11,6 +11,7 @@ import dev.inmo.tgbotapi.types.message.ParseMode
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.DocumentFile
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -22,7 +23,7 @@ suspend fun TelegramBot.sendDocument(
thumb: InputFile? = null,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -56,7 +57,7 @@ suspend fun TelegramBot.sendDocument(
thumb: InputFile? = null,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -74,7 +75,7 @@ suspend fun TelegramBot.sendDocument(
document: DocumentFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -94,7 +95,7 @@ suspend fun TelegramBot.sendDocument(
document: DocumentFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -112,7 +113,7 @@ suspend inline fun TelegramBot.sendDocument(
document: InputFile,
thumb: InputFile? = null,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -144,7 +145,7 @@ suspend inline fun TelegramBot.sendDocument(
document: InputFile,
thumb: InputFile? = null,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -161,7 +162,7 @@ suspend inline fun TelegramBot.sendDocument(
chatId: ChatIdentifier,
document: DocumentFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -180,7 +181,7 @@ suspend inline fun TelegramBot.sendDocument(
chat: Chat,
document: DocumentFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -11,6 +11,7 @@ import dev.inmo.tgbotapi.types.message.content.MediaGroupPartContent
import dev.inmo.tgbotapi.types.message.content.VisualMediaGroupPartContent
import dev.inmo.tgbotapi.types.message.content.AudioContent
import dev.inmo.tgbotapi.types.message.content.DocumentContent
import dev.inmo.tgbotapi.types.threadId
import dev.inmo.tgbotapi.utils.RiskFeature
import kotlin.jvm.JvmName
@@ -21,7 +22,7 @@ import kotlin.jvm.JvmName
suspend fun TelegramBot.sendMediaGroup(
chatId: ChatIdentifier,
media: List<MediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -39,7 +40,7 @@ suspend fun TelegramBot.sendMediaGroup(
suspend fun TelegramBot.sendMediaGroup(
chat: Chat,
media: List<MediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -56,7 +57,7 @@ suspend fun TelegramBot.sendMediaGroup(
suspend fun TelegramBot.sendMediaGroup(
chatId: ChatIdentifier,
media: List<MediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -73,7 +74,7 @@ suspend fun TelegramBot.sendMediaGroup(
suspend fun TelegramBot.sendMediaGroup(
chat: Chat,
media: List<MediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -88,7 +89,7 @@ suspend fun TelegramBot.sendMediaGroup(
suspend fun TelegramBot.sendPlaylist(
chatId: ChatIdentifier,
media: List<AudioMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -105,7 +106,7 @@ suspend fun TelegramBot.sendPlaylist(
suspend fun TelegramBot.sendPlaylist(
chat: Chat,
media: List<AudioMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -121,7 +122,7 @@ suspend fun TelegramBot.sendPlaylist(
suspend fun TelegramBot.sendPlaylist(
chatId: ChatIdentifier,
media: List<AudioContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -137,7 +138,7 @@ suspend fun TelegramBot.sendPlaylist(
suspend fun TelegramBot.sendPlaylist(
chat: Chat,
media: List<AudioContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -152,7 +153,7 @@ suspend fun TelegramBot.sendPlaylist(
suspend fun TelegramBot.sendDocumentsGroup(
chatId: ChatIdentifier,
media: List<DocumentMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -169,7 +170,7 @@ suspend fun TelegramBot.sendDocumentsGroup(
suspend fun TelegramBot.sendDocumentsGroup(
chat: Chat,
media: List<DocumentMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -185,7 +186,7 @@ suspend fun TelegramBot.sendDocumentsGroup(
suspend fun TelegramBot.sendDocumentsGroup(
chatId: ChatIdentifier,
media: List<DocumentContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -201,7 +202,7 @@ suspend fun TelegramBot.sendDocumentsGroup(
suspend fun TelegramBot.sendDocumentsGroup(
chat: Chat,
media: List<DocumentContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -216,7 +217,7 @@ suspend fun TelegramBot.sendDocumentsGroup(
suspend fun TelegramBot.sendVisualMediaGroup(
chatId: ChatIdentifier,
media: List<VisualMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -233,7 +234,7 @@ suspend fun TelegramBot.sendVisualMediaGroup(
suspend fun TelegramBot.sendVisualMediaGroup(
chat: Chat,
media: List<VisualMediaGroupMemberTelegramMedia>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -249,7 +250,7 @@ suspend fun TelegramBot.sendVisualMediaGroup(
suspend fun TelegramBot.sendVisualMediaGroup(
chatId: ChatIdentifier,
media: List<VisualMediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -265,7 +266,7 @@ suspend fun TelegramBot.sendVisualMediaGroup(
suspend fun TelegramBot.sendVisualMediaGroup(
chat: Chat,
media: List<VisualMediaGroupPartContent>,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -11,6 +11,7 @@ import dev.inmo.tgbotapi.types.message.ParseMode
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.*
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -21,7 +22,7 @@ suspend fun TelegramBot.sendPhoto(
fileId: InputFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -51,7 +52,7 @@ suspend fun TelegramBot.sendPhoto(
fileId: InputFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -68,7 +69,7 @@ suspend fun TelegramBot.sendPhoto(
photo: Photo,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -85,7 +86,7 @@ suspend fun TelegramBot.sendPhoto(
photo: Photo,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -102,7 +103,7 @@ suspend fun TelegramBot.sendPhoto(
photoSize: PhotoSize,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -119,7 +120,7 @@ suspend fun TelegramBot.sendPhoto(
photoSize: PhotoSize,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -136,7 +137,7 @@ suspend inline fun TelegramBot.sendPhoto(
chatId: ChatIdentifier,
fileId: InputFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -164,7 +165,7 @@ suspend inline fun TelegramBot.sendPhoto(
chat: Chat,
fileId: InputFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -180,7 +181,7 @@ suspend inline fun TelegramBot.sendPhoto(
chatId: ChatIdentifier,
photo: Photo,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -196,7 +197,7 @@ suspend inline fun TelegramBot.sendPhoto(
chat: Chat,
photo: Photo,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -212,7 +213,7 @@ suspend inline fun TelegramBot.sendPhoto(
chatId: ChatIdentifier,
photoSize: PhotoSize,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -228,7 +229,7 @@ suspend inline fun TelegramBot.sendPhoto(
chat: Chat,
photoSize: PhotoSize,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -9,6 +9,7 @@ import dev.inmo.tgbotapi.types.MessageThreadId
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.Sticker
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -17,7 +18,7 @@ import dev.inmo.tgbotapi.types.files.Sticker
suspend fun TelegramBot.sendSticker(
chatId: ChatIdentifier,
sticker: InputFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -34,7 +35,7 @@ suspend fun TelegramBot.sendSticker(
suspend fun TelegramBot.sendSticker(
chat: Chat,
sticker: InputFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -49,7 +50,7 @@ suspend fun TelegramBot.sendSticker(
suspend fun TelegramBot.sendSticker(
chatId: ChatIdentifier,
sticker: Sticker,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -64,7 +65,7 @@ suspend fun TelegramBot.sendSticker(
suspend fun TelegramBot.sendSticker(
chat: Chat,
sticker: Sticker,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -11,6 +11,7 @@ import dev.inmo.tgbotapi.types.message.ParseMode
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.VideoFile
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -25,7 +26,7 @@ suspend fun TelegramBot.sendVideo(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -60,7 +61,7 @@ suspend fun TelegramBot.sendVideo(
video: VideoFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -81,7 +82,7 @@ suspend fun TelegramBot.sendVideo(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -99,7 +100,7 @@ suspend fun TelegramBot.sendVideo(
video: VideoFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -119,7 +120,7 @@ suspend inline fun TelegramBot.sendVideo(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -152,7 +153,7 @@ suspend inline fun TelegramBot.sendVideo(
chatId: ChatIdentifier,
video: VideoFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -172,7 +173,7 @@ suspend inline fun TelegramBot.sendVideo(
duration: Long? = null,
width: Int? = null,
height: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -189,7 +190,7 @@ suspend inline fun TelegramBot.sendVideo(
chat: Chat,
video: VideoFile,
entities: TextSourcesList,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -9,6 +9,7 @@ import dev.inmo.tgbotapi.types.MessageThreadId
import dev.inmo.tgbotapi.types.buttons.KeyboardMarkup
import dev.inmo.tgbotapi.types.chat.Chat
import dev.inmo.tgbotapi.types.files.VideoNoteFile
import dev.inmo.tgbotapi.types.threadId
/**
* @param replyMarkup Some of [KeyboardMarkup]. See [dev.inmo.tgbotapi.extensions.utils.types.buttons.replyKeyboard] or
@@ -20,7 +21,7 @@ suspend fun TelegramBot.sendVideoNote(
thumb: InputFile? = null,
duration: Long? = null,
size: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -49,7 +50,7 @@ suspend fun TelegramBot.sendVideoNote(
suspend fun TelegramBot.sendVideoNote(
chatId: ChatIdentifier,
videoNote: VideoNoteFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chatId.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -69,7 +70,7 @@ suspend fun TelegramBot.sendVideoNote(
thumb: InputFile? = null,
duration: Long? = null,
size: Int? = null,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -84,7 +85,7 @@ suspend fun TelegramBot.sendVideoNote(
suspend fun TelegramBot.sendVideoNote(
chat: Chat,
videoNote: VideoNoteFile,
threadId: MessageThreadId? = null,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -55,7 +55,7 @@ suspend fun TelegramBot.sendVoice(
text: String? = null,
parseMode: ParseMode? = null,
duration: Long? = null,
threadId: MessageThreadId? = chatId.threadId,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -91,7 +91,7 @@ suspend fun TelegramBot.sendVoice(
voice: VoiceFile,
text: String? = null,
parseMode: ParseMode? = null,
threadId: MessageThreadId? = chatId.threadId,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -139,7 +139,7 @@ suspend inline fun TelegramBot.sendVoice(
voice: InputFile,
entities: TextSourcesList,
duration: Long? = null,
threadId: MessageThreadId? = chatId.threadId,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
@@ -172,7 +172,7 @@ suspend inline fun TelegramBot.sendVoice(
chat: Chat,
voice: VoiceFile,
entities: TextSourcesList,
threadId: MessageThreadId? = chatId.threadId,
threadId: MessageThreadId? = chat.id.threadId,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,

View File

@@ -64,10 +64,9 @@ suspend fun TelegramBot.sendInvoice(
shouldSendPhoneNumberToProvider: Boolean = false,
shouldSendEmailToProvider: Boolean = false,
priceDependOnShipAddress: Boolean = false,
threadId: MessageThreadId? = null,
disableNotification: Boolean = false,
protectContent: Boolean = false,
replyToMessageId: MessageId? = null,
allowSendingWithoutReply: Boolean? = null,
replyMarkup: InlineKeyboardMarkup? = null
) = sendInvoice(user.id, title, description, payload, providerToken, currency, prices, maxTipAmount, suggestedTipAmounts, startParameter, providerData, requireName, requirePhoneNumber, requireEmail, requireShippingAddress, shouldSendPhoneNumberToProvider, shouldSendEmailToProvider, priceDependOnShipAddress, threadId, disableNotification, protectContent, replyToMessageId, allowSendingWithoutReply, replyMarkup)
) = sendInvoice(user.id, title, description, payload, providerToken, currency, prices, maxTipAmount, suggestedTipAmounts, startParameter, providerData, requireName, requirePhoneNumber, requireEmail, requireShippingAddress, shouldSendPhoneNumberToProvider, shouldSendEmailToProvider, priceDependOnShipAddress, null, disableNotification, protectContent, replyToMessageId, allowSendingWithoutReply, replyMarkup)