@cometchat/chat-sdk-javascript 4.1.4 → 4.1.5
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/CometChat.d.ts +31 -8
- package/CometChat.js +1 -1
- package/package.json +1 -1
package/CometChat.d.ts
CHANGED
|
@@ -300,7 +300,7 @@ export class CometChat {
|
|
|
300
300
|
};
|
|
301
301
|
SESSION_ID_REQUIRED: {
|
|
302
302
|
code: string;
|
|
303
|
-
|
|
303
|
+
name: string;
|
|
304
304
|
message: string;
|
|
305
305
|
details: {};
|
|
306
306
|
};
|
|
@@ -493,6 +493,7 @@ export class CometChat {
|
|
|
493
493
|
CORE_CONVERSATIONS_UPDATE_ON_GROUP_ACTIONS: string;
|
|
494
494
|
CORE_CONVERSATIONS_UPDATE_ON_CUSTOM_MESSAGES: string;
|
|
495
495
|
CORE_CONVERSATIONS_UPDATE_ON_REPLIES: string;
|
|
496
|
+
FLAG_REASONS: string;
|
|
496
497
|
};
|
|
497
498
|
};
|
|
498
499
|
static GroupConstants: {
|
|
@@ -2072,6 +2073,26 @@ export class CometChat {
|
|
|
2072
2073
|
* @return A ConversationUpdateSettings object that holds the settings for updating the conversation.
|
|
2073
2074
|
*/
|
|
2074
2075
|
static getConversationUpdateSettings(): Promise<ConversationUpdateSettings>;
|
|
2076
|
+
/**
|
|
2077
|
+
* Fetches the list of flag reasons configured in the CometChat Dashboard.
|
|
2078
|
+
* @returns {Promise<FlagReason[]>}
|
|
2079
|
+
* @memberof CometChat
|
|
2080
|
+
*/
|
|
2081
|
+
static getFlagReasons(): Promise<FlagReason[]>;
|
|
2082
|
+
/**
|
|
2083
|
+
* Allows users to flag a message with a specific reason and an optional remark.
|
|
2084
|
+
* @param {string} messageId
|
|
2085
|
+
* @param {{ reasonId?: string; remark?: string }} payload
|
|
2086
|
+
* @returns {Promise<{ success: boolean; message: string }>}
|
|
2087
|
+
* @memberof CometChat
|
|
2088
|
+
*/
|
|
2089
|
+
static flagMessage(messageId: string, payload: {
|
|
2090
|
+
reasonId: string;
|
|
2091
|
+
remark?: string;
|
|
2092
|
+
}): Promise<{
|
|
2093
|
+
success: boolean;
|
|
2094
|
+
message: string;
|
|
2095
|
+
}>;
|
|
2075
2096
|
}
|
|
2076
2097
|
|
|
2077
2098
|
export class CometChatNotifications {
|
|
@@ -3894,6 +3915,7 @@ export const APP_SETTINGS: {
|
|
|
3894
3915
|
CORE_CONVERSATIONS_UPDATE_ON_GROUP_ACTIONS: string;
|
|
3895
3916
|
CORE_CONVERSATIONS_UPDATE_ON_CUSTOM_MESSAGES: string;
|
|
3896
3917
|
CORE_CONVERSATIONS_UPDATE_ON_REPLIES: string;
|
|
3918
|
+
FLAG_REASONS: string;
|
|
3897
3919
|
};
|
|
3898
3920
|
};
|
|
3899
3921
|
export const COMMON_UTILITY_CONSTANTS: {
|
|
@@ -4002,6 +4024,14 @@ export const AI_ASSISTANT_EVENTS: {
|
|
|
4002
4024
|
TOOL_CALL_RESULT: string;
|
|
4003
4025
|
TOOL_CALL_ARGUMENT: string;
|
|
4004
4026
|
};
|
|
4027
|
+
export interface FlagReason {
|
|
4028
|
+
id: string;
|
|
4029
|
+
name: string;
|
|
4030
|
+
description: string;
|
|
4031
|
+
default?: boolean;
|
|
4032
|
+
createdAt: number;
|
|
4033
|
+
updatedAt: number;
|
|
4034
|
+
}
|
|
4005
4035
|
|
|
4006
4036
|
/**
|
|
4007
4037
|
*
|
|
@@ -4523,12 +4553,6 @@ export class Call extends BaseMessage implements Message {
|
|
|
4523
4553
|
MEDIA: string;
|
|
4524
4554
|
IMAGE: string;
|
|
4525
4555
|
VIDEO: string;
|
|
4526
|
-
AUDIO: string;
|
|
4527
|
-
FILE: string;
|
|
4528
|
-
CUSTOM: string;
|
|
4529
|
-
ASSISTANT: string;
|
|
4530
|
-
TOOL_RESULT: string;
|
|
4531
|
-
TOOL_ARGUMENTS: string;
|
|
4532
4556
|
};
|
|
4533
4557
|
static readonly RECEIVER_TYPE: {
|
|
4534
4558
|
USER: string;
|
|
@@ -4540,7 +4564,6 @@ export class Call extends BaseMessage implements Message {
|
|
|
4540
4564
|
CALL: string;
|
|
4541
4565
|
CUSTOM: string;
|
|
4542
4566
|
INTERACTIVE: string;
|
|
4543
|
-
AGENTIC: string;
|
|
4544
4567
|
};
|
|
4545
4568
|
static readonly ACTION_TYPE: {
|
|
4546
4569
|
TYPE_MEMBER_JOINED: string;
|