mezon-js-protobuf 1.8.5 → 1.8.7

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/api/api.ts CHANGED
@@ -545,7 +545,11 @@ export interface Friend {
545
545
  | number
546
546
  | undefined;
547
547
  /** Time of the latest relationship update. */
548
- update_time: Date | undefined;
548
+ update_time:
549
+ | Date
550
+ | undefined;
551
+ /** source id */
552
+ source_id: string;
549
553
  }
550
554
 
551
555
  /** The friendship status. */
@@ -2906,18 +2910,18 @@ export interface RoleListEventRequest {
2906
2910
  /** clan id */
2907
2911
  clan_id: string;
2908
2912
  /** limit */
2909
- limit: string;
2913
+ limit: number;
2910
2914
  /** state */
2911
- state: string;
2915
+ state: number;
2912
2916
  /** cursor */
2913
2917
  cursor: string;
2914
2918
  }
2915
2919
 
2916
2920
  export interface RoleListEventResponse {
2917
2921
  /** limit */
2918
- limit: string;
2922
+ limit: number;
2919
2923
  /** state */
2920
- state: string;
2924
+ state: number;
2921
2925
  /** cursor */
2922
2926
  cursor: string;
2923
2927
  /** clan_id */
@@ -6967,7 +6971,7 @@ export const Event_PropertiesEntry = {
6967
6971
  };
6968
6972
 
6969
6973
  function createBaseFriend(): Friend {
6970
- return { user: undefined, state: undefined, update_time: undefined };
6974
+ return { user: undefined, state: undefined, update_time: undefined, source_id: "" };
6971
6975
  }
6972
6976
 
6973
6977
  export const Friend = {
@@ -6981,6 +6985,9 @@ export const Friend = {
6981
6985
  if (message.update_time !== undefined) {
6982
6986
  Timestamp.encode(toTimestamp(message.update_time), writer.uint32(26).fork()).ldelim();
6983
6987
  }
6988
+ if (message.source_id !== "") {
6989
+ writer.uint32(34).string(message.source_id);
6990
+ }
6984
6991
  return writer;
6985
6992
  },
6986
6993
 
@@ -7012,6 +7019,13 @@ export const Friend = {
7012
7019
 
7013
7020
  message.update_time = fromTimestamp(Timestamp.decode(reader, reader.uint32()));
7014
7021
  continue;
7022
+ case 4:
7023
+ if (tag !== 34) {
7024
+ break;
7025
+ }
7026
+
7027
+ message.source_id = reader.string();
7028
+ continue;
7015
7029
  }
7016
7030
  if ((tag & 7) === 4 || tag === 0) {
7017
7031
  break;
@@ -7026,6 +7040,7 @@ export const Friend = {
7026
7040
  user: isSet(object.user) ? User.fromJSON(object.user) : undefined,
7027
7041
  state: isSet(object.state) ? Number(object.state) : undefined,
7028
7042
  update_time: isSet(object.update_time) ? fromJsonTimestamp(object.update_time) : undefined,
7043
+ source_id: isSet(object.source_id) ? globalThis.String(object.source_id) : "",
7029
7044
  };
7030
7045
  },
7031
7046
 
@@ -7040,6 +7055,9 @@ export const Friend = {
7040
7055
  if (message.update_time !== undefined) {
7041
7056
  obj.update_time = message.update_time.toISOString();
7042
7057
  }
7058
+ if (message.source_id !== "") {
7059
+ obj.source_id = message.source_id;
7060
+ }
7043
7061
  return obj;
7044
7062
  },
7045
7063
 
@@ -7051,6 +7069,7 @@ export const Friend = {
7051
7069
  message.user = (object.user !== undefined && object.user !== null) ? User.fromPartial(object.user) : undefined;
7052
7070
  message.state = object.state ?? undefined;
7053
7071
  message.update_time = object.update_time ?? undefined;
7072
+ message.source_id = object.source_id ?? "";
7054
7073
  return message;
7055
7074
  },
7056
7075
  };
@@ -27749,7 +27768,7 @@ export const AllUserClans = {
27749
27768
  };
27750
27769
 
27751
27770
  function createBaseRoleListEventRequest(): RoleListEventRequest {
27752
- return { clan_id: "", limit: "", state: "", cursor: "" };
27771
+ return { clan_id: "", limit: 0, state: 0, cursor: "" };
27753
27772
  }
27754
27773
 
27755
27774
  export const RoleListEventRequest = {
@@ -27757,11 +27776,11 @@ export const RoleListEventRequest = {
27757
27776
  if (message.clan_id !== "") {
27758
27777
  writer.uint32(10).string(message.clan_id);
27759
27778
  }
27760
- if (message.limit !== "") {
27761
- writer.uint32(18).string(message.limit);
27779
+ if (message.limit !== 0) {
27780
+ writer.uint32(16).int32(message.limit);
27762
27781
  }
27763
- if (message.state !== "") {
27764
- writer.uint32(26).string(message.state);
27782
+ if (message.state !== 0) {
27783
+ writer.uint32(24).int32(message.state);
27765
27784
  }
27766
27785
  if (message.cursor !== "") {
27767
27786
  writer.uint32(34).string(message.cursor);
@@ -27784,18 +27803,18 @@ export const RoleListEventRequest = {
27784
27803
  message.clan_id = reader.string();
27785
27804
  continue;
27786
27805
  case 2:
27787
- if (tag !== 18) {
27806
+ if (tag !== 16) {
27788
27807
  break;
27789
27808
  }
27790
27809
 
27791
- message.limit = reader.string();
27810
+ message.limit = reader.int32();
27792
27811
  continue;
27793
27812
  case 3:
27794
- if (tag !== 26) {
27813
+ if (tag !== 24) {
27795
27814
  break;
27796
27815
  }
27797
27816
 
27798
- message.state = reader.string();
27817
+ message.state = reader.int32();
27799
27818
  continue;
27800
27819
  case 4:
27801
27820
  if (tag !== 34) {
@@ -27816,8 +27835,8 @@ export const RoleListEventRequest = {
27816
27835
  fromJSON(object: any): RoleListEventRequest {
27817
27836
  return {
27818
27837
  clan_id: isSet(object.clan_id) ? globalThis.String(object.clan_id) : "",
27819
- limit: isSet(object.limit) ? globalThis.String(object.limit) : "",
27820
- state: isSet(object.state) ? globalThis.String(object.state) : "",
27838
+ limit: isSet(object.limit) ? globalThis.Number(object.limit) : 0,
27839
+ state: isSet(object.state) ? globalThis.Number(object.state) : 0,
27821
27840
  cursor: isSet(object.cursor) ? globalThis.String(object.cursor) : "",
27822
27841
  };
27823
27842
  },
@@ -27827,11 +27846,11 @@ export const RoleListEventRequest = {
27827
27846
  if (message.clan_id !== "") {
27828
27847
  obj.clan_id = message.clan_id;
27829
27848
  }
27830
- if (message.limit !== "") {
27831
- obj.limit = message.limit;
27849
+ if (message.limit !== 0) {
27850
+ obj.limit = Math.round(message.limit);
27832
27851
  }
27833
- if (message.state !== "") {
27834
- obj.state = message.state;
27852
+ if (message.state !== 0) {
27853
+ obj.state = Math.round(message.state);
27835
27854
  }
27836
27855
  if (message.cursor !== "") {
27837
27856
  obj.cursor = message.cursor;
@@ -27845,24 +27864,24 @@ export const RoleListEventRequest = {
27845
27864
  fromPartial<I extends Exact<DeepPartial<RoleListEventRequest>, I>>(object: I): RoleListEventRequest {
27846
27865
  const message = createBaseRoleListEventRequest();
27847
27866
  message.clan_id = object.clan_id ?? "";
27848
- message.limit = object.limit ?? "";
27849
- message.state = object.state ?? "";
27867
+ message.limit = object.limit ?? 0;
27868
+ message.state = object.state ?? 0;
27850
27869
  message.cursor = object.cursor ?? "";
27851
27870
  return message;
27852
27871
  },
27853
27872
  };
27854
27873
 
27855
27874
  function createBaseRoleListEventResponse(): RoleListEventResponse {
27856
- return { limit: "", state: "", cursor: "", clanId: "", roles: undefined };
27875
+ return { limit: 0, state: 0, cursor: "", clanId: "", roles: undefined };
27857
27876
  }
27858
27877
 
27859
27878
  export const RoleListEventResponse = {
27860
27879
  encode(message: RoleListEventResponse, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {
27861
- if (message.limit !== "") {
27862
- writer.uint32(10).string(message.limit);
27880
+ if (message.limit !== 0) {
27881
+ writer.uint32(8).int32(message.limit);
27863
27882
  }
27864
- if (message.state !== "") {
27865
- writer.uint32(18).string(message.state);
27883
+ if (message.state !== 0) {
27884
+ writer.uint32(16).int32(message.state);
27866
27885
  }
27867
27886
  if (message.cursor !== "") {
27868
27887
  writer.uint32(26).string(message.cursor);
@@ -27884,18 +27903,18 @@ export const RoleListEventResponse = {
27884
27903
  const tag = reader.uint32();
27885
27904
  switch (tag >>> 3) {
27886
27905
  case 1:
27887
- if (tag !== 10) {
27906
+ if (tag !== 8) {
27888
27907
  break;
27889
27908
  }
27890
27909
 
27891
- message.limit = reader.string();
27910
+ message.limit = reader.int32();
27892
27911
  continue;
27893
27912
  case 2:
27894
- if (tag !== 18) {
27913
+ if (tag !== 16) {
27895
27914
  break;
27896
27915
  }
27897
27916
 
27898
- message.state = reader.string();
27917
+ message.state = reader.int32();
27899
27918
  continue;
27900
27919
  case 3:
27901
27920
  if (tag !== 26) {
@@ -27929,8 +27948,8 @@ export const RoleListEventResponse = {
27929
27948
 
27930
27949
  fromJSON(object: any): RoleListEventResponse {
27931
27950
  return {
27932
- limit: isSet(object.limit) ? globalThis.String(object.limit) : "",
27933
- state: isSet(object.state) ? globalThis.String(object.state) : "",
27951
+ limit: isSet(object.limit) ? globalThis.Number(object.limit) : 0,
27952
+ state: isSet(object.state) ? globalThis.Number(object.state) : 0,
27934
27953
  cursor: isSet(object.cursor) ? globalThis.String(object.cursor) : "",
27935
27954
  clanId: isSet(object.clanId) ? globalThis.String(object.clanId) : "",
27936
27955
  roles: isSet(object.roles) ? RoleList.fromJSON(object.roles) : undefined,
@@ -27939,11 +27958,11 @@ export const RoleListEventResponse = {
27939
27958
 
27940
27959
  toJSON(message: RoleListEventResponse): unknown {
27941
27960
  const obj: any = {};
27942
- if (message.limit !== "") {
27943
- obj.limit = message.limit;
27961
+ if (message.limit !== 0) {
27962
+ obj.limit = Math.round(message.limit);
27944
27963
  }
27945
- if (message.state !== "") {
27946
- obj.state = message.state;
27964
+ if (message.state !== 0) {
27965
+ obj.state = Math.round(message.state);
27947
27966
  }
27948
27967
  if (message.cursor !== "") {
27949
27968
  obj.cursor = message.cursor;
@@ -27962,8 +27981,8 @@ export const RoleListEventResponse = {
27962
27981
  },
27963
27982
  fromPartial<I extends Exact<DeepPartial<RoleListEventResponse>, I>>(object: I): RoleListEventResponse {
27964
27983
  const message = createBaseRoleListEventResponse();
27965
- message.limit = object.limit ?? "";
27966
- message.state = object.state ?? "";
27984
+ message.limit = object.limit ?? 0;
27985
+ message.state = object.state ?? 0;
27967
27986
  message.cursor = object.cursor ?? "";
27968
27987
  message.clanId = object.clanId ?? "";
27969
27988
  message.roles = (object.roles !== undefined && object.roles !== null)
@@ -384,6 +384,8 @@ export interface Friend {
384
384
  state: number | undefined;
385
385
  /** Time of the latest relationship update. */
386
386
  update_time: Date | undefined;
387
+ /** source id */
388
+ source_id: string;
387
389
  }
388
390
  /** The friendship status. */
389
391
  export declare enum Friend_State {
@@ -2311,17 +2313,17 @@ export interface RoleListEventRequest {
2311
2313
  /** clan id */
2312
2314
  clan_id: string;
2313
2315
  /** limit */
2314
- limit: string;
2316
+ limit: number;
2315
2317
  /** state */
2316
- state: string;
2318
+ state: number;
2317
2319
  /** cursor */
2318
2320
  cursor: string;
2319
2321
  }
2320
2322
  export interface RoleListEventResponse {
2321
2323
  /** limit */
2322
- limit: string;
2324
+ limit: number;
2323
2325
  /** state */
2324
- state: string;
2326
+ state: number;
2325
2327
  /** cursor */
2326
2328
  cursor: string;
2327
2329
  /** clan_id */
@@ -4828,6 +4830,7 @@ export declare const Friend: {
4828
4830
  } | undefined;
4829
4831
  state?: number | undefined;
4830
4832
  update_time?: Date | undefined;
4833
+ source_id?: string | undefined;
4831
4834
  } & {
4832
4835
  user?: ({
4833
4836
  id?: string | undefined;
@@ -4878,6 +4881,7 @@ export declare const Friend: {
4878
4881
  } & { [K in Exclude<keyof I["user"], keyof User>]: never; }) | undefined;
4879
4882
  state?: number | undefined;
4880
4883
  update_time?: Date | undefined;
4884
+ source_id?: string | undefined;
4881
4885
  } & { [K_1 in Exclude<keyof I, keyof Friend>]: never; }>(base?: I | undefined): Friend;
4882
4886
  fromPartial<I_1 extends {
4883
4887
  user?: {
@@ -4906,6 +4910,7 @@ export declare const Friend: {
4906
4910
  } | undefined;
4907
4911
  state?: number | undefined;
4908
4912
  update_time?: Date | undefined;
4913
+ source_id?: string | undefined;
4909
4914
  } & {
4910
4915
  user?: ({
4911
4916
  id?: string | undefined;
@@ -4956,6 +4961,7 @@ export declare const Friend: {
4956
4961
  } & { [K_2 in Exclude<keyof I_1["user"], keyof User>]: never; }) | undefined;
4957
4962
  state?: number | undefined;
4958
4963
  update_time?: Date | undefined;
4964
+ source_id?: string | undefined;
4959
4965
  } & { [K_3 in Exclude<keyof I_1, keyof Friend>]: never; }>(object: I_1): Friend;
4960
4966
  };
4961
4967
  export declare const FriendList: {
@@ -4991,6 +4997,7 @@ export declare const FriendList: {
4991
4997
  } | undefined;
4992
4998
  state?: number | undefined;
4993
4999
  update_time?: Date | undefined;
5000
+ source_id?: string | undefined;
4994
5001
  }[] | undefined;
4995
5002
  cursor?: string | undefined;
4996
5003
  } & {
@@ -5021,6 +5028,7 @@ export declare const FriendList: {
5021
5028
  } | undefined;
5022
5029
  state?: number | undefined;
5023
5030
  update_time?: Date | undefined;
5031
+ source_id?: string | undefined;
5024
5032
  }[] & ({
5025
5033
  user?: {
5026
5034
  id?: string | undefined;
@@ -5048,6 +5056,7 @@ export declare const FriendList: {
5048
5056
  } | undefined;
5049
5057
  state?: number | undefined;
5050
5058
  update_time?: Date | undefined;
5059
+ source_id?: string | undefined;
5051
5060
  } & {
5052
5061
  user?: ({
5053
5062
  id?: string | undefined;
@@ -5098,6 +5107,7 @@ export declare const FriendList: {
5098
5107
  } & { [K in Exclude<keyof I["friends"][number]["user"], keyof User>]: never; }) | undefined;
5099
5108
  state?: number | undefined;
5100
5109
  update_time?: Date | undefined;
5110
+ source_id?: string | undefined;
5101
5111
  } & { [K_1 in Exclude<keyof I["friends"][number], keyof Friend>]: never; })[] & { [K_2 in Exclude<keyof I["friends"], keyof {
5102
5112
  user?: {
5103
5113
  id?: string | undefined;
@@ -5125,6 +5135,7 @@ export declare const FriendList: {
5125
5135
  } | undefined;
5126
5136
  state?: number | undefined;
5127
5137
  update_time?: Date | undefined;
5138
+ source_id?: string | undefined;
5128
5139
  }[]>]: never; }) | undefined;
5129
5140
  cursor?: string | undefined;
5130
5141
  } & { [K_3 in Exclude<keyof I, keyof FriendList>]: never; }>(base?: I | undefined): FriendList;
@@ -5156,6 +5167,7 @@ export declare const FriendList: {
5156
5167
  } | undefined;
5157
5168
  state?: number | undefined;
5158
5169
  update_time?: Date | undefined;
5170
+ source_id?: string | undefined;
5159
5171
  }[] | undefined;
5160
5172
  cursor?: string | undefined;
5161
5173
  } & {
@@ -5186,6 +5198,7 @@ export declare const FriendList: {
5186
5198
  } | undefined;
5187
5199
  state?: number | undefined;
5188
5200
  update_time?: Date | undefined;
5201
+ source_id?: string | undefined;
5189
5202
  }[] & ({
5190
5203
  user?: {
5191
5204
  id?: string | undefined;
@@ -5213,6 +5226,7 @@ export declare const FriendList: {
5213
5226
  } | undefined;
5214
5227
  state?: number | undefined;
5215
5228
  update_time?: Date | undefined;
5229
+ source_id?: string | undefined;
5216
5230
  } & {
5217
5231
  user?: ({
5218
5232
  id?: string | undefined;
@@ -5263,6 +5277,7 @@ export declare const FriendList: {
5263
5277
  } & { [K_4 in Exclude<keyof I_1["friends"][number]["user"], keyof User>]: never; }) | undefined;
5264
5278
  state?: number | undefined;
5265
5279
  update_time?: Date | undefined;
5280
+ source_id?: string | undefined;
5266
5281
  } & { [K_5 in Exclude<keyof I_1["friends"][number], keyof Friend>]: never; })[] & { [K_6 in Exclude<keyof I_1["friends"], keyof {
5267
5282
  user?: {
5268
5283
  id?: string | undefined;
@@ -5290,6 +5305,7 @@ export declare const FriendList: {
5290
5305
  } | undefined;
5291
5306
  state?: number | undefined;
5292
5307
  update_time?: Date | undefined;
5308
+ source_id?: string | undefined;
5293
5309
  }[]>]: never; }) | undefined;
5294
5310
  cursor?: string | undefined;
5295
5311
  } & { [K_7 in Exclude<keyof I_1, keyof FriendList>]: never; }>(object: I_1): FriendList;
@@ -17927,24 +17943,24 @@ export declare const RoleListEventRequest: {
17927
17943
  toJSON(message: RoleListEventRequest): unknown;
17928
17944
  create<I extends {
17929
17945
  clan_id?: string | undefined;
17930
- limit?: string | undefined;
17931
- state?: string | undefined;
17946
+ limit?: number | undefined;
17947
+ state?: number | undefined;
17932
17948
  cursor?: string | undefined;
17933
17949
  } & {
17934
17950
  clan_id?: string | undefined;
17935
- limit?: string | undefined;
17936
- state?: string | undefined;
17951
+ limit?: number | undefined;
17952
+ state?: number | undefined;
17937
17953
  cursor?: string | undefined;
17938
17954
  } & { [K in Exclude<keyof I, keyof RoleListEventRequest>]: never; }>(base?: I | undefined): RoleListEventRequest;
17939
17955
  fromPartial<I_1 extends {
17940
17956
  clan_id?: string | undefined;
17941
- limit?: string | undefined;
17942
- state?: string | undefined;
17957
+ limit?: number | undefined;
17958
+ state?: number | undefined;
17943
17959
  cursor?: string | undefined;
17944
17960
  } & {
17945
17961
  clan_id?: string | undefined;
17946
- limit?: string | undefined;
17947
- state?: string | undefined;
17962
+ limit?: number | undefined;
17963
+ state?: number | undefined;
17948
17964
  cursor?: string | undefined;
17949
17965
  } & { [K_1 in Exclude<keyof I_1, keyof RoleListEventRequest>]: never; }>(object: I_1): RoleListEventRequest;
17950
17966
  };
@@ -17954,8 +17970,8 @@ export declare const RoleListEventResponse: {
17954
17970
  fromJSON(object: any): RoleListEventResponse;
17955
17971
  toJSON(message: RoleListEventResponse): unknown;
17956
17972
  create<I extends {
17957
- limit?: string | undefined;
17958
- state?: string | undefined;
17973
+ limit?: number | undefined;
17974
+ state?: number | undefined;
17959
17975
  cursor?: string | undefined;
17960
17976
  clanId?: string | undefined;
17961
17977
  roles?: {
@@ -18005,8 +18021,8 @@ export declare const RoleListEventResponse: {
18005
18021
  cacheable_cursor?: string | undefined;
18006
18022
  } | undefined;
18007
18023
  } & {
18008
- limit?: string | undefined;
18009
- state?: string | undefined;
18024
+ limit?: number | undefined;
18025
+ state?: number | undefined;
18010
18026
  cursor?: string | undefined;
18011
18027
  clanId?: string | undefined;
18012
18028
  roles?: ({
@@ -18292,8 +18308,8 @@ export declare const RoleListEventResponse: {
18292
18308
  } & { [K_9 in Exclude<keyof I["roles"], keyof RoleList>]: never; }) | undefined;
18293
18309
  } & { [K_10 in Exclude<keyof I, keyof RoleListEventResponse>]: never; }>(base?: I | undefined): RoleListEventResponse;
18294
18310
  fromPartial<I_1 extends {
18295
- limit?: string | undefined;
18296
- state?: string | undefined;
18311
+ limit?: number | undefined;
18312
+ state?: number | undefined;
18297
18313
  cursor?: string | undefined;
18298
18314
  clanId?: string | undefined;
18299
18315
  roles?: {
@@ -18343,8 +18359,8 @@ export declare const RoleListEventResponse: {
18343
18359
  cacheable_cursor?: string | undefined;
18344
18360
  } | undefined;
18345
18361
  } & {
18346
- limit?: string | undefined;
18347
- state?: string | undefined;
18362
+ limit?: number | undefined;
18363
+ state?: number | undefined;
18348
18364
  cursor?: string | undefined;
18349
18365
  clanId?: string | undefined;
18350
18366
  roles?: ({