Closed CMfengbuzhi closed 11 months ago
The search on the chat page is searchRecentlyFoundChats
+ searchChats
+ searchChatsOnServer
+ searchContacts
+ searchPublicChats
+ searchMessages
+ searchSecretMessages
.
聊天页面上的搜索是
searchRecentlyFoundChats
+searchChats
+searchChatsOnServer
+searchPublicChats
+searchMessages
+searchSecretMessages
.
Thank u. The searchChatsOnServer interface only returns data once when searching for the same content. Do developers need to save the returned data in the database themselves to avoid duplicate searches? Is there another interface for querying tdlib's saved search results?
You don't need database. You must add results from the mentioned request in the specified order. skipping previously received chats, users and messages.
You don't need database. You must add results from the mentioned request in the specified order. skipping previously received chats, users and messages.
Why sometimes using searchChatsOnServer to search does not return data, while using tg to search results in data? Is this a problem with the limit parameter? How should limit be written?
//@description Searches for the specified query in the title and username of already known chats via request to the server. Returns chats in the order seen in the main chat list @query Query to search for @limit The maximum number of chats to be returned
searchChatsOnServer query:string limit:int32 = Chats;
The method works as documented. It can return only chats from the chat list.
Like the search on the Telegram homepage, global search can be performed.Which API interface should I use?