mirror of
https://github.com/InsanusMokrassar/TelegramBotAPI.git
synced 2024-12-23 09:07:12 +00:00
remove redundant includes of business connection id in send requests
This commit is contained in:
parent
e4a3acdd68
commit
170747741f
@ -29,7 +29,6 @@ fun CopyMessage(
|
|||||||
text: String? = null,
|
text: String? = null,
|
||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
threadId: MessageThreadId? = toChatId.threadId,
|
threadId: MessageThreadId? = toChatId.threadId,
|
||||||
businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
disableNotification: Boolean = false,
|
disableNotification: Boolean = false,
|
||||||
protectContent: Boolean = false,
|
protectContent: Boolean = false,
|
||||||
replyParameters: ReplyParameters? = null,
|
replyParameters: ReplyParameters? = null,
|
||||||
@ -42,7 +41,6 @@ fun CopyMessage(
|
|||||||
parseMode,
|
parseMode,
|
||||||
null,
|
null,
|
||||||
threadId,
|
threadId,
|
||||||
businessConnectionId,
|
|
||||||
disableNotification,
|
disableNotification,
|
||||||
protectContent,
|
protectContent,
|
||||||
replyParameters,
|
replyParameters,
|
||||||
@ -55,7 +53,6 @@ fun CopyMessage(
|
|||||||
messageId: MessageId,
|
messageId: MessageId,
|
||||||
entities: List<TextSource>,
|
entities: List<TextSource>,
|
||||||
threadId: MessageThreadId? = toChatId.threadId,
|
threadId: MessageThreadId? = toChatId.threadId,
|
||||||
businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
disableNotification: Boolean = false,
|
disableNotification: Boolean = false,
|
||||||
protectContent: Boolean = false,
|
protectContent: Boolean = false,
|
||||||
replyParameters: ReplyParameters? = null,
|
replyParameters: ReplyParameters? = null,
|
||||||
@ -68,7 +65,6 @@ fun CopyMessage(
|
|||||||
null,
|
null,
|
||||||
entities.toRawMessageEntities(),
|
entities.toRawMessageEntities(),
|
||||||
threadId,
|
threadId,
|
||||||
businessConnectionId,
|
|
||||||
disableNotification,
|
disableNotification,
|
||||||
protectContent,
|
protectContent,
|
||||||
replyParameters,
|
replyParameters,
|
||||||
@ -82,7 +78,6 @@ fun CopyMessage(
|
|||||||
text: String? = null,
|
text: String? = null,
|
||||||
parseMode: ParseMode? = null,
|
parseMode: ParseMode? = null,
|
||||||
threadId: MessageThreadId? = toChatId.threadId,
|
threadId: MessageThreadId? = toChatId.threadId,
|
||||||
businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
disableNotification: Boolean = false,
|
disableNotification: Boolean = false,
|
||||||
protectContent: Boolean = false,
|
protectContent: Boolean = false,
|
||||||
replyParameters: ReplyParameters? = null,
|
replyParameters: ReplyParameters? = null,
|
||||||
@ -95,7 +90,6 @@ fun CopyMessage(
|
|||||||
parseMode,
|
parseMode,
|
||||||
null,
|
null,
|
||||||
threadId,
|
threadId,
|
||||||
businessConnectionId,
|
|
||||||
disableNotification,
|
disableNotification,
|
||||||
protectContent,
|
protectContent,
|
||||||
replyParameters,
|
replyParameters,
|
||||||
@ -108,7 +102,6 @@ fun CopyMessage(
|
|||||||
toChatId: ChatIdentifier,
|
toChatId: ChatIdentifier,
|
||||||
entities: List<TextSource>,
|
entities: List<TextSource>,
|
||||||
threadId: MessageThreadId? = toChatId.threadId,
|
threadId: MessageThreadId? = toChatId.threadId,
|
||||||
businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
disableNotification: Boolean = false,
|
disableNotification: Boolean = false,
|
||||||
protectContent: Boolean = false,
|
protectContent: Boolean = false,
|
||||||
replyParameters: ReplyParameters? = null,
|
replyParameters: ReplyParameters? = null,
|
||||||
@ -121,7 +114,6 @@ fun CopyMessage(
|
|||||||
null,
|
null,
|
||||||
entities.toRawMessageEntities(),
|
entities.toRawMessageEntities(),
|
||||||
threadId,
|
threadId,
|
||||||
businessConnectionId,
|
|
||||||
disableNotification,
|
disableNotification,
|
||||||
protectContent,
|
protectContent,
|
||||||
replyParameters,
|
replyParameters,
|
||||||
@ -144,8 +136,6 @@ data class CopyMessage internal constructor(
|
|||||||
private val rawEntities: List<RawMessageEntity>? = null,
|
private val rawEntities: List<RawMessageEntity>? = null,
|
||||||
@SerialName(messageThreadIdField)
|
@SerialName(messageThreadIdField)
|
||||||
override val threadId: MessageThreadId? = toChatId.threadId,
|
override val threadId: MessageThreadId? = toChatId.threadId,
|
||||||
@SerialName(businessConnectionIdField)
|
|
||||||
override val businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
@SerialName(disableNotificationField)
|
@SerialName(disableNotificationField)
|
||||||
override val disableNotification: Boolean = false,
|
override val disableNotification: Boolean = false,
|
||||||
@SerialName(protectContentField)
|
@SerialName(protectContentField)
|
||||||
|
@ -22,7 +22,6 @@ fun CopyMessages(
|
|||||||
fromChatId: ChatIdentifier,
|
fromChatId: ChatIdentifier,
|
||||||
messageIds: Array<MessageId>,
|
messageIds: Array<MessageId>,
|
||||||
threadId: MessageThreadId? = toChatId.threadId,
|
threadId: MessageThreadId? = toChatId.threadId,
|
||||||
businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
disableNotification: Boolean = false,
|
disableNotification: Boolean = false,
|
||||||
protectContent: Boolean = false,
|
protectContent: Boolean = false,
|
||||||
removeCaption: Boolean = false
|
removeCaption: Boolean = false
|
||||||
@ -46,8 +45,6 @@ data class CopyMessages (
|
|||||||
override val messageIds: List<MessageId>,
|
override val messageIds: List<MessageId>,
|
||||||
@SerialName(messageThreadIdField)
|
@SerialName(messageThreadIdField)
|
||||||
override val threadId: MessageThreadId? = toChatId.threadId,
|
override val threadId: MessageThreadId? = toChatId.threadId,
|
||||||
@SerialName(businessConnectionIdField)
|
|
||||||
override val businessConnectionId: BusinessConnectionId? = toChatId.businessConnectionId,
|
|
||||||
@SerialName(disableNotificationField)
|
@SerialName(disableNotificationField)
|
||||||
override val disableNotification: Boolean = false,
|
override val disableNotification: Boolean = false,
|
||||||
@SerialName(protectContentField)
|
@SerialName(protectContentField)
|
||||||
@ -58,7 +55,6 @@ data class CopyMessages (
|
|||||||
MessagesAction,
|
MessagesAction,
|
||||||
ProtectContent,
|
ProtectContent,
|
||||||
OptionallyMessageThreadRequest,
|
OptionallyMessageThreadRequest,
|
||||||
OptionallyBusinessConnectionRequest,
|
|
||||||
DisableNotification {
|
DisableNotification {
|
||||||
override val chatId: ChatIdentifier
|
override val chatId: ChatIdentifier
|
||||||
get() = fromChatId
|
get() = fromChatId
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
package dev.inmo.tgbotapi.requests.send
|
package dev.inmo.tgbotapi.requests.send
|
||||||
|
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.ReplyingMarkupSendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.ReplyingMarkupSendMessageRequest
|
||||||
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendContentMessageRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
||||||
import dev.inmo.tgbotapi.types.*
|
import dev.inmo.tgbotapi.types.*
|
||||||
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
||||||
@ -35,7 +36,7 @@ data class SendContact(
|
|||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : SendMessageRequest<ContentMessage<ContactContent>>,
|
) : SendContentMessageRequest<ContentMessage<ContactContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<ContactContent>>
|
ReplyingMarkupSendMessageRequest<ContentMessage<ContactContent>>
|
||||||
{
|
{
|
||||||
constructor(
|
constructor(
|
||||||
|
@ -111,7 +111,7 @@ data class SendLocation internal constructor(
|
|||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : SendMessageRequest<ContentMessage<LocationContent>>,
|
) : SendContentMessageRequest<ContentMessage<LocationContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<LocationContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<LocationContent>>,
|
||||||
PositionedSendMessageRequest<ContentMessage<LocationContent>>,
|
PositionedSendMessageRequest<ContentMessage<LocationContent>>,
|
||||||
HorizontallyAccured,
|
HorizontallyAccured,
|
||||||
|
@ -94,7 +94,7 @@ data class SendTextMessage internal constructor(
|
|||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : SendMessageRequest<ContentMessage<TextContent>>,
|
) : SendContentMessageRequest<ContentMessage<TextContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<TextContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<TextContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<TextContent>>,
|
TextableSendMessageRequest<ContentMessage<TextContent>>,
|
||||||
LinkPreviewOptionsContainer
|
LinkPreviewOptionsContainer
|
||||||
|
@ -45,7 +45,7 @@ data class SendVenue(
|
|||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : SendMessageRequest<ContentMessage<VenueContent>>,
|
) : SendContentMessageRequest<ContentMessage<VenueContent>>,
|
||||||
PositionedSendMessageRequest<ContentMessage<VenueContent>>,
|
PositionedSendMessageRequest<ContentMessage<VenueContent>>,
|
||||||
TitledSendMessageRequest<ContentMessage<VenueContent>>,
|
TitledSendMessageRequest<ContentMessage<VenueContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<VenueContent>>
|
ReplyingMarkupSendMessageRequest<ContentMessage<VenueContent>>
|
||||||
|
@ -0,0 +1,5 @@
|
|||||||
|
package dev.inmo.tgbotapi.requests.send.abstracts
|
||||||
|
|
||||||
|
import dev.inmo.tgbotapi.abstracts.types.OptionallyBusinessConnectionRequest
|
||||||
|
|
||||||
|
interface SendContentMessageRequest<T: Any> : SendMessageRequest<T>, OptionallyBusinessConnectionRequest
|
@ -6,5 +6,4 @@ interface SendMessageRequest<T: Any> : SendChatMessageRequest<T>,
|
|||||||
WithReplyParameters,
|
WithReplyParameters,
|
||||||
DisableNotification,
|
DisableNotification,
|
||||||
ProtectContent,
|
ProtectContent,
|
||||||
OptionallyMessageThreadRequest,
|
OptionallyMessageThreadRequest
|
||||||
OptionallyBusinessConnectionRequest
|
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
package dev.inmo.tgbotapi.requests.send.games
|
package dev.inmo.tgbotapi.requests.send.games
|
||||||
|
|
||||||
import dev.inmo.tgbotapi.abstracts.types.WithReplyMarkup
|
import dev.inmo.tgbotapi.abstracts.types.WithReplyMarkup
|
||||||
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendContentMessageRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
||||||
import dev.inmo.tgbotapi.types.*
|
import dev.inmo.tgbotapi.types.*
|
||||||
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
||||||
@ -31,7 +32,7 @@ data class SendGame (
|
|||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : SendMessageRequest<ContentMessage<GameContent>>,
|
) : SendContentMessageRequest<ContentMessage<GameContent>>,
|
||||||
WithReplyMarkup {
|
WithReplyMarkup {
|
||||||
override fun method(): String = "sendGame"
|
override fun method(): String = "sendGame"
|
||||||
override val resultDeserializer: DeserializationStrategy<ContentMessage<GameContent>>
|
override val resultDeserializer: DeserializationStrategy<ContentMessage<GameContent>>
|
||||||
|
@ -156,7 +156,7 @@ data class SendAnimationData internal constructor(
|
|||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : DataRequest<ContentMessage<AnimationContent>>,
|
) : DataRequest<ContentMessage<AnimationContent>>,
|
||||||
SendMessageRequest<ContentMessage<AnimationContent>>,
|
SendContentMessageRequest<ContentMessage<AnimationContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<AnimationContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<AnimationContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<AnimationContent>>,
|
TextableSendMessageRequest<ContentMessage<AnimationContent>>,
|
||||||
ThumbedSendMessageRequest<ContentMessage<AnimationContent>>,
|
ThumbedSendMessageRequest<ContentMessage<AnimationContent>>,
|
||||||
|
@ -151,7 +151,7 @@ data class SendAudioData internal constructor(
|
|||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : DataRequest<ContentMessage<AudioContent>>,
|
) : DataRequest<ContentMessage<AudioContent>>,
|
||||||
SendMessageRequest<ContentMessage<AudioContent>>,
|
SendContentMessageRequest<ContentMessage<AudioContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<AudioContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<AudioContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<AudioContent>>,
|
TextableSendMessageRequest<ContentMessage<AudioContent>>,
|
||||||
ThumbedSendMessageRequest<ContentMessage<AudioContent>>,
|
ThumbedSendMessageRequest<ContentMessage<AudioContent>>,
|
||||||
|
@ -165,7 +165,7 @@ data class SendDocumentData internal constructor(
|
|||||||
@SerialName(disableContentTypeDetectionField)
|
@SerialName(disableContentTypeDetectionField)
|
||||||
val disableContentTypeDetection: Boolean? = null
|
val disableContentTypeDetection: Boolean? = null
|
||||||
) : DataRequest<ContentMessage<DocumentContent>>,
|
) : DataRequest<ContentMessage<DocumentContent>>,
|
||||||
SendMessageRequest<ContentMessage<DocumentContent>>,
|
SendContentMessageRequest<ContentMessage<DocumentContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<DocumentContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<DocumentContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<DocumentContent>>,
|
TextableSendMessageRequest<ContentMessage<DocumentContent>>,
|
||||||
ThumbedSendMessageRequest<ContentMessage<DocumentContent>>
|
ThumbedSendMessageRequest<ContentMessage<DocumentContent>>
|
||||||
|
@ -3,6 +3,7 @@ package dev.inmo.tgbotapi.requests.send.media
|
|||||||
import dev.inmo.tgbotapi.requests.abstracts.MultipartFile
|
import dev.inmo.tgbotapi.requests.abstracts.MultipartFile
|
||||||
import dev.inmo.tgbotapi.requests.abstracts.Request
|
import dev.inmo.tgbotapi.requests.abstracts.Request
|
||||||
import dev.inmo.tgbotapi.requests.common.CommonMultipartFileRequest
|
import dev.inmo.tgbotapi.requests.common.CommonMultipartFileRequest
|
||||||
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendContentMessageRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.media.base.*
|
import dev.inmo.tgbotapi.requests.send.media.base.*
|
||||||
import dev.inmo.tgbotapi.types.*
|
import dev.inmo.tgbotapi.types.*
|
||||||
@ -157,7 +158,7 @@ data class SendMediaGroupData internal constructor(
|
|||||||
@SerialName(replyParametersField)
|
@SerialName(replyParametersField)
|
||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
) : DataRequest<PossiblySentViaBotCommonMessage<MediaGroupContent<MediaGroupPartContent>>>,
|
) : DataRequest<PossiblySentViaBotCommonMessage<MediaGroupContent<MediaGroupPartContent>>>,
|
||||||
SendMessageRequest<PossiblySentViaBotCommonMessage<MediaGroupContent<MediaGroupPartContent>>> {
|
SendContentMessageRequest<PossiblySentViaBotCommonMessage<MediaGroupContent<MediaGroupPartContent>>> {
|
||||||
@SerialName(mediaField)
|
@SerialName(mediaField)
|
||||||
private val convertedMedia: String
|
private val convertedMedia: String
|
||||||
get() = buildJsonArray {
|
get() = buildJsonArray {
|
||||||
|
@ -124,7 +124,7 @@ data class SendPhotoData internal constructor(
|
|||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : DataRequest<ContentMessage<PhotoContent>>,
|
) : DataRequest<ContentMessage<PhotoContent>>,
|
||||||
SendMessageRequest<ContentMessage<PhotoContent>>,
|
SendContentMessageRequest<ContentMessage<PhotoContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<PhotoContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<PhotoContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<PhotoContent>>,
|
TextableSendMessageRequest<ContentMessage<PhotoContent>>,
|
||||||
OptionallyWithSpoilerRequest
|
OptionallyWithSpoilerRequest
|
||||||
|
@ -3,6 +3,7 @@ package dev.inmo.tgbotapi.requests.send.media
|
|||||||
import dev.inmo.tgbotapi.requests.abstracts.*
|
import dev.inmo.tgbotapi.requests.abstracts.*
|
||||||
import dev.inmo.tgbotapi.requests.common.CommonMultipartFileRequest
|
import dev.inmo.tgbotapi.requests.common.CommonMultipartFileRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.ReplyingMarkupSendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.ReplyingMarkupSendMessageRequest
|
||||||
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendContentMessageRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
||||||
import dev.inmo.tgbotapi.types.*
|
import dev.inmo.tgbotapi.types.*
|
||||||
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
||||||
@ -62,7 +63,7 @@ data class SendStickerByFileId internal constructor(
|
|||||||
override val replyParameters: ReplyParameters? = null,
|
override val replyParameters: ReplyParameters? = null,
|
||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : SendMessageRequest<ContentMessage<StickerContent>>, ReplyingMarkupSendMessageRequest<ContentMessage<StickerContent>> {
|
) : SendContentMessageRequest<ContentMessage<StickerContent>>, ReplyingMarkupSendMessageRequest<ContentMessage<StickerContent>> {
|
||||||
override fun method(): String = "sendSticker"
|
override fun method(): String = "sendSticker"
|
||||||
override val resultDeserializer: DeserializationStrategy<ContentMessage<StickerContent>>
|
override val resultDeserializer: DeserializationStrategy<ContentMessage<StickerContent>>
|
||||||
get() = commonResultDeserializer
|
get() = commonResultDeserializer
|
||||||
|
@ -162,7 +162,7 @@ data class SendVideoData internal constructor(
|
|||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : DataRequest<ContentMessage<VideoContent>>,
|
) : DataRequest<ContentMessage<VideoContent>>,
|
||||||
SendMessageRequest<ContentMessage<VideoContent>>,
|
SendContentMessageRequest<ContentMessage<VideoContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<VideoContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<VideoContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<VideoContent>>,
|
TextableSendMessageRequest<ContentMessage<VideoContent>>,
|
||||||
ThumbedSendMessageRequest<ContentMessage<VideoContent>>,
|
ThumbedSendMessageRequest<ContentMessage<VideoContent>>,
|
||||||
|
@ -81,7 +81,7 @@ data class SendVideoNoteData internal constructor(
|
|||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : DataRequest<ContentMessage<VideoNoteContent>>,
|
) : DataRequest<ContentMessage<VideoNoteContent>>,
|
||||||
SendMessageRequest<ContentMessage<VideoNoteContent>>,
|
SendContentMessageRequest<ContentMessage<VideoNoteContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<VideoNoteContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<VideoNoteContent>>,
|
||||||
ThumbedSendMessageRequest<ContentMessage<VideoNoteContent>>,
|
ThumbedSendMessageRequest<ContentMessage<VideoNoteContent>>,
|
||||||
DuratedSendMessageRequest<ContentMessage<VideoNoteContent>>,
|
DuratedSendMessageRequest<ContentMessage<VideoNoteContent>>,
|
||||||
|
@ -130,7 +130,7 @@ data class SendVoiceData internal constructor(
|
|||||||
@SerialName(replyMarkupField)
|
@SerialName(replyMarkupField)
|
||||||
override val replyMarkup: KeyboardMarkup? = null
|
override val replyMarkup: KeyboardMarkup? = null
|
||||||
) : DataRequest<ContentMessage<VoiceContent>>,
|
) : DataRequest<ContentMessage<VoiceContent>>,
|
||||||
SendMessageRequest<ContentMessage<VoiceContent>>,
|
SendContentMessageRequest<ContentMessage<VoiceContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<VoiceContent>>,
|
ReplyingMarkupSendMessageRequest<ContentMessage<VoiceContent>>,
|
||||||
TextableSendMessageRequest<ContentMessage<VoiceContent>>,
|
TextableSendMessageRequest<ContentMessage<VoiceContent>>,
|
||||||
DuratedSendMessageRequest<ContentMessage<VoiceContent>>
|
DuratedSendMessageRequest<ContentMessage<VoiceContent>>
|
||||||
|
@ -61,8 +61,6 @@ data class SendInvoice(
|
|||||||
override val priceDependOnShipAddress: Boolean = false,
|
override val priceDependOnShipAddress: Boolean = false,
|
||||||
@SerialName(messageThreadIdField)
|
@SerialName(messageThreadIdField)
|
||||||
override val threadId: MessageThreadId? = chatId.threadId,
|
override val threadId: MessageThreadId? = chatId.threadId,
|
||||||
@SerialName(businessConnectionIdField)
|
|
||||||
override val businessConnectionId: BusinessConnectionId? = chatId.businessConnectionId,
|
|
||||||
@SerialName(disableNotificationField)
|
@SerialName(disableNotificationField)
|
||||||
override val disableNotification: Boolean = false,
|
override val disableNotification: Boolean = false,
|
||||||
@SerialName(protectContentField)
|
@SerialName(protectContentField)
|
||||||
|
@ -3,6 +3,7 @@ package dev.inmo.tgbotapi.requests.send.polls
|
|||||||
import korlibs.time.DateTime
|
import korlibs.time.DateTime
|
||||||
import dev.inmo.tgbotapi.abstracts.TextedOutput
|
import dev.inmo.tgbotapi.abstracts.TextedOutput
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.ReplyingMarkupSendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.ReplyingMarkupSendMessageRequest
|
||||||
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendContentMessageRequest
|
||||||
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
import dev.inmo.tgbotapi.requests.send.abstracts.SendMessageRequest
|
||||||
import dev.inmo.tgbotapi.types.*
|
import dev.inmo.tgbotapi.types.*
|
||||||
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
|
||||||
@ -156,7 +157,7 @@ private fun ScheduledCloseInfo.checkSendData() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sealed class SendPoll : SendMessageRequest<ContentMessage<PollContent>>,
|
sealed class SendPoll : SendContentMessageRequest<ContentMessage<PollContent>>,
|
||||||
ReplyingMarkupSendMessageRequest<ContentMessage<PollContent>> {
|
ReplyingMarkupSendMessageRequest<ContentMessage<PollContent>> {
|
||||||
abstract val question: String
|
abstract val question: String
|
||||||
abstract val options: List<String>
|
abstract val options: List<String>
|
||||||
|
Loading…
Reference in New Issue
Block a user