Skip to content

Commit f3108bc

Browse files
committed
Updated SDK version to 4.1.1
1 parent 5024348 commit f3108bc

3 files changed

Lines changed: 27 additions & 2 deletions

File tree

CometChat.d.ts

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1017,6 +1017,7 @@ export class CometChat {
10171017
};
10181018
static GoalType: typeof GoalType;
10191019
static AttachmentType: typeof AttachmentType;
1020+
static ModerationStatus: typeof ModerationStatus;
10201021
static CometChatException: typeof CometChatException;
10211022
static TextMessage: typeof TextMessage;
10221023
static MediaMessage: typeof MediaMessage;
@@ -2473,6 +2474,13 @@ export class MediaMessage extends BaseMessage implements Message {
24732474
* Set the tags for the message.
24742475
*/
24752476
setTags(tags: Array<String>): void;
2477+
/**
2478+
* Gets the moderation status of the message.
2479+
* @description If the message is not moderated, it returns "unmoderated".
2480+
* If the message is moderated, it returns the status of the moderation.
2481+
* @returns {ModerationStatus}
2482+
*/
2483+
getModerationStatus(): ModerationStatus;
24762484
}
24772485

24782486
/**
@@ -2864,6 +2872,13 @@ export class TextMessage extends BaseMessage implements Message {
28642872
* Set the tags for the message.
28652873
*/
28662874
setTags(tags: Array<String>): void;
2875+
/**
2876+
* Gets the moderation status of the message.
2877+
* @description If the message is not moderated, it returns "unmoderated".
2878+
* If the message is moderated, it returns the status of the moderation.
2879+
* @returns {ModerationStatus}
2880+
*/
2881+
getModerationStatus(): ModerationStatus;
28672882
}
28682883

28692884
export const constants: {
@@ -3937,6 +3952,12 @@ export enum AttachmentType {
39373952
AUDIO = "audio",
39383953
FILE = "file"
39393954
}
3955+
export enum ModerationStatus {
3956+
PENDING = "pending",
3957+
APPROVED = "approved",
3958+
DISAPPROVED = "disapproved",
3959+
UNMODERATED = "unmoderated"
3960+
}
39403961
export const AI_ASSISTANT_EVENTS: {
39413962
RUN_STARTED: string;
39423963
RUN_FINISHED: string;
@@ -4211,6 +4232,10 @@ export class MessageListener {
42114232
* This event is triggered when a message is read by all members in a group.
42124233
*/
42134234
onMessagesReadByAll?: Function;
4235+
/**
4236+
* This event is triggered when a message is moderated.
4237+
*/
4238+
onMessageModerated?: Function;
42144239
/**
42154240
* This event is triggered when an AI tool result is received.
42164241
*/

CometChat.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@cometchat/chat-sdk-javascript",
3-
"version": "4.1.0",
3+
"version": "4.1.1",
44
"description": "A complete chat solution.",
55
"main": "CometChat.js",
66
"scripts": {

0 commit comments

Comments
 (0)