@rongcloud/imlib-next 5.20.2 → 5.22.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { FileType, APIContext, IAsyncRes, LogLevel, EnableLogL, AreaCode, IReceivedMessage, RCConnectionStatus, IPluginGenerator, MessageTypeDescription, MentionedInfo, NotificationStatus, IReceivedConversation, IPushConfig, IRecallMsgOptions, IConversationOption, ITypingMessage, IUpdateItem, ErrorCode, IChatroomListenerData, IExpansionListenerData, IBlockedMessageInfo, IOperateStatusNotify, IUltraChannelChangeInfo, IUltraChannelDeleteInfo, IUltraChannelUserKickedInfo, IUserGroupStatusInfo, IMessageDeliver, IGroupMessageDeliverStatus, IReadReceiptData, ISyncReadStatusData, ISubscribeUserStatusInfo, ISubscribeRelationInfo, SubscribeType, IUserProfileInfo, IGroupOperationInfo, IGroupInfoChanged, IGroupMemberInfoChanged, IGroupApplicationInfo, IGroupRemarkChangedSync, IGroupFollowsChangedSync, IFriendAdd, IFriendDelete, IFriendApplicationStatusChange, IFriendInfoChangedSync, IStreamMessageResponseEventData as IStreamMessageResponseEventData$1, ReadReceiptResponseV5, GetConversationListByTimestampParams, RCResult, ConversationType, NotificationLevel, IConversationIdentifier, IConversationUnreadCount, IGetUltraGroupListOption, IUltraGroupConversation, IBaseConversationInfo, IUltraGroupOption, IUltraGroupUnreadMentionedOption, IUltraUnreadMsg, IUltraGroupUnreadInfo, IChatroomJoinResponse, IChatroomInfo, IChatroomEntry, IChatroomEntries, IRemoveChatroomEntry, IRTCRoomBindOption, ICombineV2MessageContent, IMessageReadReceiptV4Response, IGroupReadReceiptData, MessageDirection, IClearMessageOption, IMessageReaderResponse, IFirstUnreadMessageInfo, ReadReceiptInfoV5, ReadReceiptUsersOption, ReadReceiptUsersResult, ITagParam, ITagInfo, IConversationTag, IUploadAuth, IDownloadAuth, UploadMethod, MessageType as MessageType$1, ReceivedStatus, IReceivedStatusInfo, SentStatus, IInsertMessage, IGroupMessageDeliverInfo, IProxy, IPromiseResult, IResponse, IUpdateMyProfileFail, UserProfileVisibility, IGroupInfoOption, ICreateGroupFail, IErrorKeys, IGroupInfo, IQuitGroupConfig, GroupMemberRole, IPagingQueryOption, IPagingQueryResult, IGroupMemberInfo, IProcessCode, GroupApplicationDirection, GroupApplicationStatus, IFollowsInfo, DirectionType, IFriendRelationInfo, QueryFriendsDirectionType, IFriendInfo, FriendApplicationType, FriendApplicationStatus, IFriendApplicationInfo, FriendAddPermission, INotificationQuietHoursSetting } from '@rongcloud/engine';
2
- export { AreaCode, ChatroomEntryType, ChatroomSyncStatusReason, ChatroomUserChangeType, ChrmMemBanType, ChrmMemOperateType, ChrmSyncStatus, ConnectionStatus, ConversationType, DirectionType, EnableLogL, ErrorCode, FileType, FriendAddPermission, FriendApplicationStatus, FriendApplicationType, FriendRelationType, GroupApplicationDirection, GroupApplicationStatus, GroupApplicationType, GroupInviteHandlePermission, GroupJoinPermission, GroupMemberInfoEditPermission, GroupMemberRole, GroupOperation, GroupOperationPermission, GroupOperationType, IAndroidPushConfig, IAsyncRes, IBaseConversationInfo, IBlockedMessageInfo, IChannelAndUserGroupChangeData, IChatRoomEntries, IChatRoomEntry, IChatroomEntries, IChatroomEntry, IChatroomEntryListenerData, IChatroomInfo, IChatroomJoinResponse, IChatroomListenerData, IChatroomNotifyBan, IChatroomNotifyBlock, IChatroomNotifyMultiLoginSync, IChatroomRejoinedFailed, IChatroomRejoinedInfo, IChatroomRejoinedSuccessed, IChatroomUser, IChatroomUserChangeInfo, IClearMessageOption, ICombineV2MessageContent, ICombinedMessage, IConversationIdentifier, IConversationOption, IConversationTag, IDeletedExpansion, IDeliveredUser, IDownloadAuth, IErrorKeys, IEventListener, IExpansionListenerData, IFirstUnreadMessageInfo, IFollowsInfo, IFriendAdd, IFriendApplicationInfo, IFriendApplicationStatusChange, IFriendDelete, IFriendInfo, IFriendInfoChangedSync, IFriendRelationInfo, IGetUltraGroupListOption, IGooglePushConfig, IGroupApplicationInfo, IGroupFollowsChangedSync, IGroupFollowsList, IGroupFollowsUserInfo, IGroupInfo, IGroupInfoChanged, IGroupInfoOption, IGroupMemberInfo, IGroupMemberInfoChanged, IGroupMembers, IGroupMessageDeliverInfo, IGroupMessageDeliverStatus, IGroupMessageDeliveredStatusInfo, IGroupOperationInfo, IGroupReadReceiptData, IGroupRemarkChangedSync, IHarmonyOSPushConfig, IInsertMessage, IMessageDeliver, IMessageReadReceiptV4Response, IMessageReader, IMessageReaderResponse, INotificationQuietHoursSetting, IOperateInfo, IOperateStatusNotify, IOperateSummary, IPagingQueryOption, IPagingQueryResult, IPrivateReadReceiptData, IProcessCode, IPromiseResult, IProxy, IPushConfig, IQuitGroupConfig, IRTCRoomBindOption, IReadReceiptData, IReadReceiptInfo, IReadReceiptResponseInfo, IReceivedConversation, IReceivedConversationByTag, IReceivedMessage, IReceivedStatusInfo, IRemoveChatRoomEntries, IRemoveChatRoomEntry, IRemoveChatroomEntries, IRemoveChatroomEntry, IResponse, IStreamMessageResponseChunkData, ISubscribeRelationInfo, ISubscribeStatusDetail, ISubscribeUserStatusInfo, ISyncReadStatusData, ITagInfo, ITagParam, ITypingMessage, ITypingUser, IUltraChannelChangeInfo, IUltraChannelDeleteInfo, IUltraChannelUserKickedInfo, IUltraGroupConversation, IUltraGroupOption, IUltraGroupUnreadInfo, IUltraGroupUnreadMentionedOption, IUltraUnreadMsg, IUpdateItem, IUpdateMyProfileFail, IUpdatedConversation, IUpdatedExpansion, IUploadAuth, IUserGroupChangeData, IUserGroupStatusInfo, IUserProfile, IUserProfileInfo, IiOSPushConfig, InterruptionLevel, LogL, LogLevel, MentionedInfo, MentionedType, MessageBlockSourceType, MessageBlockType, MessageDirection, NotificationLevel, NotificationStatus, OnlineStatus, OperateStatus, PlatformInfo, PushImportanceHonor, PushNotificationQuietHoursLevel, QueryFriendsDirectionType, RCConnectionStatus, RCResult, ReadReceiptInfoV5, ReadReceiptResponseV5, ReadReceiptUser, ReadReceiptUsersOption, ReadReceiptUsersResult, ReceivedStatus, SentStatus, StreamMessageResponseEventType, SubscribeOperationType, SubscribeType, UltraGroupChannelChangeType, UltraGroupChannelType, UploadMethod, UserProfileVisibility, fail, ok } from '@rongcloud/engine';
1
+ import { FileType, APIContext, IAsyncRes, IPluginGenerator, MessageTypeDescription, LogLevel, EnableLogL, AreaCode, LogDBProxy, IReceivedMessage, IReceivedConversation, IPushConfig, IAuditInfoKeyInMessage, IRecallMsgOptions, IConversationOption, ITypingMessage, IUpdateItem, ErrorCode, IChatroomListenerData, IExpansionListenerData, IBlockedMessageInfo, IOperateStatusNotify, IUltraChannelChangeInfo, IUltraChannelDeleteInfo, IUltraChannelUserKickedInfo, IUserGroupStatusInfo, IMessageDeliver, IGroupMessageDeliverStatus, IReadReceiptData, ISyncReadStatusData, ISubscribeUserStatusInfo, ISubscribeRelationInfo, SubscribeType, IUserProfileInfo, IGroupOperationInfo, IGroupInfoChanged, IGroupMemberInfoChanged, IGroupApplicationInfo, IGroupRemarkChangedSync, IGroupFollowsChangedSync, IFriendAdd, IFriendDelete, IFriendApplicationStatusChange, IFriendInfoChangedSync, IStreamMessageResponseEventData as IStreamMessageResponseEventData$1, ReadReceiptResponseV5, ISpeechToTextResponse, GetConversationListByTimestampParams, RCResult, ConversationType, NotificationLevel, NotificationStatus, IConversationIdentifier, IConversationUnreadCount, IGetUltraGroupListOption, IUltraGroupConversation, IBaseConversationInfo, IUltraGroupOption, IUltraGroupUnreadMentionedOption, IUltraUnreadMsg, IUltraGroupUnreadInfo, IChatroomJoinResponse, IChatroomInfo, IChatroomEntry, IChatroomEntries, IRemoveChatroomEntry, IRTCRoomBindOption, ICombineMessageContent, ICombineV2MessageContent, ICommandMessageContent, IFileMessageContent, IGIFMessageContent, IGroupNotificationMessageContent, IImageMessageContent, IInformationNotificationMessageContent, ILocationMessageContent, IReferenceMessageContent, IRichContentMessageContent, ISightMessageContent, IStreamMessageContent, ITextMessageContent, IHQVoiceMessageContent, IVoiceMessageContent, IUserExtraKeyInMessage, IExtraDataKeyInMessage, IMentionedInfoKeyInMessage, IMessageReadReceiptV4Response, IGroupReadReceiptData, MessageDirection, IClearMessageOption, IMessageReaderResponse, IFirstUnreadMessageInfo, ReadReceiptInfoV5, IMessageIdentifier, ReadReceiptUsersOption, ReadReceiptUsersResult, IConvertSpeechToTextOption, ITagParam, ITagInfo, IConversationTag, IUploadAuth, IDownloadAuth, UploadMethod, ReceivedStatus, IReceivedStatusInfo, SentStatus, IInsertMessage, IGroupMessageDeliverInfo, ISearchMessageParams, IProxy, IPromiseResult, IResponse, IUpdateMyProfileFail, UserProfileVisibility, IGroupInfoOption, ICreateGroupFail, IErrorKeys, IGroupInfo, IQuitGroupConfig, GroupMemberRole, IPagingQueryOption, IPagingQueryResult, IGroupMemberInfo, IProcessCode, GroupApplicationDirection, GroupApplicationStatus, IFollowsInfo, DirectionType, IFriendRelationInfo, QueryFriendsDirectionType, IFriendInfo, FriendApplicationType, FriendApplicationStatus, IFriendApplicationInfo, FriendAddPermission, RCConnectionStatus, AppSettings, INotificationQuietHoursSetting, MentionedInfo } from '@rongcloud/engine';
2
+ export { AppSettings, AreaCode, ChatroomEntryType, ChatroomSyncStatusReason, ChatroomUserChangeType, ChrmMemBanType, ChrmMemOperateType, ChrmSyncStatus, ConnectionStatus, ConversationType, DirectionType, EnableLogL, ErrorCode, FileType, FriendAddPermission, FriendApplicationStatus, FriendApplicationType, FriendRelationType, GetConversationListByTimestampParams, GroupApplicationDirection, GroupApplicationStatus, GroupApplicationType, GroupInviteHandlePermission, GroupJoinPermission, GroupMemberInfoEditPermission, GroupMemberRole, GroupOperation, GroupOperationPermission, GroupOperationType, IAndroidPushConfig, IAsyncRes, IAuditInfoKeyInMessage, IAuditInfoValueInMessage, IBaseConversationInfo, IBlockedMessageInfo, IChannelAndUserGroupChangeData, IChatRoomEntries, IChatRoomEntry, IChatroomEntries, IChatroomEntry, IChatroomEntryListenerData, IChatroomInfo, IChatroomJoinResponse, IChatroomListenerData, IChatroomNotifyBan, IChatroomNotifyBlock, IChatroomNotifyMultiLoginSync, IChatroomRejoinedFailed, IChatroomRejoinedInfo, IChatroomRejoinedSuccessed, IChatroomUser, IChatroomUserChangeInfo, IClearMessageOption, ICombineMessageContent, ICombineV2MessageContent, ICombinedMessage, ICommandMessageContent, IConversationFilter, IConversationIdentifier, IConversationOption, IConversationTag, IConvertHQVoiceMessageToTextOption, IConvertSpeechToTextOption, IConvertVoiceMessageToTextOption, IDeletedExpansion, IDeliveredUser, IDownloadAuth, IErrorKeys, IEventListener, IExpansionListenerData, IExtraDataKeyInMessage, IFileMessageContent, IFirstUnreadMessageInfo, IFollowsInfo, IFriendAdd, IFriendApplicationInfo, IFriendApplicationStatusChange, IFriendDelete, IFriendInfo, IFriendInfoChangedSync, IFriendRelationInfo, IGIFMessageContent, IGetUltraGroupListOption, IGooglePushConfig, IGroupApplicationInfo, IGroupFollowsChangedSync, IGroupFollowsList, IGroupFollowsUserInfo, IGroupInfo, IGroupInfoChanged, IGroupInfoOption, IGroupMemberInfo, IGroupMemberInfoChanged, IGroupMembers, IGroupMessageDeliverInfo, IGroupMessageDeliverStatus, IGroupMessageDeliveredStatusInfo, IGroupNotificationMessageContent, IGroupOperationInfo, IGroupReadReceiptData, IGroupRemarkChangedSync, IHQVoiceMessageContent, IHarmonyOSPushConfig, IImageMessageContent, IInformationNotificationMessageContent, IInsertMessage, ILocationMessageContent, ILogData, IMentionedInfoKeyInMessage, IMessageDeliver, IMessageFilter, IMessageIdentifier, IMessageReadReceiptV4Response, IMessageReader, IMessageReaderResponse, INotificationQuietHoursSetting, IOperateInfo, IOperateStatusNotify, IOperateSummary, IPagingQueryOption, IPagingQueryResult, IPrivateReadReceiptData, IProcessCode, IPromiseResult, IProxy, IPushConfig, IQuitGroupConfig, IRTCRoomBindOption, IReadReceiptData, IReadReceiptInfo, IReadReceiptResponseInfo, IReceivedConversation, IReceivedConversationByTag, IReceivedMessage, IReceivedStatusInfo, IReferContentInMessage, IReferContentKeyInMessage, IReferenceMessageContent, IRemoveChatRoomEntries, IRemoveChatRoomEntry, IRemoveChatroomEntries, IRemoveChatroomEntry, IResponse, IRichContentMessageContent, ISearchMessageParams, ISearchMessagesResult, ISightMessageContent, ISpeechToTextInfo, ISpeechToTextResponse, IStreamMessageContent, IStreamMessageResponseChunkData, ISubscribeRelationInfo, ISubscribeStatusDetail, ISubscribeUserStatusInfo, ISyncReadStatusData, ITagInfo, ITagParam, ITextMessageContent, ITimeRange, ITypingMessage, ITypingUser, IUltraChannelChangeInfo, IUltraChannelDeleteInfo, IUltraChannelUserKickedInfo, IUltraGroupConversation, IUltraGroupOption, IUltraGroupUnreadInfo, IUltraGroupUnreadMentionedOption, IUltraUnreadMsg, IUpdateItem, IUpdateMyProfileFail, IUpdatedConversation, IUpdatedExpansion, IUploadAuth, IUserExtraKeyInMessage, IUserExtraValueInMessage, IUserGroupChangeData, IUserGroupStatusInfo, IUserProfile, IUserProfileInfo, IVoiceMessageContent, IiOSPushConfig, InterruptionLevel, LogDBProxy, LogL, LogLevel, MentionedInfo, MentionedType, MessageAuditType, MessageBlockSourceType, MessageBlockType, MessageDirection, MessageType, NotificationLevel, NotificationStatus, OnlineStatus, OperateStatus, PlatformInfo, PushImportanceHonor, PushNotificationQuietHoursLevel, QueryFriendsDirectionType, RCConnectionStatus, RCResult, ReadReceiptInfoV5, ReadReceiptResponseV5, ReadReceiptUser, ReadReceiptUsersOption, ReadReceiptUsersResult, ReceivedStatus, SentStatus, SpeechToTextStatus, StreamMessageResponseEventType, SubscribeOperationType, SubscribeType, UltraGroupChannelChangeType, UltraGroupChannelType, UploadMethod, UserProfileVisibility, UserType, createLogDBProxy, fail, ok } from '@rongcloud/engine';
3
3
 
