mezon-js 2.8.33 → 2.8.35

Sign up to get free protection for your applications and to get access to all the features.
package/api.gen.ts CHANGED
@@ -477,6 +477,8 @@ export interface ApiChannelDescription {
477
477
 
478
478
  /** A message sent on a channel. */
479
479
  export interface ApiChannelMessage {
480
+ // id
481
+ id: string;
480
482
  //
481
483
  attachments?: string;
482
484
  //
@@ -951,15 +953,15 @@ export interface ApiMessageAttachment {
951
953
  //
952
954
  width?: number;
953
955
  /** The channel this message belongs to. */
954
- channel_id:string;
956
+ channel_id?:string;
955
957
  // The mode
956
- mode: number;
958
+ mode?: number;
957
959
  // The channel label
958
- channel_label: string;
960
+ channel_label?: string;
959
961
  /** The message that user react */
960
- message_id: string;
962
+ message_id?: string;
961
963
  /** Message sender, usually a user ID. */
962
- sender_id: string;
964
+ sender_id?: string;
963
965
  }
964
966
 
965
967
  /** */
@@ -989,15 +991,15 @@ export interface ApiMessageMention {
989
991
  // end position
990
992
  e?: number;
991
993
  /** The channel this message belongs to. */
992
- channel_id:string;
994
+ channel_id?:string;
993
995
  // The mode
994
- mode: number;
996
+ mode?: number;
995
997
  // The channel label
996
- channel_label: string;
998
+ channel_label?: string;
997
999
  /** The message that user react */
998
- message_id: string;
1000
+ message_id?: string;
999
1001
  /** Message sender, usually a user ID. */
1000
- sender_id: string;
1002
+ sender_id?: string;
1001
1003
  }
1002
1004
 
1003
1005
  /** */
package/client.ts CHANGED
@@ -1038,7 +1038,7 @@ export class Client {
1038
1038
  var result: ChannelMessageList = {
1039
1039
  messages: [],
1040
1040
  last_seen_message: response.last_seen_message,
1041
- last_sent_message: response.last_sent_message
1041
+ last_sent_message: response.last_sent_message
1042
1042
  };
1043
1043
 
1044
1044
  if (response.messages == null) {
package/dist/api.gen.d.ts CHANGED
@@ -276,6 +276,7 @@ export interface ApiChannelDescription {
276
276
  }
277
277
  /** A message sent on a channel. */
278
278
  export interface ApiChannelMessage {
279
+ id: string;
279
280
  attachments?: string;
280
281
  avatar?: string;
281
282
  category_name?: string;
@@ -547,13 +548,13 @@ export interface ApiMessageAttachment {
547
548
  url?: string;
548
549
  width?: number;
549
550
  /** The channel this message belongs to. */
550
- channel_id: string;
551
- mode: number;
552
- channel_label: string;
551
+ channel_id?: string;
552
+ mode?: number;
553
+ channel_label?: string;
553
554
  /** The message that user react */
554
- message_id: string;
555
+ message_id?: string;
555
556
  /** Message sender, usually a user ID. */
556
- sender_id: string;
557
+ sender_id?: string;
557
558
  }
558
559
  /** */
559
560
  export interface ApiMessageDeleted {
@@ -571,13 +572,13 @@ export interface ApiMessageMention {
571
572
  s?: number;
572
573
  e?: number;
573
574
  /** The channel this message belongs to. */
574
- channel_id: string;
575
- mode: number;
576
- channel_label: string;
575
+ channel_id?: string;
576
+ mode?: number;
577
+ channel_label?: string;
577
578
  /** The message that user react */
578
- message_id: string;
579
+ message_id?: string;
579
580
  /** Message sender, usually a user ID. */
580
- sender_id: string;
581
+ sender_id?: string;
581
582
  }
582
583
  /** */
583
584
  export interface ApiMessageReaction {
@@ -4798,6 +4798,7 @@ var _DefaultSocket = class _DefaultSocket {
4798
4798
  } catch (e2) {
4799
4799
  }
4800
4800
  var e = {
4801
+ id: message.id,
4801
4802
  avatar: message.channel_message.avatar,
4802
4803
  channel_id: message.channel_message.channel_id,
4803
4804
  mode: message.channel_message.mode,
@@ -4769,6 +4769,7 @@ var _DefaultSocket = class _DefaultSocket {
4769
4769
  } catch (e2) {
4770
4770
  }
4771
4771
  var e = {
4772
+ id: message.id,
4772
4773
  avatar: message.channel_message.avatar,
4773
4774
  channel_id: message.channel_message.channel_id,
4774
4775
  mode: message.channel_message.mode,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mezon-js",
3
- "version": "2.8.33",
3
+ "version": "2.8.35",
4
4
  "scripts": {
5
5
  "build": "npx tsc && npx rollup -c --bundleConfigAsCjs && node build.mjs"
6
6
  },
package/socket.ts CHANGED
@@ -937,6 +937,7 @@ export class DefaultSocket implements Socket {
937
937
  //console.log("references is invalid", e);
938
938
  }
939
939
  var e: ApiChannelMessage = {
940
+ id: message.id,
940
941
  avatar: message.channel_message.avatar,
941
942
  channel_id: message.channel_message.channel_id,
942
943
  mode: message.channel_message.mode,