@seayoo-web/gamer-api 2.0.2 → 2.0.3

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/dist/index.js CHANGED
@@ -59,7 +59,7 @@ const he = {
59
59
  }
60
60
  }
61
61
  }, f = "gamer_token";
62
- class wr {
62
+ class hr {
63
63
  constructor(t, n) {
64
64
  l(this, "$idToken", "");
65
65
  l(this, "$weixinToken", "");
@@ -279,7 +279,7 @@ const ke = {
279
279
  ...Pe.shape,
280
280
  role_level: e.number(),
281
281
  last_login_time: e.number()
282
- }).lock(), Ue = e.object({
282
+ }).lock(), $e = e.object({
283
283
  ...z.shape,
284
284
  /** 角色战力 */
285
285
  role_fighting: e.number(),
@@ -289,7 +289,7 @@ const ke = {
289
289
  kin_name: e.string().optional(),
290
290
  /** 宗门职位 */
291
291
  kin_position: e.string().optional()
292
- }).lock(), $e = e.object({
292
+ }).lock(), Ue = e.object({
293
293
  name: e.string(),
294
294
  avatar_url: e.string(),
295
295
  bio: e.string(),
@@ -309,7 +309,7 @@ const ke = {
309
309
  decreased_credit: e.number(),
310
310
  expired_credit: e.number(),
311
311
  balance_credit: e.number()
312
- }).lock(), De = e.object({
312
+ }).lock(), Ie = e.object({
313
313
  id: e.number(),
314
314
  change_type: Ve,
315
315
  change_scene: je,
@@ -351,10 +351,10 @@ const ke = {
351
351
  created_at: e.number(),
352
352
  updated_at: e.number(),
353
353
  redeemable_quantity: e.number().optional()
354
- }).lock(), Ie = e.object({
354
+ }).lock(), De = e.object({
355
355
  ...k(K.shape, "tag"),
356
356
  product: X.clone().optional()
357
- }).lock(), kr = e.union(
357
+ }).lock(), wr = e.union(
358
358
  e.object({
359
359
  server_id: e.string(),
360
360
  role_id: e.string()
@@ -389,14 +389,14 @@ const ke = {
389
389
  status: xe,
390
390
  created_at: e.number(),
391
391
  extra_data: e.union(Ge.clone(), Ae.clone()).satisfies().optional()
392
- }), Oe = e.guard(Se), N = o({ player: Le }), Be = o({ roles: e.array(z) }), j = o({ role_card: Ue }), O = e.guard($e), B = e.guard(J), Qe = o({ addresses: e.array(J) }), Me = e.guard(Fe), He = o({
393
- credit_logs: e.array(De),
392
+ }), Oe = e.guard(Se), N = o({ player: Le }), Be = o({ roles: e.array(z) }), j = o({ role_card: $e }), O = e.guard(Ue), B = e.guard(J), Qe = o({ addresses: e.array(J) }), Me = e.guard(Fe), He = o({
393
+ credit_logs: e.array(Ie),
394
394
  next_token: e.string().optional()
395
- }), ze = o({ products: e.array(X) }), Je = o({ benefits: e.array(K) }), Ke = o({ benefit: Ie }), Xe = o({
395
+ }), ze = o({ products: e.array(X) }), Je = o({ benefits: e.array(K) }), Ke = o({ benefit: De }), Xe = o({
396
396
  redemptions: e.array(Ne),
397
397
  next_token: e.string().optional()
398
398
  });
399
- class vr {
399
+ class kr {
400
400
  constructor(t) {
401
401
  l(this, "token");
402
402
  l(this, "req");
@@ -642,7 +642,7 @@ const v = {
642
642
  Credit: "credit",
643
643
  /** 空奖励 */
644
644
  VoidItem: "void_item"
645
- }, Y = e.string().enum(v).lock(), Cr = v, Z = Y, Ye = {
645
+ }, Y = e.string().enum(v).lock(), vr = v, Z = Y, Ye = {
646
646
  /** 世游通行证 ID / Combo ID */
647
647
  UserId: "user_id",
648
648
  /** 游戏角色 ID */
@@ -718,7 +718,7 @@ const v = {
718
718
  Failed: "failed",
719
719
  /** 奖励已发货 */
720
720
  Delivered: "delivered"
721
- }, Vr = e.string().enum(g).lock(), ot = {
721
+ }, Cr = e.string().enum(g).lock(), ot = {
722
722
  /** 奖励未领取 */
723
723
  Unclaimed: g.Unclaimed,
724
724
  /** 奖励已领取 */
@@ -765,7 +765,7 @@ const v = {
765
765
  Claimed: "claimed",
766
766
  /** 领奖失败 */
767
767
  Fail: "fail"
768
- }, Rr = e.string().enum(h).lock(), ut = {
768
+ }, Vr = e.string().enum(h).lock(), ut = {
769
769
  /** 发起组队 */
770
770
  Assemble: "assemble",
771
771
  /** 加入队伍 */
@@ -776,14 +776,14 @@ const v = {
776
776
  ChangeVisibility: "change_visibility",
777
777
  /** 查询组队信息 */
778
778
  Query: "query"
779
- }, jr = e.string().enum(ut).lock(), lt = {
779
+ }, Rr = e.string().enum(ut).lock(), lt = {
780
780
  /** 查询抽奖券 */
781
781
  Query: "query",
782
782
  /** 开奖 */
783
783
  Draw: "draw",
784
784
  /** 领奖 */
785
785
  Claim: "claim"
786
- }, Tr = e.string().enum(lt).lock(), mt = e.string().enum(k(v, "GiftCode", "LotteryTicket")), U = e.object({
786
+ }, jr = e.string().enum(lt).lock(), mt = e.string().enum(k(v, "GiftCode", "LotteryTicket")), $ = e.object({
787
787
  reward_item_id: e.number(),
788
788
  reward_amount: e.number(),
789
789
  reward_item_name: e.string(),
@@ -793,11 +793,11 @@ const v = {
793
793
  reward_item_rating: e.number()
794
794
  }).lock(), dt = e.object({
795
795
  engage_count: e.number(),
796
- rewards: e.array(U)
796
+ rewards: e.array($)
797
797
  }).lock(), gt = e.union(
798
798
  e.object({
799
799
  feature_reward_type: e.string().enum("every"),
800
- reward_details: e.array(U)
800
+ reward_details: e.array($)
801
801
  }),
802
802
  e.object({
803
803
  feature_reward_type: e.string().enum("regular"),
@@ -874,7 +874,7 @@ const v = {
874
874
  reward_item_desc: e.string().optional(),
875
875
  reward_amount: e.number(),
876
876
  reward_remaining_stock: e.number()
877
- }), Ut = e.object({
877
+ }), $t = e.object({
878
878
  ...c.shape,
879
879
  feature_type: e.string().enum(Pt),
880
880
  config: e.object({
@@ -885,16 +885,16 @@ const v = {
885
885
  consume_item_desc: e.string().optional(),
886
886
  rewards: e.array(Et)
887
887
  })
888
- }), $t = s.LotteryDraw, Ft = e.object({
888
+ }), Ut = s.LotteryDraw, Ft = e.object({
889
889
  ...c.shape,
890
- feature_type: e.string().enum($t),
890
+ feature_type: e.string().enum(Ut),
891
891
  config: e.object({
892
892
  draw_not_before: e.number(),
893
893
  draw_not_after: e.number()
894
894
  })
895
- }), Dt = s.Preregister, It = e.object({
895
+ }), It = s.Preregister, Dt = e.object({
896
896
  ...c.shape,
897
- feature_type: e.string().enum(Dt)
897
+ feature_type: e.string().enum(It)
898
898
  }), Gt = s.Quest, At = e.object({
899
899
  ...c.shape,
900
900
  feature_type: e.string().enum(Gt),
@@ -956,7 +956,7 @@ const v = {
956
956
  finalists_amount: e.number(),
957
957
  source: it,
958
958
  options: e.array(Zt),
959
- rewards: e.array(U)
959
+ rewards: e.array($)
960
960
  })
961
961
  }), en = e.union(
962
962
  _t,
@@ -967,9 +967,9 @@ const v = {
967
967
  jt,
968
968
  qt,
969
969
  St,
970
- Ut,
970
+ $t,
971
971
  Ft,
972
- It,
972
+ Dt,
973
973
  At,
974
974
  Ot,
975
975
  Qt,
@@ -996,19 +996,6 @@ const v = {
996
996
  avatar_url: e.string().optional()
997
997
  }), an = e.object({
998
998
  lottery_count: e.number()
999
- }), sn = e.object({
1000
- reward_id: e.number(),
1001
- reward_item_id: e.number(),
1002
- reward_item_type: Z,
1003
- reward_count: e.number(),
1004
- reward_status: ee,
1005
- reward_source: E,
1006
- reward_item_name: e.string(),
1007
- reward_item_icon_url: e.string(),
1008
- reward_item_desc: e.string().optional(),
1009
- reward_item_rating: e.number(),
1010
- receive_time: e.number(),
1011
- extra_data: e.union(...ne, e.record(e.unknown())).satisfies().optional()
1012
999
  }), te = e.object({
1013
1000
  reward_id: e.number(),
1014
1001
  reward_item_id: e.number(),
@@ -1027,32 +1014,21 @@ const v = {
1027
1014
  feature_type: tt,
1028
1015
  receive_time: e.number(),
1029
1016
  extra_data: e.record(e.unknown()).optional()
1030
- }), cn = e.object({
1031
- reward_id: e.number(),
1032
- reward_item_id: e.number(),
1033
- reward_item_name: e.string(),
1034
- reward_item_type: Z,
1035
- reward_item_icon_url: e.string(),
1036
- reward_item_desc: e.string().optional(),
1037
- reward_amount: e.number(),
1038
- reward_status: ee,
1039
- reward_source: E,
1040
- extra_data: e.record(e.unknown()).optional()
1041
- }), un = e.string().enum(h.Unknown, h.Pending), ln = e.union(
1017
+ }), sn = e.string().enum(h.Unknown, h.Pending), cn = e.union(
1042
1018
  e.object({
1043
1019
  ticket: e.string(),
1044
- status: un
1020
+ status: sn
1045
1021
  }),
1046
1022
  e.object({
1047
1023
  ticket: e.string(),
1048
1024
  status: e.string().enum(k(h, "Unknown", "Pending")),
1049
1025
  reward: te
1050
1026
  })
1051
- ).satisfies(), mn = e.object({
1052
- tickets: e.array(ln)
1053
- }), dn = e.object({
1027
+ ).satisfies(), un = e.object({
1028
+ tickets: e.array(cn)
1029
+ }), ln = e.object({
1054
1030
  platforms: e.array(e.string())
1055
- }), gn = e.object({
1031
+ }), mn = e.object({
1056
1032
  objective: W,
1057
1033
  progress: e.number(),
1058
1034
  completion_value: e.number().optional(),
@@ -1068,22 +1044,22 @@ const v = {
1068
1044
  })
1069
1045
  )
1070
1046
  }).optional()
1071
- }), pn = e.object({
1047
+ }), dn = e.object({
1072
1048
  platform: e.string()
1073
- }), _n = e.object({
1049
+ }), gn = e.object({
1074
1050
  weixin_openid: e.string()
1075
- }), bn = e.object({
1051
+ }), pn = e.object({
1076
1052
  serial_number: e.number()
1077
- }), yn = e.object({
1053
+ }), _n = e.object({
1078
1054
  team_code: e.string(),
1079
1055
  leader_name: e.string(),
1080
1056
  total_members: e.number()
1081
- }), qr = e.object({
1057
+ }), Tr = e.object({
1082
1058
  is_leader: e.bool(),
1083
1059
  is_myself: e.bool().optional(),
1084
1060
  role_name: e.string(),
1085
1061
  server_name: e.string()
1086
- }), fn = e.object({
1062
+ }), bn = e.object({
1087
1063
  team_code: e.string(),
1088
1064
  visibility: ct,
1089
1065
  members: e.array(
@@ -1093,47 +1069,71 @@ const v = {
1093
1069
  server_name: e.string()
1094
1070
  })
1095
1071
  )
1096
- }), hn = e.object({
1072
+ }), yn = e.object({
1097
1073
  option_sn: e.string()
1098
- }), wn = e.object({
1074
+ }), fn = e.object({
1099
1075
  user_id: e.string(),
1100
1076
  name: e.string(),
1101
1077
  avatar_url: e.string(),
1102
1078
  comment: e.string(),
1103
1079
  video_note: e.number(),
1104
1080
  created_at: e.number()
1105
- }), ne = [
1106
- dn,
1081
+ }), ne = e.union(
1082
+ ln,
1107
1083
  an,
1108
- bn,
1109
- on,
1110
1084
  pn,
1111
- hn,
1112
- _n,
1085
+ on,
1086
+ dn,
1087
+ yn,
1088
+ gn,
1113
1089
  nn,
1114
1090
  rn,
1115
- fn,
1116
- gn,
1117
- mn
1118
- ], kn = e.union(...ne).satisfies().lock(), re = e.object({
1091
+ bn,
1092
+ mn,
1093
+ un
1094
+ ).satisfies().lock(), hn = e.object({
1095
+ reward_id: e.number(),
1096
+ reward_item_id: e.number(),
1097
+ reward_item_type: Z,
1098
+ reward_count: e.number(),
1099
+ reward_status: ee,
1100
+ reward_source: E,
1101
+ reward_item_name: e.string(),
1102
+ reward_item_icon_url: e.string(),
1103
+ reward_item_desc: e.string().optional(),
1104
+ reward_item_rating: e.number(),
1105
+ receive_time: e.number(),
1106
+ extra_data: e.union(...ne.validators, e.record(e.unknown())).satisfies().optional()
1107
+ }), wn = e.object({
1108
+ reward_id: e.number(),
1109
+ reward_item_id: e.number(),
1110
+ reward_item_name: e.string(),
1111
+ reward_item_type: Z,
1112
+ reward_item_icon_url: e.string(),
1113
+ reward_item_desc: e.string().optional(),
1114
+ reward_amount: e.number(),
1115
+ reward_status: ee,
1116
+ reward_source: E,
1117
+ extra_data: e.record(e.unknown()).optional()
1118
+ }), re = e.object({
1119
1119
  engagement_id: e.number(),
1120
1120
  user_id: e.string(),
1121
1121
  event_id: e.number(),
1122
1122
  feature_id: e.number(),
1123
1123
  sequence: e.number(),
1124
- data: kn.clone().optional(),
1124
+ data: ne.clone().optional(),
1125
1125
  server_id: e.string().optional(),
1126
1126
  role_id: e.string().optional(),
1127
1127
  created_at: e.number(),
1128
- rewards: e.array(sn).optional()
1129
- }).lock(), vn = e.object({
1128
+ rewards: e.array(hn).optional()
1129
+ }).lock(), kn = e.object({
1130
1130
  allowed: e.bool(),
1131
1131
  registered: e.bool()
1132
- }), Cn = e.object({
1132
+ }), vn = e.object({
1133
1133
  feature_id: e.number(),
1134
1134
  can_engage: e.bool(),
1135
1135
  has_unclaimed_rewards: e.bool()
1136
- }), Vn = e.object({
1136
+ }), Cn = e.object({
1137
1137
  engagement_id: e.number(),
1138
1138
  engagement: e.object({
1139
1139
  user_id: e.string(),
@@ -1143,33 +1143,33 @@ const v = {
1143
1143
  role_id: e.string(),
1144
1144
  data: re.clone().optional()
1145
1145
  }).optional(),
1146
- rewards: e.array(cn).optional(),
1146
+ rewards: e.array(wn).optional(),
1147
1147
  scan: e.bool().optional()
1148
- }), Rn = e.object({
1148
+ }), Vn = e.object({
1149
1149
  reward_id: e.number(),
1150
1150
  reward_status: P
1151
- }), jn = e.guard(tn), Tn = e.guard(vn), q = o({ count: e.number() }), qn = o({ first_visit: e.bool() }), xn = o({
1152
- engagements: e.union(e.array(wn), e.array(yn))
1151
+ }), Rn = e.guard(tn), jn = e.guard(kn), q = o({ count: e.number() }), Tn = o({ first_visit: e.bool() }), qn = o({
1152
+ engagements: e.union(e.array(fn), e.array(_n))
1153
+ }), xn = o({
1154
+ status: e.array(vn)
1153
1155
  }), Sn = o({
1154
- status: e.array(Cn)
1155
- }), Ln = o({
1156
1156
  engagements: e.array(re),
1157
1157
  next_token: e.string().optional()
1158
- }), Pn = e.guard(Vn), En = o({
1159
- claimed_items: e.array(Rn)
1160
- }), Un = o({
1158
+ }), Ln = e.guard(Cn), Pn = o({
1159
+ claimed_items: e.array(Vn)
1160
+ }), En = o({
1161
1161
  reward_status: P
1162
1162
  }), $n = o({
1163
1163
  user_rewards: e.array(te),
1164
1164
  next_token: e.string().optional()
1165
- }), Fn = o({
1165
+ }), Un = o({
1166
1166
  scene: e.string()
1167
- }), Dn = o({
1167
+ }), Fn = o({
1168
1168
  params: e.string()
1169
1169
  }), In = o({
1170
1170
  img: e.string()
1171
1171
  });
1172
- class xr {
1172
+ class qr {
1173
1173
  constructor(t, n) {
1174
1174
  l(this, "token");
1175
1175
  l(this, "event", 0);
@@ -1182,7 +1182,7 @@ class xr {
1182
1182
  * https://kdocs.cn/l/cf2mO2uRLqh9?linkname=OWGSPF3Ysl
1183
1183
  */
1184
1184
  async verifyMobileAllowed(t, n) {
1185
- const { data: r } = await this.req.get("verify-mobile-allowed", Tn, {
1185
+ const { data: r } = await this.req.get("verify-mobile-allowed", jn, {
1186
1186
  params: { game_id: t, mobile: n }
1187
1187
  });
1188
1188
  return r;
@@ -1193,7 +1193,7 @@ class xr {
1193
1193
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=wFXxtdNKPm
1194
1194
  */
1195
1195
  async getConfig() {
1196
- const { data: t } = await this.req.get(`event/${this.event}/event-config`, jn);
1196
+ const { data: t } = await this.req.get(`event/${this.event}/event-config`, Rn);
1197
1197
  return t;
1198
1198
  }
1199
1199
  /**
@@ -1226,7 +1226,7 @@ class xr {
1226
1226
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=THtZ4ewIQW
1227
1227
  */
1228
1228
  async getEngagements(t) {
1229
- const { data: n } = await this.req.get(`event/${this.event}/feature-engagements`, xn, {
1229
+ const { data: n } = await this.req.get(`event/${this.event}/feature-engagements`, qn, {
1230
1230
  params: { feature_id: t }
1231
1231
  });
1232
1232
  return (n == null ? void 0 : n.engagements) || [];
@@ -1241,7 +1241,7 @@ class xr {
1241
1241
  const { data: n, code: r } = await this.req.post(
1242
1242
  `event/${this.event}/visit`,
1243
1243
  a(t || {}),
1244
- qn
1244
+ Tn
1245
1245
  );
1246
1246
  return n ?? {
1247
1247
  error: r
@@ -1258,7 +1258,7 @@ class xr {
1258
1258
  */
1259
1259
  async getUserFeatureStatus(t) {
1260
1260
  if (!await this.token.autoLogin()) return [];
1261
- const { data: n } = await this.req.get("event/user-feature-status", Sn, {
1261
+ const { data: n } = await this.req.get("event/user-feature-status", xn, {
1262
1262
  params: a({ ...t, event_id: this.event }),
1263
1263
  message: !1
1264
1264
  });
@@ -1273,7 +1273,7 @@ class xr {
1273
1273
  */
1274
1274
  async getUserEngagements(t, n) {
1275
1275
  if (!await this.token.autoLogin()) return [];
1276
- const { data: r } = await this.req.get("event/user-engagements", Ln, {
1276
+ const { data: r } = await this.req.get("event/user-engagements", Sn, {
1277
1277
  params: a({
1278
1278
  max_results: 20,
1279
1279
  ...n,
@@ -1304,7 +1304,7 @@ class xr {
1304
1304
  engagement: n,
1305
1305
  ...r
1306
1306
  }),
1307
- Pn
1307
+ Ln
1308
1308
  );
1309
1309
  return u ?? {
1310
1310
  error: d
@@ -1317,7 +1317,7 @@ class xr {
1317
1317
  */
1318
1318
  async claimRewards(t) {
1319
1319
  await this.token.autoLogin();
1320
- const { data: n, code: r } = await this.req.post("event/claim-rewards", a(t), En), u = n == null ? void 0 : n.claimed_items;
1320
+ const { data: n, code: r } = await this.req.post("event/claim-rewards", a(t), Pn), u = n == null ? void 0 : n.claimed_items;
1321
1321
  return u ? u.map((d) => (d.reward_status = d.reward_status === p.UnclaimedErr ? p.Unclaimed : d.reward_status, d)) : {
1322
1322
  error: r
1323
1323
  };
@@ -1332,7 +1332,7 @@ class xr {
1332
1332
  const { data: n, code: r } = await this.req.post(
1333
1333
  "event/claim-weixin-hongbao",
1334
1334
  { reward_id: t },
1335
- Un
1335
+ En
1336
1336
  );
1337
1337
  return n ? (n.reward_status = n.reward_status === p.UnclaimedErr ? p.Unclaimed : n.reward_status, n) : {
1338
1338
  error: r
@@ -1386,7 +1386,7 @@ class xr {
1386
1386
  */
1387
1387
  async getUnlimitQrcodeScene(t) {
1388
1388
  if (!await this.token.autoLogin()) return null;
1389
- const { data: n } = await this.req.get("event/unlimit-qrcode-scene", Fn, {
1389
+ const { data: n } = await this.req.get("event/unlimit-qrcode-scene", Un, {
1390
1390
  params: { params: t }
1391
1391
  });
1392
1392
  return (n == null ? void 0 : n.scene) ?? null;
@@ -1399,7 +1399,7 @@ class xr {
1399
1399
  * @param scene - 小程序码 scene 值
1400
1400
  */
1401
1401
  async getParamsByQrcodeScene(t) {
1402
- const { data: n } = await this.req.get("event/params-by-qrcode-scene", Dn, {
1402
+ const { data: n } = await this.req.get("event/params-by-qrcode-scene", Fn, {
1403
1403
  params: { scene: t }
1404
1404
  });
1405
1405
  return (n == null ? void 0 : n.params) ?? null;
@@ -1415,12 +1415,12 @@ class xr {
1415
1415
  return (n == null ? void 0 : n.img) ?? null;
1416
1416
  }
1417
1417
  }
1418
- const Gn = {
1418
+ const Dn = {
1419
1419
  /** 所有人均可以发帖 */
1420
1420
  All: "all",
1421
1421
  /** 指定用户可发帖 */
1422
1422
  Limit: "limit"
1423
- }, An = e.string().enum(Gn).lock(), Nn = {
1423
+ }, Gn = e.string().enum(Dn).lock(), An = {
1424
1424
  /** 待审核(仅自己可见) */
1425
1425
  Pending: "pending",
1426
1426
  /** 审核通过 */
@@ -1429,14 +1429,14 @@ const Gn = {
1429
1429
  Failed: "failed",
1430
1430
  /** 嫌疑(仅自己可见) */
1431
1431
  Suspect: "suspect"
1432
- }, ie = e.string().enum(Nn).lock(), On = {
1432
+ }, ie = e.string().enum(An).lock(), Nn = {
1433
1433
  /** 系统通知 */
1434
1434
  System: "system",
1435
1435
  /** 评论我的 */
1436
1436
  Comment: "comment",
1437
1437
  /** 点赞通知 */
1438
1438
  Like: "like"
1439
- }, Sr = e.string().enum(On).lock(), m = {
1439
+ }, xr = e.string().enum(Nn).lock(), m = {
1440
1440
  /** 系统通知 */
1441
1441
  System: "system",
1442
1442
  /** 帖子被置顶 */
@@ -1461,15 +1461,15 @@ const Gn = {
1461
1461
  ReplyLiked: "reply_liked",
1462
1462
  /** 回复被删除 */
1463
1463
  ReplyDeleted: "reply_deleted"
1464
- }, Bn = e.string().enum(m).lock(), oe = e.object({
1464
+ }, On = e.string().enum(m).lock(), oe = e.object({
1465
1465
  forum_id: e.number(),
1466
1466
  icon_url: e.string(),
1467
1467
  name: e.string(),
1468
1468
  tags: e.array(e.string()),
1469
1469
  sort: e.number(),
1470
- mode: An,
1470
+ mode: Gn,
1471
1471
  member_ids: e.array(e.number())
1472
- }).lock(), $ = e.object({
1472
+ }).lock(), U = e.object({
1473
1473
  topic_id: e.number(),
1474
1474
  cover_url: e.string(),
1475
1475
  name: e.string(),
@@ -1489,7 +1489,7 @@ const Gn = {
1489
1489
  comments_num: e.number(),
1490
1490
  liked: e.bool(),
1491
1491
  image_urls: e.array(e.string()),
1492
- topics: e.array($),
1492
+ topics: e.array(U),
1493
1493
  event_ids: e.array(e.number()),
1494
1494
  is_pinned: e.bool(),
1495
1495
  is_highlighted: e.bool(),
@@ -1497,7 +1497,7 @@ const Gn = {
1497
1497
  create_time: e.number()
1498
1498
  }).lock(), ae = e.object({
1499
1499
  err_msg: e.string().optional()
1500
- }).lock(), Qn = e.object({
1500
+ }).lock(), Bn = e.object({
1501
1501
  reply_id: e.number(),
1502
1502
  reply_content: e.string().optional(),
1503
1503
  replied_by: e.string(),
@@ -1516,7 +1516,7 @@ const Gn = {
1516
1516
  content: e.string(),
1517
1517
  like_num: e.number(),
1518
1518
  liked: e.bool(),
1519
- reply_to: Qn,
1519
+ reply_to: Bn,
1520
1520
  create_time: e.number()
1521
1521
  }).lock(), w = e.object({
1522
1522
  comment_id: e.number(),
@@ -1538,22 +1538,22 @@ const Gn = {
1538
1538
  create_time: e.number(),
1539
1539
  status: ie,
1540
1540
  replies: e.array(C).optional()
1541
- }).lock(), Mn = e.object({
1541
+ }).lock(), Qn = e.object({
1542
1542
  image_url: e.string(),
1543
1543
  upload_url: e.string(),
1544
1544
  existed: e.bool()
1545
1545
  }).lock(), b = e.object({
1546
1546
  notification_id: e.string(),
1547
- notification_type: Bn,
1547
+ notification_type: On,
1548
1548
  is_read: e.bool(),
1549
1549
  create_time: e.number(),
1550
1550
  origin_user_id: e.string(),
1551
1551
  origin_user_name: e.string(),
1552
1552
  origin_user_avatar_url: e.string()
1553
- }).lock(), Hn = e.object({
1553
+ }).lock(), Mn = e.object({
1554
1554
  system_message_subject: e.string(),
1555
1555
  system_message_content: e.string()
1556
- }).lock(), D = e.object({
1556
+ }).lock(), I = e.object({
1557
1557
  post_id: e.number(),
1558
1558
  post_subject: e.string(),
1559
1559
  post_summary: e.string(),
@@ -1561,81 +1561,81 @@ const Gn = {
1561
1561
  }).lock(), V = e.object({
1562
1562
  comment_id: e.number(),
1563
1563
  comment_content: e.string()
1564
- }).lock(), I = e.object({
1564
+ }).lock(), D = e.object({
1565
1565
  reply_id: e.number(),
1566
1566
  reply_content: e.string()
1567
- }).lock(), zn = e.object({
1567
+ }).lock(), Hn = e.object({
1568
1568
  ...b.shape,
1569
- ...Hn.shape,
1569
+ ...Mn.shape,
1570
1570
  notification_type: e.string().enum(m.System)
1571
- }), Jn = e.object({
1571
+ }), zn = e.object({
1572
1572
  ...b.shape,
1573
- ...D.shape,
1573
+ ...I.shape,
1574
1574
  notification_type: e.string().enum(
1575
1575
  m.PostPinned,
1576
1576
  m.PostHighlighted,
1577
1577
  m.PostDeleted,
1578
1578
  m.PostLiked
1579
1579
  )
1580
- }), Kn = e.object({
1580
+ }), Jn = e.object({
1581
1581
  ...b.shape,
1582
- ...D.shape,
1582
+ ...I.shape,
1583
1583
  ...V.shape,
1584
1584
  notification_type: e.string().enum(m.PostCommented)
1585
- }), Xn = e.object({
1585
+ }), Kn = e.object({
1586
1586
  ...b.shape,
1587
1587
  ...V.shape,
1588
- ...I.shape,
1588
+ ...D.shape,
1589
1589
  notification_type: e.string().enum(m.CommentReplied)
1590
- }), Yn = e.object({
1590
+ }), Xn = e.object({
1591
1591
  ...b.shape,
1592
1592
  ...V.shape,
1593
- ...D.shape,
1593
+ ...I.shape,
1594
1594
  notification_type: e.string().enum(m.CommentLiked, m.CommentDeleted)
1595
- }), Zn = e.object({
1595
+ }), Yn = e.object({
1596
1596
  ...b.shape,
1597
- ...I.shape,
1597
+ ...D.shape,
1598
1598
  notification_type: e.string().enum(m.ReplyReplied),
1599
1599
  comment_id: e.number(),
1600
1600
  reply_to_reply_id: e.number(),
1601
1601
  reply_to_reply_content: e.string()
1602
- }), Wn = e.object({
1602
+ }), Zn = e.object({
1603
1603
  ...b.shape,
1604
- ...I.shape,
1604
+ ...D.shape,
1605
1605
  ...V.shape,
1606
1606
  notification_type: e.string().enum(m.ReplyLiked, m.ReplyDeleted)
1607
- }), er = e.union(
1607
+ }), Wn = e.union(
1608
+ Hn,
1608
1609
  zn,
1609
1610
  Jn,
1610
1611
  Kn,
1611
1612
  Xn,
1612
1613
  Yn,
1613
- Zn,
1614
- Wn
1615
- ).satisfies().lock(), tr = o({ forums: e.array(oe) }), nr = o({ topics: e.array($) }), rr = o({ topic: $ }), ir = o({ post: F }), Q = o({
1614
+ Zn
1615
+ ).satisfies().lock(), er = o({ forums: e.array(oe) }), tr = o({ topics: e.array(U) }), nr = o({ topic: U }), rr = o({ post: F }), Q = o({
1616
1616
  posts: e.array(F),
1617
1617
  next_token: e.string().optional()
1618
- }), or = o({ post: F, antispam: ae }), ar = o({
1618
+ }), ir = o({ post: F, antispam: ae }), or = o({
1619
1619
  replies: e.array(C),
1620
1620
  next_token: e.string().optional()
1621
- }), sr = o({ reply: C }), cr = o({
1621
+ }), ar = o({ reply: C }), sr = o({
1622
1622
  reply: C.clone().optional(),
1623
1623
  antispam: ae.clone().optional()
1624
- }), ur = o({ comment: w }), lr = o({
1624
+ }), cr = o({ comment: w }), ur = o({
1625
1625
  comments: e.array(w),
1626
1626
  next_token: e.string().optional()
1627
- }), mr = o({
1627
+ }), lr = o({
1628
1628
  comment: w.clone().optional(),
1629
1629
  antispam: w.clone().optional()
1630
- }), dr = e.guard(Mn), gr = o({
1631
- notifications: e.array(er),
1630
+ }), mr = e.guard(Qn), dr = o({
1631
+ notifications: e.array(Wn),
1632
1632
  next_token: e.string().optional()
1633
- }), pr = o({
1633
+ }), gr = o({
1634
1634
  system: e.number(),
1635
1635
  comment: e.number(),
1636
1636
  like: e.number()
1637
1637
  });
1638
- class Lr {
1638
+ class Sr {
1639
1639
  constructor(t) {
1640
1640
  l(this, "token");
1641
1641
  l(this, "req");
@@ -1647,7 +1647,7 @@ class Lr {
1647
1647
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=QaqUa2K0z0
1648
1648
  */
1649
1649
  async getForums() {
1650
- const { data: t } = await this.req.get("community/forums", tr);
1650
+ const { data: t } = await this.req.get("community/forums", er);
1651
1651
  return (t == null ? void 0 : t.forums) || [];
1652
1652
  }
1653
1653
  /**
@@ -1656,7 +1656,7 @@ class Lr {
1656
1656
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=mIwpymAQom
1657
1657
  */
1658
1658
  async getTopics() {
1659
- const { data: t } = await this.req.get("community/topics", nr);
1659
+ const { data: t } = await this.req.get("community/topics", tr);
1660
1660
  return (t == null ? void 0 : t.topics) || [];
1661
1661
  }
1662
1662
  /**
@@ -1665,7 +1665,7 @@ class Lr {
1665
1665
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=Jvw7xMK31K
1666
1666
  */
1667
1667
  async getTopic(t) {
1668
- const { data: n, code: r } = await this.req.get("community/topic", rr, {
1668
+ const { data: n, code: r } = await this.req.get("community/topic", nr, {
1669
1669
  params: { topic_id: t }
1670
1670
  });
1671
1671
  return (n == null ? void 0 : n.topic) ?? { error: r };
@@ -1698,7 +1698,7 @@ class Lr {
1698
1698
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=hj1AZy5rcP
1699
1699
  */
1700
1700
  async getPost(t) {
1701
- const { data: n, code: r } = await this.req.get("community/post", ir, {
1701
+ const { data: n, code: r } = await this.req.get("community/post", rr, {
1702
1702
  params: { post_id: t }
1703
1703
  });
1704
1704
  return (n == null ? void 0 : n.post) ?? { error: r };
@@ -1709,7 +1709,7 @@ class Lr {
1709
1709
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=M5okHBuaVk
1710
1710
  */
1711
1711
  async post(t) {
1712
- const { data: n, code: r } = await this.req.post("community/post", a(t), or);
1712
+ const { data: n, code: r } = await this.req.post("community/post", a(t), ir);
1713
1713
  return n ?? {
1714
1714
  error: r
1715
1715
  };
@@ -1720,7 +1720,7 @@ class Lr {
1720
1720
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=djKbX7lFdp
1721
1721
  */
1722
1722
  async getComments(t) {
1723
- const { data: n, code: r } = await this.req.get("community/comments", lr, {
1723
+ const { data: n, code: r } = await this.req.get("community/comments", ur, {
1724
1724
  params: a(t)
1725
1725
  });
1726
1726
  return n ?? { error: r };
@@ -1731,7 +1731,7 @@ class Lr {
1731
1731
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=RIc7oxVGae
1732
1732
  */
1733
1733
  async getComment(t) {
1734
- const { data: n, code: r } = await this.req.get("community/comment", ur, {
1734
+ const { data: n, code: r } = await this.req.get("community/comment", cr, {
1735
1735
  params: { comment_id: t }
1736
1736
  });
1737
1737
  return (n == null ? void 0 : n.comment) ?? { error: r };
@@ -1743,7 +1743,7 @@ class Lr {
1743
1743
  */
1744
1744
  async comment(t) {
1745
1745
  await this.token.autoLogin();
1746
- const { data: n, code: r } = await this.req.post("community/comment", a(t), mr);
1746
+ const { data: n, code: r } = await this.req.post("community/comment", a(t), lr);
1747
1747
  return n ?? {
1748
1748
  error: r
1749
1749
  };
@@ -1754,7 +1754,7 @@ class Lr {
1754
1754
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=sVKBbY83MY
1755
1755
  */
1756
1756
  async getReplies(t) {
1757
- const { data: n } = await this.req.get("community/replies", ar, {
1757
+ const { data: n } = await this.req.get("community/replies", or, {
1758
1758
  params: a({ max_results: 20, ...t })
1759
1759
  });
1760
1760
  return n ?? { replies: [] };
@@ -1765,7 +1765,7 @@ class Lr {
1765
1765
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=kxhcSXD3MG
1766
1766
  */
1767
1767
  async getReply(t) {
1768
- const { data: n, code: r } = await this.req.get("community/reply", sr, {
1768
+ const { data: n, code: r } = await this.req.get("community/reply", ar, {
1769
1769
  params: { reply_id: t }
1770
1770
  });
1771
1771
  return (n == null ? void 0 : n.reply) ?? { error: r };
@@ -1777,7 +1777,7 @@ class Lr {
1777
1777
  */
1778
1778
  async reply(t) {
1779
1779
  await this.token.autoLogin();
1780
- const { data: n, code: r } = await this.req.post("community/reply", a(t), cr);
1780
+ const { data: n, code: r } = await this.req.post("community/reply", a(t), sr);
1781
1781
  return n ?? {
1782
1782
  error: r
1783
1783
  };
@@ -1813,7 +1813,7 @@ class Lr {
1813
1813
  */
1814
1814
  async getMediaPresignedUrl(t) {
1815
1815
  await this.token.autoLogin();
1816
- const { data: n } = await this.req.get("community/media-presign-url", dr, {
1816
+ const { data: n } = await this.req.get("community/media-presign-url", mr, {
1817
1817
  params: t
1818
1818
  });
1819
1819
  return n;
@@ -1827,7 +1827,7 @@ class Lr {
1827
1827
  */
1828
1828
  async getNotifications(t) {
1829
1829
  await this.token.autoLogin();
1830
- const { data: n } = await this.req.get("community/notifications", gr, {
1830
+ const { data: n } = await this.req.get("community/notifications", dr, {
1831
1831
  params: a({ max_results: 20, ...t })
1832
1832
  });
1833
1833
  return n || { notifications: [] };
@@ -1839,7 +1839,7 @@ class Lr {
1839
1839
  */
1840
1840
  async getUnreadNotificationsCount() {
1841
1841
  if (!await this.token.autoLogin()) return null;
1842
- const { data: t } = await this.req.get("community/unread-notifications-count", pr);
1842
+ const { data: t } = await this.req.get("community/unread-notifications-count", gr);
1843
1843
  return t;
1844
1844
  }
1845
1845
  /**
@@ -1856,9 +1856,9 @@ class Lr {
1856
1856
  function x(i) {
1857
1857
  return L(i, "openid", "unionid", "weixin_token");
1858
1858
  }
1859
- var _r = /* @__PURE__ */ ((i) => (i.RedirectUriDisMatch = "10003", i.AppidError = "10016", i.AuthorizationError = "10015", i.NoRightForScope = "10005", i.Frequently = "10009", i.AppBanded = "10004", i.ShouldFollow = "10006", i.ScopeNull = "10010", i.RedirectUriNull = "10011", i.AppidNull = "10012", i.StateNull = "10013", i))(_r || {});
1859
+ var pr = /* @__PURE__ */ ((i) => (i.RedirectUriDisMatch = "10003", i.AppidError = "10016", i.AuthorizationError = "10015", i.NoRightForScope = "10005", i.Frequently = "10009", i.AppBanded = "10004", i.ShouldFollow = "10006", i.ScopeNull = "10010", i.RedirectUriNull = "10011", i.AppidNull = "10012", i.StateNull = "10013", i))(pr || {});
1860
1860
  const M = "wx_login_cache";
1861
- class Pr {
1861
+ class Lr {
1862
1862
  /**
1863
1863
  * 创建微信相关功能接口
1864
1864
  *
@@ -1982,20 +1982,20 @@ class Pr {
1982
1982
  }
1983
1983
  export {
1984
1984
  ae as AntispamValidator,
1985
- wr as AuthToken,
1985
+ hr as AuthToken,
1986
1986
  nn as CashbackEngagementDataValidator,
1987
1987
  p as ClaimRewardStatus,
1988
1988
  P as ClaimRewardStatusValidator,
1989
- Rn as ClaimedItemValidator,
1989
+ Vn as ClaimedItemValidator,
1990
1990
  J as ClubAddressValidator,
1991
- vr as ClubApi,
1991
+ kr as ClubApi,
1992
1992
  K as ClubBenefitSummaryValidator,
1993
- Ie as ClubBenefitValidator,
1993
+ De as ClubBenefitValidator,
1994
1994
  Re as ClubCreditChangeScene,
1995
1995
  je as ClubCreditChangeSceneValidator,
1996
1996
  Ce as ClubCreditChangeType,
1997
1997
  Ve as ClubCreditChangeTypeValidator,
1998
- De as ClubCreditLogValidator,
1998
+ Ie as ClubCreditLogValidator,
1999
1999
  Se as ClubGlobalConfigValidator,
2000
2000
  Te as ClubItemType,
2001
2001
  H as ClubItemTypeValidator,
@@ -2004,15 +2004,15 @@ export {
2004
2004
  qe as ClubRedemptionStatus,
2005
2005
  xe as ClubRedemptionStatusValidator,
2006
2006
  Fe as ClubUserCreditValidator,
2007
- $e as ClubUserProfileValidator,
2008
- wn as CommentEngagementValidator,
2007
+ Ue as ClubUserProfileValidator,
2008
+ fn as CommentEngagementValidator,
2009
2009
  w as CommentValidator,
2010
- Lr as CommunityApi,
2010
+ Sr as CommunityApi,
2011
2011
  Ye as EngageAccountType,
2012
2012
  Ze as EngageAccountTypeValidator,
2013
- Vn as EngageResponseValidator,
2014
- cn as EngageRewardValidator,
2015
- xr as EventApi,
2013
+ Cn as EngageResponseValidator,
2014
+ wn as EngageRewardValidator,
2015
+ qr as EventApi,
2016
2016
  tn as EventConfigValidator,
2017
2017
  _t as EventFeatureConfigOfCashbackValidator,
2018
2018
  yt as EventFeatureConfigOfCheckInValidator,
@@ -2023,8 +2023,8 @@ export {
2023
2023
  qt as EventFeatureConfigOfInviteValidator,
2024
2024
  St as EventFeatureConfigOfInvitedRegisterValidator,
2025
2025
  Ft as EventFeatureConfigOfLotteryDrawValidator,
2026
- Ut as EventFeatureConfigOfLotteryValidator,
2027
- It as EventFeatureConfigOfPreregisterValidator,
2026
+ $t as EventFeatureConfigOfLotteryValidator,
2027
+ Dt as EventFeatureConfigOfPreregisterValidator,
2028
2028
  At as EventFeatureConfigOfQuestValidator,
2029
2029
  Ot as EventFeatureConfigOfRegisterValidator,
2030
2030
  Qt as EventFeatureConfigOfShareValidator,
@@ -2035,14 +2035,14 @@ export {
2035
2035
  en as EventFeatureConfigValidator,
2036
2036
  We as EventPeriodType,
2037
2037
  et as EventPeriodTypeValidator,
2038
- U as EventRewardItemConfigValidator,
2038
+ $ as EventRewardItemConfigValidator,
2039
2039
  Ae as ExtraGameRewardValidator,
2040
2040
  Ge as ExtraPhysicalShipmentValidator,
2041
2041
  gt as FeatureRewardValidator,
2042
2042
  s as FeatureType,
2043
2043
  tt as FeatureTypeValidator,
2044
- Gn as ForumMode,
2045
- An as ForumModeValidator,
2044
+ Dn as ForumMode,
2045
+ Gn as ForumModeValidator,
2046
2046
  oe as ForumValidator,
2047
2047
  v as GamerItemType,
2048
2048
  Y as GamerItemTypeValidator,
@@ -2051,74 +2051,73 @@ export {
2051
2051
  rn as GiftCodeEngagementDataValidator,
2052
2052
  on as InviteEngagementDataValidator,
2053
2053
  lt as LotteryDrawAction,
2054
- Tr as LotteryDrawActionValidator,
2055
- mn as LotteryDrawEngagementDataValidator,
2054
+ jr as LotteryDrawActionValidator,
2055
+ un as LotteryDrawEngagementDataValidator,
2056
2056
  an as LotteryEngagementDataValidator,
2057
2057
  h as LotteryTicketStatus,
2058
- Rr as LotteryTicketStatusValidator,
2058
+ Vr as LotteryTicketStatusValidator,
2059
2059
  b as NotificationBaseValidator,
2060
- On as NotificationCategory,
2061
- Sr as NotificationCategoryValidator,
2062
- Xn as NotificationCommentReplyValidator,
2063
- Yn as NotificationCommentValidator,
2060
+ Nn as NotificationCategory,
2061
+ xr as NotificationCategoryValidator,
2062
+ Kn as NotificationCommentReplyValidator,
2063
+ Xn as NotificationCommentValidator,
2064
2064
  V as NotificationPayloadCommentValidator,
2065
- D as NotificationPayloadPostValidator,
2066
- I as NotificationPayloadReplyValidator,
2067
- Hn as NotificationPayloadSystemValidator,
2068
- Kn as NotificationPostCommentValidator,
2069
- Jn as NotificationPostValidator,
2070
- Zn as NotificationReplyRepliedValidator,
2071
- Wn as NotificationReplyValidator,
2072
- zn as NotificationSystemValidator,
2065
+ I as NotificationPayloadPostValidator,
2066
+ D as NotificationPayloadReplyValidator,
2067
+ Mn as NotificationPayloadSystemValidator,
2068
+ Jn as NotificationPostCommentValidator,
2069
+ zn as NotificationPostValidator,
2070
+ Yn as NotificationReplyRepliedValidator,
2071
+ Zn as NotificationReplyValidator,
2072
+ Hn as NotificationSystemValidator,
2073
2073
  m as NotificationType,
2074
- Bn as NotificationTypeValidator,
2075
- er as NotificationValidator,
2076
- Ue as PlayerRoleCardValidator,
2074
+ On as NotificationTypeValidator,
2075
+ Wn as NotificationValidator,
2076
+ $e as PlayerRoleCardValidator,
2077
2077
  z as PlayerRoleValidator,
2078
- Nn as PostStatus,
2078
+ An as PostStatus,
2079
2079
  ie as PostStatusValidator,
2080
2080
  F as PostValidator,
2081
- dn as PreregisterEngagementDataValidator,
2082
- Mn as PresignedUrlResponseValidator,
2083
- gn as QuestEngagementDataValidator,
2081
+ ln as PreregisterEngagementDataValidator,
2082
+ Qn as PresignedUrlResponseValidator,
2083
+ mn as QuestEngagementDataValidator,
2084
2084
  nt as QuestObjective,
2085
2085
  W as QuestObjectiveValidator,
2086
- kr as RedeemParamsValidator,
2086
+ wr as RedeemParamsValidator,
2087
2087
  Ne as RedemptionValidator,
2088
2088
  dt as RegularRewardValidator,
2089
- Qn as ReplyToValidator,
2089
+ Bn as ReplyToValidator,
2090
2090
  C as ReplyValidator,
2091
- Cr as RewardItemType,
2091
+ vr as RewardItemType,
2092
2092
  Z as RewardItemTypeValidator,
2093
2093
  at as RewardSource,
2094
2094
  E as RewardSourceValidator,
2095
2095
  g as RewardStatus,
2096
2096
  ot as RewardStatusSuffix,
2097
2097
  ee as RewardStatusSuffixValidator,
2098
- Vr as RewardStatusValidator,
2099
- sn as RewardValidator,
2098
+ Cr as RewardStatusValidator,
2099
+ hn as RewardValidator,
2100
2100
  Ee as RoleBaseInfoValidator,
2101
2101
  Pe as ServerBaseInfoValidator,
2102
- pn as ShareEngagementDataValidator,
2103
- bn as SurveyEngagementDataValidator,
2102
+ dn as ShareEngagementDataValidator,
2103
+ pn as SurveyEngagementDataValidator,
2104
2104
  ut as TeamAction,
2105
- jr as TeamActionValidator,
2106
- fn as TeamEngagementDataValidator,
2107
- yn as TeamEngagementValidator,
2108
- qr as TeamMemberValidator,
2105
+ Rr as TeamActionValidator,
2106
+ bn as TeamEngagementDataValidator,
2107
+ _n as TeamEngagementValidator,
2108
+ Tr as TeamMemberValidator,
2109
2109
  st as TeamVisibility,
2110
2110
  ct as TeamVisibilityValidator,
2111
- $ as TopicValidator,
2112
- kn as UserEngagementDataValidator,
2113
- ne as UserEngagementDataValidators,
2111
+ U as TopicValidator,
2112
+ ne as UserEngagementDataValidator,
2114
2113
  re as UserEngagementValidator,
2115
- Cn as UserFeatureStatusValidator,
2114
+ vn as UserFeatureStatusValidator,
2116
2115
  te as UserRewardValidator,
2117
- vn as VerifyMobileResultValidator,
2118
- hn as VoteEngagementDataValidator,
2116
+ kn as VerifyMobileResultValidator,
2117
+ yn as VoteEngagementDataValidator,
2119
2118
  rt as VoteOptionSource,
2120
2119
  it as VoteOptionSourceValidator,
2121
- Pr as WeixinApi,
2122
- _n as WeixinSubscribeEngagementDataValidator,
2123
- _r as WeixinWebLoginErrorCode
2120
+ Lr as WeixinApi,
2121
+ gn as WeixinSubscribeEngagementDataValidator,
2122
+ pr as WeixinWebLoginErrorCode
2124
2123
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@seayoo-web/gamer-api",
3
3
  "description": "agent for gamer api",
4
- "version": "2.0.2",
4
+ "version": "2.0.3",
5
5
  "type": "module",
6
6
  "source": "index.ts",
7
7
  "main": "./dist/index.js",
@@ -22,15 +22,15 @@
22
22
  "license": "MIT",
23
23
  "devDependencies": {
24
24
  "@types/node": "^22.13.1",
25
+ "@seayoo-web/scripts": "^2.0.1",
26
+ "@seayoo-web/request": "^3.0.0",
25
27
  "@seayoo-web/combo-webview": "^2.5.0",
26
- "@seayoo-web/utils": "^3.4.3",
27
28
  "@seayoo-web/tsconfig": "^1.0.3",
28
- "@seayoo-web/request": "^3.0.0",
29
- "@seayoo-web/scripts": "^2.0.1"
29
+ "@seayoo-web/utils": "^3.4.3"
30
30
  },
31
31
  "peerDependencies": {
32
- "@seayoo-web/combo-webview": "^2.5.0",
33
- "@seayoo-web/utils": "^3.4.3"
32
+ "@seayoo-web/utils": "^3.4.3",
33
+ "@seayoo-web/combo-webview": "^2.5.0"
34
34
  },
35
35
  "dependencies": {
36
36
  "vitest": "^3.0.5"
@@ -41,6 +41,6 @@
41
41
  "lint": "eslint ./src/**/*.ts",
42
42
  "lint:fix": "eslint \"./src/**/*.{ts,js}\" --fix",
43
43
  "test": "vitest",
44
- "prepublish": "pnpm lint:fix && pnpm -w build"
44
+ "prepublish": "pnpm lint:fix && pnpm build"
45
45
  }
46
46
  }
@@ -24,20 +24,6 @@ export * from "./engage.survey";
24
24
  export * from "./engage.team";
25
25
  export * from "./engage.vote";
26
26
  export type UserEngagementData = PreregisterEngagementData | LotteryEngagementData | SurveyEngagementData | InviteEngagementData | ShareEngagementData | VoteEngagementData | WeixinSubscribeEngagementData | CashbackEngagementData | GiftCodeEngagementData | TeamEngagementData | QuestEngagementData | LotteryDrawEngagementData;
27
- export declare const UserEngagementDataValidators: readonly [import("@seayoo-web/utils").ObjectValidator<{
28
- platforms: string[];
29
- }, false, false>, import("@seayoo-web/utils").ObjectValidator<LotteryEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<{
30
- serial_number: number;
31
- }, false, false>, import("@seayoo-web/utils").ObjectValidator<InviteEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<ShareEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<VoteEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<WeixinSubscribeEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<CashbackEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<GiftCodeEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<TeamEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<QuestEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<{
32
- tickets: ({
33
- ticket: /*elided*/ any;
34
- status: /*elided*/ any;
35
- } | {
36
- ticket: /*elided*/ any;
37
- status: /*elided*/ any;
38
- reward: /*elided*/ any;
39
- })[];
40
- }, false, false>];
41
27
  export declare const UserEngagementDataValidator: import("@seayoo-web/utils").UnionValidator<[import("@seayoo-web/utils").ObjectValidator<{
42
28
  platforms: string[];
43
29
  }, false, false>, import("@seayoo-web/utils").ObjectValidator<LotteryEngagementData, false, false>, import("@seayoo-web/utils").ObjectValidator<{
@@ -1,6 +1,7 @@
1
1
  import { type InferType } from "@seayoo-web/utils";
2
2
  import { LotteryTicketStatus, type LotteryDrawAction } from "../event.enums";
3
- import { type UserReward } from "./reward";
3
+ import { type UserReward } from "./engage.lotteryDraw.reward";
4
+ export * from "./engage.lotteryDraw.reward";
4
5
  declare const noRewardStatus: import("@seayoo-web/utils").StringValidator<"unknown" | "pending", false, false>;
5
6
  export type LotteryDrawTicket = {
6
7
  /** 抽奖券 */
@@ -37,4 +38,3 @@ export type LotteryDrawEngagementParam = {
37
38
  /** 抽奖券 */
38
39
  ticket: string;
39
40
  };
40
- export {};
@@ -0,0 +1,38 @@
1
+ import { type ClaimRewardStatus, type FeatureType, type GamerItemType, type RewardSource } from "../event.enums";
2
+ export interface UserReward {
3
+ /** 用户奖励记录 id */
4
+ reward_id: number;
5
+ /** 奖励道具 id */
6
+ reward_item_id: number;
7
+ /** 产生奖励的来源 */
8
+ reward_source: RewardSource;
9
+ /** 奖励道具名称 */
10
+ reward_item_name: string;
11
+ /** 奖励道具类型 */
12
+ reward_item_type: GamerItemType;
13
+ /** 奖励道具图片地址 */
14
+ reward_item_icon_url: string;
15
+ /** 奖励道具描述 */
16
+ reward_item_desc?: string;
17
+ /** 奖励道具评级,用于前端展示 */
18
+ reward_item_rating: number;
19
+ /** 奖励道具数量 */
20
+ reward_amount: number;
21
+ /** 奖励状态 */
22
+ reward_status: ClaimRewardStatus;
23
+ /** 活动 ID */
24
+ event_id: number;
25
+ /** 活动名称 */
26
+ event_name: string;
27
+ /** 活动玩法 ID */
28
+ feature_id: number;
29
+ /** 参与记录 ID */
30
+ engagement_id: number;
31
+ /** 玩法类型 */
32
+ feature_type: FeatureType;
33
+ /** 领奖时间 */
34
+ receive_time: number;
35
+ /** 提供额外扩展信息,比如收获地址等 */
36
+ extra_data?: Record<string, unknown>;
37
+ }
38
+ export declare const UserRewardValidator: import("@seayoo-web/utils").ObjectValidator<UserReward, false, false>;
@@ -1,4 +1,4 @@
1
- import { ClaimRewardStatus, GamerItemType, RewardItemType, type FeatureType, type RewardSource, type RewardStatusSuffix } from "../event.enums";
1
+ import { RewardItemType, type RewardSource, type RewardStatusSuffix } from "../event.enums";
2
2
  import { type UserEngagementData } from "./engage";
3
3
  export interface Reward {
4
4
  /** 用户奖励记录 id */
@@ -27,43 +27,6 @@ export interface Reward {
27
27
  extra_data?: UserEngagementData | Record<string, unknown>;
28
28
  }
29
29
  export declare const RewardValidator: import("@seayoo-web/utils").ObjectValidator<Reward, false, false>;
30
- export interface UserReward {
31
- /** 用户奖励记录 id */
32
- reward_id: number;
33
- /** 奖励道具 id */
34
- reward_item_id: number;
35
- /** 产生奖励的来源 */
36
- reward_source: RewardSource;
37
- /** 奖励道具名称 */
38
- reward_item_name: string;
39
- /** 奖励道具类型 */
40
- reward_item_type: GamerItemType;
41
- /** 奖励道具图片地址 */
42
- reward_item_icon_url: string;
43
- /** 奖励道具描述 */
44
- reward_item_desc?: string;
45
- /** 奖励道具评级,用于前端展示 */
46
- reward_item_rating: number;
47
- /** 奖励道具数量 */
48
- reward_amount: number;
49
- /** 奖励状态 */
50
- reward_status: ClaimRewardStatus;
51
- /** 活动 ID */
52
- event_id: number;
53
- /** 活动名称 */
54
- event_name: string;
55
- /** 活动玩法 ID */
56
- feature_id: number;
57
- /** 参与记录 ID */
58
- engagement_id: number;
59
- /** 玩法类型 */
60
- feature_type: FeatureType;
61
- /** 领奖时间 */
62
- receive_time: number;
63
- /** 提供额外扩展信息,比如收获地址等 */
64
- extra_data?: Record<string, unknown>;
65
- }
66
- export declare const UserRewardValidator: import("@seayoo-web/utils").ObjectValidator<UserReward, false, false>;
67
30
  export interface EngageReward {
68
31
  /** 用户奖励记录 id(微信红包类型奖励需要前端请求一次领奖 api) */
69
32
  reward_id: number;