4
4
  /**
5
5
  * 缩略图配置
@@ -59,6 +59,14 @@ interface IUploadResult {
59
59
  * 音频时长,单位秒
60
60
  */
61
61
  duration?: number;
62
+ /**
63
+ * 音频声道数
64
+ */
65
+ numberOfChannels?: number;
66
+ /**
67
+ * 音频采样率
68
+ */
69
+ sampleRate?: number;
62
70
  length?: number;
63
71
  /**
64
72
  * 图片缩略图
@@ -95,236 +103,6 @@ declare class UploadTask {
95
103
  awaitResult(): Promise<IAsyncRes<IUploadResult>>;
96
104
  }
97
105
 
98
- /**
99
- * 初始化配置项
100
- * @category Type
101
- */
102
- declare type IInitOption = {
103
- /**
104
- * 应用 appkey 标识
105
- */
106
- appkey: string;
107
- /**
108
- * 该配置已废弃,请使用 `logOutputLevel` 替代。
109
- * @deprecated
110
- * 修改 SDK 内部日志打印等级,默认为 `LogLevel.WARN`。
111
- */
112
- logLevel?: LogLevel;
113
- /**
114
- * 修改内部日志打印等级,默认输出 `LogL.WARN` 及以上级别
115
- */
116
- logOutputLevel?: EnableLogL;
117
- /**
118
- * @deprecated 配置已废弃
119
- */
120
- logStdout?: (logLevel: LogLevel, content: string) => void;
121
- /**
122
- * 自定义导航地址,公有云用户不推荐修改
123
- */
124
- navigators?: string[];
125
- /**
126
- * 连接方式,默认使用 'websocket'
127
- * @deprecated 自 5.6.0 版本开始,不再支持 Comet 连接,该配置项失效。
128
- */
129
- connectType?: 'websocket' | 'comet';
130
- /**
131
- * 小程序平台专属配置
132
- */
133
- customCMP?: string[];
134
- /**
135
- * @deprecated
136
- * 是否打开 IndexDB 存储,默认为 true
137
- */
138
- indexDBSwitch?: boolean;
139
- /**
140
- * @deprecated 已废弃,默认不再在 Electron 平台下校验导航服务的 CA 问题
141
- */
142
- checkCA?: boolean;
143
- /**
144
- * 七牛上传文件地址域名(仅私有云 RCX 服务支持),优先级高于 ossConfig 配置
145
- */
146
- uploadDomain?: string;
147
- /**
148
- * 开启后,SDK 内的 HTTP 请求将由 Electron 主进程内发送。
149
- * @since 5.6.0
150
- * @description
151
- * 仅在 Electron 环境中搭配 `@rongcloud/electron-renderer` 与 `@rongcloud/electron` 包时有效。
152
- * * 当值为 `true` 时,HTTP 请求由 Electron 主进程内发送,不受浏览器安全沙箱策略限制。
153
- * * 当值为 `false` 时,保持使用 Chromium 的 XMLHttpRequest 发送 HTTP 协议请求,
154
- * 请求由渲染进程内发出,受浏览器安全沙箱策略限制。
155
- * @defautl `false`
156
- */
157
- httpInMainProcess?: boolean;
158
- /**
159
- * IndexDB 数据库内的日志有效期,单位为小时,有效值为 `24` - `168`,默认 IndexDB 内日志数据有效期 168 小时
160
- */
161
- logExpireTime?: number;
162
- /**
163
- * 区域码
164
- * @since 5.7.9
165
- */
166
- areaCode?: AreaCode;
167
- /**
168
- * 日志上报服务地址
169
- * @since 5.7.7
170
- */
171
- logServerUrl?: string;
172
- /**
173
- * 私有云环境配置
174
- */
175
- environment?: string;
176
- /**
177
- * 启动事件循环阻塞检查;当值为 `true` 时,SDK 会启动事件循环阻塞检查,并在发现事件循环阻塞时记录日志。
178
- * @since 5.20.0
179
- */
180
- eventLoopBlockingCheck?: boolean;
181
- };
182
- /**
183
- * 用户收到的消息结构
184
- * @category Interface
185
- */
186
- declare type IAReceivedMessage = Omit<IReceivedMessage, 'channelId' | 'isMentioned' | 'disableNotification' | 'isStatusMessage' | 'expansion'> & {
187
- /**
188
- * 会话的业务标识
189
- */
190
- channelId: string;
191
- /**
192
- * 是否为 @ 消息
193
- */
194
- isMentioned?: boolean;
195
- /**
196
- * 消息是否静默
197
- * @description 静默消息不会发送 Push 信息和本地通知提醒
198
- */
199
- disableNotification?: boolean;
200
- /**
201
- * 是否是状态消息
202
- */
203
- isStatusMessage?: boolean;
204
- /**
205
- * 消息扩展
206
- */
207
- expansion?: {
208
- [key: string]: any;
209
- } | null;
210
- };
211
- /**
212
- * 获取历史消息配置项
213
- * @category Type
214
- */
215
- declare type GetHistoryMessageOption = {
216
- /**
217
- * 获取此时间之前的消息,0 为从当前时间拉取
218
- */
219
- timestamp?: number;
220
- /**
221
- * 获取消息的数量,范围:1-100
222
- * 如果 SDK < 5.7.4,范围为 [1-20];如果 SDK ≧ 5.7.4,范围为 [1-100]。默认值 `20`
223
- */
224
- count?: number;
225
- /**
226
- * 获取消息的排列顺序
227
- * * 0: 升序
228
- * * 1: 降序
229
- */
230
- order?: 0 | 1;
231
- };
232
- /**
233
- * 通过消息类型获取历史消息配置项
234
- * @category Interface
235
- */
236
- interface IGetHistoryMessagesByTypesOption extends GetHistoryMessageOption {
237
- /**
238
- * 消息类型
239
- */
240
- messageTypes: string[];
241
- }
242
- /**
243
- * 获取历史消息返回结构
244
- * @category Type
245
- */
246
- declare type GetHistoryMessageResult = {
247
- list: IAReceivedMessage[];
248
- hasMore: boolean;
249
- };
250
-
251
- /**
252
- * 初始化
253
- * @description 初始化 IM SDK,传入 Appkey 及相关配置信息
254
- * @category 基础
255
- * @param options 初始化参数,类型为 {@link IInitOption}
256
- * @example
257
- * 初始化示例:
258
- * ```ts
259
- * RongIMLib.init({ appkey: 'appkey' });
260
- * console.log('初始化完成');
261
- * ```
262
- */
263
- declare function init(options: IInitOption): void;
264
- /**
265
- * 反初始化
266
- * @description 反初始化,清空所有监听及计时器,停止日志上报等业务
267
- * * **适用场景**:
268
- * 1. 应用退出时,推荐使用此方法
269
- * 2. 需要更换 appkey 时,需要调用此方法后,重新使用新 Appkey 在次调用 {@link init} 方法
270
- * @category 基础
271
- * @example
272
- * 反初始化示例:
273
- * ```ts
274
- * await RongIMLib.destroy();
275
- * console.log('反初始化完成');
276
- * ```
277
- */
278
- declare function destroy(): Promise<void>;
279
- /**
280
- * 获取 IM 连接状态
281
- * @category 基础
282
- * @example
283
- * 获取 IM 连接状态示例:
284
- * ```ts
285
- * const status = RongIMLib.getConnectionStatus();
286
- * console.log('获取 IM 连接状态:', status);
287
- * ```
288
- */
289
- declare function getConnectionStatus(): RCConnectionStatus;
290
- /**
291
- * 当前服务器时间
292
- * 校准时间,可能存在误差
293
- * @category 基础
294
- * @hidden
295
- */
296
- declare function getServerTime(): number;
297
- /**
298
- * 获取 IM 连接用户的 id
299
- * @category 基础
300
- * @example
301
- * 获取当前用户 id 示例:
302
- * ```ts
303
- * const userId = RongIMLib.getCurrentUserId();
304
- * console.log('获取当前用户 id:', userId);
305
- * ```
306
- */
307
- declare function getCurrentUserId(): string;
308
- /**
309
- * (内部方法)用于统计各组件版本信息
310
- * @param name
311
- * @param version
312
- * @hidden
313
- */
314
- declare function __addSDKVersion(name: string, version: string): void;
315
- /**
316
- * 获取 deviceId
317
- * @description 获取当前设备的唯一标识
318
- * @category 基础
319
- * @example
320
- * 获取 deviceId 示例:
321
- * ```ts
322
- * const deviceId = RongIMLib.getDeviceId();
323
- * console.log('获取 deviceId:', deviceId);
324
- * ```
325
- */
326
- declare function getDeviceId(): string;
327
-
328
106
  /**
329
107
  * 装载 plugin 插件
330
108
  * @description 装载 plugin 插件,需在调用 `connect` 方法之前使用,并返回相应的插件实例
@@ -634,15 +412,12 @@ declare enum Events {
634
412
  * 消息已读回执响应事件
635
413
  * @since 5.20.0
636
414
  */
