1
0
mirror of https://github.com/InsanusMokrassar/TelegramBotAPI.git synced 2026-03-03 17:32:23 +00:00

fix RepostStory class

This commit is contained in:
2026-02-16 22:39:18 +06:00
parent d68c70e898
commit 85fb7e42e5
5 changed files with 56 additions and 12 deletions

View File

@@ -0,0 +1,27 @@
package dev.inmo.tgbotapi.extensions.api.stories
import dev.inmo.tgbotapi.bot.TelegramBot
import dev.inmo.tgbotapi.requests.stories.RepostStory
import dev.inmo.tgbotapi.types.IdChatIdentifier
import dev.inmo.tgbotapi.types.Seconds
import dev.inmo.tgbotapi.types.StoryId
import dev.inmo.tgbotapi.types.business_connection.BusinessConnectionId
import dev.inmo.tgbotapi.types.stories.Story
public suspend fun TelegramBot.repostStory(
businessConnectionId: BusinessConnectionId,
fromChatId: IdChatIdentifier,
storyId: StoryId,
activePeriod: Seconds,
postToChatPage: Boolean = false,
protectContent: Boolean = false,
): Story = execute(
RepostStory(
businessConnectionId = businessConnectionId,
fromChatId = fromChatId,
storyId = storyId,
activePeriod = activePeriod,
postToChatPage = postToChatPage,
protectContent = protectContent
)
)