-
Notifications
You must be signed in to change notification settings - Fork 11
forward messages
libtd-ktx / kotlinx.telegram.coroutines / forwardMessages
suspend fun
TelegramFlow
.forwardMessages(chatId:
Long
, fromChatId:
Long
, messageIds:
LongArray
?, options:
SendMessageOptions
?, asAlbum:
Boolean
, sendCopy:
Boolean
, removeCaption:
Boolean
):
Messages
Suspend function, which forwards previously sent messages. Returns the forwarded messages in the same order as the message identifiers passed in messageIds. If a message can't be forwarded, null will be returned instead of the message.
chatId
- Identifier of the chat to which to forward messages.
fromChatId
- Identifier of the chat from which to forward messages.
messageIds
- Identifiers of the messages to forward.
options
- Options to be used to send the messages.
asAlbum
- True, if the messages should be grouped into an album after forwarding. For this
to work, no more than 10 messages may be forwarded, and all of them must be photo or video messages.
sendCopy
- True, if content of the messages needs to be copied without links to the original
messages. Always true if the messages are forwarded to a secret chat.
removeCaption
- True, if media captions of message copies needs to be removed. Ignored if
sendCopy is false.
Return Messages Contains a list of messages.