637
- MESSAGE_RECEIPT_RESPONSE_V5 = "MESSAGE_RECEIPT_RESPONSE_V5"
638
- }
639
- /**
640
- * 消息审核状态
641
- * @category Enum
642
- */
643
- declare enum MessageAuditType {
644
- DISALLOW = 0,
645
- ALLOW = 1
415
+ MESSAGE_RECEIPT_RESPONSE_V5 = "MESSAGE_RECEIPT_RESPONSE_V5",
416
+ /**
417
+ * 语音转文字结果通知
418
+ * @since 5.22.0
419
+ */
420
+ SPEECH_TO_TEXT_RESPONSE = "SPEECH_TO_TEXT_RESPONSE"
646
421
  }
647
422
 
648
423
  declare class BaseMessage<T = any> {
@@ -650,12 +425,21 @@ declare class BaseMessage<T = any> {
650
425
  content: T;
651
426
  readonly isPersited: boolean;
652
427
  readonly isCounted: boolean;
428
+ /**
429
+ * @param messageType 消息类型
430
+ * @param content 消息内容
431
+ * @param isPersited 是否存储
432
+ * @param isCounted 是否计数
433
+ */
653
434
  constructor(messageType: string, content: T, isPersited?: boolean, isCounted?: boolean);
654
435
  }
655
436
  /**
656
437
  * 内置消息类型
657
438
  */
658
- declare class InnerMessage<T = any> extends BaseMessage<T> {
439
+ declare class BuiltinMessage<T = any> extends BaseMessage<T> {
440
+ /**
441
+ * @hidden
442
+ */
659
443
  constructor(objName: string, desc: MessageTypeDescription, content: T);
660
444
  }
661
445
  /**
@@ -665,85 +449,187 @@ declare class InnerMessage<T = any> extends BaseMessage<T> {
665
449
  declare type MessageConstructor<T> = new (content: T) => BaseMessage<T>;
666
450
 
667
451
  /**
668
- * 会话更新项结构
669
- * @category Interface
452
+ * 初始化配置项
453
+ * @category Type
670
454
  */
671
- interface IConversationUpdateItem {
455
+ declare type IInitOption = {
456
+ /**
457
+ * 应用 appkey 标识
458
+ */
459
+ appkey: string;
460
+ /**
461
+ * 该配置已废弃,请使用 `logOutputLevel` 替代。
462
+ * @deprecated
463
+ * 修改 SDK 内部日志打印等级,默认为 `LogLevel.WARN`。
464
+ */
465
+ logLevel?: LogLevel;
466
+ /**
467
+ * 修改内部日志打印等级,默认输出 `LogL.WARN` 及以上级别
468
+ */
469
+ logOutputLevel?: EnableLogL;
470
+ /**
471
+ * @deprecated 配置已废弃
472
+ */
473
+ logStdout?: (logLevel: LogLevel, content: string) => void;
474
+ /**
475
+ * 自定义导航地址,公有云用户不推荐修改
476
+ */
477
+ navigators?: string[];
478
+ /**
479
+ * 连接方式,默认使用 'websocket'
480
+ * @deprecated 自 5.6.0 版本开始,不再支持 Comet 连接,该配置项失效。
481
+ */
482
+ connectType?: 'websocket' | 'comet';
483
+ /**
484
+ * 小程序平台专属配置
485
+ */
486
+ customCMP?: string[];
487
+ /**
488
+ * @deprecated
489
+ * 是否打开 IndexDB 存储,默认为 true
490
+ */
491
+ indexDBSwitch?: boolean;
492
+ /**
493
+ * @deprecated 已废弃,默认不再在 Electron 平台下校验导航服务的 CA 问题
494
+ */
495
+ checkCA?: boolean;
496
+ /**
497
+ * 七牛上传文件地址域名(仅私有云 RCX 服务支持),优先级高于 ossConfig 配置
498
+ */
499
+ uploadDomain?: string;
500
+ /**
501
+ * 开启后,SDK 内的 HTTP 请求将由 Electron 主进程内发送。
502
+ * @since 5.6.0
503
+ * @description
504
+ * 仅在 Electron 环境中搭配 `@rongcloud/electron-renderer` 与 `@rongcloud/electron` 包时有效。
505
+ * * 当值为 `true` 时,HTTP 请求由 Electron 主进程内发送,不受浏览器安全沙箱策略限制。
506
+ * * 当值为 `false` 时,保持使用 Chromium 的 XMLHttpRequest 发送 HTTP 协议请求,
507
+ * 请求由渲染进程内发出,受浏览器安全沙箱策略限制。
508
+ * @defautl `false`
509
+ */
510
+ httpInMainProcess?: boolean;
511
+ /**
512
+ * IndexDB 数据库内的日志有效期,单位为小时,有效值为 `24` - `168`,默认 IndexDB 内日志数据有效期 168 小时
513
+ */
514
+ logExpireTime?: number;
515
+ /**
516
+ * 区域码
517
+ * @since 5.7.9
518
+ */
519
+ areaCode?: AreaCode;
520
+ /**
521
+ * 日志上报服务地址
522
+ * @since 5.7.7
523
+ */
524
+ logServerUrl?: string;
525
+ /**
526
+ * 私有云环境配置
527
+ */
528
+ environment?: string;
529
+ /**
530
+ * 启动事件循环阻塞检查;当值为 `true` 时,SDK 会启动事件循环阻塞检查,并在发现事件循环阻塞时记录日志。
531
+ * @since 5.20.0
532
+ */
533
+ eventLoopBlockingCheck?: boolean;
672
534
  /**
673
- * 时间
535
+ * 开启已读回执信息本地存储
536
+ * @description 需注意:Electron 平台离线量消息量大的情况下,登录连接后拉取大量离线,可能产生性能瓶颈
537
+ * * 公有云 SDK 默认开启
538
+ * * 私有云 SDK 默认关闭
539
+ * @since 5.22.0
674
540
  */
675
- time: number;
541
+ enableReadReceiptStorage?: boolean;
676
542
  /**
677
- * 更新数据
543
+ * 启动导航服务 V2,默认关闭,仅私有云有效
544
+ * @since 5.22.0
678
545
  */
679
- val: any;
680
- }
546
+ useNaviV2?: boolean;
547
+ /**
548
+ * @hidden
549
+ * 日志存储代理
550
+ */
551
+ loggerProxy?: LogDBProxy;
552
+ };
681
553
  /**
682
- * 会话数据更新结构
554
+ * 用户收到的消息结构
683
555
  * @category Interface
684
556
  */
685
- interface IReceivedUpdateConversation {
686
- /**
687
- * 会话更新项
688
- */
689
- updatedItems: {
690
- [key: string]: IConversationUpdateItem;
691
- };
557
+ interface IAReceivedMessage extends Omit<IReceivedMessage, 'channelId' | 'isMentioned' | 'disableNotification' | 'isStatusMessage' | 'expansion'> {
692
558
  /**
693
- * 会话类型
694
- * * 1: 单聊
695
- * * 3: 群聊
696
- * * 4: 聊天室
697
- * * 5: 客服会话
698
- * * 6: 系统消息
699
- * * 7: 默认关注的公众号
700
- * * 8: 手动关注的公众号
701
- * * 9: RTCLib 房间
559
+ * 会话的业务标识
702
560
  */
703
- conversationType: number;
561
+ channelId: string;
704
562
  /**
705
- * 会话 id
563
+ * 是否为 @ 消息
706
564
  */
707
- targetId: string;
565
+ isMentioned?: boolean;
708
566
  /**
709
- * 会话最后一条消息
567
+ * 消息是否静默
568
+ * @description 静默消息不会发送 Push 信息和本地通知提醒
710
569
  */
711
- latestMessage?: IAReceivedMessage;
570
+ disableNotification?: boolean;
712
571
  /**
713
- * 未读数
572
+ * 是否是状态消息
714
573
  */
715
- unreadMessageCount?: number;
574
+ isStatusMessage?: boolean;
716
575
  /**
717
- * 是否是 @ 消息
718
- */
719
- hasMentioned?: boolean;
576
+ * 消息扩展
577
+ */
578
+ expansion?: {
579
+ [key: string]: any;
580
+ } | null;
581
+ }
582
+ /**
583
+ * 获取历史消息配置项
584
+ * @category Type
585
+ */
586
+ declare type GetHistoryMessageOption = {
720
587
  /**
721
- * @ 信息
588
+ * 获取此时间之前的消息,0 为从当前时间拉取
722
589
  */
723
- mentionedInfo?: MentionedInfo;
590
+ timestamp?: number;
724
591
  /**
725
- * 消息最后阅读时间
592
+ * 获取消息的数量,有效值范围 [1-100],默认值 `20`
593
+ * * SDK < 5.7.4,范围为 [1-20]
594
+ * * SDK ≧ 5.7.4,范围为 [1-100]
726
595
  */
727
- lastUnreadTime?: number;
596
+ count?: number;
728
597
  /**
729
- * 免打扰状态
598
+ * 获取消息的排列顺序
599
+ * * 0: 升序
600
+ * * 1: 降序
730
601
  */
731
- notificationStatus?: NotificationStatus;
602
+ order?: 0 | 1;
603
+ };
604
+ /**
605
+ * 通过消息类型获取历史消息配置项
606
+ * @category Interface
607
+ */
608
+ interface IGetHistoryMessagesByTypesOption extends GetHistoryMessageOption {
732
609
  /**
733
- * 是否制定
610
+ * 消息类型
734
611
  */
735
- isTop?: boolean;
612
+ messageTypes: string[];
736
613
  }
614
+ /**
615
+ * 获取历史消息返回结构
616
+ * @category Type
617
+ */
618
+ declare type GetHistoryMessageResult = {
619
+ list: IAReceivedMessage[];
620
+ hasMore: boolean;
621
+ };
622
+
737
623
  /**
738
624
  * 用户收到的会话结构
739
625
  * @category Interface
740
626
  */
741
- declare type IAReceivedConversation = Omit<IReceivedConversation, 'latestMessage'> & {
627
+ interface IAReceivedConversation extends Omit<IReceivedConversation, 'latestMessage'> {
742
628
  /**
743
629
  * 会话中的最后一条消息
744
630
  */
745
631
  latestMessage: IAReceivedMessage | null;
746
- };
632
+ }
747
633
  /**
748
634
  * 分页获取标签下会话数据结构
749
635
  * @category Interface
@@ -838,7 +724,7 @@ interface ISendMessageOptions {
838
724
  /**
839
725
  * 消息审核配置
840
726
  */
841
- auditInfo?: IAuditInfo;
727
+ auditInfo?: IAuditInfoKeyInMessage;
842
728
  /**
843
729
  * 禁止更新到会话最新一条消息,默认 false: 更新,true: 不更新
844
730
  */
@@ -893,69 +779,6 @@ interface IInsertOptions {
893
779
  */
894
780
  disableUpdateLastMessage?: boolean;
895
781
  }
896
- /**
897
- * 用户信息结构
898
- * @category Interface
899
- */
900
- interface IUserInfo {
901
- user?: {
902
- /**
903
- * 用户 ID
904
- */
905
- id?: string;
906
- /**
907
- * 用户名
908
- */
909
- name?: string;
910
- /**
911
- * 用户头像地址
912
- * @deprecated
913
- */
914
- portraitUri?: string;
915
- /**
916
- * user info 中附加信息
917
- */
918
- extra?: string;
919
- /**
920
- * 用户头像地址
921
- */
922
- portrait?: string;
923
- /**
924
- * 备注
925
- */
926
- alias?: string;
927
- };
928
- }
929
- /**
930
- * 消息扩展结构
931
- * @category Interface
932
- */
933
- interface IExtraData {
934
- /**
935
- * 消息中的附加信息
936
- */
937
- extra?: string;
938
- }
939
- /**
940
- * 消息审核配置结构
941
- * @category Interface
942
- */
943
- interface IAuditInfo {
944
- audit?: {
945
- /**
946
- * 发送方指定是否送审,1:送审(默认值),0:不送审
947
- */
948
- auditType?: MessageAuditType;
949
- /**
950
- * 项目名称,默认为空字符串
951
- */
952
- project?: string;
953
- /**
954
- * 策略映射字段
955
- */
956
- strategy?: string;
957
- };
958
- }
959
782
  /**
960
783
  * 消息关键信息结构
961
784
  * @category Interface
@@ -974,7 +797,8 @@ interface IMessageDesc {
974
797
  * 撤回消息 option 参数
975
798
  * @category Interface
976
799
  */
977
- declare type IRecallMessageOptions = Omit<IRecallMsgOptions, 'pushContent'>;
800
+ interface IRecallMessageOptions extends Omit<IRecallMsgOptions, 'pushContent'> {
801
+ }
978
802
  /**
979
803
  * 上传过程中的回调钩子
980
804
  * @category Interface
@@ -1119,6 +943,21 @@ interface IConversationEvent {
1119
943
  */
1120
944
  conversationList: IConversationState[];
1121
945
  }
946
+ /**
947
+ * 搜索消息结果
948
+ * @category Interface
949
+ * @since 5.22.0
950
+ */
951
+ interface ISearchMessagesResult {
952
+ /**
953
+ * 消息列表
954
+ */
955
+ messages: IAReceivedMessage[];
956
+ /**
957
+ * 数量
958
+ */
959
+ count: number;
960
+ }
1122
961
 
1123
962
  /**
1124
963
  * 事件监听器
@@ -1181,9 +1020,10 @@ declare type EventListeners = {
1181
1020
  [Events.FRIEND_INFO_CHANGED_SYNC]: (data: IFriendInfoChangedSync) => void;
1182
1021
  [Events.DATABASE_UPGRADE_WILL_START]: () => void;
1183
1022
  [Events.DATABASE_UPGRADING]: (progress: number) => void;
1184
- [Events.DATABASE_UPGRADE_DID_COMPLETE]: (code: ErrorCode) => void;
1023
+ [Events.DATABASE_UPGRADE_DID_COMPLETE]: (code: number) => void;
1185
1024
  [Events.STREAM_MESSAGE_RESPONSE]: (evt: IStreamMessageResponseEventData$1<IAReceivedMessage>) => void;
1186
1025
  [Events.MESSAGE_RECEIPT_RESPONSE_V5]: (data: ReadReceiptResponseV5[]) => void;
1026
+ [Events.SPEECH_TO_TEXT_RESPONSE]: (response: ISpeechToTextResponse) => void;
1187
1027
  };
1188
1028
 
1189
1029
  /**
@@ -1253,6 +1093,13 @@ declare function removeEventListeners(eventType: string): void;
1253
1093
  */
1254
1094
  declare function clearEventListeners(): void;
1255
1095
 
1096
+ interface IGetConversationListOptions extends Partial<Pick<GetConversationListByTimestampParams, 'count' | 'startTime'>> {
1097
+ /**
1098
+ * * 0 - 从 startTime 开始向前查询
1099
+ * * 1 - 从 startTime 开始向后查询
1100
+ */
1101
+ order?: 0 | 1;
1102
+ }
1256
1103
  /**
1257
1104
  * 获取会话列表
1258
1105
  *
@@ -1274,13 +1121,7 @@ declare function clearEventListeners(): void;
1274
1121
  * console.info('获取会话列表结果:', conversationList);
1275
1122
  * ```
1276
1123
  */
1277
- declare function getConversationList$1(options?: Partial<Pick<GetConversationListByTimestampParams, 'count' | 'startTime'>> & {
1278
- /**
1279
- * * 0 - 从 startTime 开始向前查询
1280
- * * 1 - 从 startTime 开始向后查询
1281
- */
1282
- order?: 0 | 1;
1283
- }, channelId?: string): Promise<RCResult<IAReceivedConversation[]>>;
1124
+ declare function getConversationList$1(options?: IGetConversationListOptions, channelId?: string): Promise<RCResult<IAReceivedConversation[]>>;
1284
1125
  /**
1285
1126
  * 获取指定会话数据
1286
1127
  * * 自 5.20.0 版本开始,该接口支持超级群会话获取
@@ -2377,7 +2218,7 @@ declare function getAllChatRoomEntries(targetId: string): Promise<IAsyncRes<{
2377
2218
  * console.log('获取聊天室的历史消息结果:', res);
2378
2219
  * ```
2379
2220
  */
2380
- declare function getChatroomHistoryMessages(targetId: string, options: GetHistoryMessageOption): Promise<IAsyncRes<GetHistoryMessageResult>>;
2221
+ declare function getChatroomHistoryMessages(targetId: string, options: GetHistoryMessageOption): Promise<RCResult<GetHistoryMessageResult>>;
2381
2222
  /**
2382
2223
  * 绑定音视频房间
2383
2224
  * @description 聊天室与音视频房间绑定成功后,只要音视频房间仍存在,则阻止聊天室自动销毁
@@ -2464,430 +2305,191 @@ declare function getBlacklist(): Promise<IAsyncRes<string[]>>;
2464
2305
  */
2465
2306
  declare function getBlacklistStatus(userId: string): Promise<IAsyncRes<boolean>>;
2466
2307
 
2467
- interface IMentionedInfo {
2468
- /**
2469
- * 群组消息中的 @ 信息
2470
- */
2471
- mentionedInfo?: MentionedInfo;
2472
- }
2473
-
2474
2308
  /**
2475
- * 合并转发消息
2309
+ * @deprecated - 已废弃,请使用 `ICombineMessageContent` 替代
2476
2310
  * @category Interface
2477
2311
  */
2478
- interface ICombineMessageBody extends IExtraData, IUserInfo, IMentionedInfo {
2479
- /**
2480
- * 存储在融云服务器的远端 HTML 文件路径
2481
- */
2482
- remoteUrl: string;
2483
- /**
2484
- * 在会话界面显示的合并转发消息中,前 4 条消息的用户名称
2485
- */
2486
- nameList: string[];
2487
- /**
2488
- * 在会话界面显示的合并转发消息中,前 4 条消息的简略信息,与 nameList 属 性相对应
2489
- */
2490
- summaryList: string[];
2491
- /**
2492
- * 会话类型,目前合并转发功能支持二人会话及群聊会话,二人会话是 1、群组会话是 3
2493
- */
2494
- conversationType: ConversationType;
2495
- }
2312
+ declare type ICombineMessageBody = ICombineMessageContent;
2313
+
2496
2314
  /**
2497
2315
  * 合并转发消息类型
2498
2316
  */
2499
- declare class CombineMessage extends InnerMessage<ICombineMessageBody> {
2500
- constructor(content: ICombineMessageBody);
2317
+ declare class CombineMessage extends BuiltinMessage<ICombineMessageContent> {
2318
+ constructor(content: ICombineMessageContent);
2501
2319
  }
2502
2320
 
2503
2321
  /**
2504
- * 合并消息
2322
+ * 合并转发消息 v2 版本 Content 结构
2505
2323
  * @category Type
2506
2324
  * @hidden
2325
+ * @deprecated - 已废弃,请使用 `ICombineV2MessageContent` 替代
2507
2326
  */
2508
- declare type CombineV2MessageContent = ICombineV2MessageContent & IExtraData & IUserInfo & IMentionedInfo;
2327
+ declare type CombineV2MessageContent = ICombineV2MessageContent;
2328
+
2509
2329
  /**
2510
- * 合并消息
2511
- * @hidden
2330
+ * 合并转发消息 v2 版本
2331
+ * @since 5.22.0
2512
2332
  */
2513
- declare class CombineV2Message extends InnerMessage<CombineV2MessageContent> {
2514
- constructor(content: CombineV2MessageContent);
2333
+ declare class CombineV2Message extends BuiltinMessage<ICombineV2MessageContent> {
2334
+ constructor(content: ICombineV2MessageContent);
2515
2335
  }
2516
2336
 
2517
2337
  /**
2518
2338
  * 命令消息
2519
2339
  * @category Interface
2340
+ * @deprecated - 已废弃,请使用 `ICommandMessageContent` 替代
2520
2341
  */
2521
- interface ICommandMessageBody extends IUserInfo, IExtraData, IMentionedInfo {
2522
- /**
2523
- * 命令名称,可以自行定义
2524
- */
2525
- name: string;
2526
- /**
2527
- * 命令内容
2528
- */
2529
- data: string;
2530
- }
2342
+ declare type ICommandMessageBody = ICommandMessageContent;
2343
+
2531
2344
  /**
2532
2345
  * 命令消息类型
2533
2346
  */
2534
- declare class CommandMessage extends InnerMessage<ICommandMessageBody> {
2535
- constructor(content: ICommandMessageBody);
2347
+ declare class CommandMessage extends BuiltinMessage<ICommandMessageContent> {
2348
+ constructor(content: ICommandMessageContent);
2536
2349
  }
2537
2350
 
2538
2351
  /**
2539
2352
  * 文件消息
2540
2353
  * @category Interface
2354
+ * @deprecated - 已废弃,请使用 `IFileMessageContent` 替代
2541
2355
  */
2542
- interface IFileMessageBody extends IExtraData, IUserInfo, IMentionedInfo {
2543
- /**
2544
- * 文件名称
2545
- */
2546
- name: string;
2547
- /**
2548
- * 文件尺寸,单位:Byte
2549
- */
2550
- size: number;
2551
- /**
2552
- * 文件类型
2553
- */
2554
- type: string;
2555
- /**
2556
- * 远程文件资源地址
2557
- */
2558
- fileUrl: string;
2559
- }
2560
- declare class FileMessage extends InnerMessage<IFileMessageBody> {
2561
- constructor(content: IFileMessageBody);
2356
+ declare type IFileMessageBody = IFileMessageContent;
2357
+
2358
+ declare class FileMessage extends BuiltinMessage<IFileMessageContent> {
2359
+ constructor(content: IFileMessageContent);
2562
2360
  }
2563
2361
 
2564
2362
  /**
2565
2363
  * @category Interface
2364
+ * @deprecated - 已废弃,请使用 `IGIFMessageContent` 替代
2566
2365
  */
2567
- interface IGIFMessageBody extends IExtraData, IUserInfo, IMentionedInfo, IAuditInfo {
2568
- /**
2569
- * GIF 图片文件大小,单位为 Byte
2570
- */
2571
- gifDataSize: number;
2572
- /**
2573
- * GIF 图片资源 url 地址
2574
- */
2575
- remoteUrl: string;
2576
- /**
2577
- * 图片宽度
2578
- */
2579
- width: number;
2580
- /**
2581
- * 图片高度
2582
- */
2583
- height: number;
2584
- }
2585
- declare class GIFMessage extends InnerMessage<IGIFMessageBody> {
2586
- constructor(content: IGIFMessageBody);
2366
+ declare type IGIFMessageBody = IGIFMessageContent;
2367
+
2368
+ declare class GIFMessage extends BuiltinMessage<IGIFMessageContent> {
2369
+ constructor(content: IGIFMessageContent);
2587
2370
  }
2588
2371
 
2589
2372
  /**
2590
2373
  * 群组通知消息
2591
2374
  * @category Interface
2375
+ * @deprecated - 已废弃,请使用 `IGroupNotificationMessageContent` 替代
2592
2376
  */
2593
- interface IGroupNotificationMessageBody extends IUserInfo, IExtraData, IMentionedInfo {
2594
- /**
2595
- * 操作人用户 Id
2596
- */
2597
- operatorUserId: string;
2598
- /**
2599
- * 群组中各种通知的操作名称
2600
- */
2601
- operation: string;
2602
- /**
2603
- * 操作数据
2604
- */
2605
- data: string;
2606
- /**
2607
- * 消息内容
2608
- */
2609
- message: string;
2610
- /**
2611
- * 扩展信息
2612
- */
2613
- extra?: string;
2614
- }
2615
- declare class GroupNotificationMessage extends InnerMessage<IGroupNotificationMessageBody> {
2616
- constructor(content: IGroupNotificationMessageBody);
2617
- }
2377
+ declare type IGroupNotificationMessageBody = IGroupNotificationMessageContent;
2618
2378
 
2619
- /**
2620
- * 语音消息
2621
- * @category Interface
2622
- */
2623
- interface IHQVoiceMessageBody extends IUserInfo, IExtraData, IMentionedInfo, IAuditInfo {
2624
- /**
2625
- * 远程媒体资源地址
2626
- */
2627
- remoteUrl: string;
2628
- /**
2629
- * 编解码类型,默认为 aac 音频
2630
- */
2631
- type?: string;
2632
- /**
2633
- * 语音消息的时长,最大值为 60(单位:秒)
2634
- */
2635
- duration: number;
2636
- }
2637
- /**
2638
- * 高清语音消息类型
2639
- */
2640
- declare class HQVoiceMessage extends InnerMessage<IHQVoiceMessageBody> {
2641
- constructor(content: IHQVoiceMessageBody);
2379
+ declare class GroupNotificationMessage extends BuiltinMessage<IGroupNotificationMessageBody> {
2380
+ constructor(content: IGroupNotificationMessageBody);
2642
2381
  }
2643
2382
 
2644
2383
  /**
2645
2384
  * 图片消息
2646
2385
  * @category Interface
2386
+ * @deprecated - 已废弃,请使用 `IImageMessageContent` 替代
2647
2387
  */
2648
- interface IImageMessageBody extends IExtraData, IMentionedInfo, IUserInfo, IAuditInfo {
2649
- /**
2650
- * 图片的略缩图
2651
- * @description
2652
- * 1. 必须是 base64 字符串,图片类型为 JPG
2653
- * 2. base64 字符串大小不可超过 80 KB
2654
- * 3. 字符串前无媒体类型前缀
2655
- */
2656
- content: string;
2657
- /**
2658
- * 原图远程地址
2659
- */
2660
- imageUri: string;
2661
- /**
2662
- * 略缩图宽度
2663
- * @since 5.18.0
2664
- */
2665
- thumWidth?: number;
2666
- /**
2667
- * 略缩图高度
2668
- * @since 5.18.0
2669
- */
2670
- thumHeight?: number;
2671
- }
2672
- declare class ImageMessage extends InnerMessage<IImageMessageBody> {
2673
- constructor(content: IImageMessageBody);
2388
+ declare type IImageMessageBody = IImageMessageContent;
2389
+
2390
+ declare class ImageMessage extends BuiltinMessage<IImageMessageContent> {
2391
+ constructor(content: IImageMessageContent);
2674
2392
  }
2675
2393
 
2676
2394
  /**
2677
2395
  * 小灰条消息
2678
2396
  * @category Interface
2397
+ * @deprecated - 已废弃,请使用 `IInformationNotificationMessageContent` 替代
2679
2398
  */
2680
- interface IInformationNotificationMessageBody extends IUserInfo, IExtraData, IMentionedInfo {
2681
- /**
2682
- * 提示条消息内容
2683
- */
2684
- message: string;
2685
- /**
2686
- * 提示条消息附加信息
2687
- */
2688
- extra?: string;
2689
- }
2690
- declare class InformationNotificationMessage extends InnerMessage<IInformationNotificationMessageBody> {
2691
- constructor(content: IInformationNotificationMessageBody);
2399
+ declare type IInformationNotificationMessageBody = IInformationNotificationMessageContent;
2400
+
2401
+ declare class InformationNotificationMessage extends BuiltinMessage<IInformationNotificationMessageContent> {
2402
+ constructor(content: IInformationNotificationMessageContent);
2692
2403
  }
2693
2404
 
2694
2405
  /**
2695
2406
  * 位置消息数据
2696
2407
  * @category Interface
2408
+ * @deprecated - 已废弃,请使用 `ILocationMessageContent` 替代
2697
2409
  */
2698
- interface ILocationMessageBody extends IExtraData, IMentionedInfo, IUserInfo {
2699
- /**
2700
- * 经度
2701
- */
2702
- longitude: number;
2703
- /**
2704
- * 维度
2705
- */
2706
- latitude: number;
2707
- /**
2708
- * 位置信息
2709
- */
2710
- poi: string;
2711
- /**
2712
- * [EN]
2713
- * TODO(Translate)
2714
- */
2715
- /**
2716
- * 位置缩略图,图片需要是不带前缀的 base64 字符串
2717
- */
2718
- content: string;
2719
- }
2410
+ declare type ILocationMessageBody = ILocationMessageContent;
2411
+
2720
2412
  /**
2721
2413
  * 位置消息
2722
2414
  */
2723
- declare class LocationMessage extends InnerMessage<ILocationMessageBody> {
2724
- constructor(content: ILocationMessageBody);
2415
+ declare class LocationMessage extends BuiltinMessage<ILocationMessageContent> {
2416
+ constructor(content: ILocationMessageContent);
2725
2417
  }
2726
2418
 
2727
2419
  /**
2728
2420
  * 引用消息
2729
2421
  * @category Interface
2422
+ * @deprecated - 已废弃,请使用 `IReferenceMessageContent` 替代
2730
2423
  */
2731
- interface IReferenceMessageBody extends IExtraData, IMentionedInfo, IUserInfo, IAuditInfo {
2732
- /**
2733
- * 被引用消息的发送用户 Id
2734
- */
2735
- referMsgUserId: String;
2736
- /**
2737
- * 引用消息对象
2738
- */
2739
- referMsg: any;
2740
- /**
2741
- * 引用消息 UID
2742
- */
2743
- referMsgUid: string;
2744
- /**
2745
- * 输入的文本消息内容
2746
- */
2747
- content: string;
2748
- /**
2749
- * 发送的引用消息类型
2750
- */
2751
- objName: string;
2752
- }
2753
- declare class ReferenceMessage extends InnerMessage<IReferenceMessageBody> {
2754
- constructor(content: IReferenceMessageBody);
2755
- }
2424
+ declare type IReferenceMessageBody = IReferenceMessageContent;
2756
2425
 
2757
- interface IArticle {
2758
- title: string;
2759
- content: string;
2760
- imageUri: string;
2761
- url: string;
2426
+ declare class ReferenceMessage extends BuiltinMessage<IReferenceMessageContent> {
2427
+ constructor(content: IReferenceMessageContent);
2762
2428
  }
2429
+
2763
2430
  /**
2764
2431
  * 富文本消息
2765
2432
  * @category Interface
2433
+ * @deprecated - 已废弃,请使用 `IRichContentMessageContent` 替代
2766
2434
  */
2767
- interface IRichContentMessageBody extends IArticle, IExtraData, IMentionedInfo, IUserInfo {
2768
- }
2769
- declare class RichContentMessage extends InnerMessage<IRichContentMessageBody> {
2770
- constructor(content: IRichContentMessageBody);
2435
+ declare type IRichContentMessageBody = IRichContentMessageContent;
2436
+
2437
+ declare class RichContentMessage extends BuiltinMessage<IRichContentMessageContent> {
2438
+ constructor(content: IRichContentMessageContent);
2771
2439
  }
2772
2440
 
2773
2441
  /**
2774
- * 短视频消息内容结构
2442
+ * 短视频消息 content 数据
2443
+ * @deprecated - 已废弃,请使用 `ISightMessageContent` 替代
2775
2444
  * @category Interface
2776
2445
  */
2777
- interface ISightMessageBody extends IExtraData, IMentionedInfo, IUserInfo, IAuditInfo {
2778
- /**
2779
- * 远程视频资源 url 地址
2780
- */
2781
- sightUrl: string;
2782
- /**
2783
- * 小视频首帧的缩略图进行 Base64 编码的结果值,格式为 JPG
2784
- * @description 注意在 Base64 进行 Encode 后需要将所有 \r\n 和 \r 和 \n 替换成空
2785
- */
2786
- content: string;
2787
- /**
2788
- * 视频时长,单位:秒
2789
- */
2790
- duration: number;
2791
- /**
2792
- * 视频尺寸,单位:Byte
2793
- */
2794
- size: number;
2795
- /**
2796
- * 视频文件名称
2797
- */
2798
- name: string;
2799
- }
2446
+ declare type ISightMessageBody = ISightMessageContent;
2447
+
2800
2448
  /**
2801
2449
  * 短视频消息
2802
2450
  */
2803
- declare class SightMessage extends InnerMessage<ISightMessageBody> {
2451
+ declare class SightMessage extends BuiltinMessage<ISightMessageBody> {
2804
2452
  constructor(content: ISightMessageBody);
2805
2453
  }
2806
2454
 
2807
- /**
2808
- * 消息引用信息
2809
- */
2810
- interface IReferMsg {
2811
- /**
2812
- * 消息中包含的引用消息数据
2813
- */
2814
- referMsg?: {
2815
- /**
2816
- * 被引用消息 UId
2817
- */
2818
- messageUId: string;
2819
- /**
2820
- * 被引用消息类型
2821
- */
2822
- objectName: string;
2823
- /**
2824
- * 消息发送者 ID
2825
- */
2826
- senderId: string;
2827
- };
2828
- }
2829
-
2830
2455
  /**
2831
2456
  * 流式消息内容结构
2832
2457
  * @category Interface
2458
+ * @deprecated - 已废弃,请使用 `IStreamMessageContent` 替代
2833
2459
  */
2834
- interface IStreamMessageBody extends IUserInfo, IExtraData, IMentionedInfo, IReferMsg {
2835
- /**
2836
- * 流式消息内容
2837
- *
2838
- * * Web 平台拉取到的内容为流式消息的首包数据;
2839
- * * Electron 平台下,当新收消息时,该字段为消息首包数据;通过拉取流式数据接口,SDK 将逐渐补全该数据内容
2840
- */
2841
- content: string;
2842
- /**
2843
- * 用于标识服务器是否已接收流推送完成
2844
- */
2845
- complete?: boolean;
2846
- /**
2847
- * 业务层推流结束时透传的结束 reason 信息
2848
- */
2849
- completeReason?: number;
2850
- /**
2851
- * 服务器端接收流数据的结束原因
2852
- */
2853
- stopReason?: number;
2854
- /**
2855
- * 用于标识客户端是否已完成流数据拉取,当该值为 true 时,content 内容为全量流消息数据;仅限 Electron 平台有效
2856
- */
2857
- isSynced?: boolean;
2858
- /**
2859
- * 自定义编码流媒体数据类型
2860
- */
2861
- type?: string;
2862
- }
2863
- declare class StreamMessage extends InnerMessage<IStreamMessageBody> {
2864
- constructor(content: IStreamMessageBody);
2865
- }
2460
+ declare type IStreamMessageBody = IStreamMessageContent;
2866
2461
 
2867
2462
  /**
2868
- * 文本消息
2463
+ * 文本消息 content 数据
2464
+ * @deprecated - 已废弃,请使用 `ITextMessageContent` 替代
2869
2465
  * @category Interface
2870
2466
  */
2871
- interface ITextMessageBody extends IUserInfo, IExtraData, IMentionedInfo, IAuditInfo {
2872
- /**
2873
- * 文本消息内容
2874
- */
2875
- content: string;
2876
- }
2877
- declare class TextMessage extends InnerMessage<ITextMessageBody> {
2878
- constructor(content: ITextMessageBody);
2467
+ declare type ITextMessageBody = ITextMessageContent;
2468
+
2469
+ declare class TextMessage extends BuiltinMessage<ITextMessageContent> {
2470
+ constructor(content: ITextMessageContent);
2879
2471
  }
2880
2472
 
2881
2473
  /**
2474
+ * 高清语音消息 content 数据
2882
2475
  * @category Interface
2476
+ * @deprecated - 已废弃,使用 IHQVoiceMessageContent 代替
2883
2477
  */
2884
- interface IVoiceMessageBody extends IExtraData, IMentionedInfo, IUserInfo, IAuditInfo {
2885
- content: string;
2886
- duration: number;
2887
- extra: string;
2478
+ declare type IHQVoiceMessageBody = IHQVoiceMessageContent;
2479
+ /**
2480
+ * 高清语音消息类型
2481
+ */
2482
+ declare class HQVoiceMessage extends BuiltinMessage<IHQVoiceMessageContent> {
2483
+ constructor(content: IHQVoiceMessageContent);
2888
2484
  }
2889
- declare class VoiceMessage extends InnerMessage<IVoiceMessageBody> {
2890
- constructor(content: IVoiceMessageBody);
2485
+ /**
2486
+ * 语音消息 content 数据
2487
+ * @category Interface
2488
+ * @deprecated - 已废弃,使用 IVoiceMessageContent 代替
2489
+ */
2490
+ declare type IVoiceMessageBody = IVoiceMessageContent;
2491
+ declare class VoiceMessage extends BuiltinMessage<IVoiceMessageContent> {
2492
+ constructor(content: IVoiceMessageContent);
2891
2493
  }
2892
2494
 
2893
2495
  /**
@@ -2946,9 +2548,9 @@ declare function sendTextMessage(conversation: IConversationOption, messageBody:
2946
2548
  * 发送消息基础类型
2947
2549
  * @category Type
2948
2550
  */
2949
- declare type ISendBody = IUserInfo & IExtraData & {
2551
+ declare type ISendBody = IUserExtraKeyInMessage & IExtraDataKeyInMessage & {
2950
2552
  file: File;
2951
- } & IMentionedInfo & IAuditInfo;
2553
+ } & IMentionedInfoKeyInMessage & IAuditInfoKeyInMessage;
2952
2554
  /**
2953
2555
  * 发送文件消息配置项
2954
2556
  * @category Type
@@ -3214,9 +2816,7 @@ declare function sendReadReceiptResponse(targetId: string, messageUIds: string[]
3214
2816
  * const readReceiptRes = await RongIMLib.sendReadReceiptResponseV2(targetId, messageList);
3215
2817
  * console.info('群已读回执响应:', readReceiptRes);
3216
2818
  */
3217
- declare function sendReadReceiptResponseV2(targetId: string, messageList?: {
3218
- [senderUserId: string]: string[];
3219
- }, channelId?: string): Promise<IAsyncRes<void>>;
2819
+ declare function sendReadReceiptResponseV2(targetId: string, messageList?: Record<string, string[]>, channelId?: string): Promise<IAsyncRes<void>>;
3220
2820
  /**
3221
2821
  * 多端同步阅读状态
3222
2822
  * @description 由于未读消息数存储在本地,服务器不存未读消息数量。当用户多端登录时,需要同步未读消息数以保证多端未读数一致
@@ -3444,9 +3044,7 @@ declare function batchClearRemoteHistoryMessages(clearMessageOption: IClearMessa
3444
3044
  * console.info('更新消息扩展属性结果:', updateRes);
3445
3045
  * ```
3446
3046
  */
3447
- declare function updateMessageExpansion(expansion: {
3448
- [key: string]: any;
3449
- }, message: IAReceivedMessage): Promise<IAsyncRes<void>>;
3047
+ declare function updateMessageExpansion(expansion: Record<string, string>, message: IAReceivedMessage): Promise<IAsyncRes<void>>;
3450
3048
  /**
3451
3049
  * 删除扩展存储
3452
3050
  * @description 删除消息扩展信息中指定的 Key
@@ -3593,12 +3191,9 @@ declare function getUnreadMentionedMessages(conversation: IConversationOption):
3593
3191
  /**
3594
3192
  * 按关键字搜索会话内的消息
3595
3193
  * @category 消息
3596
- * @deprecated 已废弃,@since 5.4.0。请替换使用 {@link electronExtension.searchMessages} 方法
3194
+ * @deprecated 已废弃,请替换使用 {@link electronExtension.searchMessagesWithParams} 方法
3597
3195
  */
3598
- declare function searchMessages$1(conversation: IConversationOption, keyword: string, timestamp: number, count: number): Promise<IAsyncRes<{
3599
- messages: IAReceivedMessage[];
3600
- count: number | undefined;
3601
- }>>;
3196
+ declare function searchMessages$1(conversation: IConversationOption, keyword: string, timestamp: number, count: number): Promise<RCResult<ISearchMessagesResult>>;
3602
3197
  /**
3603
3198
  * 从本地消息数据库中删除某一会话指定时间之前的消息数据
3604
3199
  * @category 消息
@@ -3666,6 +3261,13 @@ declare function sendReadReceiptResponseV5(conId: IConversationOption, messageUI
3666
3261
  * @param msgIds 消息 UId 列表,长度限制为 1-100
3667
3262
  */
3668
3263
  declare function getMessageReadReceiptInfoV5(conId: IConversationOption, messageUIds: Array<string>): Promise<RCResult<ReadReceiptInfoV5[]>>;
3264
+ /**
3265
+ * 跨会话批量获取消息已读人数信息(V5 版本)
3266
+ * @since 5.22.0
3267
+ * @param list 会话信息列表
3268
+ * @returns 消息已读人数信息列表
3269
+ */
3270
+ declare function getMessageReadReceiptInfoV5ByIdentifiers(messageIds: IMessageIdentifier[]): Promise<RCResult<ReadReceiptInfoV5[]>>;
3669
3271
  /**
3670
3272
  * 分页查询消息已读、未读成员列表
3671
3273
  * @param conId 会话信息
@@ -3682,6 +3284,15 @@ declare function getMessagesReadReceiptUsersByPageV5(conId: IConversationOption,
3682
3284
  * @since 5.20.0
3683
3285
  */
3684
3286
  declare function getMessagesReadReceiptByUsersV5(conId: IConversationOption, messageUId: string, userIds: Array<string>): Promise<RCResult<ReadReceiptUsersResult>>;
3287
+ /**
3288
+ * 发起语音转文字请求
3289
+ * @param messageUId 消息 UId
3290
+ * @param content 语音消息内容数据:
3291
+ * * Web 平台为必传数据;
3292
+ * * Electron 平台该参数无效,SDK 将从本地数据库内读取消息并发起请求;
3293
+ * @since 5.22.0
3294
+ */
3295
+ declare function requestSpeechToTextForMessage(messageUId: string, option?: IConvertSpeechToTextOption): Promise<RCResult>;
3685
3296
 
3686
3297
  /**
3687
3298
  * 创建标签
@@ -3841,10 +3452,10 @@ declare function removeTagFromConversations(tagId: string, conversations: IConve
3841
3452
  * 分页获取标签下会话列表
3842
3453
  * @category 标签
3843
3454
  * @param tagId 标签 id
3844
- * @param count 获取数量
3845
- * @param timestamp 会话中消息的时间戳
3846
- * @returns 返回一个 {@link IAsyncRes} 类型 Promise,data 为会话列表,类型为 {@link IAReceivedConversationByTag} 数组或者 undefined
3847
- * 从 SDK 版本 @since 5.7.0 开始该接口的返回数据类型由 {@link IReceivedConversationByTag} 变更为 {@link IAReceivedConversationByTag}
3455
+ * @param count 数量
3456
+ * @param timestamp 分页起始时间戳
3457
+ * @returns 返回一个 {@link IAsyncRes} 类型 Promise,data 为会话列表,类型为 {@link IAReceivedConversationByTag} 数组;
3458
+ * 从 SDK 5.7.0 版本开始该接口的返回数据类型由 {@link IReceivedConversationByTag} 变更为 {@link IAReceivedConversationByTag}
3848
3459
  * @example 分页获取标签下会话列表示例:
3849
3460
  * ```ts
3850
3461
  * const tagId = 'tagId';
@@ -3854,7 +3465,7 @@ declare function removeTagFromConversations(tagId: string, conversations: IConve
3854
3465
  * console.log('分页获取标签下会话列表结果:', res);
3855
3466
  * ```
3856
3467
  */
3857
- declare function getConversationsFromTagByPage(tagId: string, count: number, startTime: number): Promise<IAsyncRes<IAReceivedConversationByTag[] | undefined>>;
3468
+ declare function getConversationsFromTagByPage(tagId: string, count: number, startTime: number): Promise<IAsyncRes<IAReceivedConversationByTag[]>>;
3858
3469
  /**
3859
3470
  * 根据标签获取未读消息数
3860
3471
  * @category 标签
@@ -3957,38 +3568,6 @@ declare function getFileUrl(fileType: FileType, filename: string, saveName?: str
3957
3568
  downloadUrl: string;
3958
3569
  }>>;
3959
3570
 
3960
- /**
3961
- * @deprecated 从 5.6.0 版本开始,此定义失效
3962
- * @category 基础
3963
- */
3964
- declare const ConnectType: {
3965
- COMET: string;
3966
- WEBSOCKET: string;
3967
- };
3968
- /**
3969
- * 消息类型
3970
- * @category 消息
3971
- */
3972
- declare const MessageType: {
3973
- TEXT: MessageType$1;
3974
- VOICE: MessageType$1;
3975
- HQ_VOICE: MessageType$1;
3976
- IMAGE: MessageType$1;
3977
- GIF: MessageType$1;
3978
- RICH_CONTENT: MessageType$1;
3979
- LOCATION: MessageType$1;
3980
- FILE: MessageType$1;
3981
- SIGHT: MessageType$1;
3982
- COMBINE: MessageType$1;
3983
- COMBINE_V2: MessageType$1;
3984
- CHRM_KV_NOTIFY: MessageType$1;
3985
- LOG_COMMAND: MessageType$1;
3986
- EXPANSION_NOTIFY: MessageType$1;
3987
- REFERENCE: MessageType$1;
3988
- RECALL_MESSAGE_TYPE: MessageType$1;
3989
- STREAM_MESSAGE: MessageType$1;
3990
- };
3991
-
3992
3571
  /**
3993
3572
  * 获取全部本地会话列表
3994
3573
  * @category Electron 独有
@@ -4074,6 +3653,7 @@ declare function getConversations(conversations: IConversationOption[]): Promise
4074
3653
 
4075
3654
  /**
4076
3655
  * 根据关键字搜索本地消息
3656
+ * @deprecated 已废弃。请替换使用 {@link searchMessagesWithParams} 方法
4077
3657
  * @category Electron 独有
4078
3658
  * @description 本接口仅适用 Electron 平台搜索本地消息
4079
3659
  * * **注意**:
@@ -4103,10 +3683,7 @@ declare function getConversations(conversations: IConversationOption[]): Promise
4103
3683
  * console.info('根据关键字搜索本地消息结果:', res);
4104
3684
  * ```
4105
3685
  */
4106
- declare function searchMessages(conversation: IConversationOption, keyword: string, startTime: number, count: number, messageTypes?: string[]): Promise<IAsyncRes<{
4107
- messages: IAReceivedMessage[];
4108
- count: number | undefined;
4109
- }>>;
3686
+ declare function searchMessages(conversation: IConversationOption, keyword: string, startTime: number, count: number, messageTypes?: string[]): Promise<RCResult<ISearchMessagesResult>>;
4110
3687
  /**
4111
3688
  * 在指定时间范围内搜索本地消息
4112
3689
  * @category Electron 独有
@@ -4131,12 +3708,7 @@ declare function searchMessages(conversation: IConversationOption, keyword: stri
4131
3708
  * console.info('在指定时间范围内搜索本地消息结果:', res);
4132
3709
  * ```
4133
3710
  */
4134
- declare function searchMessageInTimeRange(conversation: {
4135
- conversationType: ConversationType;
4136
- targetId: string;
4137
- }, option: ISearchMessageInTimeRangeOption): Promise<IAsyncRes<{
4138
- messages: IAReceivedMessage[];
4139
- }>>;
3711
+ declare function searchMessageInTimeRange(conversation: IConversationOption, option: ISearchMessageInTimeRangeOption): Promise<RCResult<ISearchMessagesResult>>;
4140
3712
  /**
4141
3713
  * 根据用户 ID 搜索本地消息
4142
3714
  * @category Electron 独有
@@ -4161,9 +3733,7 @@ declare function searchMessageInTimeRange(conversation: {
4161
3733
  * console.info('根据用户 ID 搜索本地消息', res);
4162
3734
  * ```
4163
3735
  */
4164
- declare function searchMessagesByUser(conversation: IConversationOption, userId: string, startTime: number, count: number): Promise<IAsyncRes<{
4165
- messages: IAReceivedMessage[];
4166
- }>>;
3736
+ declare function searchMessagesByUser(conversation: IConversationOption, userId: string, startTime: number, count: number): Promise<RCResult<Pick<ISearchMessagesResult, 'messages'>>>;
4167
3737
  /**
4168
3738
  * 获取会话中指定类型的消息
4169
3739
  * @category Electron 独有
@@ -4244,7 +3814,7 @@ declare function getContinuousMessages(conversation: IConversationOption, option
4244
3814
  * console.info('通过时间戳设置消息状态为对方已读结果:', res);
4245
3815
  * ```
4246
3816
  */
4247
- declare function setMessageStatusToRead(conversation: IConversationOption, timestamp: number): Promise<IAsyncRes<boolean>>;
3817
+ declare function setMessageStatusToRead(conversation: IConversationOption, timestamp: number): Promise<RCResult<boolean>>;
4248
3818
  /**
4249
3819
  * 设置消息的接收状态
4250
3820
  * @category Electron 独有
@@ -4555,6 +4125,48 @@ declare function getMessagesAroundTimestamp(conversation: IConversationOption, o
4555
4125
  * ```
4556
4126
  */
4557
4127
  declare function getLocalMessage(messageId: number | string): Promise<RCResult<IAReceivedMessage>>;
4128
+ /**
4129
+ * 全局搜索本地消息
4130
+ * @category Electron 独有
4131
+ * @since 5.22.0
4132
+ * @description 本接口仅适用 Electron 平台,全局搜索本地消息,支持跨会话搜索等通用场景
4133
+ * @param params 搜索参数
4134
+ * @example
4135
+ * 根据参数搜索消息示例:
4136
+ * ```ts
4137
+ * const params = {
4138
+ * keyword: 'test',
4139
+ * count: 10,
4140
+ * offset: 0,
4141
+ * order: 0,
4142
+ * range: {
4143
+ * startTime: 0,
4144
+ * endTime: 0,
4145
+ * },
4146
+ * conversationFilter: {
4147
+ * conversationTypes: [RongIMLib.ConversationType.PRIVATE, RongIMLib.ConversationType.GROUP],
4148
+ * targetIds: ['targetId1', 'targetId2'],
4149
+ * },
4150
+ * messageFilter: {
4151
+ * messageTypes: [RongIMLib.MessageType.TEXT],
4152
+ * },
4153
+ * };
4154
+ * const res = await RongIMLib.electronExtension.searchMessagesWithParams(params);
4155
+ * if (res.isOk) {
4156
+ * console.info('搜索消息结果:', res.data.messages, res.data.matchedCount);
4157
+ * } else {
4158
+ * console.error('搜索消息失败:', res.code);
4159
+ * }
4160
+ * ```
4161
+ */
4162
+ declare function searchMessagesWithParams(params: ISearchMessageParams): Promise<RCResult<ISearchMessagesResult>>;
4163
+ /**
4164
+ * 设置语音转文字内容可见性
4165
+ * @param messageId 消息 ID,为本地消息 ID,非消息 UId
4166
+ * @param isVisible 是否可见
4167
+ * @since 5.22.0
4168
+ */
4169
+ declare function setMessageSpeechToTextVisible(messageId: number, isVisible: boolean): Promise<RCResult>;
4558
4170
 
4559
4171
  /**
4560
4172
  * 清除本地数据
@@ -4570,7 +4182,7 @@ declare function getLocalMessage(messageId: number | string): Promise<RCResult<I
4570
4182
  * console.info('清除本地数据结果:', res);
4571
4183
  * ```
4572
4184
  */
4573
- declare function clearLocalData(): Promise<IAsyncRes<boolean>>;
4185
+ declare function clearLocalData(): Promise<RCResult<boolean>>;
4574
4186
  /**
4575
4187
  * 获取是否使用 Electron 扩展
4576
4188
  * @category Electron 独有
@@ -4613,6 +4225,8 @@ declare const index_setCheckDuplicateMessage: typeof setCheckDuplicateMessage;
4613
4225
  declare const index_setCheckChatRoomDuplicateMessage: typeof setCheckChatRoomDuplicateMessage;
4614
4226
  declare const index_getMessagesAroundTimestamp: typeof getMessagesAroundTimestamp;
4615
4227
  declare const index_getLocalMessage: typeof getLocalMessage;
4228
+ declare const index_searchMessagesWithParams: typeof searchMessagesWithParams;
4229
+ declare const index_setMessageSpeechToTextVisible: typeof setMessageSpeechToTextVisible;
4616
4230
  declare const index_clearLocalData: typeof clearLocalData;
4617
4231
  declare const index_enable: typeof enable;
4618
4232
  declare namespace index {
@@ -4644,6 +4258,8 @@ declare namespace index {
4644
4258
  index_setCheckChatRoomDuplicateMessage as setCheckChatRoomDuplicateMessage,
4645
4259
  index_getMessagesAroundTimestamp as getMessagesAroundTimestamp,
4646
4260
  index_getLocalMessage as getLocalMessage,
4261
+ index_searchMessagesWithParams as searchMessagesWithParams,
4262
+ index_setMessageSpeechToTextVisible as setMessageSpeechToTextVisible,
4647
4263
  index_clearLocalData as clearLocalData,
4648
4264
  index_enable as enable,
4649
4265
  };
@@ -5237,16 +4853,205 @@ declare function setFriendAddPermission(permission: FriendAddPermission): Promis
5237
4853
  */
5238
4854
  declare function getFriendAddPermission(): Promise<IAsyncRes<FriendAddPermission>>;
5239
4855
 
4856
+ /**
4857
+ * 初始化
4858
+ * @description 初始化 IM SDK,传入 Appkey 及相关配置信息
4859
+ * @category 基础
4860
+ * @param options 初始化参数,类型为 {@link IInitOption}
4861
+ * @example
4862
+ * 初始化示例:
4863
+ * ```ts
4864
+ * RongIMLib.init({ appkey: 'appkey' });
4865
+ * console.log('初始化完成');
4866
+ * ```
4867
+ */
4868
+ declare function init(options: IInitOption): void;
4869
+ /**
4870
+ * 反初始化
4871
+ * @description 反初始化,清空所有监听及计时器,停止日志上报等业务
4872
+ * * **适用场景**:
4873
+ * 1. 应用退出时,推荐使用此方法
4874
+ * 2. 需要更换 appkey 时,需要调用此方法后,重新使用新 Appkey 在次调用 {@link init} 方法
4875
+ * @category 基础
4876
+ * @example
4877
+ * 反初始化示例:
4878
+ * ```ts
4879
+ * await RongIMLib.destroy();
4880
+ * console.log('反初始化完成');
4881
+ * ```
4882
+ */
4883
+ declare function destroy(): Promise<void>;
4884
+ /**
4885
+ * 获取 IM 连接状态
4886
+ * @category 基础
4887
+ * @example
4888
+ * 获取 IM 连接状态示例:
4889
+ * ```ts
4890
+ * const status = RongIMLib.getConnectionStatus();
4891
+ * console.log('获取 IM 连接状态:', status);
4892
+ * ```
4893
+ */
4894
+ declare function getConnectionStatus(): RCConnectionStatus;
4895
+ /**
4896
+ * 当前服务器时间
4897
+ * 校准时间,可能存在误差
4898
+ * @category 基础
4899
+ * @hidden
4900
+ */
4901
+ declare function getServerTime(): number;
4902
+ /**
4903
+ * 获取 IM 连接用户的 id
4904
+ * @category 基础
4905
+ * @example
4906
+ * 获取当前用户 id 示例:
4907
+ * ```ts
4908
+ * const userId = RongIMLib.getCurrentUserId();
4909
+ * console.log('获取当前用户 id:', userId);
4910
+ * ```
4911
+ */
4912
+ declare function getCurrentUserId(): string;
4913
+ /**
4914
+ * (内部方法)用于统计各组件版本信息
4915
+ * @param name
4916
+ * @param version
4917
+ * @hidden
4918
+ */
4919
+ declare function __addSDKVersion(name: string, version: string): void;
4920
+ /**
4921
+ * 获取 deviceId
4922
+ * @description 获取当前设备的唯一标识
4923
+ * @category 基础
4924
+ * @example
4925
+ * 获取 deviceId 示例:
4926
+ * ```ts
4927
+ * const deviceId = RongIMLib.getDeviceId();
4928
+ * console.log('获取 deviceId:', deviceId);
4929
+ * ```
4930
+ */
4931
+ declare function getDeviceId(): string;
4932
+ /**
4933
+ * 获取应用设置,需登录后调用,否则将返回 null
4934
+ * @since 5.22.0
4935
+ * @returns 应用设置
4936
+ * @example
4937
+ * 获取应用设置示例:
4938
+ * ```ts
4939
+ * const settings = RongIMLib.getAppSettings();
4940
+ * if (settings) {
4941
+ * console.log('是否已开启语音转文字:', settings.isSpeechToTextEnabled);
4942
+ * }
4943
+ * ```
4944
+ */
4945
+ declare function getAppSettings(): AppSettings | null;
4946
+
4947
+ /**
4948
+ * @deprecated - 已废弃
4949
+ */
4950
+ declare const ConnectType: {
4951
+ COMET: string;
4952
+ WEBSOCKET: string;
4953
+ };
4954
+
5240
4955
  declare function setNotificationQuietHoursWithSetting(opts: INotificationQuietHoursSetting): Promise<RCResult>;
5241
4956
  declare function removeNotificationQuietHoursSetting(): Promise<RCResult>;
5242
4957
  declare function getNotificationQuietHoursSetting(): Promise<RCResult<INotificationQuietHoursSetting>>;
5243
4958
 
5244
4959
  /**
5245
- * @category Type
4960
+ * 会话更新项结构
4961
+ * @category Interface
4962
+ * @deprecated
4963
+ */
4964
+ interface IConversationUpdateItem {
4965
+ /**
4966
+ * 时间
4967
+ */
4968
+ time: number;
4969
+ /**
4970
+ * 更新数据
4971
+ */
4972
+ val: any;
4973
+ }
4974
+ /**
4975
+ * 会话数据更新结构
4976
+ * @category Interface
5246
4977
  * @deprecated
5247
4978
  */
4979
+ interface IReceivedUpdateConversation {
4980
+ /**
4981
+ * 会话更新项
4982
+ */
4983
+ updatedItems: {
4984
+ [key: string]: IConversationUpdateItem;
4985
+ };
4986
+ /**
4987
+ * 会话类型
4988
+ * * 1: 单聊
4989
+ * * 3: 群聊
4990
+ * * 4: 聊天室
4991
+ * * 5: 客服会话
4992
+ * * 6: 系统消息
4993
+ * * 7: 默认关注的公众号
4994
+ * * 8: 手动关注的公众号
4995
+ * * 9: RTCLib 房间
4996
+ */
4997
+ conversationType: number;
4998
+ /**
4999
+ * 会话 id
5000
+ */
5001
+ targetId: string;
5002
+ /**
5003
+ * 会话最后一条消息
5004
+ */
5005
+ latestMessage?: IAReceivedMessage;
5006
+ /**
5007
+ * 未读数
5008
+ */
5009
+ unreadMessageCount?: number;
5010
+ /**
5011
+ * 是否是 @ 消息
5012
+ */
5013
+ hasMentioned?: boolean;
5014
+ /**
5015
+ * @ 信息
5016
+ */
5017
+ mentionedInfo?: MentionedInfo;
5018
+ /**
5019
+ * 消息最后阅读时间
5020
+ */
5021
+ lastUnreadTime?: number;
5022
+ /**
5023
+ * 免打扰状态
5024
+ */
5025
+ notificationStatus?: NotificationStatus;
5026
+ /**
5027
+ * 是否置顶
5028
+ */
5029
+ isTop?: boolean;
5030
+ }
5031
+ /**
5032
+ * @category Type
5033
+ * @deprecated - 已废弃,请使用 `MentionedInfo` 替代
5034
+ */
5248
5035
  declare type MentionedInfoBody = MentionedInfo;
5036
+ /**
5037
+ * 用户信息结构
5038
+ * @category Interface
5039
+ * @deprecated - 已废弃,请使用 `IUserExtraKeyInMessage` 替代
5040
+ */
5041
+ declare type IUserInfo = IUserExtraKeyInMessage;
5042
+ /**
5043
+ * 消息扩展结构
5044
+ * @category Interface
5045
+ * @deprecated - 已废弃,请使用 `IExtraDataKeyInMessage` 替代
5046
+ */
5047
+ declare type IExtraData = IExtraDataKeyInMessage;
5048
+ /**
5049
+ * 消息审核配置结构
5050
+ * @category Interface
5051
+ * @deprecated - 已废弃,请使用 `IAuditInfoKeyInMessage` 替代
5052
+ */
5053
+ declare type IAuditInfo = IAuditInfoKeyInMessage;
5249
5054
 
5250
5055
  declare type IStreamMessageResponseEventData = IStreamMessageResponseEventData$1<IAReceivedMessage>;
5251
5056
 
5252
- export { BaseMessage, CombineMessage, CombineV2Message, CombineV2MessageContent, CommandMessage, ConnectType, EventListeners, Events, FileMessage, GIFMessage, GetHistoryMessageOption, GetHistoryMessageResult, GroupNotificationMessage, HQVoiceMessage, IAReceivedConversation, IAReceivedConversationByTag, IAReceivedMessage, IAUltraGroupReceivedConversation, IAuditInfo, ICombineMessageBody, ICommandMessageBody, IConversationEvent, IConversationState, IConversationUpdateItem, IExtraData, IFileMessageBody, IGIFMessageBody, IGetHistoryMessagesByTypesOption, IGroupNotificationMessageBody, IHQVoiceMessageBody, IImageMessageBody, IImageMessageOption, IInformationNotificationMessageBody, IInitOption, IInsertOptions, ILocationMessageBody, IMessageDesc, IMessageReceiptRequestEvent, IMessageReceiptResponseEvent, IMessagesEvent, IReadReceiptReceivedEvent, IRecallMessageOptions, IReceivedUpdateConversation, IReferenceMessageBody, IRichContentMessageBody, ISearchMessageInTimeRangeOption, ISendBody, ISendFileMessageOptions, ISendImageMessageOptions, ISendMessageOptions, ISendSightMessageOptions, ISightMessageBody, IStreamMessageBody, IStreamMessageResponseEventData, ITextMessageBody, IThumbnailConfig, ITypingStatusEvent, IUploadConfig, IUploadHooks, IUploadInfo, IUploadMessageOption, IUploadResult, IUserInfo, IVoiceMessageBody, ImageMessage, InformationNotificationMessage, LocationMessage, MentionedInfoBody, MessageAuditType, MessageConstructor, MessageType, Monitor, MonitorableAPI, ReferenceMessage, RichContentMessage, SightMessage, StreamMessage, TextMessage, Transformer, UploadTask, VoiceMessage, __addSDKVersion, acceptFriendApplication, acceptGroupApplication, acceptGroupInvite, addConversationsToTag, addEventListener, addFriend, addGroupFollows, addGroupManagers, addMonitor, addTag, addToBlacklist, batchClearRemoteHistoryMessages, batchGetMessageReadReceiptInfoV4, batchRemoveConversation, batchSetConversationNotificationLevel, batchSetConversationToTop, bindRTCRoomForChatroom, checkFriends, clearAllMessagesUnreadStatus, clearEventListeners, clearHistoryMessages, clearMessages$1 as clearMessages, clearMessagesUnreadStatus, clearRealtimeConUnreadCount, clearTextMessageDraft, clearUnreadCountByTimestamp, connect, createGroup, createUploadTask, deleteFriends, deleteLocalMessagesByTimestamp, deleteMessages$1 as deleteMessages, destroy, disconnect, dismissGroup, index as electronExtension, forceRemoveChatRoomEntry, forceSetChatRoomEntry, getAllChatRoomEntries, getAllUltraGroupUnreadCount, getAllUltraGroupUnreadMentionedCount, getAllUnreadMentionedCount, getBlacklist, getBlacklistStatus, getBlockUltraGroupList, getBlockedConversationList, getChatRoomEntry, getChatRoomInfo, getChatroomHistoryMessages, getConnectionStatus, getConversation, getConversationList$1 as getConversationList, getConversationNotificationLevel, getConversationNotificationStatus, getConversationTypeNotificationLevel, getConversationsFromTagByPage, getCurrentUserId, getDeviceId, getDownloadAuth, getFileToken, getFileUrl, getFirstUnreadMessage, getFirstUnreadMessageInfo, getFriendAddPermission, getFriendApplications, getFriends, getFriendsInfo, getGroupApplications, getGroupFollows, getGroupMembers, getGroupMembersByRole, getGroupsInfo, getHistoryMessages, getJoinedGroups, getJoinedGroupsByRole, getMessage, getMessageReadReceiptInfoV5, getMessageReadReceiptV4, getMessageReader, getMessagesReadReceiptByUsersV5, getMessagesReadReceiptUsersByPageV5, getMyUserProfile, getMyUserProfileVisibility, getNotificationQuietHoursSetting, getProxy, getRealtimeConTotalUnreadCount, getRealtimeConUnreadCounts, getRealtimeConversations, getRemoteHistoryMessages, getServerTime, getSubscribeUserList, getSubscribeUserStatus, getTags, getTagsFromConversation, getTextMessageDraft, getTopConversationList, getTotalUnreadCount, getTotalUnreadCountByLevels, getTotalUnreadMentionedCountByLevels, getUltraGroupDefaultNotificationLevel, getUltraGroupFirstUnreadMessageTimestamp, getUltraGroupList, getUltraGroupMessageListByMessageUId, getUltraGroupUnreadCountByTargetId, getUltraGroupUnreadInfoList, getUltraGroupUnreadMentionedCountByTargetId, getUltraGroupUnreadMentionedMessages, getUnreadConversationList, getUnreadCount, getUnreadCountByTag, getUnreadMentionedCount, getUnreadMentionedMessages, getUserProfiles, init, insertMessage$1 as insertMessage, installPlugin, inviteUsersToGroup, joinChatRoom, joinExistChatRoom, joinGroup, kickGroupMembers, modifyMessage, onceEventListener, quitChatRoom, quitGroup, recallMessage, refuseFriendApplication, refuseGroupApplication, refuseGroupInvite, registerMessageType, removeAllExpansionForUltraGroupMessage, removeChatRoomEntries, removeChatRoomEntry, removeConversation, removeConversationsFromTag, removeEventListener, removeEventListeners, removeExpansionForUltraGroupMessage, removeFromBlacklist, removeGroupFollows, removeGroupManagers, removeMessageExpansionForKey, removeMonitor, removeNotificationQuietHoursSetting, removeRealtimeConversations, removeTag, removeTagFromConversations, removeTagsFromConversation, requestStreamMessageContent, saveTextMessageDraft, searchConversationByContent$1 as searchConversationByContent, searchFriendsInfo, searchGroupMembers, searchJoinedGroups, searchMessages$1 as searchMessages, searchUserProfileByUniqueId, sendFileMessage, sendGIFMessage, sendHQVoiceMessage, sendImageMessage, sendMessage, sendReadReceiptMessage, sendReadReceiptMessageV4, sendReadReceiptRequest, sendReadReceiptResponse, sendReadReceiptResponseV2, sendReadReceiptResponseV5, sendSightMessage, sendSyncReadStatusMessage, sendTextMessage, sendTypingStatusMessage, sendUltraGroupTypingStatus, setChatRoomEntries, setChatRoomEntry, setConversationNotificationLevel, setConversationNotificationStatus, setConversationToTop, setConversationToTopInTag, setConversationTypeNotificationLevel, setFriendAddPermission, setFriendInfo, setGroupMemberInfo, setGroupRemark, setMessageReceivedStatus$1 as setMessageReceivedStatus, setNotificationQuietHoursWithSetting, setProxy, setUltraGroupDefaultNotificationLevel, stopUploadTask, subscribeUserStatus, testProxy, transferGroupOwner, unSubscribeUserStatus, updateExpansionForUltraGroupMessage, updateGroupInfo, updateMessageExpansion, updateMyUserProfile, updateMyUserProfileVisibility, updateTag, upload };
5057
+ export { BaseMessage, BuiltinMessage, CombineMessage, CombineV2Message, CombineV2MessageContent, CommandMessage, ConnectType, EventListeners, Events, FileMessage, GIFMessage, GetHistoryMessageOption, GetHistoryMessageResult, GroupNotificationMessage, HQVoiceMessage, IAReceivedConversation, IAReceivedConversationByTag, IAReceivedMessage, IAUltraGroupReceivedConversation, IAuditInfo, ICombineMessageBody, ICommandMessageBody, IConversationEvent, IConversationState, IConversationUpdateItem, IExtraData, IFileMessageBody, IGIFMessageBody, IGetConversationListOptions, IGetHistoryMessagesByTypesOption, IGroupNotificationMessageBody, IHQVoiceMessageBody, IImageMessageBody, IImageMessageOption, IInformationNotificationMessageBody, IInitOption, IInsertOptions, ILocationMessageBody, IMessageDesc, IMessageReceiptRequestEvent, IMessageReceiptResponseEvent, IMessagesEvent, IReadReceiptReceivedEvent, IRecallMessageOptions, IReceivedUpdateConversation, IReferenceMessageBody, IRichContentMessageBody, ISearchMessageInTimeRangeOption, ISendBody, ISendFileMessageOptions, ISendImageMessageOptions, ISendMessageOptions, ISendSightMessageOptions, ISightMessageBody, IStreamMessageBody, IStreamMessageResponseEventData, ITextMessageBody, IThumbnailConfig, ITypingStatusEvent, IUploadConfig, IUploadHooks, IUploadInfo, IUploadMessageOption, IUploadResult, IUserInfo, IVoiceMessageBody, ImageMessage, InformationNotificationMessage, LocationMessage, MentionedInfoBody, MessageConstructor, Monitor, MonitorableAPI, ReferenceMessage, RichContentMessage, SightMessage, TextMessage, Transformer, UploadTask, VoiceMessage, __addSDKVersion, acceptFriendApplication, acceptGroupApplication, acceptGroupInvite, addConversationsToTag, addEventListener, addFriend, addGroupFollows, addGroupManagers, addMonitor, addTag, addToBlacklist, batchClearRemoteHistoryMessages, batchGetMessageReadReceiptInfoV4, batchRemoveConversation, batchSetConversationNotificationLevel, batchSetConversationToTop, bindRTCRoomForChatroom, checkFriends, clearAllMessagesUnreadStatus, clearEventListeners, clearHistoryMessages, clearMessages$1 as clearMessages, clearMessagesUnreadStatus, clearRealtimeConUnreadCount, clearTextMessageDraft, clearUnreadCountByTimestamp, connect, createGroup, createUploadTask, deleteFriends, deleteLocalMessagesByTimestamp, deleteMessages$1 as deleteMessages, destroy, disconnect, dismissGroup, index as electronExtension, forceRemoveChatRoomEntry, forceSetChatRoomEntry, getAllChatRoomEntries, getAllUltraGroupUnreadCount, getAllUltraGroupUnreadMentionedCount, getAllUnreadMentionedCount, getAppSettings, getBlacklist, getBlacklistStatus, getBlockUltraGroupList, getBlockedConversationList, getChatRoomEntry, getChatRoomInfo, getChatroomHistoryMessages, getConnectionStatus, getConversation, getConversationList$1 as getConversationList, getConversationNotificationLevel, getConversationNotificationStatus, getConversationTypeNotificationLevel, getConversationsFromTagByPage, getCurrentUserId, getDeviceId, getDownloadAuth, getFileToken, getFileUrl, getFirstUnreadMessage, getFirstUnreadMessageInfo, getFriendAddPermission, getFriendApplications, getFriends, getFriendsInfo, getGroupApplications, getGroupFollows, getGroupMembers, getGroupMembersByRole, getGroupsInfo, getHistoryMessages, getJoinedGroups, getJoinedGroupsByRole, getMessage, getMessageReadReceiptInfoV5, getMessageReadReceiptInfoV5ByIdentifiers, getMessageReadReceiptV4, getMessageReader, getMessagesReadReceiptByUsersV5, getMessagesReadReceiptUsersByPageV5, getMyUserProfile, getMyUserProfileVisibility, getNotificationQuietHoursSetting, getProxy, getRealtimeConTotalUnreadCount, getRealtimeConUnreadCounts, getRealtimeConversations, getRemoteHistoryMessages, getServerTime, getSubscribeUserList, getSubscribeUserStatus, getTags, getTagsFromConversation, getTextMessageDraft, getTopConversationList, getTotalUnreadCount, getTotalUnreadCountByLevels, getTotalUnreadMentionedCountByLevels, getUltraGroupDefaultNotificationLevel, getUltraGroupFirstUnreadMessageTimestamp, getUltraGroupList, getUltraGroupMessageListByMessageUId, getUltraGroupUnreadCountByTargetId, getUltraGroupUnreadInfoList, getUltraGroupUnreadMentionedCountByTargetId, getUltraGroupUnreadMentionedMessages, getUnreadConversationList, getUnreadCount, getUnreadCountByTag, getUnreadMentionedCount, getUnreadMentionedMessages, getUserProfiles, init, insertMessage$1 as insertMessage, installPlugin, inviteUsersToGroup, joinChatRoom, joinExistChatRoom, joinGroup, kickGroupMembers, modifyMessage, onceEventListener, quitChatRoom, quitGroup, recallMessage, refuseFriendApplication, refuseGroupApplication, refuseGroupInvite, registerMessageType, removeAllExpansionForUltraGroupMessage, removeChatRoomEntries, removeChatRoomEntry, removeConversation, removeConversationsFromTag, removeEventListener, removeEventListeners, removeExpansionForUltraGroupMessage, removeFromBlacklist, removeGroupFollows, removeGroupManagers, removeMessageExpansionForKey, removeMonitor, removeNotificationQuietHoursSetting, removeRealtimeConversations, removeTag, removeTagFromConversations, removeTagsFromConversation, requestSpeechToTextForMessage, requestStreamMessageContent, saveTextMessageDraft, searchConversationByContent$1 as searchConversationByContent, searchFriendsInfo, searchGroupMembers, searchJoinedGroups, searchMessages$1 as searchMessages, searchUserProfileByUniqueId, sendFileMessage, sendGIFMessage, sendHQVoiceMessage, sendImageMessage, sendMessage, sendReadReceiptMessage, sendReadReceiptMessageV4, sendReadReceiptRequest, sendReadReceiptResponse, sendReadReceiptResponseV2, sendReadReceiptResponseV5, sendSightMessage, sendSyncReadStatusMessage, sendTextMessage, sendTypingStatusMessage, sendUltraGroupTypingStatus, setChatRoomEntries, setChatRoomEntry, setConversationNotificationLevel, setConversationNotificationStatus, setConversationToTop, setConversationToTopInTag, setConversationTypeNotificationLevel, setFriendAddPermission, setFriendInfo, setGroupMemberInfo, setGroupRemark, setMessageReceivedStatus$1 as setMessageReceivedStatus, setNotificationQuietHoursWithSetting, setProxy, setUltraGroupDefaultNotificationLevel, stopUploadTask, subscribeUserStatus, testProxy, transferGroupOwner, unSubscribeUserStatus, updateExpansionForUltraGroupMessage, updateGroupInfo, updateMessageExpansion, updateMyUserProfile, updateMyUserProfileVisibility, updateTag, upload };