@seayoo-web/gamer-api 2.5.4 → 2.5.6

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
@@ -1,77 +1,81 @@
1
- import { isComboWebView as le } from "@seayoo-web/combo-webview";
2
- import { isPlainObject as C, useConsole as me, Support as b, usePromise as de, pruneURL as ge, queryString as E, pruneObject as c, v as e, omitFields as V, typedObjectGuard as s, parseJSON as pe, removePara as B } from "@seayoo-web/utils";
3
- function _e(o) {
4
- return C(o, "gamer_token") && typeof o.gamer_token == "string";
1
+ var me = Object.defineProperty;
2
+ var de = (a, t, r) => t in a ? me(a, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : a[t] = r;
3
+ var m = (a, t, r) => de(a, typeof t != "symbol" ? t + "" : t, r);
4
+ import { isComboWebView as ge } from "@seayoo-web/combo-webview";
5
+ import { isPlainObject as C, Support as y, useConsole as pe, usePromise as _e, pruneURL as be, queryString as $, pruneObject as c, v as e, omitFields as V, typedObjectGuard as s, parseJSON as ye, removePara as Q } from "@seayoo-web/utils";
6
+ function he(a) {
7
+ return C(a, "gamer_token") && typeof a.gamer_token == "string";
5
8
  }
6
- function M(o) {
7
- return C(o);
9
+ function M(a) {
10
+ return C(a);
8
11
  }
9
- const h = me("GamerApiSDK");
10
- function be(o) {
11
- return /^\/[a-z\d-]+$/.test(o);
12
+ const q = pe("GamerApiSDK");
13
+ function fe(a) {
14
+ return /^\/[a-z\d-]+$/.test(a);
12
15
  }
13
- async function ye() {
14
- const { promise: o, resolve: t } = de();
16
+ async function we() {
17
+ const { promise: a, resolve: t } = _e();
15
18
  return wx.login({
16
- success(n) {
17
- t(n.code);
19
+ success(r) {
20
+ t(r.code);
18
21
  },
19
22
  fail() {
20
23
  t("");
21
24
  }
22
- }), await o;
25
+ }), await a;
23
26
  }
24
- const fe = {
25
- get(o) {
26
- return localStorage.getItem(o) || "";
27
+ const ke = {
28
+ get(a) {
29
+ return localStorage.getItem(a) || "";
27
30
  },
28
- set(o, t) {
29
- localStorage.setItem(o, t);
31
+ set(a, t) {
32
+ localStorage.setItem(a, t);
30
33
  },
31
- remove(o) {
32
- localStorage.removeItem(o);
34
+ remove(a) {
35
+ localStorage.removeItem(a);
33
36
  }
34
- }, he = {
35
- get(o) {
37
+ }, ve = {
38
+ get(a) {
36
39
  try {
37
- if (b.wx) return wx.getStorageSync(o) || "";
40
+ if (y.wx) return wx.getStorageSync(a) || "";
38
41
  } catch (t) {
39
- h.error("getStorageSyncError", t);
42
+ q.error("getStorageSyncError", t);
40
43
  }
41
44
  return "";
42
45
  },
43
- set(o, t) {
46
+ set(a, t) {
44
47
  try {
45
- b.wx && wx.setStorageSync(o, t);
46
- } catch (n) {
47
- h.error("setStorageSyncError", n);
48
+ y.wx && wx.setStorageSync(a, t);
49
+ } catch (r) {
50
+ q.error("setStorageSyncError", r);
48
51
  }
49
52
  },
50
- remove(o) {
53
+ remove(a) {
51
54
  try {
52
- b.wx && wx.removeStorageSync(o);
55
+ y.wx && wx.removeStorageSync(a);
53
56
  } catch (t) {
54
- h.error("removeStorageSync", t);
57
+ q.error("removeStorageSync", t);
55
58
  }
56
59
  }
57
60
  }, w = "gamer_token";
58
- class jr {
59
- $NetRequest;
60
- $idToken = "";
61
- $weixinToken = "";
62
- $gamerToken = "";
63
- req;
64
- storage;
65
- constructor(t, n) {
66
- this.storage = b.wx ? he : fe;
67
- const r = be(t) ? t : `https://${ge(t)}`;
68
- if (this.$NetRequest = n, this.req = n({
69
- baseURL: `${r}/v1`,
61
+ class Sr {
62
+ constructor(t, r) {
63
+ m(this, "$NetRequest");
64
+ m(this, "$idToken", "");
65
+ m(this, "$weixinToken", "");
66
+ m(this, "$gamerToken", "");
67
+ m(this, "req");
68
+ m(this, "storage");
69
+ m(this, "$loginWithTokenJob", null);
70
+ this.storage = y.wx ? ve : ke;
71
+ const n = fe(t) ? t : `https://${be(t)}`;
72
+ if (this.$NetRequest = r, this.req = r({
73
+ baseURL: `${n}/v1`,
70
74
  timeout: 1e4,
71
75
  maxRetry: 2,
72
76
  retryInterval: "2EB",
73
- retryResolve({ method: a, status: i }) {
74
- return a === "GET" && i < 0;
77
+ retryResolve({ method: i, status: o }) {
78
+ return i === "GET" && o < 0;
75
79
  },
76
80
  responseRule: {
77
81
  ok: { resolve: "body" },
@@ -82,12 +86,12 @@ class jr {
82
86
  }
83
87
  },
84
88
  // 使用箭头函数绑定执行上下文
85
- requestTransformer: (a) => {
86
- this.$gamerToken && (a.headers.Authorization = `Bearer ${this.$gamerToken}`);
89
+ requestTransformer: (i) => {
90
+ this.$gamerToken && (i.headers.Authorization = `Bearer ${this.$gamerToken}`);
87
91
  }
88
- }), b.window) {
89
- const a = /^(?:localhost|[\d.]+):\d{4}$/.test(location.host), i = E("gamer_token");
90
- (le() || a && i) && (this.$gamerToken = i);
92
+ }), y.window) {
93
+ const i = /^(?:localhost|[\d.]+):\d{4}$/.test(location.host), o = $("gamer_token");
94
+ (ge() || i && o) && (this.$gamerToken = o);
91
95
  }
92
96
  this.$gamerToken || this.loadGamerTokenCache();
93
97
  }
@@ -95,11 +99,11 @@ class jr {
95
99
  return this.$NetRequest;
96
100
  }
97
101
  loadGamerTokenCache() {
98
- const n = this.storage.get(w).match(/^(\d{12,})#(.{8,})$/);
99
- if (n) {
100
- const r = parseInt(n[1]), a = n[2];
101
- if (r > Date.now() - (24 * 3600 - 10) * 1e3) {
102
- this.$gamerToken = a;
102
+ const r = this.storage.get(w).match(/^(\d{12,})#(.{8,})$/);
103
+ if (r) {
104
+ const n = parseInt(r[1]), i = r[2];
105
+ if (n > Date.now() - (24 * 3600 - 10) * 1e3) {
106
+ this.$gamerToken = i;
103
107
  return;
104
108
  }
105
109
  }
@@ -164,16 +168,9 @@ class jr {
164
168
  async autoLogin() {
165
169
  if (this.gamerToken)
166
170
  return !0;
167
- if (!this.idToken)
168
- return h.error("Missing idToken when call autoLogin()"), !1;
169
- if (b.wx && !this.weixinToken)
170
- return h.error("Missing weixinToken when call autoLogin()"), !1;
171
- const { code: t, data: n } = await this.req.post(
172
- "login-with-token",
173
- c({ id_token: this.idToken, weixin_token: b.wx ? this.weixinToken : null }),
174
- _e,
175
- { message: !1 }
176
- );
171
+ if (!this.idToken || y.wx && !this.weixinToken)
172
+ return !1;
173
+ const { code: t, data: r } = await this.loginWithToken();
177
174
  switch (t) {
178
175
  case "invalid_id_token":
179
176
  this.idToken = "";
@@ -182,7 +179,19 @@ class jr {
182
179
  this.weixinToken = "";
183
180
  break;
184
181
  }
185
- return this.gamerToken = n?.gamer_token || "", !!this.gamerToken;
182
+ return this.gamerToken = (r == null ? void 0 : r.gamer_token) || "", !!this.gamerToken;
183
+ }
184
+ async loginWithToken() {
185
+ if (this.$loginWithTokenJob)
186
+ return await this.$loginWithTokenJob;
187
+ this.$loginWithTokenJob = this.req.post(
188
+ "login-with-token",
189
+ c({ id_token: this.idToken, weixin_token: y.wx ? this.weixinToken : null }),
190
+ he,
191
+ { message: !1 }
192
+ );
193
+ const t = await this.$loginWithTokenJob;
194
+ return this.$loginWithTokenJob = null, t;
186
195
  }
187
196
  /**
188
197
  * 获取当前登录用户的 Session 的信息
@@ -205,25 +214,25 @@ class jr {
205
214
  */
206
215
  async authRealName(t) {
207
216
  if (!await this.autoLogin()) return null;
208
- const { data: n } = await this.req.post("auth-real-name", c(t), M);
209
- return n;
217
+ const { data: r } = await this.req.post("auth-real-name", c(t), M);
218
+ return r;
210
219
  }
211
220
  }
212
- const we = {
221
+ const Ce = {
213
222
  /** 未知 */
214
223
  Unknown: "unknown",
215
224
  /** 男 */
216
225
  Male: "male",
217
226
  /** 女 */
218
227
  Female: "female"
219
- }, ke = e.string().enum(we).lock(), ve = {
228
+ }, Ve = e.string().enum(Ce).lock(), Re = {
220
229
  /** 积分增加 */
221
230
  Increase: "increase",
222
231
  /** 积分减少 */
223
232
  Decrease: "decrease",
224
233
  /** 积分过期 */
225
234
  Expired: "expired"
226
- }, Ce = e.string().enum(ve).lock(), Ve = {
235
+ }, je = e.string().enum(Re).lock(), Te = {
227
236
  /** 游戏内购买 */
228
237
  Order: "order",
229
238
  /** 游戏内消耗 */
@@ -236,21 +245,21 @@ const we = {
236
245
  Admin: "admin",
237
246
  /** 运营活动 */
238
247
  Event: "event"
239
- }, Re = e.string().enum(Ve).lock(), je = {
248
+ }, qe = e.string().enum(Te).lock(), xe = {
240
249
  /** 游戏内奖励 */
241
250
  GameReward: "game_reward",
242
251
  /** 实物商品 */
243
252
  Physical: "physical",
244
253
  /** 虚拟商品 */
245
254
  Virtual: "virtual"
246
- }, Z = e.string().enum(je).lock(), Te = {
255
+ }, W = e.string().enum(xe).lock(), Se = {
247
256
  /** 待发放 */
248
257
  Pending: "pending",
249
258
  /** 已发放 */
250
259
  Issued: "issued",
251
260
  /** 发放失败 */
252
261
  Failed: "failed"
253
- }, qe = e.string().enum(Te).lock(), xe = e.object({
262
+ }, Le = e.string().enum(Se).lock(), Ee = e.object({
254
263
  default_avatar_url: e.string(),
255
264
  official_avatar_urls: e.array(e.string()),
256
265
  default_nickname: e.string(),
@@ -268,7 +277,7 @@ const we = {
268
277
  exp_description: e.string(),
269
278
  credit_description: e.string(),
270
279
  send_role_mail_rate_limit: e.number()
271
- }).lock(), Se = e.object({
280
+ }).lock(), $e = e.object({
272
281
  member_id: e.string(),
273
282
  player_id: e.string(),
274
283
  exp: e.number(),
@@ -277,18 +286,18 @@ const we = {
277
286
  credit_expiring: e.number(),
278
287
  level_change_time: e.number(),
279
288
  level_expire_time: e.number()
280
- }).lock(), Le = e.object({
289
+ }).lock(), Pe = e.object({
281
290
  server_id: e.string(),
282
291
  server_name: e.string()
283
- }).lock(), Ee = e.object({
292
+ }).lock(), Ue = e.object({
284
293
  role_id: e.string(),
285
294
  role_name: e.string()
286
295
  }).lock(), X = e.object({
287
- ...Ee.shape,
288
- ...Le.shape,
296
+ ...Ue.shape,
297
+ ...Pe.shape,
289
298
  role_level: e.number(),
290
299
  last_login_time: e.number()
291
- }).lock(), Pe = e.object({
300
+ }).lock(), Fe = e.object({
292
301
  ...X.shape,
293
302
  /** 角色战力 */
294
303
  role_fighting: e.number(),
@@ -298,11 +307,11 @@ const we = {
298
307
  kin_name: e.string().optional(),
299
308
  /** 宗门职位 */
300
309
  kin_position: e.string().optional()
301
- }).lock(), $e = e.object({
310
+ }).lock(), De = e.object({
302
311
  name: e.string(),
303
312
  avatar_url: e.string(),
304
313
  bio: e.string(),
305
- gender: ke,
314
+ gender: Ve,
306
315
  birthday: e.object({ year: e.number(), month: e.number(), day: e.number() })
307
316
  }).lock(), Y = e.object({
308
317
  address_id: e.number(),
@@ -313,19 +322,19 @@ const we = {
313
322
  district: e.string(),
314
323
  address: e.string(),
315
324
  is_default: e.bool()
316
- }).lock(), Ue = e.object({
325
+ }).lock(), Ie = e.object({
317
326
  increased_credit: e.number(),
318
327
  decreased_credit: e.number(),
319
328
  expired_credit: e.number(),
320
329
  balance_credit: e.number()
321
- }).lock(), Fe = e.object({
330
+ }).lock(), Ge = e.object({
322
331
  id: e.number(),
323
- change_type: Ce,
324
- change_scene: Re,
332
+ change_type: je,
333
+ change_scene: qe,
325
334
  change_credit: e.number(),
326
335
  balance: e.number(),
327
336
  change_time: e.number()
328
- }).lock(), W = e.object({
337
+ }).lock(), ee = e.object({
329
338
  benefit_id: e.number(),
330
339
  name: e.string(),
331
340
  img_url: e.string(),
@@ -334,11 +343,11 @@ const we = {
334
343
  max_level: e.number(),
335
344
  product_id: e.number(),
336
345
  tag: e.string()
337
- }).lock(), ee = e.object({
346
+ }).lock(), te = e.object({
338
347
  product_id: e.number(),
339
348
  catalog_id: e.number(),
340
349
  catalog_name: e.string(),
341
- item_type: Z,
350
+ item_type: W,
342
351
  name: e.string(),
343
352
  img_url: e.string(),
344
353
  description: e.string(),
@@ -360,10 +369,10 @@ const we = {
360
369
  created_at: e.number(),
361
370
  updated_at: e.number(),
362
371
  redeemable_quantity: e.number().optional()
363
- }).lock(), De = e.object({
364
- ...V(W.shape, "tag"),
365
- product: ee.clone().optional()
366
- }).lock(), Tr = e.union(
372
+ }).lock(), Ae = e.object({
373
+ ...V(ee.shape, "tag"),
374
+ product: te.clone().optional()
375
+ }).lock(), Lr = e.union(
367
376
  e.object({
368
377
  server_id: e.string(),
369
378
  role_id: e.string()
@@ -371,7 +380,7 @@ const we = {
371
380
  e.object({
372
381
  address_id: e.number()
373
382
  })
374
- ).satisfies().lock(), Ie = e.object({
383
+ ).satisfies().lock(), Ne = e.object({
375
384
  recipient: e.string(),
376
385
  mobile: e.string(),
377
386
  province: e.string(),
@@ -380,35 +389,35 @@ const we = {
380
389
  address: e.string(),
381
390
  express_company: e.string(),
382
391
  express_number: e.string()
383
- }).lock(), Ge = e.object({
392
+ }).lock(), Oe = e.object({
384
393
  server_id: e.string(),
385
394
  role_id: e.string(),
386
395
  role_name: e.string()
387
- }).lock(), Ae = e.object({
396
+ }).lock(), Be = e.object({
388
397
  redemption_id: e.number(),
389
398
  player_id: e.string(),
390
399
  product_id: e.number(),
391
400
  name: e.string(),
392
401
  img_url: e.string(),
393
- item_type: Z,
402
+ item_type: W,
394
403
  catalog_id: e.number(),
395
404
  catalog_name: e.string(),
396
405
  quantity: e.number(),
397
406
  amount: e.number(),
398
- status: qe,
407
+ status: Le,
399
408
  created_at: e.number(),
400
- extra_data: e.union(Ie.clone(), Ge.clone()).satisfies().optional()
401
- }), Ne = e.guard(xe), Q = s({ player: Se }), Oe = s({ roles: e.array(X) }), q = s({ role_card: Pe }), K = e.guard($e), H = e.guard(Y), Be = s({ addresses: e.array(Y) }), Me = e.guard(Ue), Qe = s({
402
- credit_logs: e.array(Fe),
409
+ extra_data: e.union(Ne.clone(), Oe.clone()).satisfies().optional()
410
+ }), Qe = e.guard(Ee), J = s({ player: $e }), Me = s({ roles: e.array(X) }), x = s({ role_card: Fe }), K = e.guard(De), H = e.guard(Y), Je = s({ addresses: e.array(Y) }), Ke = e.guard(Ie), He = s({
411
+ credit_logs: e.array(Ge),
403
412
  next_token: e.string().optional()
404
- }), Ke = s({ products: e.array(ee) }), He = s({ benefits: e.array(W) }), ze = s({ benefit: De }), Je = s({
405
- redemptions: e.array(Ae),
413
+ }), ze = s({ products: e.array(te) }), Ze = s({ benefits: e.array(ee) }), We = s({ benefit: Ae }), Xe = s({
414
+ redemptions: e.array(Be),
406
415
  next_token: e.string().optional()
407
416
  });
408
- class qr {
409
- token;
410
- req;
417
+ class Er {
411
418
  constructor(t) {
419
+ m(this, "token");
420
+ m(this, "req");
412
421
  this.token = t, this.req = t.req;
413
422
  }
414
423
  /**
@@ -417,8 +426,8 @@ class qr {
417
426
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=tuhsPt3ihp
418
427
  */
419
428
  async getConfig(t) {
420
- const { data: n } = await this.req.get("club/config", Ne, t);
421
- return n;
429
+ const { data: r } = await this.req.get("club/config", Qe, t);
430
+ return r;
422
431
  }
423
432
  /**
424
433
  * 用于游戏内嵌 Web 页面和微信小程序获取当前登录的游戏账号在俱乐部中的信息。
@@ -427,10 +436,10 @@ class qr {
427
436
  */
428
437
  async getCurrentPlayer(t) {
429
438
  await this.token.autoLogin();
430
- const { data: n, code: r, message: a } = await this.req.get("club/current-player", Q, t);
431
- return n?.player ?? {
432
- message: a,
433
- error: r
439
+ const { data: r, code: n, message: i } = await this.req.get("club/current-player", J, t);
440
+ return (r == null ? void 0 : r.player) ?? {
441
+ message: i,
442
+ error: n
434
443
  };
435
444
  }
436
445
  /**
@@ -440,15 +449,15 @@ class qr {
440
449
  */
441
450
  async linkPlayer(t) {
442
451
  await this.token.autoLogin();
443
- const { data: n, code: r, message: a } = await this.req.post(
452
+ const { data: r, code: n, message: i } = await this.req.post(
444
453
  "club/link-player",
445
454
  { id_token: this.token.idToken },
446
- Q,
455
+ J,
447
456
  t
448
457
  );
449
- return n?.player ?? {
450
- message: a,
451
- error: r
458
+ return (r == null ? void 0 : r.player) ?? {
459
+ message: i,
460
+ error: n
452
461
  };
453
462
  }
454
463
  /**
@@ -456,35 +465,35 @@ class qr {
456
465
  *
457
466
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=nwu4FiGM9V
458
467
  */
459
- async getRoles(t, n, r) {
468
+ async getRoles(t, r, n) {
460
469
  if (!await this.token.autoLogin()) return [];
461
- const { data: a } = await this.req.get("club/roles", Oe, {
462
- ...r,
463
- params: c({ player_id: t, refresh: n })
470
+ const { data: i } = await this.req.get("club/roles", Me, {
471
+ ...n,
472
+ params: c({ player_id: t, refresh: r })
464
473
  });
465
- return a?.roles || [];
474
+ return (i == null ? void 0 : i.roles) || [];
466
475
  }
467
476
  /**
468
477
  * 获取俱乐部会员的角色卡片数据
469
478
  *
470
479
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=A1Wr7kUXnS
471
480
  */
472
- async getRoleCard(t, n) {
473
- const { data: r } = await this.req.get("club/role-card", q, {
474
- ...n,
481
+ async getRoleCard(t, r) {
482
+ const { data: n } = await this.req.get("club/role-card", x, {
483
+ ...r,
475
484
  params: { member_id: t }
476
485
  });
477
- return r?.role_card ?? null;
486
+ return (n == null ? void 0 : n.role_card) ?? null;
478
487
  }
479
488
  /**
480
489
  * 设置自己的角色卡片
481
490
  *
482
491
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=XgMf6OFE5i
483
492
  */
484
- async setRoleCard(t, n) {
493
+ async setRoleCard(t, r) {
485
494
  if (!await this.token.autoLogin()) return null;
486
- const { data: r } = await this.req.post("club/role-card", t, q, n);
487
- return r?.role_card ?? null;
495
+ const { data: n } = await this.req.post("club/role-card", t, x, r);
496
+ return (n == null ? void 0 : n.role_card) ?? null;
488
497
  }
489
498
  /**
490
499
  * 强制刷新自己的角色卡片,从游戏内获取最新数据
@@ -493,32 +502,32 @@ class qr {
493
502
  */
494
503
  async refreshRoleCard(t) {
495
504
  if (!await this.token.autoLogin()) return null;
496
- const { data: n } = await this.req.post("club/refresh-role-card", {}, q, t);
497
- return n?.role_card ?? null;
505
+ const { data: r } = await this.req.post("club/refresh-role-card", {}, x, t);
506
+ return (r == null ? void 0 : r.role_card) ?? null;
498
507
  }
499
508
  /**
500
509
  * 获取俱乐部用户的信息
501
510
  *
502
511
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=TMWBCFcOr2
503
512
  */
504
- async getUserProfile(t, n) {
505
- const { data: r } = await this.req.get("club/user-profile", K, {
506
- ...n,
513
+ async getUserProfile(t, r) {
514
+ const { data: n } = await this.req.get("club/user-profile", K, {
515
+ ...r,
507
516
  params: { member_id: t }
508
517
  });
509
- return r;
518
+ return n;
510
519
  }
511
520
  /**
512
521
  * 修改自己的俱乐部用户信息
513
522
  *
514
523
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=Qt822A57jd
515
524
  */
516
- async updateUserProfile(t, n) {
525
+ async updateUserProfile(t, r) {
517
526
  await this.token.autoLogin();
518
- const { data: r, code: a, message: i } = await this.req.post("club/user-profile", t, K, n);
519
- return r ?? {
520
- message: i,
521
- error: a
527
+ const { data: n, code: i, message: o } = await this.req.post("club/user-profile", t, K, r);
528
+ return n ?? {
529
+ message: o,
530
+ error: i
522
531
  };
523
532
  }
524
533
  /**
@@ -528,35 +537,35 @@ class qr {
528
537
  */
529
538
  async getAddresses(t) {
530
539
  if (!await this.token.autoLogin()) return [];
531
- const { data: n } = await this.req.get("club/addresses", Be, t);
532
- return n?.addresses ?? [];
540
+ const { data: r } = await this.req.get("club/addresses", Je, t);
541
+ return (r == null ? void 0 : r.addresses) ?? [];
533
542
  }
534
543
  /**
535
544
  * 增加俱乐部收货地址
536
545
  *
537
546
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=TaGIIYDRYA
538
547
  */
539
- async addAddress(t, n) {
548
+ async addAddress(t, r) {
540
549
  if (!await this.token.autoLogin()) return null;
541
- const { data: r } = await this.req.post("/club/add-address", c(t), H, n);
542
- return r;
550
+ const { data: n } = await this.req.post("/club/add-address", c(t), H, r);
551
+ return n;
543
552
  }
544
553
  /**
545
554
  * 修改自己的俱乐部收货地址
546
555
  *
547
556
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=p9FlJhHnWN
548
557
  */
549
- async updateAddress(t, n) {
558
+ async updateAddress(t, r) {
550
559
  await this.token.autoLogin();
551
- const { data: r, code: a, message: i } = await this.req.post(
560
+ const { data: n, code: i, message: o } = await this.req.post(
552
561
  "club/update-address",
553
562
  c(t),
554
563
  H,
555
- n
564
+ r
556
565
  );
557
- return r ?? {
558
- message: i,
559
- error: a
566
+ return n ?? {
567
+ message: o,
568
+ error: i
560
569
  };
561
570
  }
562
571
  /**
@@ -564,25 +573,25 @@ class qr {
564
573
  *
565
574
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=MEEOBdf8rm
566
575
  */
567
- async deleteAddress(t, n) {
576
+ async deleteAddress(t, r) {
568
577
  if (!await this.token.autoLogin()) return null;
569
- const { ok: r } = await this.req.post("club/delete-address", { address_id: t }, null, n);
570
- return r;
578
+ const { ok: n } = await this.req.post("club/delete-address", { address_id: t }, null, r);
579
+ return n;
571
580
  }
572
581
  /**
573
582
  * 获取俱乐部积分统计信息
574
583
  *
575
584
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=x4uxtGstRL
576
585
  */
577
- async getUserCredit(t, n) {
586
+ async getUserCredit(t, r) {
578
587
  await this.token.autoLogin();
579
- const { data: r, code: a, message: i } = await this.req.get("club/user-credit", Me, {
580
- ...n,
588
+ const { data: n, code: i, message: o } = await this.req.get("club/user-credit", Ke, {
589
+ ...r,
581
590
  params: c(t)
582
591
  });
583
- return r ?? {
584
- message: i,
585
- error: a
592
+ return n ?? {
593
+ message: o,
594
+ error: i
586
595
  };
587
596
  }
588
597
  /**
@@ -590,15 +599,15 @@ class qr {
590
599
  *
591
600
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=lQFgF689P8
592
601
  */
593
- async getCreditLogs(t, n) {
602
+ async getCreditLogs(t, r) {
594
603
  await this.token.autoLogin();
595
- const { data: r } = await this.req.get("club/credit-logs", Qe, {
596
- ...n,
604
+ const { data: n } = await this.req.get("club/credit-logs", He, {
605
+ ...r,
597
606
  params: c({ max_results: 20, ...t })
598
607
  });
599
608
  return {
600
- credit_logs: r?.credit_logs || [],
601
- next_token: r?.next_token
609
+ credit_logs: (n == null ? void 0 : n.credit_logs) || [],
610
+ next_token: n == null ? void 0 : n.next_token
602
611
  };
603
612
  }
604
613
  /**
@@ -608,45 +617,45 @@ class qr {
608
617
  */
609
618
  async getBenefits(t) {
610
619
  if (!await this.token.autoLogin()) return [];
611
- const { data: n } = await this.req.get("club/benefits", He, t);
612
- return n?.benefits || [];
620
+ const { data: r } = await this.req.get("club/benefits", Ze, t);
621
+ return (r == null ? void 0 : r.benefits) || [];
613
622
  }
614
623
  /**
615
624
  * 获取某个权益详细信息
616
625
  *
617
626
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=XKto0MeaHF
618
627
  */
619
- async getBenefit(t, n) {
628
+ async getBenefit(t, r) {
620
629
  if (!await this.token.autoLogin()) return null;
621
- const { data: r } = await this.req.get("club/benefit", ze, {
622
- ...n,
630
+ const { data: n } = await this.req.get("club/benefit", We, {
631
+ ...r,
623
632
  params: { benefit_id: t }
624
633
  });
625
- return r?.benefit || null;
634
+ return (n == null ? void 0 : n.benefit) || null;
626
635
  }
627
636
  /**
628
637
  * 获取商城商品列表
629
638
  *
630
639
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=r3vC3PzfMQ
631
640
  */
632
- async getProducts(t, n) {
633
- const { data: r } = await this.req.get("club/products", Ke, {
634
- ...n,
641
+ async getProducts(t, r) {
642
+ const { data: n } = await this.req.get("club/products", ze, {
643
+ ...r,
635
644
  params: t
636
645
  });
637
- return r?.products || [];
646
+ return (n == null ? void 0 : n.products) || [];
638
647
  }
639
648
  /**
640
649
  * 兑换商城商品
641
650
  *
642
651
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=LWcMVwX3OY
643
652
  */
644
- async redeemProduct(t, n) {
653
+ async redeemProduct(t, r) {
645
654
  await this.token.autoLogin();
646
- const { ok: r, code: a, message: i } = await this.req.post("club/redeem-product", c(t), null, n);
647
- return r || {
648
- message: i,
649
- error: a
655
+ const { ok: n, code: i, message: o } = await this.req.post("club/redeem-product", c(t), null, r);
656
+ return n || {
657
+ message: o,
658
+ error: i
650
659
  };
651
660
  }
652
661
  /**
@@ -654,15 +663,15 @@ class qr {
654
663
  *
655
664
  * https://kdocs.cn/l/cgp4gSBMbOf1?linkname=Ml6mLgT4cM
656
665
  */
657
- async getRedemptions(t, n) {
666
+ async getRedemptions(t, r) {
658
667
  await this.token.autoLogin();
659
- const { data: r } = await this.req.get("club/redemptions", Je, {
660
- ...n,
668
+ const { data: n } = await this.req.get("club/redemptions", Xe, {
669
+ ...r,
661
670
  params: c({ max_results: 20, ...t })
662
671
  });
663
672
  return {
664
- redemptions: r?.redemptions || [],
665
- next_token: r?.next_token
673
+ redemptions: (n == null ? void 0 : n.redemptions) || [],
674
+ next_token: n == null ? void 0 : n.next_token
666
675
  };
667
676
  }
668
677
  }
@@ -687,17 +696,17 @@ const R = {
687
696
  ExternalCode: "external_gift_code",
688
697
  /** 空奖励 */
689
698
  VoidItem: "void_item"
690
- }, te = e.string().enum(R).lock(), xr = R, ne = te, Ze = {
699
+ }, ne = e.string().enum(R).lock(), $r = R, re = ne, Ye = {
691
700
  /** 世游通行证 ID / Combo ID */
692
701
  UserId: "user_id",
693
702
  /** 游戏角色 ID */
694
703
  RoleId: "role_id"
695
- }, Xe = e.string().enum(Ze).lock(), Ye = {
704
+ }, et = e.string().enum(Ye).lock(), tt = {
696
705
  None: "none",
697
706
  Daily: "daily",
698
707
  Weekly: "weekly",
699
708
  Monthly: "monthly"
700
- }, We = e.string().enum(Ye).lock(), u = {
709
+ }, nt = e.string().enum(tt).lock(), u = {
701
710
  /** 预约 */
702
711
  Preregister: "preregister",
703
712
  /** 抽奖 */
@@ -738,7 +747,7 @@ const R = {
738
747
  ClaimActivationKey: "claim_activation_key",
739
748
  /** 不朽箴言特有的 AI 聊天 */
740
749
  ZeroChatgpt: "zero_chatgpt"
741
- }, et = e.string().enum(u).lock(), tt = {
750
+ }, rt = e.string().enum(u).lock(), it = {
742
751
  /** 累计游戏内活跃值 */
743
752
  Active: "player_active_points",
744
753
  /** 累计登录,单位 人天 */
@@ -753,14 +762,14 @@ const R = {
753
762
  MatchCounts: "player_match_counts",
754
763
  /** 游戏对局天数 */
755
764
  MatchDays: "player_match_days"
756
- }, re = e.string().enum(tt).lock(), nt = {
765
+ }, ie = e.string().enum(it).lock(), ot = {
757
766
  /** 官方上传 */
758
767
  System: "system",
759
768
  /** 用户投稿 */
760
769
  UserSubmission: "user_submission",
761
770
  /** 投票入围 */
762
771
  Shortlisted: "shortlisted"
763
- }, rt = e.string().enum(nt).lock(), p = {
772
+ }, at = e.string().enum(ot).lock(), _ = {
764
773
  /** 未获得奖励 */
765
774
  Ineligible: "ineligible",
766
775
  /** 奖励未领取 */
@@ -771,7 +780,7 @@ const R = {
771
780
  Failed: "failed",
772
781
  /** 奖励已发货 */
773
782
  Delivered: "delivered"
774
- }, Sr = e.string().enum(p).lock(), P = {
783
+ }, Pr = e.string().enum(_).lock(), P = {
775
784
  /**
776
785
  * 奖励未领取,拼写错误以兼容后端历史版本,检查请使用 Unclaimed
777
786
  *
@@ -779,16 +788,16 @@ const R = {
779
788
  */
780
789
  UnclaimedErr: "unaccalimed",
781
790
  /** 奖励未领取 */
782
- Unclaimed: p.Unclaimed,
791
+ Unclaimed: _.Unclaimed,
783
792
  /** 奖励已领取 */
784
- Received: p.Received,
793
+ Received: _.Received,
785
794
  /** 奖励发放失败 */
786
- Failed: p.Failed,
795
+ Failed: _.Failed,
787
796
  /** 奖励已发货 */
788
- Delivered: p.Delivered
789
- }, ae = e.string().enum(P).lock(), _ = {
797
+ Delivered: _.Delivered
798
+ }, oe = e.string().enum(P).lock(), b = {
790
799
  /** 未获得奖励 */
791
- Ineligible: p.Ineligible,
800
+ Ineligible: _.Ineligible,
792
801
  /**
793
802
  * 奖励未领取,拼写错误以兼容后端历史版本,检查请使用 Unclaimed
794
803
  *
@@ -796,24 +805,24 @@ const R = {
796
805
  */
797
806
  UnclaimedErr: "unaccalimed",
798
807
  /** 奖励未领取 */
799
- Unclaimed: p.Unclaimed,
808
+ Unclaimed: _.Unclaimed,
800
809
  /** 奖励已领取 */
801
- Received: p.Received,
810
+ Received: _.Received,
802
811
  /** 奖励发放失败 */
803
- Failed: p.Failed,
812
+ Failed: _.Failed,
804
813
  /** 奖励已发货 */
805
- Delivered: p.Delivered
806
- }, $ = e.string().enum(_).lock(), at = {
814
+ Delivered: _.Delivered
815
+ }, U = e.string().enum(b).lock(), st = {
807
816
  /** 玩法产出奖励 */
808
817
  Output: "output",
809
818
  /** 玩法参与奖励 */
810
819
  Engage: "engage"
811
- }, U = e.string().enum(at).lock(), it = {
820
+ }, F = e.string().enum(st).lock(), ct = {
812
821
  /** 私有队伍 */
813
822
  Private: "private",
814
823
  /** 公开队伍 */
815
824
  Public: "public"
816
- }, ot = e.string().enum(it).lock(), k = {
825
+ }, ut = e.string().enum(ct).lock(), k = {
817
826
  /** 未知状态 */
818
827
  Unknown: "unknown",
819
828
  /** 等待开奖 */
@@ -824,7 +833,7 @@ const R = {
824
833
  Claimed: "claimed",
825
834
  /** 领奖失败 */
826
835
  Fail: "fail"
827
- }, Lr = e.string().enum(k).lock(), st = {
836
+ }, Ur = e.string().enum(k).lock(), lt = {
828
837
  /** 发起组队 */
829
838
  Assemble: "assemble",
830
839
  /** 加入队伍 */
@@ -835,71 +844,71 @@ const R = {
835
844
  ChangeVisibility: "change_visibility",
836
845
  /** 查询组队信息 */
837
846
  Query: "query"
838
- }, Er = e.string().enum(st).lock(), ct = {
847
+ }, Fr = e.string().enum(lt).lock(), mt = {
839
848
  /** 查询抽奖券 */
840
849
  Query: "query",
841
850
  /** 开奖 */
842
851
  Draw: "draw",
843
852
  /** 领奖 */
844
853
  Claim: "claim"
845
- }, Pr = e.string().enum(ct).lock(), ut = e.string().enum(V(R, "GiftCode", "LotteryTicket")), F = e.object({
854
+ }, Dr = e.string().enum(mt).lock(), dt = e.string().enum(V(R, "GiftCode", "LotteryTicket")), D = e.object({
846
855
  reward_item_id: e.number(),
847
856
  reward_amount: e.number(),
848
857
  reward_item_name: e.string(),
849
858
  reward_item_icon_url: e.string(),
850
859
  reward_item_desc: e.string().optional(),
851
- reward_item_type: ut,
860
+ reward_item_type: dt,
852
861
  reward_item_rating: e.number()
853
- }).lock(), lt = e.object({
862
+ }).lock(), gt = e.object({
854
863
  engage_count: e.number(),
855
- rewards: e.array(F)
856
- }).lock(), mt = e.union(
864
+ rewards: e.array(D)
865
+ }).lock(), pt = e.union(
857
866
  e.object({
858
867
  feature_reward_type: e.string().enum("every"),
859
- reward_details: e.array(F)
868
+ reward_details: e.array(D)
860
869
  }),
861
870
  e.object({
862
871
  feature_reward_type: e.string().enum("regular"),
863
- reward_details: e.array(lt)
872
+ reward_details: e.array(gt)
864
873
  })
865
874
  ).satisfies().lock(), l = e.object({
866
875
  feature_name: e.string(),
867
876
  feature_id: e.number(),
868
877
  description: e.string(),
869
- cycle: We,
878
+ cycle: nt,
870
879
  limit: e.number(),
871
880
  since: e.number(),
872
881
  until: e.number(),
873
- engage_account: Xe,
874
- feature_rewards: mt.clone().optional()
875
- }), dt = u.Cashback, gt = e.object({
882
+ engage_account: et,
883
+ feature_rewards: pt.clone().optional()
884
+ }), _t = u.Cashback, bt = e.object({
876
885
  ...l.shape,
877
- feature_type: e.string().enum(dt),
886
+ feature_type: e.string().enum(_t),
878
887
  config: e.object({
879
888
  order_start_time: e.number(),
880
889
  order_end_time: e.number(),
881
890
  claim_rewards_start_time: e.number(),
882
891
  claim_rewards_end_time: e.number()
883
892
  })
884
- }), pt = u.CheckIn, _t = e.object({
893
+ }), yt = u.CheckIn, ht = e.object({
885
894
  ...l.shape,
886
- feature_type: e.string().enum(pt)
887
- }), bt = u.ClaimActivationKey, yt = e.object({
888
- ...l.shape,
889
- feature_type: e.string().enum(bt)
890
- }), ft = u.ClaimRewards, ht = e.object({
895
+ feature_type: e.string().enum(yt)
896
+ }), ft = u.ClaimActivationKey, wt = e.object({
891
897
  ...l.shape,
892
898
  feature_type: e.string().enum(ft)
893
- }), wt = u.Comment, kt = e.object({
899
+ }), kt = u.ClaimRewards, vt = e.object({
900
+ ...l.shape,
901
+ feature_type: e.string().enum(kt)
902
+ }), Ct = u.Comment, Vt = e.object({
894
903
  ...l.shape,
895
- feature_type: e.string().enum(wt),
904
+ feature_type: e.string().enum(Ct),
896
905
  config: e.object({
897
906
  comments: e.array(e.string()),
898
907
  send_rate: e.number()
899
908
  })
900
- }), vt = u.Follow, Ct = e.object({
909
+ }), Rt = u.Follow, jt = e.object({
901
910
  ...l.shape,
902
- feature_type: e.string().enum(vt),
911
+ feature_type: e.string().enum(Rt),
903
912
  config: e.object({
904
913
  platform: e.string(),
905
914
  platform_icon: e.string().optional(),
@@ -907,61 +916,61 @@ const R = {
907
916
  qr_code_url: e.string().optional(),
908
917
  platform_desc: e.string().optional()
909
918
  })
910
- }), Vt = u.GiftCode, Rt = e.object({
919
+ }), Tt = u.GiftCode, qt = e.object({
911
920
  name: e.string(),
912
921
  icon_url: e.string(),
913
922
  count: e.number()
914
- }), jt = e.object({
923
+ }), xt = e.object({
915
924
  ...l.shape,
916
- feature_type: e.string().enum(Vt),
925
+ feature_type: e.string().enum(Tt),
917
926
  config: e.object({
918
- gift_items: e.array(Rt),
927
+ gift_items: e.array(qt),
919
928
  mp_url: e.string().optional(),
920
929
  mp_qrcode_url: e.string().optional()
921
930
  })
922
- }), Tt = u.Invite, qt = e.object({
931
+ }), St = u.Invite, Lt = e.object({
923
932
  ...l.shape,
924
- feature_type: e.string().enum(Tt),
933
+ feature_type: e.string().enum(St),
925
934
  config: e.object({
926
935
  share_url: e.string()
927
936
  })
928
- }), xt = u.InvitedRegister, St = e.object({
937
+ }), Et = u.InvitedRegister, $t = e.object({
929
938
  ...l.shape,
930
- feature_type: e.string().enum(xt)
931
- }), Lt = e.string().enum(V(R, "GiftCode", "LotteryTicket")), Et = u.Lottery, Pt = e.object({
939
+ feature_type: e.string().enum(Et)
940
+ }), Pt = e.string().enum(V(R, "GiftCode", "LotteryTicket")), Ut = u.Lottery, Ft = e.object({
932
941
  reward_item_id: e.number(),
933
942
  reward_item_name: e.string(),
934
- reward_item_type: Lt,
943
+ reward_item_type: Pt,
935
944
  reward_item_icon_url: e.string(),
936
945
  reward_item_desc: e.string().optional(),
937
946
  reward_amount: e.number(),
938
947
  reward_remaining_stock: e.number()
939
- }), $t = e.object({
948
+ }), Dt = e.object({
940
949
  ...l.shape,
941
- feature_type: e.string().enum(Et),
950
+ feature_type: e.string().enum(Ut),
942
951
  config: e.object({
943
952
  consume_item_id: e.number(),
944
953
  consume_item_name: e.number(),
945
954
  consume_item_icon_url: e.string(),
946
955
  consume_item_count: e.number(),
947
956
  consume_item_desc: e.string().optional(),
948
- rewards: e.array(Pt)
957
+ rewards: e.array(Ft)
949
958
  })
950
- }), Ut = u.LotteryDraw, Ft = e.object({
959
+ }), It = u.LotteryDraw, Gt = e.object({
951
960
  ...l.shape,
952
- feature_type: e.string().enum(Ut),
961
+ feature_type: e.string().enum(It),
953
962
  config: e.object({
954
963
  draw_not_before: e.number(),
955
964
  draw_not_after: e.number()
956
965
  })
957
- }), Dt = u.Preregister, It = e.object({
966
+ }), At = u.Preregister, Nt = e.object({
958
967
  ...l.shape,
959
- feature_type: e.string().enum(Dt)
960
- }), Gt = u.Quest, At = e.object({
968
+ feature_type: e.string().enum(At)
969
+ }), Ot = u.Quest, Bt = e.object({
961
970
  ...l.shape,
962
- feature_type: e.string().enum(Gt),
971
+ feature_type: e.string().enum(Ot),
963
972
  config: e.object({
964
- objective: re,
973
+ objective: ie,
965
974
  completion_value: e.number(),
966
975
  team: e.object({
967
976
  feature_id: e.number().optional(),
@@ -973,38 +982,38 @@ const R = {
973
982
  required_matches: e.number().min(1).optional()
974
983
  }).optional()
975
984
  })
976
- }), Nt = u.Register, Ot = e.object({
985
+ }), Qt = u.Register, Mt = e.object({
977
986
  ...l.shape,
978
- feature_type: e.string().enum(Nt)
979
- }), Bt = u.Share, Mt = e.object({
987
+ feature_type: e.string().enum(Qt)
988
+ }), Jt = u.Share, Kt = e.object({
980
989
  ...l.shape,
981
- feature_type: e.string().enum(Bt),
990
+ feature_type: e.string().enum(Jt),
982
991
  config: e.object({
983
992
  share_platform: e.string(),
984
993
  jump_url: e.string().optional(),
985
994
  icon_url: e.string().optional()
986
995
  })
987
- }), Qt = u.Subscribe, Kt = e.object({
996
+ }), Ht = u.Subscribe, zt = e.object({
988
997
  ...l.shape,
989
- feature_type: e.string().enum(Qt),
998
+ feature_type: e.string().enum(Ht),
990
999
  config: e.object({
991
1000
  weixin_template_ids: e.array(e.string())
992
1001
  })
993
- }), Ht = u.Survey, zt = e.object({
1002
+ }), Zt = u.Survey, Wt = e.object({
994
1003
  ...l.shape,
995
- feature_type: e.string().enum(Ht),
1004
+ feature_type: e.string().enum(Zt),
996
1005
  config: e.object({
997
1006
  survey_id: e.string(),
998
1007
  survey_url: e.string()
999
1008
  })
1000
- }), Jt = u.Team, Zt = e.object({
1009
+ }), Xt = u.Team, Yt = e.object({
1001
1010
  ...l.shape,
1002
- feature_type: e.string().enum(Jt),
1011
+ feature_type: e.string().enum(Xt),
1003
1012
  config: e.object({
1004
1013
  max_members: e.number().min(1),
1005
1014
  min_members: e.number().min(1)
1006
1015
  })
1007
- }), Xt = u.Vote, Yt = e.object({
1016
+ }), en = u.Vote, tn = e.object({
1008
1017
  sn: e.string(),
1009
1018
  name: e.string(),
1010
1019
  img_urls: e.array(e.string()).optional(),
@@ -1014,96 +1023,96 @@ const R = {
1014
1023
  amount: e.number(),
1015
1024
  finalists: e.bool(),
1016
1025
  last_vote_time: e.number()
1017
- }), Wt = e.object({
1026
+ }), nn = e.object({
1018
1027
  ...l.shape,
1019
- feature_type: e.string().enum(Xt),
1028
+ feature_type: e.string().enum(en),
1020
1029
  config: e.object({
1021
1030
  vote_feature_ids: e.array(e.number()),
1022
1031
  submission_feature_ids: e.array(e.number()),
1023
1032
  finalists_amount: e.number(),
1024
- source: rt,
1025
- options: e.array(Yt),
1026
- rewards: e.array(F)
1033
+ source: at,
1034
+ options: e.array(tn),
1035
+ rewards: e.array(D)
1027
1036
  })
1028
- }), en = u.ZeroChatgpt, tn = e.object({
1037
+ }), rn = u.ZeroChatgpt, on = e.object({
1029
1038
  ...l.shape,
1030
- feature_type: e.string().enum(en)
1031
- }), nn = e.union(
1032
- gt,
1033
- _t,
1039
+ feature_type: e.string().enum(rn)
1040
+ }), an = e.union(
1041
+ bt,
1034
1042
  ht,
1035
- kt,
1036
- Ct,
1043
+ vt,
1044
+ Vt,
1037
1045
  jt,
1038
- qt,
1039
- St,
1046
+ xt,
1047
+ Lt,
1040
1048
  $t,
1041
- Ft,
1042
- It,
1043
- At,
1044
- Ot,
1049
+ Dt,
1050
+ Gt,
1051
+ Nt,
1052
+ Bt,
1045
1053
  Mt,
1046
1054
  Kt,
1047
1055
  zt,
1048
- Zt,
1049
1056
  Wt,
1050
- yt,
1051
- tn
1052
- ).key("feature_type").satisfies(), rn = e.object({
1057
+ Yt,
1058
+ nn,
1059
+ wt,
1060
+ on
1061
+ ).key("feature_type").satisfies(), sn = e.object({
1053
1062
  event_name: e.string(),
1054
1063
  rules: e.string(),
1055
1064
  since: e.number(),
1056
1065
  until: e.number(),
1057
1066
  visit_count: e.number().optional(),
1058
- features: e.array(nn)
1059
- }).lock(), x = e.union(e.string().pattern("NumberString", /^\d+$/), e.number()), an = e.object({
1060
- order_total_amount: x,
1061
- cashback_total_amount: x,
1062
- game_item_count: x
1063
- }), on = e.object({
1067
+ features: e.array(an)
1068
+ }).lock(), S = e.union(e.string().pattern("NumberString", /^\d+$/), e.number()), cn = e.object({
1069
+ order_total_amount: S,
1070
+ cashback_total_amount: S,
1071
+ game_item_count: S
1072
+ }), un = e.object({
1064
1073
  activation_key: e.string().disallow("")
1065
- }), sn = e.object({
1074
+ }), ln = e.object({
1066
1075
  gift_code: e.string()
1067
- }), cn = e.object({
1076
+ }), mn = e.object({
1068
1077
  user_id: e.string(),
1069
1078
  name: e.string().optional(),
1070
1079
  avatar_url: e.string().optional()
1071
- }), un = e.object({
1080
+ }), dn = e.object({
1072
1081
  lottery_count: e.number()
1073
- }), D = e.object({
1082
+ }), I = e.object({
1074
1083
  reward_id: e.number(),
1075
1084
  reward_item_id: e.number(),
1076
- reward_source: U,
1085
+ reward_source: F,
1077
1086
  reward_item_name: e.string(),
1078
- reward_item_type: te,
1087
+ reward_item_type: ne,
1079
1088
  reward_item_icon_url: e.string(),
1080
1089
  reward_item_desc: e.string().optional(),
1081
1090
  reward_item_rating: e.number(),
1082
1091
  reward_amount: e.number(),
1083
- reward_status: $,
1092
+ reward_status: U,
1084
1093
  event_id: e.number(),
1085
1094
  event_name: e.string(),
1086
1095
  feature_id: e.number(),
1087
1096
  engagement_id: e.number(),
1088
- feature_type: et,
1097
+ feature_type: rt,
1089
1098
  receive_time: e.number(),
1090
1099
  extra_data: e.record(e.unknown()).optional()
1091
- }), ln = e.string().enum(k.Unknown, k.Pending), mn = e.union(
1100
+ }), gn = e.string().enum(k.Unknown, k.Pending), pn = e.union(
1092
1101
  e.object({
1093
1102
  ticket: e.string(),
1094
- status: ln
1103
+ status: gn
1095
1104
  }),
1096
1105
  e.object({
1097
1106
  ticket: e.string(),
1098
1107
  status: e.string().enum(V(k, "Unknown", "Pending")),
1099
- reward: D
1108
+ reward: I
1100
1109
  })
1101
- ).satisfies(), dn = e.object({
1102
- tickets: e.array(mn)
1103
- }), gn = e.object({
1110
+ ).satisfies(), _n = e.object({
1111
+ tickets: e.array(pn)
1112
+ }), bn = e.object({
1104
1113
  platforms: e.array(e.string())
1105
- }), pn = e.object({
1106
- objective: re,
1114
+ }), yn = e.object({
1115
+ objective: ie,
1107
1116
  progress: e.number(),
1108
1117
  completion_value: e.number().optional(),
1109
1118
  team: e.object({
@@ -1118,24 +1127,24 @@ const R = {
1118
1127
  })
1119
1128
  )
1120
1129
  }).optional()
1121
- }), _n = e.object({
1130
+ }), hn = e.object({
1122
1131
  platform: e.string()
1123
- }), bn = e.object({
1132
+ }), fn = e.object({
1124
1133
  weixin_openid: e.string()
1125
- }), yn = e.object({
1134
+ }), wn = e.object({
1126
1135
  serial_number: e.number()
1127
- }), fn = e.object({
1136
+ }), kn = e.object({
1128
1137
  team_code: e.string(),
1129
1138
  leader_name: e.string(),
1130
1139
  total_members: e.number()
1131
- }), $r = e.object({
1140
+ }), Ir = e.object({
1132
1141
  is_leader: e.bool(),
1133
1142
  is_myself: e.bool().optional(),
1134
1143
  role_name: e.string(),
1135
1144
  server_name: e.string()
1136
- }), hn = e.object({
1145
+ }), vn = e.object({
1137
1146
  team_code: e.string(),
1138
- visibility: ot,
1147
+ visibility: ut,
1139
1148
  members: e.array(
1140
1149
  e.object({
1141
1150
  is_leader: e.bool(),
@@ -1143,137 +1152,137 @@ const R = {
1143
1152
  server_name: e.string()
1144
1153
  })
1145
1154
  )
1146
- }), wn = e.object({
1155
+ }), Cn = e.object({
1147
1156
  option_sn: e.string()
1148
- }), kn = e.object({
1157
+ }), Vn = e.object({
1149
1158
  role: e.string(),
1150
1159
  content: e.string()
1151
- }), vn = e.object({
1152
- conversations: e.array(kn)
1153
- }), Cn = e.object({
1160
+ }), Rn = e.object({
1161
+ conversations: e.array(Vn)
1162
+ }), jn = e.object({
1154
1163
  user_id: e.string(),
1155
1164
  name: e.string(),
1156
1165
  avatar_url: e.string(),
1157
1166
  comment: e.string(),
1158
1167
  video_note: e.number(),
1159
1168
  created_at: e.number()
1160
- }), I = e.union(
1161
- gn,
1162
- un,
1163
- yn,
1164
- cn,
1165
- _n,
1166
- wn,
1169
+ }), G = e.union(
1167
1170
  bn,
1168
- an,
1169
- sn,
1170
- hn,
1171
- pn,
1172
1171
  dn,
1173
- on,
1172
+ wn,
1173
+ mn,
1174
+ hn,
1175
+ Cn,
1176
+ fn,
1177
+ cn,
1178
+ ln,
1174
1179
  vn,
1180
+ yn,
1181
+ _n,
1182
+ un,
1183
+ Rn,
1175
1184
  e.custom(
1176
1185
  "EmptyObject",
1177
- (o) => C(o) && Object.keys(o).length === 0
1186
+ (a) => C(a) && Object.keys(a).length === 0
1178
1187
  )
1179
- ).satisfies().lock(), Vn = e.object({
1188
+ ).satisfies().lock(), Tn = e.object({
1180
1189
  reward_id: e.number(),
1181
1190
  reward_item_id: e.number(),
1182
- reward_item_type: ne,
1191
+ reward_item_type: re,
1183
1192
  reward_count: e.number(),
1184
- reward_status: ae,
1185
- reward_source: U,
1193
+ reward_status: oe,
1194
+ reward_source: F,
1186
1195
  reward_item_name: e.string(),
1187
1196
  reward_item_icon_url: e.string(),
1188
1197
  reward_item_desc: e.string().optional(),
1189
1198
  reward_item_rating: e.number(),
1190
1199
  receive_time: e.number(),
1191
- extra_data: e.union(...I.validators, e.record(e.unknown())).satisfies().optional()
1192
- }), Rn = e.object({
1200
+ extra_data: e.union(...G.validators, e.record(e.unknown())).satisfies().optional()
1201
+ }), qn = e.object({
1193
1202
  reward_id: e.number(),
1194
1203
  reward_item_id: e.number(),
1195
1204
  reward_item_name: e.string(),
1196
- reward_item_type: ne,
1205
+ reward_item_type: re,
1197
1206
  reward_item_icon_url: e.string(),
1198
1207
  reward_item_desc: e.string().optional(),
1199
1208
  reward_amount: e.number(),
1200
- reward_status: ae,
1201
- reward_source: U,
1209
+ reward_status: oe,
1210
+ reward_source: F,
1202
1211
  extra_data: e.record(e.unknown()).optional()
1203
- }), jn = e.object({
1212
+ }), xn = e.object({
1204
1213
  engagement_id: e.number(),
1205
1214
  user_id: e.string(),
1206
1215
  event_id: e.number(),
1207
1216
  feature_id: e.number(),
1208
1217
  sequence: e.number(),
1209
- data: I.clone().optional(),
1218
+ data: G.clone().optional(),
1210
1219
  server_id: e.string().optional(),
1211
1220
  role_id: e.string().optional(),
1212
1221
  created_at: e.number(),
1213
- rewards: e.array(Vn).optional()
1214
- }).lock(), Tn = e.object({
1222
+ rewards: e.array(Tn).optional()
1223
+ }).lock(), Sn = e.object({
1215
1224
  allowed: e.bool(),
1216
1225
  registered: e.bool()
1217
- }), qn = e.object({
1226
+ }), Ln = e.object({
1218
1227
  feature_id: e.number(),
1219
1228
  can_engage: e.bool(),
1220
1229
  has_unclaimed_rewards: e.bool()
1221
- }), xn = e.object({
1230
+ }), En = e.object({
1222
1231
  engagement_id: e.number(),
1223
1232
  engagement: e.object({
1224
1233
  engagement_id: e.number(),
1225
1234
  sequence: e.number(),
1226
1235
  feature_id: e.number(),
1227
- data: I.clone().optional()
1236
+ data: G.clone().optional()
1228
1237
  }).optional(),
1229
- rewards: e.array(Rn).optional(),
1238
+ rewards: e.array(qn).optional(),
1230
1239
  scan: e.bool().optional()
1231
- }), Sn = e.object({
1240
+ }), $n = e.object({
1232
1241
  reward_id: e.number(),
1233
- reward_status: $
1234
- }), Ln = e.guard(rn), En = e.guard(Tn), S = s({ count: e.number() }), Pn = s({ first_visit: e.bool() }), $n = s({
1235
- engagements: e.union(e.array(Cn), e.array(fn))
1236
- }), Un = s({
1237
- status: e.array(qn)
1238
- }), Fn = s({
1242
+ reward_status: U
1243
+ }), Pn = e.guard(sn), Un = e.guard(Sn), L = s({ count: e.number() }), Fn = s({ first_visit: e.bool() }), Dn = s({
1244
+ engagements: e.union(e.array(jn), e.array(kn))
1245
+ }), In = s({
1246
+ status: e.array(Ln)
1247
+ }), Gn = s({
1239
1248
  engagements_counts: e.record(e.number())
1240
- }), Dn = s({
1241
- engagements: e.array(jn),
1242
- next_token: e.string().optional()
1243
- }), In = e.guard(xn), Gn = s({
1244
- claimed_items: e.array(Sn)
1245
1249
  }), An = s({
1246
- rewards: e.array(D)
1247
- }), Nn = s({
1248
- reward_status: $
1249
- }), On = s({
1250
- user_rewards: e.array(D),
1250
+ engagements: e.array(xn),
1251
1251
  next_token: e.string().optional()
1252
+ }), Nn = e.guard(En), On = s({
1253
+ claimed_items: e.array($n)
1252
1254
  }), Bn = s({
1253
- scene: e.string()
1255
+ rewards: e.array(I)
1256
+ }), Qn = s({
1257
+ reward_status: U
1254
1258
  }), Mn = s({
1259
+ user_rewards: e.array(I),
1260
+ next_token: e.string().optional()
1261
+ }), Jn = s({
1262
+ scene: e.string()
1263
+ }), Kn = s({
1255
1264
  params: e.string()
1256
- }), Qn = s({
1265
+ }), Hn = s({
1257
1266
  img: e.string()
1258
1267
  });
1259
- class Ur {
1260
- token;
1261
- event = 0;
1262
- req;
1263
- constructor(t, n) {
1264
- this.token = t, this.event = +n, this.req = t.req;
1268
+ class Gr {
1269
+ constructor(t, r) {
1270
+ m(this, "token");
1271
+ m(this, "event", 0);
1272
+ m(this, "req");
1273
+ this.token = t, this.event = +r, this.req = t.req;
1265
1274
  }
1266
1275
  /**
1267
1276
  * 根据手机号白名单,检查手机号是否允许登录某个游戏
1268
1277
  *
1269
1278
  * https://kdocs.cn/l/cf2mO2uRLqh9?linkname=OWGSPF3Ysl
1270
1279
  */
1271
- async verifyMobileAllowed(t, n, r) {
1272
- const { data: a } = await this.req.get("verify-mobile-allowed", En, {
1273
- ...r,
1274
- params: { game_id: t, mobile: n }
1280
+ async verifyMobileAllowed(t, r, n) {
1281
+ const { data: i } = await this.req.get("verify-mobile-allowed", Un, {
1282
+ ...n,
1283
+ params: { game_id: t, mobile: r }
1275
1284
  });
1276
- return a;
1285
+ return i;
1277
1286
  }
1278
1287
  /**
1279
1288
  * 获取运营活动的基础配置信息
@@ -1281,32 +1290,32 @@ class Ur {
1281
1290
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=wFXxtdNKPm
1282
1291
  */
1283
1292
  async getConfig(t) {
1284
- const { data: n } = await this.req.get(`event/${this.event}/event-config`, Ln, t);
1285
- return n;
1293
+ const { data: r } = await this.req.get(`event/${this.event}/event-config`, Pn, t);
1294
+ return r;
1286
1295
  }
1287
1296
  /**
1288
1297
  * 获取某个玩法参与用户数量
1289
1298
  *
1290
1299
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=ejPOcWMvT1
1291
1300
  */
1292
- async getEngagementsUserCount(t, n) {
1293
- const { data: r } = await this.req.get(`event/${this.event}/feature-engagement-count`, S, {
1294
- ...n,
1301
+ async getEngagementsUserCount(t, r) {
1302
+ const { data: n } = await this.req.get(`event/${this.event}/feature-engagement-count`, L, {
1303
+ ...r,
1295
1304
  params: { feature_id: t, type: "user" }
1296
1305
  });
1297
- return r?.count ?? null;
1306
+ return (n == null ? void 0 : n.count) ?? null;
1298
1307
  }
1299
1308
  /**
1300
1309
  * 获取某个玩法参与次数
1301
1310
  *
1302
1311
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=ejPOcWMvT1
1303
1312
  */
1304
- async getEngagementsCount(t, n) {
1305
- const { data: r } = await this.req.get(`event/${this.event}/feature-engagement-count`, S, {
1306
- ...n,
1313
+ async getEngagementsCount(t, r) {
1314
+ const { data: n } = await this.req.get(`event/${this.event}/feature-engagement-count`, L, {
1315
+ ...r,
1307
1316
  params: { feature_id: t, type: "engagement" }
1308
1317
  });
1309
- return r?.count ?? null;
1318
+ return (n == null ? void 0 : n.count) ?? null;
1310
1319
  }
1311
1320
  /**
1312
1321
  * 获取某个玩法的参与记录(和特定用户无关)
@@ -1315,29 +1324,29 @@ class Ur {
1315
1324
  *
1316
1325
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=THtZ4ewIQW
1317
1326
  */
1318
- async getEngagements(t, n) {
1319
- const { data: r } = await this.req.get(`event/${this.event}/feature-engagements`, $n, {
1320
- ...n,
1327
+ async getEngagements(t, r) {
1328
+ const { data: n } = await this.req.get(`event/${this.event}/feature-engagements`, Dn, {
1329
+ ...r,
1321
1330
  params: { feature_id: t }
1322
1331
  });
1323
- return r?.engagements || [];
1332
+ return (n == null ? void 0 : n.engagements) || [];
1324
1333
  }
1325
1334
  /**
1326
1335
  * 用户访问某个活动或玩法
1327
1336
  *
1328
1337
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=DWtJrnrBCn
1329
1338
  */
1330
- async visit(t, n) {
1339
+ async visit(t, r) {
1331
1340
  await this.token.autoLogin();
1332
- const { data: r, code: a, message: i } = await this.req.post(
1341
+ const { data: n, code: i, message: o } = await this.req.post(
1333
1342
  `event/${this.event}/visit`,
1334
1343
  c(t || {}),
1335
- Pn,
1336
- n
1344
+ Fn,
1345
+ r
1337
1346
  );
1338
- return r ?? {
1339
- message: i,
1340
- error: a
1347
+ return n ?? {
1348
+ message: o,
1349
+ error: i
1341
1350
  };
1342
1351
  }
1343
1352
  /**
@@ -1349,27 +1358,27 @@ class Ur {
1349
1358
  *
1350
1359
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=WzX5BrMNpL
1351
1360
  */
1352
- async getUserFeatureStatus(t, n) {
1361
+ async getUserFeatureStatus(t, r) {
1353
1362
  if (!await this.token.autoLogin()) return [];
1354
- const { data: r } = await this.req.get("event/user-feature-status", Un, {
1355
- ...n,
1363
+ const { data: n } = await this.req.get("event/user-feature-status", In, {
1364
+ ...r,
1356
1365
  message: !1,
1357
1366
  params: c({ ...t, event_id: this.event })
1358
1367
  });
1359
- return r?.status || [];
1368
+ return (n == null ? void 0 : n.status) || [];
1360
1369
  }
1361
1370
  /**
1362
1371
  * 获取用户在目标活动下的某个玩法的参与次数
1363
1372
  *
1364
1373
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=uYCsjWyL36
1365
1374
  */
1366
- async getUserEngagementCount(t, n) {
1375
+ async getUserEngagementCount(t, r) {
1367
1376
  if (!await this.token.autoLogin()) return {};
1368
- const { data: r } = await this.req.get("event/user-engagements-count", Fn, {
1377
+ const { data: n } = await this.req.get("event/user-engagements-count", Gn, {
1369
1378
  message: !1,
1370
- params: c({ ...n, event_id: this.event, feature_id: t })
1379
+ params: c({ ...r, event_id: this.event, feature_id: t })
1371
1380
  });
1372
- return r?.engagements_counts || {};
1381
+ return (n == null ? void 0 : n.engagements_counts) || {};
1373
1382
  }
1374
1383
  /**
1375
1384
  * 获取当前登录用户参与某个玩法的记录
@@ -1378,24 +1387,24 @@ class Ur {
1378
1387
  *
1379
1388
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=NFDdV1dwWb
1380
1389
  */
1381
- async getUserEngagements(t, n, r) {
1390
+ async getUserEngagements(t, r, n) {
1382
1391
  if (!await this.token.autoLogin())
1383
1392
  return {
1384
1393
  engagements: [],
1385
1394
  next_token: ""
1386
1395
  };
1387
- const { data: a } = await this.req.get("event/user-engagements", Dn, {
1388
- ...r,
1396
+ const { data: i } = await this.req.get("event/user-engagements", An, {
1397
+ ...n,
1389
1398
  params: c({
1390
1399
  max_results: 20,
1391
- ...n,
1400
+ ...r,
1392
1401
  event_id: this.event,
1393
1402
  feature_id: t
1394
1403
  })
1395
1404
  });
1396
1405
  return {
1397
- engagements: a?.engagements || [],
1398
- next_token: a?.next_token || ""
1406
+ engagements: (i == null ? void 0 : i.engagements) || [],
1407
+ next_token: (i == null ? void 0 : i.next_token) || ""
1399
1408
  };
1400
1409
  }
1401
1410
  /**
@@ -1407,21 +1416,21 @@ class Ur {
1407
1416
  *
1408
1417
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=vuOyrcry3S
1409
1418
  */
1410
- async engage(t, n, r, a) {
1419
+ async engage(t, r, n, i) {
1411
1420
  await this.token.autoLogin();
1412
- const { data: i, code: d, message: m } = await this.req.post(
1421
+ const { data: o, code: g, message: d } = await this.req.post(
1413
1422
  `event/${this.event}/engage`,
1414
1423
  c({
1415
1424
  feature_id: t,
1416
- engagement: n,
1417
- ...r
1425
+ engagement: r,
1426
+ ...n
1418
1427
  }),
1419
- In,
1420
- a
1428
+ Nn,
1429
+ i
1421
1430
  );
1422
- return i && i.rewards && (i.rewards = i.rewards.map((f) => (f.reward_status = f.reward_status === P.UnclaimedErr ? P.Unclaimed : f.reward_status, f))), i ?? {
1423
- message: m,
1424
- error: d
1431
+ return o && o.rewards && (o.rewards = o.rewards.map((f) => (f.reward_status = f.reward_status === P.UnclaimedErr ? P.Unclaimed : f.reward_status, f))), o ?? {
1432
+ message: d,
1433
+ error: g
1425
1434
  // 激活码已领完
1426
1435
  };
1427
1436
  }
@@ -1432,20 +1441,20 @@ class Ur {
1432
1441
  *
1433
1442
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=lCGuqgvUDP
1434
1443
  */
1435
- async claimRewards(t, n) {
1444
+ async claimRewards(t, r) {
1436
1445
  await this.token.autoLogin();
1437
- const { data: r, code: a, message: i } = await this.req.post(
1446
+ const { data: n, code: i, message: o } = await this.req.post(
1438
1447
  "event/claim-rewards",
1439
1448
  c({
1440
1449
  ...t,
1441
1450
  server_id: t.server_id ? +t.server_id : void 0
1442
1451
  }),
1443
- Gn,
1444
- n
1445
- ), d = r?.claimed_items;
1446
- return d ? d.map((m) => (m.reward_status = m.reward_status === _.UnclaimedErr ? _.Unclaimed : m.reward_status, m)) : {
1447
- message: i,
1448
- error: a
1452
+ On,
1453
+ r
1454
+ ), g = n == null ? void 0 : n.claimed_items;
1455
+ return g ? g.map((d) => (d.reward_status = d.reward_status === b.UnclaimedErr ? b.Unclaimed : d.reward_status, d)) : {
1456
+ message: o,
1457
+ error: i
1449
1458
  };
1450
1459
  }
1451
1460
  /**
@@ -1453,20 +1462,20 @@ class Ur {
1453
1462
  *
1454
1463
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=vdc4SrqXjF
1455
1464
  */
1456
- async claimRewardsV2(t, n) {
1465
+ async claimRewardsV2(t, r) {
1457
1466
  await this.token.autoLogin();
1458
- const { data: r, code: a, message: i } = await this.req.post(
1467
+ const { data: n, code: i, message: o } = await this.req.post(
1459
1468
  "event/claim-rewards-v2",
1460
1469
  c({
1461
1470
  ...t,
1462
1471
  server_id: t.server_id ? +t.server_id : void 0
1463
1472
  }),
1464
- An,
1465
- n
1466
- ), d = r?.rewards;
1467
- return d ? d.map((m) => (m.reward_status = m.reward_status === _.UnclaimedErr ? _.Unclaimed : m.reward_status, m)) : {
1468
- message: i,
1469
- error: a
1473
+ Bn,
1474
+ r
1475
+ ), g = n == null ? void 0 : n.rewards;
1476
+ return g ? g.map((d) => (d.reward_status = d.reward_status === b.UnclaimedErr ? b.Unclaimed : d.reward_status, d)) : {
1477
+ message: o,
1478
+ error: i
1470
1479
  };
1471
1480
  }
1472
1481
  /**
@@ -1474,17 +1483,17 @@ class Ur {
1474
1483
  *
1475
1484
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=aQLhlOAB4Q
1476
1485
  */
1477
- async claimWeixinHongbao(t, n) {
1486
+ async claimWeixinHongbao(t, r) {
1478
1487
  await this.token.autoLogin();
1479
- const { data: r, code: a, message: i } = await this.req.post(
1488
+ const { data: n, code: i, message: o } = await this.req.post(
1480
1489
  "event/claim-weixin-hongbao",
1481
1490
  { reward_id: t },
1482
- Nn,
1483
- n
1491
+ Qn,
1492
+ r
1484
1493
  );
1485
- return r ? (r.reward_status = r.reward_status === _.UnclaimedErr ? _.Unclaimed : r.reward_status, r) : {
1486
- message: i,
1487
- error: a
1494
+ return n ? (n.reward_status = n.reward_status === b.UnclaimedErr ? b.Unclaimed : n.reward_status, n) : {
1495
+ message: o,
1496
+ error: i
1488
1497
  };
1489
1498
  }
1490
1499
  /**
@@ -1492,18 +1501,18 @@ class Ur {
1492
1501
  *
1493
1502
  * https://kdocs.cn/l/cf2mO2uRLqh9?linkname=B4xwTbDzhn
1494
1503
  */
1495
- async verifyActivationKey(t, n) {
1504
+ async verifyActivationKey(t, r) {
1496
1505
  if (!this.token.isLoggedIn)
1497
1506
  return { error: "not_logged_in" };
1498
- const { ok: r, code: a, message: i } = await this.req.post(
1507
+ const { ok: n, code: i, message: o } = await this.req.post(
1499
1508
  "verify-activation-key",
1500
1509
  { activation_key: t },
1501
1510
  null,
1502
- { message: !1, ...n }
1511
+ { message: !1, ...r }
1503
1512
  );
1504
- return r || {
1505
- message: i,
1506
- error: a
1513
+ return n || {
1514
+ message: o,
1515
+ error: i
1507
1516
  };
1508
1517
  }
1509
1518
  /**
@@ -1511,21 +1520,21 @@ class Ur {
1511
1520
  *
1512
1521
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=qj12eIgYQG
1513
1522
  */
1514
- async getUserRewards(t, n) {
1523
+ async getUserRewards(t, r) {
1515
1524
  if (!await this.token.autoLogin())
1516
1525
  return {
1517
1526
  user_rewards: [],
1518
1527
  next_token: ""
1519
1528
  };
1520
- const { data: r } = await this.req.post(
1529
+ const { data: n } = await this.req.post(
1521
1530
  "event/user-rewards",
1522
1531
  c({ max_results: 20, ...t, event_id: this.event }),
1523
- On,
1524
- n
1532
+ Mn,
1533
+ r
1525
1534
  );
1526
1535
  return {
1527
- user_rewards: (r?.user_rewards || []).map((a) => (a.reward_status = a.reward_status === _.UnclaimedErr ? _.Unclaimed : a.reward_status, a)),
1528
- next_token: r?.next_token || ""
1536
+ user_rewards: ((n == null ? void 0 : n.user_rewards) || []).map((i) => (i.reward_status = i.reward_status === b.UnclaimedErr ? b.Unclaimed : i.reward_status, i)),
1537
+ next_token: (n == null ? void 0 : n.next_token) || ""
1529
1538
  };
1530
1539
  }
1531
1540
  /**
@@ -1533,23 +1542,23 @@ class Ur {
1533
1542
  *
1534
1543
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=mnGCTeTgMb
1535
1544
  */
1536
- async getUserItemCount(t, n) {
1545
+ async getUserItemCount(t, r) {
1537
1546
  if (!await this.token.autoLogin()) return null;
1538
- const { data: r } = await this.req.get(`event/${this.event}/user-item-count`, S, {
1539
- ...n,
1547
+ const { data: n } = await this.req.get(`event/${this.event}/user-item-count`, L, {
1548
+ ...r,
1540
1549
  params: { item_id: t }
1541
1550
  });
1542
- return r?.count ?? null;
1551
+ return (n == null ? void 0 : n.count) ?? null;
1543
1552
  }
1544
1553
  /**
1545
1554
  * 填写实物奖励收货地址,返回 null 表示未登录
1546
1555
  *
1547
1556
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=QIwGhnaexb
1548
1557
  */
1549
- async submitUserRewardAddress(t, n) {
1558
+ async submitUserRewardAddress(t, r) {
1550
1559
  if (!await this.token.autoLogin()) return null;
1551
- const { ok: r } = await this.req.post(`event/${this.event}/user-reward-address`, t, null, n);
1552
- return r;
1560
+ const { ok: n } = await this.req.post(`event/${this.event}/user-reward-address`, t, null, r);
1561
+ return n;
1553
1562
  }
1554
1563
  /**
1555
1564
  * 小程序码携带参数最多 32 个可见字符,若前端携带参数过长,则将参数保存在 api 中,并返回符合小程序码要求的 scene
@@ -1558,13 +1567,13 @@ class Ur {
1558
1567
  *
1559
1568
  * @param params - 前端扫描二维码打开小程序所需参数
1560
1569
  */
1561
- async getUnlimitQrcodeScene(t, n) {
1570
+ async getUnlimitQrcodeScene(t, r) {
1562
1571
  if (!await this.token.autoLogin()) return null;
1563
- const { data: r } = await this.req.get("event/unlimit-qrcode-scene", Bn, {
1564
- ...n,
1572
+ const { data: n } = await this.req.get("event/unlimit-qrcode-scene", Jn, {
1573
+ ...r,
1565
1574
  params: { params: t }
1566
1575
  });
1567
- return r?.scene ?? null;
1576
+ return (n == null ? void 0 : n.scene) ?? null;
1568
1577
  }
1569
1578
  /**
1570
1579
  * 根据小程序码携带 scene 值,获取对应的前端所需参数
@@ -1573,35 +1582,35 @@ class Ur {
1573
1582
  *
1574
1583
  * @param scene - 小程序码 scene 值
1575
1584
  */
1576
- async getParamsByQrcodeScene(t, n) {
1577
- const { data: r } = await this.req.get("event/params-by-qrcode-scene", Mn, {
1578
- ...n,
1585
+ async getParamsByQrcodeScene(t, r) {
1586
+ const { data: n } = await this.req.get("event/params-by-qrcode-scene", Kn, {
1587
+ ...r,
1579
1588
  params: { scene: t }
1580
1589
  });
1581
- return r?.params ?? null;
1590
+ return (n == null ? void 0 : n.params) ?? null;
1582
1591
  }
1583
1592
  /**
1584
1593
  * 生成不限制的带参数的小程序码(dataURI 格式的小程序码图片)
1585
1594
  *
1586
1595
  * https://kdocs.cn/l/ckWFDcOsYEUA?linkname=Rvmoq8iIy0
1587
1596
  */
1588
- async generateUnlimitQrcode(t, n) {
1597
+ async generateUnlimitQrcode(t, r) {
1589
1598
  if (!await this.token.autoLogin()) return null;
1590
- const { data: r } = await this.req.post(
1599
+ const { data: n } = await this.req.post(
1591
1600
  "event/unlimit-qrcode",
1592
1601
  c(t),
1593
- Qn,
1594
- n
1602
+ Hn,
1603
+ r
1595
1604
  );
1596
- return r?.img ?? null;
1605
+ return (n == null ? void 0 : n.img) ?? null;
1597
1606
  }
1598
1607
  }
1599
- const Kn = {
1608
+ const zn = {
1600
1609
  /** 所有人均可以发帖 */
1601
1610
  All: "all",
1602
1611
  /** 指定用户可发帖 */
1603
1612
  Limit: "limit"
1604
- }, Hn = e.string().enum(Kn).lock(), zn = {
1613
+ }, Zn = e.string().enum(zn).lock(), Wn = {
1605
1614
  /** 待审核(仅自己可见) */
1606
1615
  Pending: "pending",
1607
1616
  /** 审核通过 */
@@ -1610,14 +1619,14 @@ const Kn = {
1610
1619
  Failed: "failed",
1611
1620
  /** 嫌疑(仅自己可见) */
1612
1621
  Suspect: "suspect"
1613
- }, ie = e.string().enum(zn).lock(), Jn = {
1622
+ }, ae = e.string().enum(Wn).lock(), Xn = {
1614
1623
  /** 系统通知 */
1615
1624
  System: "system",
1616
1625
  /** 评论我的 */
1617
1626
  Comment: "comment",
1618
1627
  /** 点赞通知 */
1619
1628
  Like: "like"
1620
- }, Fr = e.string().enum(Jn).lock(), g = {
1629
+ }, Ar = e.string().enum(Xn).lock(), p = {
1621
1630
  /** 系统通知 */
1622
1631
  System: "system",
1623
1632
  /** 帖子被置顶 */
@@ -1642,24 +1651,24 @@ const Kn = {
1642
1651
  ReplyLiked: "reply_liked",
1643
1652
  /** 回复被删除 */
1644
1653
  ReplyDeleted: "reply_deleted"
1645
- }, Zn = e.string().enum(g).lock(), oe = e.object({
1654
+ }, Yn = e.string().enum(p).lock(), se = e.object({
1646
1655
  forum_id: e.number(),
1647
1656
  icon_url: e.string(),
1648
1657
  name: e.string(),
1649
1658
  tags: e.array(e.string()),
1650
1659
  sort: e.number(),
1651
- mode: Hn,
1660
+ mode: Zn,
1652
1661
  member_ids: e.array(e.number())
1653
- }).lock(), G = e.object({
1662
+ }).lock(), A = e.object({
1654
1663
  topic_id: e.number(),
1655
1664
  cover_url: e.string(),
1656
1665
  name: e.string(),
1657
1666
  description: e.string(),
1658
1667
  tags: e.array(e.string()),
1659
1668
  post_num: e.number()
1660
- }).lock(), A = e.object({
1669
+ }).lock(), N = e.object({
1661
1670
  post_id: e.number(),
1662
- forum: oe,
1671
+ forum: se,
1663
1672
  posted_by: e.string(),
1664
1673
  nickname: e.string(),
1665
1674
  avatar_url: e.string(),
@@ -1671,15 +1680,15 @@ const Kn = {
1671
1680
  comments_num: e.number(),
1672
1681
  liked: e.bool(),
1673
1682
  image_urls: e.array(e.string()),
1674
- topics: e.array(G),
1683
+ topics: e.array(A),
1675
1684
  event_ids: e.array(e.number()),
1676
1685
  is_pinned: e.bool(),
1677
1686
  is_highlighted: e.bool(),
1678
- status: ie,
1687
+ status: ae,
1679
1688
  create_time: e.number()
1680
- }).lock(), se = e.object({
1689
+ }).lock(), ce = e.object({
1681
1690
  err_msg: e.string().optional()
1682
- }).lock(), Xn = e.object({
1691
+ }).lock(), er = e.object({
1683
1692
  reply_id: e.number(),
1684
1693
  reply_content: e.string().optional(),
1685
1694
  replied_by: e.string(),
@@ -1698,7 +1707,7 @@ const Kn = {
1698
1707
  content: e.string(),
1699
1708
  like_num: e.number(),
1700
1709
  liked: e.bool(),
1701
- reply_to: Xn,
1710
+ reply_to: er,
1702
1711
  create_time: e.number()
1703
1712
  }).lock(), v = e.object({
1704
1713
  comment_id: e.number(),
@@ -1718,24 +1727,24 @@ const Kn = {
1718
1727
  liked: e.bool(),
1719
1728
  image_url: e.string(),
1720
1729
  create_time: e.number(),
1721
- status: ie,
1730
+ status: ae,
1722
1731
  replies: e.array(j).optional()
1723
- }).lock(), Yn = e.object({
1732
+ }).lock(), tr = e.object({
1724
1733
  image_url: e.string(),
1725
1734
  upload_url: e.string(),
1726
1735
  existed: e.bool()
1727
- }).lock(), y = e.object({
1736
+ }).lock(), h = e.object({
1728
1737
  notification_id: e.string(),
1729
- notification_type: Zn,
1738
+ notification_type: Yn,
1730
1739
  is_read: e.bool(),
1731
1740
  create_time: e.number(),
1732
1741
  origin_user_id: e.string(),
1733
1742
  origin_user_name: e.string(),
1734
1743
  origin_user_avatar_url: e.string()
1735
- }).lock(), Wn = e.object({
1744
+ }).lock(), nr = e.object({
1736
1745
  system_message_subject: e.string(),
1737
1746
  system_message_content: e.string()
1738
- }).lock(), N = e.object({
1747
+ }).lock(), O = e.object({
1739
1748
  post_id: e.number(),
1740
1749
  post_subject: e.string(),
1741
1750
  post_summary: e.string(),
@@ -1743,84 +1752,84 @@ const Kn = {
1743
1752
  }).lock(), T = e.object({
1744
1753
  comment_id: e.number(),
1745
1754
  comment_content: e.string()
1746
- }).lock(), O = e.object({
1755
+ }).lock(), B = e.object({
1747
1756
  reply_id: e.number(),
1748
1757
  reply_content: e.string()
1749
- }).lock(), er = e.object({
1750
- ...y.shape,
1751
- ...Wn.shape,
1752
- notification_type: e.string().enum(g.System)
1753
- }), tr = e.object({
1754
- ...y.shape,
1755
- ...N.shape,
1758
+ }).lock(), rr = e.object({
1759
+ ...h.shape,
1760
+ ...nr.shape,
1761
+ notification_type: e.string().enum(p.System)
1762
+ }), ir = e.object({
1763
+ ...h.shape,
1764
+ ...O.shape,
1756
1765
  notification_type: e.string().enum(
1757
- g.PostPinned,
1758
- g.PostHighlighted,
1759
- g.PostDeleted,
1760
- g.PostLiked
1766
+ p.PostPinned,
1767
+ p.PostHighlighted,
1768
+ p.PostDeleted,
1769
+ p.PostLiked
1761
1770
  )
1762
- }), nr = e.object({
1763
- ...y.shape,
1764
- ...N.shape,
1765
- ...T.shape,
1766
- notification_type: e.string().enum(g.PostCommented)
1767
- }), rr = e.object({
1768
- ...y.shape,
1769
- ...T.shape,
1771
+ }), or = e.object({
1772
+ ...h.shape,
1770
1773
  ...O.shape,
1771
- notification_type: e.string().enum(g.CommentReplied)
1774
+ ...T.shape,
1775
+ notification_type: e.string().enum(p.PostCommented)
1772
1776
  }), ar = e.object({
1773
- ...y.shape,
1777
+ ...h.shape,
1778
+ ...T.shape,
1779
+ ...B.shape,
1780
+ notification_type: e.string().enum(p.CommentReplied)
1781
+ }), sr = e.object({
1782
+ ...h.shape,
1774
1783
  ...T.shape,
1775
- ...N.shape,
1776
- notification_type: e.string().enum(g.CommentLiked, g.CommentDeleted)
1777
- }), ir = e.object({
1778
- ...y.shape,
1779
1784
  ...O.shape,
1780
- notification_type: e.string().enum(g.ReplyReplied),
1785
+ notification_type: e.string().enum(p.CommentLiked, p.CommentDeleted)
1786
+ }), cr = e.object({
1787
+ ...h.shape,
1788
+ ...B.shape,
1789
+ notification_type: e.string().enum(p.ReplyReplied),
1781
1790
  comment_id: e.number(),
1782
1791
  reply_to_reply_id: e.number(),
1783
1792
  reply_to_reply_content: e.string()
1784
- }), or = e.object({
1785
- ...y.shape,
1786
- ...O.shape,
1793
+ }), ur = e.object({
1794
+ ...h.shape,
1795
+ ...B.shape,
1787
1796
  ...T.shape,
1788
- notification_type: e.string().enum(g.ReplyLiked, g.ReplyDeleted)
1789
- }), sr = e.union(
1790
- er,
1791
- tr,
1792
- nr,
1797
+ notification_type: e.string().enum(p.ReplyLiked, p.ReplyDeleted)
1798
+ }), lr = e.union(
1793
1799
  rr,
1794
- ar,
1795
1800
  ir,
1796
- or
1797
- ).satisfies().lock(), cr = s({ forums: e.array(oe) }), ur = s({ topics: e.array(G) }), lr = s({ topic: G }), mr = s({ post: A }), z = s({
1798
- posts: e.array(A),
1801
+ or,
1802
+ ar,
1803
+ sr,
1804
+ cr,
1805
+ ur
1806
+ ).satisfies().lock(), mr = s({ forums: e.array(se) }), dr = s({ topics: e.array(A) }), gr = s({ topic: A }), pr = s({ post: N }), z = s({
1807
+ posts: e.array(N),
1799
1808
  next_token: e.string().optional()
1800
- }), dr = s({ post: A, antispam: se }), gr = s({
1809
+ }), _r = s({ post: N, antispam: ce }), br = s({
1801
1810
  replies: e.array(j),
1802
1811
  next_token: e.string().optional()
1803
- }), pr = s({ reply: j }), _r = s({
1812
+ }), yr = s({ reply: j }), hr = s({
1804
1813
  reply: j.clone().optional(),
1805
- antispam: se.clone().optional()
1806
- }), br = s({ comment: v }), yr = s({
1814
+ antispam: ce.clone().optional()
1815
+ }), fr = s({ comment: v }), wr = s({
1807
1816
  comments: e.array(v),
1808
1817
  next_token: e.string().optional()
1809
- }), fr = s({
1818
+ }), kr = s({
1810
1819
  comment: v.clone().optional(),
1811
1820
  antispam: v.clone().optional()
1812
- }), hr = e.guard(Yn), wr = s({
1813
- notifications: e.array(sr),
1821
+ }), vr = e.guard(tr), Cr = s({
1822
+ notifications: e.array(lr),
1814
1823
  next_token: e.string().optional()
1815
- }), kr = s({
1824
+ }), Vr = s({
1816
1825
  system: e.number(),
1817
1826
  comment: e.number(),
1818
1827
  like: e.number()
1819
1828
  });
1820
- class Dr {
1821
- token;
1822
- req;
1829
+ class Nr {
1823
1830
  constructor(t) {
1831
+ m(this, "token");
1832
+ m(this, "req");
1824
1833
  this.token = t, this.req = t.req;
1825
1834
  }
1826
1835
  /**
@@ -1829,8 +1838,8 @@ class Dr {
1829
1838
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=QaqUa2K0z0
1830
1839
  */
1831
1840
  async getForums(t) {
1832
- const { data: n } = await this.req.get("community/forums", cr, t);
1833
- return n?.forums || [];
1841
+ const { data: r } = await this.req.get("community/forums", mr, t);
1842
+ return (r == null ? void 0 : r.forums) || [];
1834
1843
  }
1835
1844
  /**
1836
1845
  * 获取社区话题列表,仅返回启用状态的话题
@@ -1838,34 +1847,34 @@ class Dr {
1838
1847
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=mIwpymAQom
1839
1848
  */
1840
1849
  async getTopics(t) {
1841
- const { data: n } = await this.req.get("community/topics", ur, t);
1842
- return n?.topics || [];
1850
+ const { data: r } = await this.req.get("community/topics", dr, t);
1851
+ return (r == null ? void 0 : r.topics) || [];
1843
1852
  }
1844
1853
  /**
1845
1854
  * 根据话题 ID 获取社区话题信息
1846
1855
  *
1847
1856
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=Jvw7xMK31K
1848
1857
  */
1849
- async getTopic(t, n) {
1850
- const { data: r, code: a } = await this.req.get("community/topic", lr, {
1851
- ...n,
1858
+ async getTopic(t, r) {
1859
+ const { data: n, code: i } = await this.req.get("community/topic", gr, {
1860
+ ...r,
1852
1861
  params: { topic_id: t }
1853
1862
  });
1854
- return r?.topic ?? { error: a };
1863
+ return (n == null ? void 0 : n.topic) ?? { error: i };
1855
1864
  }
1856
1865
  /**
1857
1866
  * 获取社区帖子列表
1858
1867
  *
1859
1868
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=XKI9lDVrPq
1860
1869
  */
1861
- async getPosts(t, n) {
1862
- const { data: r, code: a, message: i } = await this.req.get("community/posts", z, {
1863
- ...n,
1870
+ async getPosts(t, r) {
1871
+ const { data: n, code: i, message: o } = await this.req.get("community/posts", z, {
1872
+ ...r,
1864
1873
  params: c(t)
1865
1874
  });
1866
- return r ?? {
1867
- message: i,
1868
- error: a
1875
+ return n ?? {
1876
+ message: o,
1877
+ error: i
1869
1878
  };
1870
1879
  }
1871
1880
  /**
@@ -1873,14 +1882,14 @@ class Dr {
1873
1882
  *
1874
1883
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=yXubbZuDlC
1875
1884
  */
1876
- async getPinnedPosts(t, n, r, a) {
1877
- const { data: i, code: d, message: m } = await this.req.get("community/pinned-posts", z, {
1878
- ...a,
1879
- params: c({ forum_id: t, max_results: n, next_token: r })
1885
+ async getPinnedPosts(t, r, n, i) {
1886
+ const { data: o, code: g, message: d } = await this.req.get("community/pinned-posts", z, {
1887
+ ...i,
1888
+ params: c({ forum_id: t, max_results: r, next_token: n })
1880
1889
  });
1881
- return i ?? {
1882
- message: m,
1883
- error: d
1890
+ return o ?? {
1891
+ message: d,
1892
+ error: g
1884
1893
  };
1885
1894
  }
1886
1895
  /**
@@ -1888,14 +1897,14 @@ class Dr {
1888
1897
  *
1889
1898
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=hj1AZy5rcP
1890
1899
  */
1891
- async getPost(t, n) {
1892
- const { data: r, code: a, message: i } = await this.req.get("community/post", mr, {
1893
- ...n,
1900
+ async getPost(t, r) {
1901
+ const { data: n, code: i, message: o } = await this.req.get("community/post", pr, {
1902
+ ...r,
1894
1903
  params: { post_id: t }
1895
1904
  });
1896
- return r?.post ?? {
1897
- message: i,
1898
- error: a
1905
+ return (n == null ? void 0 : n.post) ?? {
1906
+ message: o,
1907
+ error: i
1899
1908
  };
1900
1909
  }
1901
1910
  /**
@@ -1903,16 +1912,16 @@ class Dr {
1903
1912
  *
1904
1913
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=M5okHBuaVk
1905
1914
  */
1906
- async post(t, n) {
1907
- const { data: r, code: a, message: i } = await this.req.post(
1915
+ async post(t, r) {
1916
+ const { data: n, code: i, message: o } = await this.req.post(
1908
1917
  "community/post",
1909
1918
  c(t),
1910
- dr,
1911
- n
1919
+ _r,
1920
+ r
1912
1921
  );
1913
- return r ?? {
1914
- message: i,
1915
- error: a
1922
+ return n ?? {
1923
+ message: o,
1924
+ error: i
1916
1925
  };
1917
1926
  }
1918
1927
  /**
@@ -1920,14 +1929,14 @@ class Dr {
1920
1929
  *
1921
1930
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=djKbX7lFdp
1922
1931
  */
1923
- async getComments(t, n) {
1924
- const { data: r, code: a, message: i } = await this.req.get("community/comments", yr, {
1925
- ...n,
1932
+ async getComments(t, r) {
1933
+ const { data: n, code: i, message: o } = await this.req.get("community/comments", wr, {
1934
+ ...r,
1926
1935
  params: c(t)
1927
1936
  });
1928
- return r ?? {
1929
- message: i,
1930
- error: a
1937
+ return n ?? {
1938
+ message: o,
1939
+ error: i
1931
1940
  };
1932
1941
  }
1933
1942
  /**
@@ -1935,14 +1944,14 @@ class Dr {
1935
1944
  *
1936
1945
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=RIc7oxVGae
1937
1946
  */
1938
- async getComment(t, n) {
1939
- const { data: r, code: a, message: i } = await this.req.get("community/comment", br, {
1940
- ...n,
1947
+ async getComment(t, r) {
1948
+ const { data: n, code: i, message: o } = await this.req.get("community/comment", fr, {
1949
+ ...r,
1941
1950
  params: { comment_id: t }
1942
1951
  });
1943
- return r?.comment ?? {
1944
- message: i,
1945
- error: a
1952
+ return (n == null ? void 0 : n.comment) ?? {
1953
+ message: o,
1954
+ error: i
1946
1955
  };
1947
1956
  }
1948
1957
  /**
@@ -1950,17 +1959,17 @@ class Dr {
1950
1959
  *
1951
1960
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=Nv7lk0nTmr
1952
1961
  */
1953
- async comment(t, n) {
1962
+ async comment(t, r) {
1954
1963
  await this.token.autoLogin();
1955
- const { data: r, code: a, message: i } = await this.req.post(
1964
+ const { data: n, code: i, message: o } = await this.req.post(
1956
1965
  "community/comment",
1957
1966
  c(t),
1958
- fr,
1959
- n
1967
+ kr,
1968
+ r
1960
1969
  );
1961
- return r ?? {
1962
- message: i,
1963
- error: a
1970
+ return n ?? {
1971
+ message: o,
1972
+ error: i
1964
1973
  };
1965
1974
  }
1966
1975
  /**
@@ -1968,14 +1977,14 @@ class Dr {
1968
1977
  *
1969
1978
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=sVKBbY83MY
1970
1979
  */
1971
- async getReplies(t, n) {
1972
- const { data: r } = await this.req.get("community/replies", gr, {
1973
- ...n,
1980
+ async getReplies(t, r) {
1981
+ const { data: n } = await this.req.get("community/replies", br, {
1982
+ ...r,
1974
1983
  params: c({ max_results: 20, ...t })
1975
1984
  });
1976
1985
  return {
1977
- replies: r?.replies || [],
1978
- next_token: r?.next_token || ""
1986
+ replies: (n == null ? void 0 : n.replies) || [],
1987
+ next_token: (n == null ? void 0 : n.next_token) || ""
1979
1988
  };
1980
1989
  }
1981
1990
  /**
@@ -1983,14 +1992,14 @@ class Dr {
1983
1992
  *
1984
1993
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=kxhcSXD3MG
1985
1994
  */
1986
- async getReply(t, n) {
1987
- const { data: r, code: a, message: i } = await this.req.get("community/reply", pr, {
1988
- ...n,
1995
+ async getReply(t, r) {
1996
+ const { data: n, code: i, message: o } = await this.req.get("community/reply", yr, {
1997
+ ...r,
1989
1998
  params: { reply_id: t }
1990
1999
  });
1991
- return r?.reply ?? {
1992
- message: i,
1993
- error: a
2000
+ return (n == null ? void 0 : n.reply) ?? {
2001
+ message: o,
2002
+ error: i
1994
2003
  };
1995
2004
  }
1996
2005
  /**
@@ -1998,17 +2007,17 @@ class Dr {
1998
2007
  *
1999
2008
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=KA8WpTX2pg
2000
2009
  */
2001
- async reply(t, n) {
2010
+ async reply(t, r) {
2002
2011
  await this.token.autoLogin();
2003
- const { data: r, code: a, message: i } = await this.req.post(
2012
+ const { data: n, code: i, message: o } = await this.req.post(
2004
2013
  "community/reply",
2005
2014
  c(t),
2006
- _r,
2007
- n
2015
+ hr,
2016
+ r
2008
2017
  );
2009
- return r ?? {
2010
- message: i,
2011
- error: a
2018
+ return n ?? {
2019
+ message: o,
2020
+ error: i
2012
2021
  };
2013
2022
  }
2014
2023
  /**
@@ -2016,17 +2025,17 @@ class Dr {
2016
2025
  *
2017
2026
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=CR3m6PyXfZ
2018
2027
  */
2019
- async like(t, n) {
2028
+ async like(t, r) {
2020
2029
  await this.token.autoLogin();
2021
- const { ok: r, code: a, message: i } = await this.req.post(
2030
+ const { ok: n, code: i, message: o } = await this.req.post(
2022
2031
  "community/like",
2023
2032
  { ...t, action: "like" },
2024
2033
  null,
2025
- n
2034
+ r
2026
2035
  );
2027
- return r || {
2028
- message: i,
2029
- error: a
2036
+ return n || {
2037
+ message: o,
2038
+ error: i
2030
2039
  };
2031
2040
  }
2032
2041
  /**
@@ -2034,17 +2043,17 @@ class Dr {
2034
2043
  *
2035
2044
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=CR3m6PyXfZ
2036
2045
  */
2037
- async unlike(t, n) {
2046
+ async unlike(t, r) {
2038
2047
  await this.token.autoLogin();
2039
- const { ok: r, code: a, message: i } = await this.req.post(
2048
+ const { ok: n, code: i, message: o } = await this.req.post(
2040
2049
  "community/like",
2041
2050
  { ...t, action: "unlike" },
2042
2051
  null,
2043
- n
2052
+ r
2044
2053
  );
2045
- return r || {
2046
- message: i,
2047
- error: a
2054
+ return n || {
2055
+ message: o,
2056
+ error: i
2048
2057
  };
2049
2058
  }
2050
2059
  /**
@@ -2052,13 +2061,13 @@ class Dr {
2052
2061
  *
2053
2062
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=dWWhpoShxZ
2054
2063
  */
2055
- async getMediaPresignedUrl(t, n) {
2064
+ async getMediaPresignedUrl(t, r) {
2056
2065
  await this.token.autoLogin();
2057
- const { data: r } = await this.req.get("community/media-presign-url", hr, {
2058
- ...n,
2066
+ const { data: n } = await this.req.get("community/media-presign-url", vr, {
2067
+ ...r,
2059
2068
  params: t
2060
2069
  });
2061
- return r;
2070
+ return n;
2062
2071
  }
2063
2072
  /**
2064
2073
  * 获取用户社区通知
@@ -2067,15 +2076,15 @@ class Dr {
2067
2076
  *
2068
2077
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=W5lceDgbBG
2069
2078
  */
2070
- async getNotifications(t, n) {
2079
+ async getNotifications(t, r) {
2071
2080
  await this.token.autoLogin();
2072
- const { data: r } = await this.req.get("community/notifications", wr, {
2073
- ...n,
2081
+ const { data: n } = await this.req.get("community/notifications", Cr, {
2082
+ ...r,
2074
2083
  params: c({ max_results: 20, ...t })
2075
2084
  });
2076
2085
  return {
2077
- notifications: r?.notifications || [],
2078
- next_token: r?.next_token || ""
2086
+ notifications: (n == null ? void 0 : n.notifications) || [],
2087
+ next_token: (n == null ? void 0 : n.next_token) || ""
2079
2088
  };
2080
2089
  }
2081
2090
  /**
@@ -2085,38 +2094,35 @@ class Dr {
2085
2094
  */
2086
2095
  async getUnreadNotificationsCount(t) {
2087
2096
  if (!await this.token.autoLogin()) return null;
2088
- const { data: n } = await this.req.get(
2097
+ const { data: r } = await this.req.get(
2089
2098
  "community/unread-notifications-count",
2090
- kr,
2099
+ Vr,
2091
2100
  t
2092
2101
  );
2093
- return n;
2102
+ return r;
2094
2103
  }
2095
2104
  /**
2096
2105
  * 社区用户将通知标为已读
2097
2106
  *
2098
2107
  * https://kdocs.cn/l/cbggfJodHLIz?linkname=TCJQxnOjJe
2099
2108
  */
2100
- async clearUnreadNotifications(t, n) {
2109
+ async clearUnreadNotifications(t, r) {
2101
2110
  if (!await this.token.autoLogin()) return !1;
2102
- const { ok: r } = await this.req.post("community/clear-unread-notifications", { category: t }, null, n);
2103
- return r;
2111
+ const { ok: n } = await this.req.post("community/clear-unread-notifications", { category: t }, null, r);
2112
+ return n;
2104
2113
  }
2105
2114
  }
2106
- const vr = s({
2115
+ const Rr = s({
2107
2116
  nonce_str: e.string(),
2108
2117
  timestamp: e.number(),
2109
2118
  signature: e.string()
2110
2119
  });
2111
- var Cr = /* @__PURE__ */ ((o) => (o.RedirectUriDisMatch = "10003", o.AppidError = "10016", o.AuthorizationError = "10015", o.NoRightForScope = "10005", o.Frequently = "10009", o.AppBanded = "10004", o.ShouldFollow = "10006", o.ScopeNull = "10010", o.RedirectUriNull = "10011", o.AppidNull = "10012", o.StateNull = "10013", o))(Cr || {});
2112
- function L(o) {
2113
- return C(o, "open_id", "union_id", "weixin_token");
2120
+ var jr = /* @__PURE__ */ ((a) => (a.RedirectUriDisMatch = "10003", a.AppidError = "10016", a.AuthorizationError = "10015", a.NoRightForScope = "10005", a.Frequently = "10009", a.AppBanded = "10004", a.ShouldFollow = "10006", a.ScopeNull = "10010", a.RedirectUriNull = "10011", a.AppidNull = "10012", a.StateNull = "10013", a))(jr || {});
2121
+ function E(a) {
2122
+ return C(a, "open_id", "union_id", "weixin_token");
2114
2123
  }
2115
- const J = "wx_login_cache";
2116
- class Ir {
2117
- token;
2118
- $appid;
2119
- req;
2124
+ const Z = "wx_login_cache";
2125
+ class Or {
2120
2126
  /**
2121
2127
  * 创建微信相关功能接口
2122
2128
  *
@@ -2130,8 +2136,11 @@ class Ir {
2130
2136
  *
2131
2137
  * https://developers.weixin.qq.com/miniprogram/dev/api/open-api/account-info/wx.getAccountInfoSync.html
2132
2138
  */
2133
- constructor(t, n) {
2134
- this.token = t, this.req = t.req, this.$appid = n, this.getLoginCache();
2139
+ constructor(t, r) {
2140
+ m(this, "token");
2141
+ m(this, "$appid");
2142
+ m(this, "req");
2143
+ this.token = t, this.req = t.req, this.$appid = r, this.getLoginCache();
2135
2144
  }
2136
2145
  get appid() {
2137
2146
  return this.$appid;
@@ -2144,11 +2153,11 @@ class Ir {
2144
2153
  * 也可以直接调用 login 方法,并传入 weixin code 的读取函数
2145
2154
  */
2146
2155
  async getLoginCache() {
2147
- const t = this.token.storage.get(J);
2156
+ const t = this.token.storage.get(Z);
2148
2157
  if (!t)
2149
2158
  return null;
2150
- const n = pe(t);
2151
- return L(n) ? (this.token.weixinToken = n.weixin_token, await this.token.autoLogin(), n) : null;
2159
+ const r = ye(t);
2160
+ return E(r) ? (this.token.weixinToken = r.weixin_token, await this.token.autoLogin(), r) : null;
2152
2161
  }
2153
2162
  /**
2154
2163
  * 小程序页面微信静默登录,获取 weixinToken / open_id / union_id。
@@ -2168,20 +2177,20 @@ class Ir {
2168
2177
  * https://kdocs.cn/l/cf2mO2uRLqh9?linkname=GwIZ0givCb
2169
2178
  */
2170
2179
  async login(t) {
2171
- if (!b.wx)
2180
+ if (!y.wx)
2172
2181
  throw new Error("当前环境非微信小程序");
2173
- const n = await this.getLoginCache();
2174
- if (n)
2175
- return n;
2176
- const r = await ye(), { data: a, code: i, message: d } = await this.req.post(
2182
+ const r = await this.getLoginCache();
2183
+ if (r)
2184
+ return r;
2185
+ const n = await we(), { data: i, code: o, message: g } = await this.req.post(
2177
2186
  "weixin/login",
2178
- { code: r, appid: this.appid },
2179
- L,
2187
+ { code: n, appid: this.appid },
2188
+ E,
2180
2189
  { ...t, message: !1 }
2181
2190
  );
2182
- return a && (this.token.weixinToken = a.weixin_token, this.token.storage.set(J, JSON.stringify(a))), a ?? {
2183
- message: d,
2184
- error: i
2191
+ return i && (this.token.weixinToken = i.weixin_token, this.token.storage.set(Z, JSON.stringify(i))), i ?? {
2192
+ message: g,
2193
+ error: o
2185
2194
  };
2186
2195
  }
2187
2196
  /**
@@ -2200,29 +2209,29 @@ class Ir {
2200
2209
  * - snsapi_base 不弹出授权页面,用户无感知,只能获取用户 openid,如果需要获取 union_id 则需要 snsapi_userinfo
2201
2210
  * - snsapi_userinfo 【默认】弹出授权页面,可拿到 openid、union_id、昵称、头像等信息,但用户也可能会拒绝授权
2202
2211
  */
2203
- async webLogin(t = "snsapi_userinfo", n) {
2204
- const r = E("code"), a = Date.now(), i = +E("state");
2205
- if (!r || !i || i < a - 1e3 * 60 * 5 || i > a) {
2206
- const ue = B(["code", "state"]);
2212
+ async webLogin(t = "snsapi_userinfo", r) {
2213
+ const n = $("code"), i = Date.now(), o = +$("state");
2214
+ if (!n || !o || o < i - 1e3 * 60 * 5 || o > i) {
2215
+ const le = Q(["code", "state"]);
2207
2216
  location.replace(
2208
- `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${this.appid}&redirect_uri=${encodeURIComponent(ue)}&response_type=code&scope=${t}&state=${a}#wechat_redirect`
2217
+ `https://open.weixin.qq.com/connect/oauth2/authorize?appid=${this.appid}&redirect_uri=${encodeURIComponent(le)}&response_type=code&scope=${t}&state=${i}#wechat_redirect`
2209
2218
  );
2210
2219
  return;
2211
2220
  }
2212
- if (/^100\d{2}$/.test(r))
2221
+ if (/^100\d{2}$/.test(n))
2213
2222
  return {
2214
- message: "Error: " + r,
2215
- error: r
2223
+ message: "Error: " + n,
2224
+ error: n
2216
2225
  };
2217
- const d = B(["code", "state"]);
2218
- "replaceState" in history && history.replaceState({}, "", d);
2226
+ const g = Q(["code", "state"]);
2227
+ "replaceState" in history && history.replaceState({}, "", g);
2219
2228
  const {
2220
- data: m,
2229
+ data: d,
2221
2230
  code: f,
2222
- message: ce
2223
- } = await this.req.post("weixin/login", { code: r, appid: this.appid }, L, n);
2224
- return m && (this.token.weixinToken = m.weixin_token, await this.token.autoLogin()), m ?? {
2225
- message: ce,
2231
+ message: ue
2232
+ } = await this.req.post("weixin/login", { code: n, appid: this.appid }, E, r);
2233
+ return d && (this.token.weixinToken = d.weixin_token, await this.token.autoLogin()), d ?? {
2234
+ message: ue,
2226
2235
  error: f
2227
2236
  };
2228
2237
  }
@@ -2238,14 +2247,14 @@ class Ir {
2238
2247
  * @param weixinToken 调用 login 后,得到的 weixinToken,如果 weixinToken 为空则跳过不处理
2239
2248
  * @param gameCode 从游戏内跳转至小程序时,通过请求参数 query 携带的 game_code,如果值为空则跳过不处理
2240
2249
  */
2241
- async linkPlayer(t, n, r) {
2242
- if (!t || !n)
2250
+ async linkPlayer(t, r, n) {
2251
+ if (!t || !r)
2243
2252
  return !1;
2244
- const { ok: a } = await this.req.post("weixin/link-player", { weixin_token: t, game_code: n }, null, {
2245
- ...r,
2253
+ const { ok: i } = await this.req.post("weixin/link-player", { weixin_token: t, game_code: r }, null, {
2254
+ ...n,
2246
2255
  message: !1
2247
2256
  });
2248
- return a;
2257
+ return i;
2249
2258
  }
2250
2259
  /**
2251
2260
  * 获取集成 JSSDK 所需的签名信息
@@ -2253,162 +2262,162 @@ class Ir {
2253
2262
  * https://kdocs.cn/l/cf2mO2uRLqh9?linkname=CuWOqxr9Ue
2254
2263
  */
2255
2264
  async getJSSDKConfig(t) {
2256
- const { data: n } = await this.req.get("weixin/offiaccount/jssdk-sign", vr, {
2265
+ const { data: r } = await this.req.get("weixin/offiaccount/jssdk-sign", Rr, {
2257
2266
  ...t,
2258
2267
  params: {
2259
2268
  appid: this.appid,
2260
2269
  url: location.href.split("#")[0]
2261
2270
  }
2262
2271
  });
2263
- return n ? {
2272
+ return r ? {
2264
2273
  appid: this.appid,
2265
- nonceStr: n.nonce_str,
2266
- timestamp: n.timestamp,
2267
- signature: n.signature
2274
+ nonceStr: r.nonce_str,
2275
+ timestamp: r.timestamp,
2276
+ signature: r.signature
2268
2277
  } : null;
2269
2278
  }
2270
2279
  }
2271
2280
  export {
2272
- se as AntispamValidator,
2273
- jr as AuthToken,
2274
- an as CashbackEngagementDataValidator,
2275
- on as ClaimActivationKeyEngagementDataValidator,
2276
- _ as ClaimRewardStatus,
2277
- $ as ClaimRewardStatusValidator,
2278
- Sn as ClaimedItemValidator,
2281
+ ce as AntispamValidator,
2282
+ Sr as AuthToken,
2283
+ cn as CashbackEngagementDataValidator,
2284
+ un as ClaimActivationKeyEngagementDataValidator,
2285
+ b as ClaimRewardStatus,
2286
+ U as ClaimRewardStatusValidator,
2287
+ $n as ClaimedItemValidator,
2279
2288
  Y as ClubAddressValidator,
2280
- qr as ClubApi,
2281
- W as ClubBenefitSummaryValidator,
2282
- De as ClubBenefitValidator,
2283
- Ve as ClubCreditChangeScene,
2284
- Re as ClubCreditChangeSceneValidator,
2285
- ve as ClubCreditChangeType,
2286
- Ce as ClubCreditChangeTypeValidator,
2287
- Fe as ClubCreditLogValidator,
2288
- xe as ClubGlobalConfigValidator,
2289
- je as ClubItemType,
2290
- Z as ClubItemTypeValidator,
2291
- Se as ClubPlayerValidator,
2292
- ee as ClubProductValidator,
2293
- Te as ClubRedemptionStatus,
2294
- qe as ClubRedemptionStatusValidator,
2295
- Ue as ClubUserCreditValidator,
2296
- $e as ClubUserProfileValidator,
2297
- Cn as CommentEngagementValidator,
2289
+ Er as ClubApi,
2290
+ ee as ClubBenefitSummaryValidator,
2291
+ Ae as ClubBenefitValidator,
2292
+ Te as ClubCreditChangeScene,
2293
+ qe as ClubCreditChangeSceneValidator,
2294
+ Re as ClubCreditChangeType,
2295
+ je as ClubCreditChangeTypeValidator,
2296
+ Ge as ClubCreditLogValidator,
2297
+ Ee as ClubGlobalConfigValidator,
2298
+ xe as ClubItemType,
2299
+ W as ClubItemTypeValidator,
2300
+ $e as ClubPlayerValidator,
2301
+ te as ClubProductValidator,
2302
+ Se as ClubRedemptionStatus,
2303
+ Le as ClubRedemptionStatusValidator,
2304
+ Ie as ClubUserCreditValidator,
2305
+ De as ClubUserProfileValidator,
2306
+ jn as CommentEngagementValidator,
2298
2307
  v as CommentValidator,
2299
- Dr as CommunityApi,
2300
- Ze as EngageAccountType,
2301
- Xe as EngageAccountTypeValidator,
2302
- xn as EngageResponseValidator,
2303
- Rn as EngageRewardValidator,
2304
- Ur as EventApi,
2305
- rn as EventConfigValidator,
2306
- gt as EventFeatureConfigOfCashbackValidator,
2307
- _t as EventFeatureConfigOfCheckInValidator,
2308
- yt as EventFeatureConfigOfClaimActivationKeyValidator,
2309
- ht as EventFeatureConfigOfClaimRewardsValidator,
2310
- kt as EventFeatureConfigOfCommentValidator,
2311
- Ct as EventFeatureConfigOfFollowValidator,
2312
- jt as EventFeatureConfigOfGiftCodeValidator,
2313
- qt as EventFeatureConfigOfInviteValidator,
2314
- St as EventFeatureConfigOfInvitedRegisterValidator,
2315
- Ft as EventFeatureConfigOfLotteryDrawValidator,
2316
- $t as EventFeatureConfigOfLotteryValidator,
2317
- It as EventFeatureConfigOfPreregisterValidator,
2318
- At as EventFeatureConfigOfQuestValidator,
2319
- Ot as EventFeatureConfigOfRegisterValidator,
2320
- Mt as EventFeatureConfigOfShareValidator,
2321
- Kt as EventFeatureConfigOfSubscribeValidator,
2322
- zt as EventFeatureConfigOfSurveyValidator,
2323
- Zt as EventFeatureConfigOfTeamValidator,
2324
- Wt as EventFeatureConfigOfVoteValidator,
2325
- nn as EventFeatureConfigValidator,
2326
- Ye as EventPeriodType,
2327
- We as EventPeriodTypeValidator,
2328
- F as EventRewardItemConfigValidator,
2329
- Ge as ExtraGameRewardValidator,
2330
- Ie as ExtraPhysicalShipmentValidator,
2331
- mt as FeatureRewardValidator,
2308
+ Nr as CommunityApi,
2309
+ Ye as EngageAccountType,
2310
+ et as EngageAccountTypeValidator,
2311
+ En as EngageResponseValidator,
2312
+ qn as EngageRewardValidator,
2313
+ Gr as EventApi,
2314
+ sn as EventConfigValidator,
2315
+ bt as EventFeatureConfigOfCashbackValidator,
2316
+ ht as EventFeatureConfigOfCheckInValidator,
2317
+ wt as EventFeatureConfigOfClaimActivationKeyValidator,
2318
+ vt as EventFeatureConfigOfClaimRewardsValidator,
2319
+ Vt as EventFeatureConfigOfCommentValidator,
2320
+ jt as EventFeatureConfigOfFollowValidator,
2321
+ xt as EventFeatureConfigOfGiftCodeValidator,
2322
+ Lt as EventFeatureConfigOfInviteValidator,
2323
+ $t as EventFeatureConfigOfInvitedRegisterValidator,
2324
+ Gt as EventFeatureConfigOfLotteryDrawValidator,
2325
+ Dt as EventFeatureConfigOfLotteryValidator,
2326
+ Nt as EventFeatureConfigOfPreregisterValidator,
2327
+ Bt as EventFeatureConfigOfQuestValidator,
2328
+ Mt as EventFeatureConfigOfRegisterValidator,
2329
+ Kt as EventFeatureConfigOfShareValidator,
2330
+ zt as EventFeatureConfigOfSubscribeValidator,
2331
+ Wt as EventFeatureConfigOfSurveyValidator,
2332
+ Yt as EventFeatureConfigOfTeamValidator,
2333
+ nn as EventFeatureConfigOfVoteValidator,
2334
+ an as EventFeatureConfigValidator,
2335
+ tt as EventPeriodType,
2336
+ nt as EventPeriodTypeValidator,
2337
+ D as EventRewardItemConfigValidator,
2338
+ Oe as ExtraGameRewardValidator,
2339
+ Ne as ExtraPhysicalShipmentValidator,
2340
+ pt as FeatureRewardValidator,
2332
2341
  u as FeatureType,
2333
- et as FeatureTypeValidator,
2334
- Kn as ForumMode,
2335
- Hn as ForumModeValidator,
2336
- oe as ForumValidator,
2342
+ rt as FeatureTypeValidator,
2343
+ zn as ForumMode,
2344
+ Zn as ForumModeValidator,
2345
+ se as ForumValidator,
2337
2346
  R as GamerItemType,
2338
- te as GamerItemTypeValidator,
2339
- we as Gender,
2340
- ke as GenderValidator,
2341
- sn as GiftCodeEngagementDataValidator,
2342
- cn as InviteEngagementDataValidator,
2343
- ct as LotteryDrawAction,
2344
- Pr as LotteryDrawActionValidator,
2345
- dn as LotteryDrawEngagementDataValidator,
2346
- un as LotteryEngagementDataValidator,
2347
+ ne as GamerItemTypeValidator,
2348
+ Ce as Gender,
2349
+ Ve as GenderValidator,
2350
+ ln as GiftCodeEngagementDataValidator,
2351
+ mn as InviteEngagementDataValidator,
2352
+ mt as LotteryDrawAction,
2353
+ Dr as LotteryDrawActionValidator,
2354
+ _n as LotteryDrawEngagementDataValidator,
2355
+ dn as LotteryEngagementDataValidator,
2347
2356
  k as LotteryTicketStatus,
2348
- Lr as LotteryTicketStatusValidator,
2349
- y as NotificationBaseValidator,
2350
- Jn as NotificationCategory,
2351
- Fr as NotificationCategoryValidator,
2352
- rr as NotificationCommentReplyValidator,
2353
- ar as NotificationCommentValidator,
2357
+ Ur as LotteryTicketStatusValidator,
2358
+ h as NotificationBaseValidator,
2359
+ Xn as NotificationCategory,
2360
+ Ar as NotificationCategoryValidator,
2361
+ ar as NotificationCommentReplyValidator,
2362
+ sr as NotificationCommentValidator,
2354
2363
  T as NotificationPayloadCommentValidator,
2355
- N as NotificationPayloadPostValidator,
2356
- O as NotificationPayloadReplyValidator,
2357
- Wn as NotificationPayloadSystemValidator,
2358
- nr as NotificationPostCommentValidator,
2359
- tr as NotificationPostValidator,
2360
- ir as NotificationReplyRepliedValidator,
2361
- or as NotificationReplyValidator,
2362
- er as NotificationSystemValidator,
2363
- g as NotificationType,
2364
- Zn as NotificationTypeValidator,
2365
- sr as NotificationValidator,
2366
- Pe as PlayerRoleCardValidator,
2364
+ O as NotificationPayloadPostValidator,
2365
+ B as NotificationPayloadReplyValidator,
2366
+ nr as NotificationPayloadSystemValidator,
2367
+ or as NotificationPostCommentValidator,
2368
+ ir as NotificationPostValidator,
2369
+ cr as NotificationReplyRepliedValidator,
2370
+ ur as NotificationReplyValidator,
2371
+ rr as NotificationSystemValidator,
2372
+ p as NotificationType,
2373
+ Yn as NotificationTypeValidator,
2374
+ lr as NotificationValidator,
2375
+ Fe as PlayerRoleCardValidator,
2367
2376
  X as PlayerRoleValidator,
2368
- zn as PostStatus,
2369
- ie as PostStatusValidator,
2370
- A as PostValidator,
2371
- gn as PreregisterEngagementDataValidator,
2372
- Yn as PresignedUrlResponseValidator,
2373
- pn as QuestEngagementDataValidator,
2374
- tt as QuestObjective,
2375
- re as QuestObjectiveValidator,
2376
- Tr as RedeemParamsValidator,
2377
- Ae as RedemptionValidator,
2378
- lt as RegularRewardValidator,
2379
- Xn as ReplyToValidator,
2377
+ Wn as PostStatus,
2378
+ ae as PostStatusValidator,
2379
+ N as PostValidator,
2380
+ bn as PreregisterEngagementDataValidator,
2381
+ tr as PresignedUrlResponseValidator,
2382
+ yn as QuestEngagementDataValidator,
2383
+ it as QuestObjective,
2384
+ ie as QuestObjectiveValidator,
2385
+ Lr as RedeemParamsValidator,
2386
+ Be as RedemptionValidator,
2387
+ gt as RegularRewardValidator,
2388
+ er as ReplyToValidator,
2380
2389
  j as ReplyValidator,
2381
- xr as RewardItemType,
2382
- ne as RewardItemTypeValidator,
2383
- at as RewardSource,
2384
- U as RewardSourceValidator,
2385
- p as RewardStatus,
2390
+ $r as RewardItemType,
2391
+ re as RewardItemTypeValidator,
2392
+ st as RewardSource,
2393
+ F as RewardSourceValidator,
2394
+ _ as RewardStatus,
2386
2395
  P as RewardStatusSuffix,
2387
- ae as RewardStatusSuffixValidator,
2388
- Sr as RewardStatusValidator,
2389
- Vn as RewardValidator,
2390
- Ee as RoleBaseInfoValidator,
2391
- Le as ServerBaseInfoValidator,
2392
- _n as ShareEngagementDataValidator,
2393
- yn as SurveyEngagementDataValidator,
2394
- st as TeamAction,
2395
- Er as TeamActionValidator,
2396
- hn as TeamEngagementDataValidator,
2397
- fn as TeamEngagementValidator,
2398
- $r as TeamMemberValidator,
2399
- it as TeamVisibility,
2400
- ot as TeamVisibilityValidator,
2401
- G as TopicValidator,
2402
- I as UserEngagementDataValidator,
2403
- jn as UserEngagementValidator,
2404
- qn as UserFeatureStatusValidator,
2405
- D as UserRewardValidator,
2406
- Tn as VerifyMobileResultValidator,
2407
- wn as VoteEngagementDataValidator,
2408
- nt as VoteOptionSource,
2409
- rt as VoteOptionSourceValidator,
2410
- Ir as WeixinApi,
2411
- bn as WeixinSubscribeEngagementDataValidator,
2412
- Cr as WeixinWebLoginErrorCode,
2413
- vr as isWeixinSignResponse
2396
+ oe as RewardStatusSuffixValidator,
2397
+ Pr as RewardStatusValidator,
2398
+ Tn as RewardValidator,
2399
+ Ue as RoleBaseInfoValidator,
2400
+ Pe as ServerBaseInfoValidator,
2401
+ hn as ShareEngagementDataValidator,
2402
+ wn as SurveyEngagementDataValidator,
2403
+ lt as TeamAction,
2404
+ Fr as TeamActionValidator,
2405
+ vn as TeamEngagementDataValidator,
2406
+ kn as TeamEngagementValidator,
2407
+ Ir as TeamMemberValidator,
2408
+ ct as TeamVisibility,
2409
+ ut as TeamVisibilityValidator,
2410
+ A as TopicValidator,
2411
+ G as UserEngagementDataValidator,
2412
+ xn as UserEngagementValidator,
2413
+ Ln as UserFeatureStatusValidator,
2414
+ I as UserRewardValidator,
2415
+ Sn as VerifyMobileResultValidator,
2416
+ Cn as VoteEngagementDataValidator,
2417
+ ot as VoteOptionSource,
2418
+ at as VoteOptionSourceValidator,
2419
+ Or as WeixinApi,
2420
+ fn as WeixinSubscribeEngagementDataValidator,
2421
+ jr as WeixinWebLoginErrorCode,
2422
+ Rr as isWeixinSignResponse
2414
2423
  };