searchSecretMessages - libtd-ktx

Kotlin Coroutines extensions for Telegram API TDLib (Telegram Database library)


libtd-ktx / kotlinx.telegram.coroutines / searchSecretMessages

searchSecretMessages

suspend fun TelegramFlow.searchSecretMessages(chatId: Long, query: String?, fromSearchId: Long, limit: Int, filter: SearchMessagesFilter?): FoundMessages

Suspend function, which searches for messages in secret chats. Returns the results in reverse chronological order. For optimal performance the number of returned messages is chosen by the library.

Parameters

chatId - Identifier of the chat in which to search. Specify 0 to search in all secret chats.

query - Query to search for. If empty, searchChatMessages should be used instead.

fromSearchId - The identifier from the result of a previous request, use 0 to get results from the last message.

limit - The maximum number of messages to be returned; up to 100. Fewer messages may be returned than specified by the limit, even if the end of the message history has not been reached.

filter - A filter for the content of messages in the search results.

Return FoundMessages Contains a list of messages found by a search.