@seayoo-web/gamer-api 4.2.2 → 4.3.2

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,22 +1,22 @@
1
1
  import { isComboWebView as e } from "@seayoo-web/combo-webview";
2
- import { isPlainObject as t, localStorageHelper as n, omitFields as r, parseJSON as i, pruneObject as a, pruneURL as o, queryString as s, removePara as ee, supportWindow as te, supportWx as c, useConsole as ne, usePromise as re, weixinStorageHelper as ie } from "@seayoo-web/utils";
3
- import { objectGuard as l, v as u } from "@seayoo-web/validator";
2
+ import { isPlainObject as t, localStorageHelper as n, omitFields as r, parseJSON as i, pruneObject as a, pruneURL as o, queryString as s, removePara as c, supportWindow as l, supportWx as u, useConsole as ee, usePromise as te, weixinStorageHelper as ne } from "@seayoo-web/utils";
3
+ import { objectGuard as d, v as f } from "@seayoo-web/validator";
4
4
  //#region src/token.guards.ts
5
- function ae(e) {
5
+ function re(e) {
6
6
  return t(e, "gamer_token") && typeof e.gamer_token == "string";
7
7
  }
8
- function oe(e) {
8
+ function ie(e) {
9
9
  return t(e, "gamer_token", "game_id") && typeof e.gamer_token == "string" && typeof e.game_id == "string";
10
10
  }
11
- function se(e) {
11
+ function ae(e) {
12
12
  return t(e);
13
13
  }
14
- ne("GamerApiSDK");
15
- function d(e) {
14
+ ee("GamerApiSDK");
15
+ function oe(e) {
16
16
  return /^\/[a-z\d-]+$/.test(e);
17
17
  }
18
- async function ce() {
19
- let { promise: e, resolve: t } = re();
18
+ async function se() {
19
+ let { promise: e, resolve: t } = te();
20
20
  return wx.login({
21
21
  success(e) {
22
22
  t(e.code);
@@ -28,7 +28,7 @@ async function ce() {
28
28
  }
29
29
  //#endregion
30
30
  //#region src/token.ts
31
- var f = "gamer_token", le = class {
31
+ var p = "gamer_token", ce = class {
32
32
  _NetRequest;
33
33
  _idToken = "";
34
34
  _weixinToken = "";
@@ -36,8 +36,8 @@ var f = "gamer_token", le = class {
36
36
  req;
37
37
  storage;
38
38
  constructor(t, r) {
39
- this.storage = c() ? ie : n;
40
- let i = d(t) ? t : `https://${o(t)}`;
39
+ this.storage = u() ? ne : n;
40
+ let i = oe(t) ? t : `https://${o(t)}`;
41
41
  if (this._NetRequest = r, this.req = r({
42
42
  baseURL: `${i}/v1`,
43
43
  timeout: 1e4,
@@ -54,7 +54,7 @@ var f = "gamer_token", le = class {
54
54
  requestTransformer: (e) => {
55
55
  this._gamerToken && (e.headers.Authorization = `Bearer ${this._gamerToken}`);
56
56
  }
57
- }), te()) {
57
+ }), l()) {
58
58
  let t = /^(?:localhost|[\d.]+):\d{4}$/.test(location.host), n = s("gamer_token");
59
59
  (e() || t && n) && (this._gamerToken = n);
60
60
  }
@@ -64,7 +64,7 @@ var f = "gamer_token", le = class {
64
64
  return this._NetRequest;
65
65
  }
66
66
  loadGamerTokenCache() {
67
- let e = this.storage.get(f).match(/^(\d{12,})#(.{8,})$/);
67
+ let e = this.storage.get(p).match(/^(\d{12,})#(.{8,})$/);
68
68
  if (e) {
69
69
  let t = parseInt(e[1]), n = e[2];
70
70
  if (t > Date.now() - (24 * 3600 - 10) * 1e3) {
@@ -72,7 +72,7 @@ var f = "gamer_token", le = class {
72
72
  return;
73
73
  }
74
74
  }
75
- this.storage.remove(f);
75
+ this.storage.remove(p);
76
76
  }
77
77
  get isLoggedIn() {
78
78
  return this._gamerToken !== "";
@@ -93,19 +93,19 @@ var f = "gamer_token", le = class {
93
93
  return this._gamerToken;
94
94
  }
95
95
  set gamerToken(e) {
96
- this._gamerToken = e, e ? this.storage.set(f, `${Date.now()}#${e}`) : this.storage.remove(f);
96
+ this._gamerToken = e, e ? this.storage.set(p, `${Date.now()}#${e}`) : this.storage.remove(p);
97
97
  }
98
98
  logout() {
99
99
  this._idToken = "", this._weixinToken = "", this.gamerToken = "";
100
100
  }
101
101
  async autoLogin() {
102
102
  if (this.gamerToken) return !0;
103
- let e = c();
103
+ let e = u();
104
104
  if (!this.idToken || e && !this.weixinToken) return !1;
105
105
  let { code: t, data: n } = await this.req.post("login-with-token", a({
106
106
  id_token: this.idToken,
107
107
  weixin_token: e ? this.weixinToken : null
108
- }), ae, {
108
+ }), re, {
109
109
  message: !1,
110
110
  cacheTTL: 300,
111
111
  cacheResolve: () => `${this.idToken}_${e ? this.weixinToken : "null"}`
@@ -121,9 +121,9 @@ var f = "gamer_token", le = class {
121
121
  return this.gamerToken = n?.gamer_token || "", !!this.gamerToken;
122
122
  }
123
123
  async switchGame(e) {
124
- let t = c();
124
+ let t = u();
125
125
  if (!this.idToken || t && !this.weixinToken) return !1;
126
- let { code: n, data: r } = await this.req.post("session/switch-game", a({ game_id: e }), oe, {
126
+ let { code: n, data: r } = await this.req.post("session/switch-game", a({ game_id: e }), ie, {
127
127
  message: !1,
128
128
  maxRetry: 2
129
129
  });
@@ -134,193 +134,193 @@ var f = "gamer_token", le = class {
134
134
  }
135
135
  async getSession() {
136
136
  if (!await this.autoLogin()) return null;
137
- let { data: e } = await this.req.get("session", null, se, { message: !1 });
137
+ let { data: e } = await this.req.get("session", null, ae, { message: !1 });
138
138
  return e;
139
139
  }
140
140
  async authRealName(e) {
141
141
  if (!await this.autoLogin()) return null;
142
- let { data: t } = await this.req.post("auth-real-name", a(e), se);
142
+ let { data: t } = await this.req.post("auth-real-name", a(e), ae);
143
143
  return t;
144
144
  }
145
- }, ue = {
145
+ }, le = {
146
146
  Unknown: "unknown",
147
147
  Male: "male",
148
148
  Female: "female"
149
- }, de = u.string().enum(ue).lock(), fe = {
149
+ }, ue = f.string().enum(le).lock(), de = {
150
150
  Increase: "increase",
151
151
  Decrease: "decrease",
152
152
  Expired: "expired"
153
- }, pe = u.string().enum(fe).lock(), me = {
153
+ }, fe = f.string().enum(de).lock(), pe = {
154
154
  Order: "order",
155
155
  Consumption: "consumption",
156
156
  Redeem: "redeem",
157
157
  Expire: "expire",
158
158
  Admin: "admin",
159
159
  Event: "event"
160
- }, he = u.string().enum(me).lock(), ge = {
160
+ }, me = f.string().enum(pe).lock(), he = {
161
161
  GameReward: "game_reward",
162
162
  Physical: "physical",
163
163
  Virtual: "virtual"
164
- }, p = u.string().enum(ge).lock(), _e = {
164
+ }, m = f.string().enum(he).lock(), ge = {
165
165
  Pending: "pending",
166
166
  Issued: "issued",
167
167
  Failed: "failed"
168
- }, ve = u.string().enum(_e).lock(), ye = u.object({
169
- default_avatar_url: u.string(),
170
- official_avatar_urls: u.array(u.string()),
171
- default_nickname: u.string(),
172
- default_bio: u.string(),
173
- default_role_avatar_url: u.string(),
174
- level_configs: u.array(u.object({
175
- level: u.number(),
176
- exp: u.number(),
177
- title: u.string()
168
+ }, _e = f.string().enum(ge).lock(), ve = f.object({
169
+ default_avatar_url: f.string(),
170
+ official_avatar_urls: f.array(f.string()),
171
+ default_nickname: f.string(),
172
+ default_bio: f.string(),
173
+ default_role_avatar_url: f.string(),
174
+ level_configs: f.array(f.object({
175
+ level: f.number(),
176
+ exp: f.number(),
177
+ title: f.string()
178
178
  })),
179
- level_valid_days: u.number(),
180
- benefit_description: u.string(),
181
- exp_description: u.string(),
182
- credit_description: u.string(),
183
- send_role_mail_rate_limit: u.number()
184
- }).lock(), be = u.object({
185
- member_id: u.string(),
186
- player_id: u.string(),
187
- exp: u.number(),
188
- level: u.number(),
189
- credit: u.number(),
190
- credit_expiring: u.number(),
191
- level_change_time: u.number(),
192
- level_expire_time: u.number()
193
- }).lock(), xe = u.object({
194
- server_id: u.string(),
195
- server_name: u.string()
196
- }).lock(), Se = u.object({
197
- role_id: u.string(),
198
- role_name: u.string()
199
- }).lock(), m = u.object({
200
- ...Se.shape,
201
- ...xe.shape,
202
- role_level: u.number(),
203
- last_login_time: u.number()
204
- }).lock(), Ce = u.object({
205
- ...m.shape,
206
- role_fighting: u.number(),
207
- kin_id: u.string().optional(),
208
- kin_name: u.string().optional(),
209
- kin_position: u.string().optional()
210
- }).lock(), we = u.object({
211
- name: u.string(),
212
- avatar_url: u.string(),
213
- bio: u.string(),
214
- gender: de,
215
- birthday: u.object({
216
- year: u.number(),
217
- month: u.number(),
218
- day: u.number()
179
+ level_valid_days: f.number(),
180
+ benefit_description: f.string(),
181
+ exp_description: f.string(),
182
+ credit_description: f.string(),
183
+ send_role_mail_rate_limit: f.number()
184
+ }).lock(), ye = f.object({
185
+ member_id: f.string(),
186
+ player_id: f.string(),
187
+ exp: f.number(),
188
+ level: f.number(),
189
+ credit: f.number(),
190
+ credit_expiring: f.number(),
191
+ level_change_time: f.number(),
192
+ level_expire_time: f.number()
193
+ }).lock(), h = f.object({
194
+ server_id: f.string(),
195
+ server_name: f.string()
196
+ }).lock(), be = f.object({
197
+ role_id: f.string(),
198
+ role_name: f.string()
199
+ }).lock(), g = f.object({
200
+ ...be.shape,
201
+ ...h.shape,
202
+ role_level: f.number(),
203
+ last_login_time: f.number()
204
+ }).lock(), xe = f.object({
205
+ ...g.shape,
206
+ role_fighting: f.number(),
207
+ kin_id: f.string().optional(),
208
+ kin_name: f.string().optional(),
209
+ kin_position: f.string().optional()
210
+ }).lock(), Se = f.object({
211
+ name: f.string(),
212
+ avatar_url: f.string(),
213
+ bio: f.string(),
214
+ gender: ue,
215
+ birthday: f.object({
216
+ year: f.number(),
217
+ month: f.number(),
218
+ day: f.number()
219
219
  }),
220
- social_medias: u.record(u.object({
221
- homepage_url: u.string(),
222
- homepage_image_url: u.string()
220
+ social_medias: f.record(f.object({
221
+ homepage_url: f.string(),
222
+ homepage_image_url: f.string()
223
223
  }).optional()).optional()
224
- }).lock(), h = u.object({
225
- address_id: u.number(),
226
- recipient: u.string(),
227
- mobile: u.string(),
228
- province: u.string(),
229
- city: u.string(),
230
- district: u.string(),
231
- address: u.string(),
232
- is_default: u.bool()
233
- }).lock(), Te = u.object({
234
- increased_credit: u.number(),
235
- decreased_credit: u.number(),
236
- expired_credit: u.number(),
237
- balance_credit: u.number()
238
- }).lock(), Ee = u.object({
239
- id: u.number(),
240
- change_type: pe,
241
- change_scene: he,
242
- change_credit: u.number(),
243
- balance: u.number(),
244
- change_time: u.number(),
245
- metadata: u.record(u.unknown()).optional()
246
- }).lock(), g = u.object({
247
- benefit_id: u.number(),
248
- name: u.string(),
249
- img_url: u.string(),
250
- description: u.string(),
251
- min_level: u.number(),
252
- max_level: u.number(),
253
- product_id: u.number(),
254
- tag: u.string()
255
- }).lock(), _ = u.object({
256
- product_id: u.number(),
257
- catalog_id: u.number(),
258
- catalog_name: u.string(),
259
- item_type: p,
260
- name: u.string(),
261
- img_url: u.string(),
262
- description: u.string(),
263
- tag: u.string(),
264
- price: u.number(),
265
- stock: u.number(),
266
- redeem_quantity: u.number(),
267
- not_visible_before: u.number(),
268
- not_visible_after: u.number(),
269
- not_before: u.number(),
270
- not_after: u.number(),
271
- min_level: u.number(),
272
- max_level: u.number(),
273
- limit_daily: u.number(),
274
- limit_monthly: u.number(),
275
- limit_yearly: u.number(),
276
- limit_total: u.number(),
277
- weight: u.number(),
278
- created_at: u.number(),
279
- updated_at: u.number(),
280
- redeemable_quantity: u.number().optional()
281
- }).lock(), De = u.object({
282
- ...r(g.shape, "tag"),
283
- product: _.clone().optional()
284
- }).lock(), Oe = u.union(u.object({
285
- server_id: u.string(),
286
- role_id: u.string()
287
- }), u.object({ address_id: u.number() })).satisfies().lock(), ke = u.object({
288
- recipient: u.string(),
289
- mobile: u.string(),
290
- province: u.string(),
291
- city: u.string(),
292
- district: u.string(),
293
- address: u.string(),
294
- express_company: u.string(),
295
- express_number: u.string()
296
- }).lock(), Ae = u.object({
297
- server_id: u.string(),
298
- role_id: u.string(),
299
- role_name: u.string()
300
- }).lock(), je = u.object({
301
- redemption_id: u.number(),
302
- player_id: u.string(),
303
- product_id: u.number(),
304
- name: u.string(),
305
- img_url: u.string(),
306
- item_type: p,
307
- catalog_id: u.number(),
308
- catalog_name: u.string(),
309
- quantity: u.number(),
310
- amount: u.number(),
311
- status: ve,
312
- created_at: u.number(),
313
- extra_data: u.union(ke.clone(), Ae.clone()).satisfies().optional()
314
- }), Me = u.guard(ye), v = l({ player: be }), Ne = l({ roles: u.array(m) }), y = l({ role_card: Ce }), b = u.guard(we), x = u.guard(h), Pe = l({ addresses: u.array(h) }), Fe = u.guard(Te), Ie = l({
315
- credit_logs: u.array(Ee),
316
- next_token: u.string().optional()
317
- }), Le = l({ products: u.array(_) }), Re = l({ benefits: u.array(g) }), ze = l({ benefit: De }), Be = l({
318
- redemptions: u.array(je),
319
- next_token: u.string().optional()
320
- }), Ve = l({
321
- existed: u.bool(),
322
- image_upload_url: u.string().optional(),
323
- image_id: u.string()
224
+ }).lock(), _ = f.object({
225
+ address_id: f.number(),
226
+ recipient: f.string(),
227
+ mobile: f.string(),
228
+ province: f.string(),
229
+ city: f.string(),
230
+ district: f.string(),
231
+ address: f.string(),
232
+ is_default: f.bool()
233
+ }).lock(), Ce = f.object({
234
+ increased_credit: f.number(),
235
+ decreased_credit: f.number(),
236
+ expired_credit: f.number(),
237
+ balance_credit: f.number()
238
+ }).lock(), we = f.object({
239
+ id: f.number(),
240
+ change_type: fe,
241
+ change_scene: me,
242
+ change_credit: f.number(),
243
+ balance: f.number(),
244
+ change_time: f.number(),
245
+ metadata: f.record(f.unknown()).optional()
246
+ }).lock(), v = f.object({
247
+ benefit_id: f.number(),
248
+ name: f.string(),
249
+ img_url: f.string(),
250
+ description: f.string(),
251
+ min_level: f.number(),
252
+ max_level: f.number(),
253
+ product_id: f.number(),
254
+ tag: f.string()
255
+ }).lock(), y = f.object({
256
+ product_id: f.number(),
257
+ catalog_id: f.number(),
258
+ catalog_name: f.string(),
259
+ item_type: m,
260
+ name: f.string(),
261
+ img_url: f.string(),
262
+ description: f.string(),
263
+ tag: f.string(),
264
+ price: f.number(),
265
+ stock: f.number(),
266
+ redeem_quantity: f.number(),
267
+ not_visible_before: f.number(),
268
+ not_visible_after: f.number(),
269
+ not_before: f.number(),
270
+ not_after: f.number(),
271
+ min_level: f.number(),
272
+ max_level: f.number(),
273
+ limit_daily: f.number(),
274
+ limit_monthly: f.number(),
275
+ limit_yearly: f.number(),
276
+ limit_total: f.number(),
277
+ weight: f.number(),
278
+ created_at: f.number(),
279
+ updated_at: f.number(),
280
+ redeemable_quantity: f.number().optional()
281
+ }).lock(), Te = f.object({
282
+ ...r(v.shape, "tag"),
283
+ product: y.clone().optional()
284
+ }).lock(), Ee = f.union(f.object({
285
+ server_id: f.string(),
286
+ role_id: f.string()
287
+ }), f.object({ address_id: f.number() })).satisfies().lock(), De = f.object({
288
+ recipient: f.string(),
289
+ mobile: f.string(),
290
+ province: f.string(),
291
+ city: f.string(),
292
+ district: f.string(),
293
+ address: f.string(),
294
+ express_company: f.string(),
295
+ express_number: f.string()
296
+ }).lock(), Oe = f.object({
297
+ server_id: f.string(),
298
+ role_id: f.string(),
299
+ role_name: f.string()
300
+ }).lock(), ke = f.object({
301
+ redemption_id: f.number(),
302
+ player_id: f.string(),
303
+ product_id: f.number(),
304
+ name: f.string(),
305
+ img_url: f.string(),
306
+ item_type: m,
307
+ catalog_id: f.number(),
308
+ catalog_name: f.string(),
309
+ quantity: f.number(),
310
+ amount: f.number(),
311
+ status: _e,
312
+ created_at: f.number(),
313
+ extra_data: f.union(De.clone(), Oe.clone()).satisfies().optional()
314
+ }), Ae = f.guard(ve), je = d({ player: ye }), Me = d({ roles: f.array(g) }), b = d({ role_card: xe }), x = f.guard(Se), Ne = f.guard(_), Pe = d({ addresses: f.array(_) }), Fe = f.guard(Ce), Ie = d({
315
+ credit_logs: f.array(we),
316
+ next_token: f.string().optional()
317
+ }), Le = d({ products: f.array(y) }), Re = d({ benefits: f.array(v) }), ze = d({ benefit: Te }), Be = d({
318
+ redemptions: f.array(ke),
319
+ next_token: f.string().optional()
320
+ }), Ve = d({
321
+ existed: f.bool(),
322
+ image_upload_url: f.string().optional(),
323
+ image_id: f.string()
324
324
  }), He = class {
325
325
  token;
326
326
  req;
@@ -329,12 +329,12 @@ var f = "gamer_token", le = class {
329
329
  }
330
330
  async getConfig(e) {
331
331
  await this.token.autoLogin();
332
- let { data: t } = await this.req.get("club/config", null, Me, e);
332
+ let { data: t } = await this.req.get("club/config", null, Ae, e);
333
333
  return t;
334
334
  }
335
335
  async getCurrentPlayer(e) {
336
336
  await this.token.autoLogin();
337
- let { data: t, code: n, message: r } = await this.req.get("club/current-player", null, v, e);
337
+ let { data: t, code: n, message: r } = await this.req.get("club/current-player", null, je, e);
338
338
  return t?.player ?? {
339
339
  message: r,
340
340
  error: n
@@ -342,7 +342,7 @@ var f = "gamer_token", le = class {
342
342
  }
343
343
  async linkPlayer(e) {
344
344
  await this.token.autoLogin();
345
- let { data: t, code: n, message: r } = await this.req.post("club/link-player", { id_token: this.token.idToken }, v, e);
345
+ let { data: t, code: n, message: r } = await this.req.post("club/link-player", { id_token: this.token.idToken }, je, e);
346
346
  return t?.player ?? {
347
347
  message: r,
348
348
  error: n
@@ -353,27 +353,27 @@ var f = "gamer_token", le = class {
353
353
  let { data: r } = await this.req.get("club/roles", {
354
354
  player_id: e,
355
355
  refresh: t
356
- }, Ne, n);
356
+ }, Me, n);
357
357
  return r?.roles || [];
358
358
  }
359
359
  async getRoleCard(e, t) {
360
360
  await this.token.autoLogin();
361
- let { data: n } = await this.req.get("club/role-card", { member_id: e }, y, t);
361
+ let { data: n } = await this.req.get("club/role-card", { member_id: e }, b, t);
362
362
  return n?.role_card ?? null;
363
363
  }
364
364
  async setRoleCard(e, t) {
365
365
  if (!await this.token.autoLogin()) return null;
366
- let { data: n } = await this.req.post("club/role-card", e, y, t);
366
+ let { data: n } = await this.req.post("club/role-card", e, b, t);
367
367
  return n?.role_card ?? null;
368
368
  }
369
369
  async refreshRoleCard(e) {
370
370
  if (!await this.token.autoLogin()) return null;
371
- let { data: t } = await this.req.post("club/refresh-role-card", {}, y, e);
371
+ let { data: t } = await this.req.post("club/refresh-role-card", {}, b, e);
372
372
  return t?.role_card ?? null;
373
373
  }
374
374
  async getUserProfile(e, t) {
375
375
  await this.token.autoLogin();
376
- let { data: n } = await this.req.get("club/user-profile", { member_id: e }, b, t);
376
+ let { data: n } = await this.req.get("club/user-profile", { member_id: e }, x, t);
377
377
  return n;
378
378
  }
379
379
  async updateUserProfile(e, t) {
@@ -382,7 +382,7 @@ var f = "gamer_token", le = class {
382
382
  message: "请提供需要修改的信息"
383
383
  };
384
384
  await this.token.autoLogin();
385
- let { data: n, code: r, message: i } = await this.req.post("club/user-profile", e, b, t);
385
+ let { data: n, code: r, message: i } = await this.req.post("club/user-profile", e, x, t);
386
386
  return n ?? {
387
387
  message: i,
388
388
  error: r
@@ -395,7 +395,7 @@ var f = "gamer_token", le = class {
395
395
  }
396
396
  async addAddress(e, t) {
397
397
  if (!await this.token.autoLogin()) return null;
398
- let { data: n, code: r, message: i } = await this.req.post("/club/add-address", a(e), x, t);
398
+ let { data: n, code: r, message: i } = await this.req.post("/club/add-address", a(e), Ne, t);
399
399
  return n ?? {
400
400
  message: i,
401
401
  error: r
@@ -403,7 +403,7 @@ var f = "gamer_token", le = class {
403
403
  }
404
404
  async updateAddress(e, t) {
405
405
  await this.token.autoLogin();
406
- let { data: n, code: r, message: i } = await this.req.post("club/update-address", a(e), x, t);
406
+ let { data: n, code: r, message: i } = await this.req.post("club/update-address", a(e), Ne, t);
407
407
  return n ?? {
408
408
  message: i,
409
409
  error: r
@@ -502,15 +502,15 @@ var f = "gamer_token", le = class {
502
502
  ClubExp: "club_exp",
503
503
  ExternalCode: "external_gift_code",
504
504
  VoidItem: "void_item"
505
- }, C = u.string().enum(S).lock(), We = S, w = C, Ge = {
505
+ }, C = f.string().enum(S).lock(), We = S, w = C, Ge = {
506
506
  UserId: "user_id",
507
507
  RoleId: "role_id"
508
- }, Ke = u.string().enum(Ge).lock(), qe = {
508
+ }, Ke = f.string().enum(Ge).lock(), qe = {
509
509
  None: "none",
510
510
  Daily: "daily",
511
511
  Weekly: "weekly",
512
512
  Monthly: "monthly"
513
- }, Je = u.string().enum(qe).lock(), T = {
513
+ }, Je = f.string().enum(qe).lock(), T = {
514
514
  Preregister: "preregister",
515
515
  Lottery: "lottery",
516
516
  Survey: "survey",
@@ -534,8 +534,9 @@ var f = "gamer_token", le = class {
534
534
  ZeroChatgpt: "zero_chatgpt",
535
535
  Ugc: "ugc",
536
536
  UgcLike: "ugc_like",
537
- Redeem: "redeem"
538
- }, Ye = u.string().enum(T).lock(), Xe = {
537
+ Redeem: "redeem",
538
+ Referral: "referral"
539
+ }, Ye = f.string().enum(T).lock(), Xe = {
539
540
  Active: "player_active_points",
540
541
  Login: "player_login_days",
541
542
  OrderAmount: "order_total_amount",
@@ -552,52 +553,56 @@ var f = "gamer_token", le = class {
552
553
  TeamSize: "team_size",
553
554
  UserGroup: "user_group",
554
555
  engagementCount: "engagement_count"
555
- }, E = u.string().enum(Xe).lock(), Ze = {
556
+ }, E = f.string().enum(Xe).lock(), Ze = {
556
557
  System: "system",
557
558
  UserSubmission: "user_submission",
558
559
  Shortlisted: "shortlisted"
559
- }, Qe = u.string().enum(Ze).lock(), D = {
560
+ }, Qe = f.string().enum(Ze).lock(), D = {
560
561
  Ineligible: "ineligible",
561
562
  Unclaimed: "unclaimed",
562
563
  Received: "received",
563
564
  Failed: "failed",
564
565
  Delivered: "delivered"
565
- }, O = u.string().enum(D).lock(), $e = {
566
+ }, O = f.string().enum(D).lock(), $e = {
566
567
  Ineligible: D.Ineligible,
567
568
  Unclaimed: D.Unclaimed,
568
569
  Received: D.Received,
569
570
  Failed: D.Failed,
570
571
  Delivered: D.Delivered
571
- }, k = u.string().enum($e).lock(), et = {
572
+ }, k = f.string().enum($e).lock(), et = {
572
573
  Output: "output",
573
574
  Engage: "engage"
574
- }, A = u.string().enum(et).lock(), tt = {
575
+ }, A = f.string().enum(et).lock(), tt = {
575
576
  Private: "private",
576
577
  Public: "public"
577
- }, nt = u.string().enum(tt).lock(), j = {
578
+ }, nt = f.string().enum(tt).lock(), j = {
578
579
  Unknown: "unknown",
579
580
  Pending: "pending",
580
581
  Drawn: "drawn",
581
582
  Claimed: "claimed",
582
583
  Fail: "fail"
583
- }, rt = u.string().enum(j).lock(), it = {
584
+ }, rt = f.string().enum(j).lock(), it = {
584
585
  Assemble: "assemble",
585
586
  Join: "join",
586
587
  Disband: "disband",
587
588
  ChangeVisibility: "change_visibility",
588
589
  Query: "query"
589
- }, at = u.string().enum(it).lock(), ot = {
590
+ }, at = f.string().enum(it).lock(), ot = {
591
+ Share: "share",
592
+ Join: "join",
593
+ Query: "query"
594
+ }, st = f.string().enum(ot).lock(), ct = {
590
595
  Query: "query",
591
596
  Draw: "draw",
592
597
  Claim: "claim"
593
- }, st = u.string().enum(ot).lock(), ct = {
598
+ }, lt = f.string().enum(ct).lock(), ut = {
594
599
  Sum: "sum",
595
600
  TopN: "top_n"
596
- }, lt = u.string().enum(ct).lock(), ut = {
601
+ }, dt = f.string().enum(ut).lock(), ft = {
597
602
  None: "none",
598
603
  Winner: "winner",
599
604
  Consolation: "consolation"
600
- }, dt = u.string().enum(ut).lock(), ft = {
605
+ }, pt = f.string().enum(ft).lock(), mt = {
601
606
  Douyin: "douyin",
602
607
  Xiaohongshu: "xiaohongshu",
603
608
  Taptap: "taptap",
@@ -606,542 +611,568 @@ var f = "gamer_token", le = class {
606
611
  Huya: "huya",
607
612
  Douyu: "douyu",
608
613
  Kuaishou: "kuaishou"
609
- }, M = u.string().enum(ft).lock(), pt = {
614
+ }, M = f.string().enum(mt).lock(), ht = {
610
615
  Submitted: "submitted",
611
616
  Accepted: "accepted",
612
617
  Rejected: "rejected"
613
- }, mt = u.string().enum(pt).lock(), ht = u.string().enum(S), N = u.object({
614
- reward_item_id: u.number(),
615
- reward_amount: u.number(),
616
- reward_item_name: u.string(),
617
- reward_item_icon_url: u.string(),
618
- reward_item_desc: u.string().optional(),
619
- reward_item_type: ht,
620
- reward_item_rating: u.number()
621
- }).lock(), gt = u.object({
622
- engage_count: u.number(),
623
- rewards: u.array(N)
624
- }).lock(), _t = u.union(u.object({
625
- feature_reward_type: u.string().enum("every"),
626
- reward_details: u.array(N)
627
- }), u.object({
628
- feature_reward_type: u.string().enum("regular"),
629
- reward_details: u.array(gt)
630
- })).satisfies().lock(), P = u.object({
631
- feature_name: u.string(),
632
- feature_id: u.number(),
633
- description: u.string(),
618
+ }, gt = f.string().enum(ht).lock(), _t = f.string().enum(S), N = f.object({
619
+ reward_item_id: f.number(),
620
+ reward_amount: f.number(),
621
+ reward_item_name: f.string(),
622
+ reward_item_icon_url: f.string(),
623
+ reward_item_desc: f.string().optional(),
624
+ reward_item_type: _t,
625
+ reward_item_rating: f.number()
626
+ }).lock(), vt = f.object({
627
+ engage_count: f.number(),
628
+ rewards: f.array(N)
629
+ }).lock(), yt = f.union(f.object({
630
+ feature_reward_type: f.string().enum("every"),
631
+ reward_details: f.array(N)
632
+ }), f.object({
633
+ feature_reward_type: f.string().enum("regular"),
634
+ reward_details: f.array(vt)
635
+ })).satisfies().lock(), P = f.object({
636
+ feature_name: f.string(),
637
+ feature_id: f.number(),
638
+ description: f.string(),
634
639
  cycle: Je,
635
- cycle_limit: u.number(),
636
- limit: u.number(),
637
- since: u.number(),
638
- until: u.number(),
640
+ cycle_limit: f.number(),
641
+ limit: f.number(),
642
+ since: f.number(),
643
+ until: f.number(),
639
644
  engage_account: Ke,
640
- feature_rewards: _t.clone().optional(),
641
- sort: u.number().optional()
642
- }), vt = T.Cashback, yt = u.object({
645
+ feature_rewards: yt.clone().optional(),
646
+ sort: f.number().optional()
647
+ }), bt = T.Cashback, xt = f.object({
643
648
  ...P.shape,
644
- feature_type: u.string().enum(vt),
645
- config: u.object({
646
- order_start_time: u.number(),
647
- order_end_time: u.number(),
648
- claim_rewards_start_time: u.number(),
649
- claim_rewards_end_time: u.number()
649
+ feature_type: f.string().enum(bt),
650
+ config: f.object({
651
+ order_start_time: f.number(),
652
+ order_end_time: f.number(),
653
+ claim_rewards_start_time: f.number(),
654
+ claim_rewards_end_time: f.number()
650
655
  })
651
- }), bt = T.CheckIn, xt = u.object({
656
+ }), St = T.CheckIn, Ct = f.object({
652
657
  ...P.shape,
653
- feature_type: u.string().enum(bt)
654
- }), St = T.ClaimActivationKey, Ct = u.object({
658
+ feature_type: f.string().enum(St)
659
+ }), wt = T.ClaimActivationKey, Tt = f.object({
655
660
  ...P.shape,
656
- feature_type: u.string().enum(St)
657
- }), wt = T.ClaimRewards, Tt = u.object({
661
+ feature_type: f.string().enum(wt)
662
+ }), Et = T.ClaimRewards, Dt = f.object({
658
663
  ...P.shape,
659
- feature_type: u.string().enum(wt)
660
- }), Et = T.Comment, Dt = u.object({
664
+ feature_type: f.string().enum(Et)
665
+ }), Ot = T.Comment, kt = f.object({
661
666
  ...P.shape,
662
- feature_type: u.string().enum(Et),
663
- config: u.object({
664
- comments: u.array(u.string()),
665
- send_rate: u.number()
667
+ feature_type: f.string().enum(Ot),
668
+ config: f.object({
669
+ comments: f.array(f.string()),
670
+ send_rate: f.number()
666
671
  })
667
- }), Ot = T.Follow, kt = u.object({
672
+ }), At = T.Follow, jt = f.object({
668
673
  ...P.shape,
669
- feature_type: u.string().enum(Ot),
670
- config: u.object({
671
- platform: u.string(),
672
- platform_icon: u.string().optional(),
673
- link: u.string().optional(),
674
- qr_code_url: u.string().optional(),
675
- platform_desc: u.string().optional()
674
+ feature_type: f.string().enum(At),
675
+ config: f.object({
676
+ platform: f.string(),
677
+ platform_icon: f.string().optional(),
678
+ link: f.string().optional(),
679
+ qr_code_url: f.string().optional(),
680
+ platform_desc: f.string().optional()
676
681
  })
677
- }), At = T.GiftCode, jt = u.object({
678
- name: u.string(),
679
- icon_url: u.string(),
680
- count: u.number()
681
- }), Mt = u.object({
682
+ }), Mt = T.GiftCode, Nt = f.object({
683
+ name: f.string(),
684
+ icon_url: f.string(),
685
+ count: f.number()
686
+ }), Pt = f.object({
682
687
  ...P.shape,
683
- feature_type: u.string().enum(At),
684
- config: u.object({
685
- gift_items: u.array(jt),
686
- mp_url: u.string().optional(),
687
- mp_qrcode_url: u.string().optional()
688
+ feature_type: f.string().enum(Mt),
689
+ config: f.object({
690
+ gift_items: f.array(Nt),
691
+ mp_url: f.string().optional(),
692
+ mp_qrcode_url: f.string().optional()
688
693
  })
689
- }), Nt = T.Invite, Pt = u.object({
694
+ }), Ft = T.Invite, It = f.object({
690
695
  ...P.shape,
691
- feature_type: u.string().enum(Nt),
692
- config: u.object({ share_url: u.string() })
693
- }), Ft = T.InvitedRegister, It = u.object({
696
+ feature_type: f.string().enum(Ft),
697
+ config: f.object({ share_url: f.string() })
698
+ }), Lt = T.InvitedRegister, Rt = f.object({
694
699
  ...P.shape,
695
- feature_type: u.string().enum(Ft)
696
- }), Lt = u.string().enum(r(S, "GiftCode", "LotteryTicket")), Rt = T.Lottery, zt = u.object({
697
- reward_item_id: u.number(),
698
- reward_item_name: u.string(),
699
- reward_item_type: Lt,
700
- reward_item_icon_url: u.string(),
701
- reward_item_desc: u.string().optional(),
702
- reward_amount: u.number(),
703
- reward_remaining_stock: u.number(),
704
- reward_item_rating: u.number()
705
- }), Bt = u.object({
700
+ feature_type: f.string().enum(Lt)
701
+ }), zt = f.string().enum(r(S, "GiftCode", "LotteryTicket")), Bt = T.Lottery, Vt = f.object({
702
+ reward_item_id: f.number(),
703
+ reward_item_name: f.string(),
704
+ reward_item_type: zt,
705
+ reward_item_icon_url: f.string(),
706
+ reward_item_desc: f.string().optional(),
707
+ reward_amount: f.number(),
708
+ reward_remaining_stock: f.number(),
709
+ reward_item_rating: f.number()
710
+ }), Ht = f.object({
706
711
  ...P.shape,
707
- feature_type: u.string().enum(Rt),
708
- config: u.object({
709
- consume_item_id: u.number(),
710
- consume_item_name: u.string(),
711
- consume_item_icon_url: u.string(),
712
- consume_item_count: u.array(u.number()),
713
- consume_item_desc: u.string().optional(),
714
- rewards: u.array(zt)
712
+ feature_type: f.string().enum(Bt),
713
+ config: f.object({
714
+ consume_item_id: f.number(),
715
+ consume_item_name: f.string(),
716
+ consume_item_icon_url: f.string(),
717
+ consume_item_count: f.array(f.number()),
718
+ consume_item_desc: f.string().optional(),
719
+ rewards: f.array(Vt)
715
720
  })
716
- }), Vt = T.LotteryDraw, Ht = u.object({
721
+ }), Ut = T.LotteryDraw, Wt = f.object({
717
722
  ...P.shape,
718
- feature_type: u.string().enum(Vt),
719
- config: u.object({
720
- draw_not_before: u.number(),
721
- draw_not_after: u.number()
723
+ feature_type: f.string().enum(Ut),
724
+ config: f.object({
725
+ draw_not_before: f.number(),
726
+ draw_not_after: f.number()
722
727
  })
723
- }), Ut = T.Preregister, Wt = u.object({
728
+ }), Gt = T.Preregister, Kt = f.object({
724
729
  ...P.shape,
725
- feature_type: u.string().enum(Ut)
726
- }), Gt = T.Quest, Kt = u.object({
730
+ feature_type: f.string().enum(Gt)
731
+ }), qt = T.Quest, Jt = f.object({
727
732
  ...P.shape,
728
- feature_type: u.string().enum(Gt),
729
- config: u.object({
733
+ feature_type: f.string().enum(qt),
734
+ config: f.object({
730
735
  objective: E,
731
- completion_value: u.number(),
732
- team: u.object({
733
- feature_id: u.number().optional(),
734
- completion_value: u.number(),
735
- progress_algorithm: lt.clone().optional(),
736
- top_n: u.number().optional()
736
+ completion_value: f.number(),
737
+ team: f.object({
738
+ feature_id: f.number().optional(),
739
+ completion_value: f.number(),
740
+ progress_algorithm: dt.clone().optional(),
741
+ top_n: f.number().optional()
737
742
  }).optional(),
738
- config: u.object({
739
- topic_id: u.number().optional(),
740
- required_players: u.number().min(1).optional(),
741
- required_matches: u.number().min(1).optional(),
742
- event_item_id: u.number().optional()
743
+ config: f.object({
744
+ topic_id: f.number().optional(),
745
+ required_players: f.number().min(1).optional(),
746
+ required_matches: f.number().min(1).optional(),
747
+ event_item_id: f.number().optional()
743
748
  }).optional()
744
749
  })
745
- }), qt = T.Redeem, Jt = u.object({
746
- price: u.number(),
747
- per_user_limit: u.number(),
750
+ }), Yt = T.Redeem, Xt = f.object({
751
+ price: f.number(),
752
+ per_user_limit: f.number(),
748
753
  item: N
749
- }), Yt = u.object({
750
- ...P.shape,
751
- feature_type: u.string().enum(qt),
752
- config: u.object({
753
- event_item_id: u.number(),
754
- redeem_catalog: u.array(Jt)
755
- })
756
- }), Xt = T.Register, Zt = u.object({
757
- ...P.shape,
758
- feature_type: u.string().enum(Xt)
759
- }), Qt = T.Share, $t = u.object({
760
- ...P.shape,
761
- feature_type: u.string().enum(Qt),
762
- config: u.object({
763
- share_platform: u.string(),
764
- jump_url: u.string().optional(),
765
- icon_url: u.string().optional()
766
- })
767
- }), en = T.Subscribe, tn = u.object({
768
- ...P.shape,
769
- feature_type: u.string().enum(en),
770
- config: u.object({ weixin_template_ids: u.array(u.string()) })
771
- }), nn = T.Survey, rn = u.object({
772
- ...P.shape,
773
- feature_type: u.string().enum(nn),
774
- config: u.object({
775
- survey_id: u.string(),
776
- survey_url: u.string()
777
- })
778
- }), an = T.Team, on = u.object({
779
- ...P.shape,
780
- feature_type: u.string().enum(an),
781
- config: u.object({
782
- max_members: u.number().min(1),
783
- min_members: u.number().min(1)
784
- })
785
- }), sn = T.Ugc, cn = u.object({
786
- ...P.shape,
787
- feature_type: u.string().enum(sn),
788
- config: u.object({
789
- allowed_social_medias: u.array(u.string()).optional(),
790
- acceptance_rewards: u.array(N).optional()
791
- })
792
- }), ln = T.UgcLike, un = u.object({
754
+ }), Zt = f.object({
793
755
  ...P.shape,
794
- feature_type: u.string().enum(ln),
795
- config: u.object({ ugc_feature_id: u.number() })
796
- }), dn = T.Vote, fn = u.object({
797
- sn: u.string(),
798
- name: u.string(),
799
- img_urls: u.array(u.string()).optional(),
800
- video_urls: u.array(u.string()).optional(),
801
- descriptions: u.array(u.string()).optional(),
802
- jump_url: u.string(),
803
- amount: u.number(),
804
- finalists: u.bool(),
805
- last_vote_time: u.number()
806
- }), pn = u.object({
807
- ...P.shape,
808
- feature_type: u.string().enum(dn),
809
- config: u.object({
810
- vote_feature_ids: u.array(u.number()),
811
- submission_feature_ids: u.array(u.number()),
812
- finalists_amount: u.number(),
813
- source: Qe,
814
- options: u.array(fn),
815
- rewards: u.array(N)
756
+ feature_type: f.string().enum(Yt),
757
+ config: f.object({
758
+ event_item_id: f.number(),
759
+ redeem_catalog: f.array(Xt)
816
760
  })
817
- }), F = u.union(u.string().pattern("NumberString", /^\d+$/), u.number()), I = u.object({
761
+ }), F = f.union(f.string().pattern("NumberString", /^\d+$/), f.number()), I = f.object({
818
762
  order_total_amount: F,
819
763
  cashback_total_amount: F,
820
764
  game_item_count: F
821
- }), mn = u.object({ activation_key: u.string().disallow("") }), hn = u.object({ gift_code: u.string() }), gn = u.object({
822
- user_id: u.string(),
823
- name: u.string().optional(),
824
- avatar_url: u.string().optional()
825
- }), _n = u.object({ lottery_count: u.number() }), L = u.object({
826
- reward_id: u.number(),
827
- reward_item_id: u.number(),
765
+ }), Qt = f.object({ activation_key: f.string().disallow("") }), $t = f.object({ gift_code: f.string() }), en = f.object({
766
+ user_id: f.string(),
767
+ name: f.string().optional(),
768
+ avatar_url: f.string().optional()
769
+ }), tn = f.object({ lottery_count: f.number() }), L = f.object({
770
+ reward_id: f.number(),
771
+ reward_item_id: f.number(),
828
772
  reward_source: A,
829
- reward_item_name: u.string(),
773
+ reward_item_name: f.string(),
830
774
  reward_item_type: C,
831
- reward_item_icon_url: u.string(),
832
- reward_item_desc: u.string().optional(),
833
- reward_item_rating: u.number(),
834
- reward_amount: u.number(),
775
+ reward_item_icon_url: f.string(),
776
+ reward_item_desc: f.string().optional(),
777
+ reward_item_rating: f.number(),
778
+ reward_amount: f.number(),
835
779
  reward_status: k,
836
- event_id: u.number(),
837
- event_name: u.string(),
838
- feature_id: u.number(),
839
- engagement_id: u.number(),
780
+ event_id: f.number(),
781
+ event_name: f.string(),
782
+ feature_id: f.number(),
783
+ engagement_id: f.number(),
840
784
  feature_type: Ye,
841
- receive_time: u.number(),
842
- extra_data: u.record(u.unknown()).optional()
843
- }), vn = u.string().enum(j.Unknown, j.Pending), yn = u.union(u.object({
844
- ticket: u.string(),
845
- status: vn,
846
- created_at: u.number()
847
- }), u.object({
848
- ticket: u.string(),
849
- status: u.string().enum(r(j, "Unknown", "Pending")),
850
- created_at: u.number(),
785
+ receive_time: f.number(),
786
+ extra_data: f.record(f.unknown()).optional()
787
+ }), nn = f.string().enum(j.Unknown, j.Pending), rn = f.union(f.object({
788
+ ticket: f.string(),
789
+ status: nn,
790
+ created_at: f.number()
791
+ }), f.object({
792
+ ticket: f.string(),
793
+ status: f.string().enum(r(j, "Unknown", "Pending")),
794
+ created_at: f.number(),
851
795
  reward: L
852
- })).satisfies(), bn = u.object({ tickets: u.array(yn) }), xn = u.object({ platforms: u.array(u.string()) }), Sn = u.object({
853
- role_name: u.string(),
854
- is_leader: u.bool(),
855
- is_myself: u.bool().optional(),
856
- progress: u.number().optional(),
857
- avatar_url: u.string().optional()
858
- }).lock(), Cn = u.object({
796
+ })).satisfies(), an = f.object({ tickets: f.array(rn) }), on = f.object({ platforms: f.array(f.string()) }), sn = f.object({
797
+ role_name: f.string(),
798
+ is_leader: f.bool(),
799
+ is_myself: f.bool().optional(),
800
+ progress: f.number().optional(),
801
+ avatar_url: f.string().optional()
802
+ }).lock(), cn = f.object({
859
803
  objective: E,
860
- progress: u.number(),
861
- completion_value: u.number().optional(),
862
- team: u.object({
863
- progress: u.number(),
864
- completion_value: u.number().optional(),
865
- players: u.array(Sn)
804
+ progress: f.number(),
805
+ completion_value: f.number().optional(),
806
+ team: f.object({
807
+ progress: f.number(),
808
+ completion_value: f.number().optional(),
809
+ players: f.array(sn)
866
810
  }).optional()
867
- }), wn = u.object({
868
- progress: u.number(),
869
- team: u.object({
870
- progress: u.number(),
871
- team_members: u.array(Sn).optional()
811
+ }), ln = f.object({
812
+ progress: f.number(),
813
+ team: f.object({
814
+ progress: f.number(),
815
+ team_members: f.array(sn).optional()
872
816
  }).optional()
873
- }), Tn = u.object({
874
- item_id: u.number(),
875
- item_count: u.number(),
876
- redeem_count: u.number()
877
- }), En = u.object({ item_stocks: u.array(u.object({
878
- item_id: u.number(),
879
- item_stock: u.number(),
880
- user_limit: u.number()
881
- })) }), Dn = u.object({ platform: u.string().optional() }), On = u.object({ weixin_openid: u.string() }), kn = u.object({ serial_number: u.number() }), An = u.object({
882
- team_code: u.string(),
883
- leader_name: u.string(),
884
- total_members: u.number()
885
- }), jn = u.object({
886
- is_leader: u.bool(),
887
- is_myself: u.bool().optional(),
888
- role_name: u.string(),
889
- server_name: u.string(),
890
- avatar_url: u.string().optional()
891
- }), Mn = u.object({
892
- team_code: u.string(),
817
+ }), un = f.object({
818
+ item_id: f.number(),
819
+ item_count: f.number(),
820
+ redeem_count: f.number()
821
+ }), dn = f.object({ item_stocks: f.array(f.object({
822
+ item_id: f.number(),
823
+ item_stock: f.number(),
824
+ user_limit: f.number()
825
+ })) }), fn = f.object({
826
+ avatar_url: f.string().optional(),
827
+ role_name: f.string(),
828
+ server_name: f.string()
829
+ }), pn = f.object({
830
+ referral_code: f.string().optional(),
831
+ invitee_count: f.number().optional(),
832
+ invitees: f.array(fn).optional()
833
+ }), mn = f.object({
834
+ required_invitees: f.number(),
835
+ unlocked: f.bool(),
836
+ generated: f.bool()
837
+ }), hn = f.object({
838
+ invitee_count: f.number().optional(),
839
+ generated_rewards: f.array(L).optional(),
840
+ referral_tier_status: f.array(mn).optional()
841
+ }), gn = f.object({ platform: f.string().optional() }), _n = f.object({ weixin_openid: f.string() }), vn = f.object({ serial_number: f.number() }), yn = f.object({
842
+ team_code: f.string(),
843
+ leader_name: f.string(),
844
+ total_members: f.number()
845
+ }), bn = f.object({
846
+ is_leader: f.bool(),
847
+ is_myself: f.bool().optional(),
848
+ role_name: f.string(),
849
+ server_name: f.string(),
850
+ avatar_url: f.string().optional()
851
+ }), xn = f.object({
852
+ team_code: f.string(),
893
853
  visibility: nt,
894
- members: u.array(u.object({
895
- is_leader: u.bool(),
896
- role_name: u.string(),
897
- server_name: u.string()
854
+ members: f.array(f.object({
855
+ is_leader: f.bool(),
856
+ role_name: f.string(),
857
+ server_name: f.string()
898
858
  }))
899
- }), Nn = u.object({
900
- ugc_id: u.number(),
901
- title: u.string(),
902
- content: u.string().optional(),
903
- image_urls: u.array(u.string()).optional(),
859
+ }), Sn = f.object({
860
+ ugc_id: f.number(),
861
+ title: f.string(),
862
+ content: f.string().optional(),
863
+ image_urls: f.array(f.string()).optional(),
904
864
  social_media: M.clone().optional(),
905
- social_media_url: u.string().optional()
906
- }), Pn = u.object({
907
- ugcs: u.array(u.object({
908
- ugc_id: u.number(),
909
- event_id: u.number().optional(),
910
- feature_id: u.number().optional(),
911
- title: u.string(),
912
- content: u.string().optional(),
913
- image_urls: u.array(u.string()).optional(),
865
+ social_media_url: f.string().optional()
866
+ }), Cn = f.object({
867
+ ugcs: f.array(f.object({
868
+ ugc_id: f.number(),
869
+ event_id: f.number().optional(),
870
+ feature_id: f.number().optional(),
871
+ title: f.string(),
872
+ content: f.string().optional(),
873
+ image_urls: f.array(f.string()).optional(),
914
874
  social_media: M.clone().optional(),
915
- social_media_url: u.string().optional(),
916
- server_id: u.number().optional(),
917
- server_name: u.string().optional(),
918
- role_id: u.string().optional(),
919
- role_name: u.string().optional(),
920
- total_likes: u.number().optional(),
921
- created_at: u.number()
875
+ social_media_url: f.string().optional(),
876
+ server_id: f.number().optional(),
877
+ server_name: f.string().optional(),
878
+ role_id: f.string().optional(),
879
+ role_name: f.string().optional(),
880
+ total_likes: f.number().optional(),
881
+ created_at: f.number()
922
882
  })).optional(),
923
- next_token: u.string().optional()
924
- }), Fn = u.object({
925
- ugcs: u.array(u.object({
926
- ugc_id: u.number(),
927
- event_id: u.number().optional(),
928
- feature_id: u.number().optional(),
929
- feature_name: u.string().optional(),
930
- review_status: mt,
931
- reviewer_comment: u.string().optional(),
932
- title: u.string(),
933
- content: u.string().optional(),
934
- image_urls: u.array(u.string()).optional(),
883
+ next_token: f.string().optional()
884
+ }), wn = f.object({
885
+ ugcs: f.array(f.object({
886
+ ugc_id: f.number(),
887
+ event_id: f.number().optional(),
888
+ feature_id: f.number().optional(),
889
+ feature_name: f.string().optional(),
890
+ review_status: gt,
891
+ reviewer_comment: f.string().optional(),
892
+ title: f.string(),
893
+ content: f.string().optional(),
894
+ image_urls: f.array(f.string()).optional(),
935
895
  social_media: M.clone().optional(),
936
- social_media_url: u.string().optional(),
937
- server_id: u.number().optional(),
938
- server_name: u.string().optional(),
939
- role_id: u.string().optional(),
940
- role_name: u.string().optional(),
941
- total_likes: u.number().optional(),
942
- created_at: u.number()
896
+ social_media_url: f.string().optional(),
897
+ server_id: f.number().optional(),
898
+ server_name: f.string().optional(),
899
+ role_id: f.string().optional(),
900
+ role_name: f.string().optional(),
901
+ total_likes: f.number().optional(),
902
+ created_at: f.number()
943
903
  })).optional(),
944
- next_token: u.string().optional()
945
- }), In = u.object({ total_count: u.number() }), Ln = u.object({
946
- existed: u.bool(),
947
- upload_url: u.string().optional(),
948
- image_url: u.string()
949
- }), Rn = u.object({ ugcs: u.array(u.object({
950
- ugc_id: u.number(),
951
- rank: u.number(),
952
- total_likes: u.number(),
953
- image_urls: u.array(u.string()).optional(),
954
- server_id: u.number().optional(),
955
- server_name: u.string().optional(),
956
- role_id: u.string().optional(),
957
- role_name: u.string().optional()
958
- })).optional() }), R = u.object({ option_sn: u.string() }), zn = u.object({
959
- candidate_id: u.string(),
960
- total_votes: u.number().optional(),
961
- my_votes: u.number().optional(),
962
- cycle_votes: u.number().optional(),
963
- votes: u.number().optional()
964
- }), Bn = u.object({
965
- rewards_type: dt,
966
- rewards: u.array(L).optional()
967
- }), Vn = u.object({
968
- candidate_id: u.string(),
969
- is_winner: u.bool(),
970
- total_votes: u.number(),
971
- my_votes: u.number(),
972
- cycle_votes: u.number().optional()
973
- }), Hn = u.object({
974
- role: u.string(),
975
- content: u.string()
976
- }), Un = u.object({ conversations: u.array(Hn) }), Wn = u.object({
977
- user_id: u.string(),
978
- name: u.string(),
979
- avatar_url: u.string(),
980
- comment: u.string(),
981
- video_note: u.number(),
982
- created_at: u.number()
983
- }), z = u.union(xn, _n, kn, gn, Dn, R, zn, On, I, hn, Mn, Cn, bn, mn, Un, Nn, Tn, u.custom("EmptyObject", (e) => t(e) && Object.keys(e).length === 0)).satisfies().lock(), Gn = u.object({
984
- reward_id: u.number(),
985
- reward_item_id: u.number(),
904
+ next_token: f.string().optional()
905
+ }), Tn = f.object({ total_count: f.number() }), En = f.object({
906
+ existed: f.bool(),
907
+ upload_url: f.string().optional(),
908
+ image_url: f.string()
909
+ }), Dn = f.object({ ugcs: f.array(f.object({
910
+ ugc_id: f.number(),
911
+ rank: f.number(),
912
+ total_likes: f.number(),
913
+ image_urls: f.array(f.string()).optional(),
914
+ server_id: f.number().optional(),
915
+ server_name: f.string().optional(),
916
+ role_id: f.string().optional(),
917
+ role_name: f.string().optional()
918
+ })).optional() }), On = f.object({ option_sn: f.string() }), kn = f.object({
919
+ candidate_id: f.string(),
920
+ total_votes: f.number().optional(),
921
+ my_votes: f.number().optional(),
922
+ cycle_votes: f.number().optional(),
923
+ votes: f.number().optional()
924
+ }), An = f.object({
925
+ rewards_type: pt,
926
+ rewards: f.array(L).optional()
927
+ }), jn = f.object({
928
+ candidate_id: f.string(),
929
+ is_winner: f.bool(),
930
+ total_votes: f.number(),
931
+ my_votes: f.number(),
932
+ cycle_votes: f.number().optional()
933
+ }), Mn = f.object({
934
+ role: f.string(),
935
+ content: f.string()
936
+ }), Nn = f.object({ conversations: f.array(Mn) }), Pn = f.object({
937
+ user_id: f.string(),
938
+ name: f.string(),
939
+ avatar_url: f.string(),
940
+ comment: f.string(),
941
+ video_note: f.number(),
942
+ created_at: f.number()
943
+ }), R = f.union(on, tn, vn, en, gn, On, kn, _n, I, $t, xn, cn, an, Qt, Nn, Sn, un, pn, f.custom("EmptyObject", (e) => t(e) && Object.keys(e).length === 0)).satisfies().lock(), z = f.object({
944
+ reward_id: f.number(),
945
+ reward_item_id: f.number(),
986
946
  reward_item_type: w,
987
- reward_count: u.number(),
947
+ reward_count: f.number(),
988
948
  reward_status: O,
989
949
  reward_source: A,
990
- reward_item_name: u.string(),
991
- reward_item_icon_url: u.string(),
992
- reward_item_desc: u.string().optional(),
993
- reward_item_rating: u.number(),
994
- receive_time: u.number(),
995
- extra_data: u.union(...z.validators, u.record(u.unknown())).satisfies().optional()
996
- }), Kn = u.object({
997
- reward_id: u.number(),
998
- reward_item_id: u.number(),
999
- reward_item_name: u.string(),
950
+ reward_item_name: f.string(),
951
+ reward_item_icon_url: f.string(),
952
+ reward_item_desc: f.string().optional(),
953
+ reward_item_rating: f.number(),
954
+ receive_time: f.number(),
955
+ extra_data: f.union(...R.validators, f.record(f.unknown())).satisfies().optional()
956
+ }), Fn = f.object({
957
+ reward_id: f.number(),
958
+ reward_item_id: f.number(),
959
+ reward_item_name: f.string(),
1000
960
  reward_item_type: w,
1001
- reward_item_icon_url: u.string(),
1002
- reward_item_desc: u.string().optional(),
1003
- reward_item_rating: u.number(),
1004
- reward_amount: u.number(),
961
+ reward_item_icon_url: f.string(),
962
+ reward_item_desc: f.string().optional(),
963
+ reward_item_rating: f.number(),
964
+ reward_amount: f.number(),
1005
965
  reward_status: O,
1006
966
  reward_source: A,
1007
- extra_data: u.record(u.unknown()).optional()
1008
- }), qn = u.object({
1009
- engagement_id: u.number(),
1010
- user_id: u.string(),
1011
- event_id: u.number(),
1012
- feature_id: u.number(),
1013
- sequence: u.number(),
1014
- data: z.clone().optional(),
1015
- server_id: u.string().optional(),
1016
- role_id: u.string().optional(),
1017
- created_at: u.number(),
1018
- rewards: u.array(Gn).optional()
1019
- }).lock(), Jn = u.object({
1020
- allowed: u.bool(),
1021
- registered: u.bool()
1022
- }), Yn = u.object({
1023
- feature_id: u.number(),
1024
- can_engage: u.bool(),
1025
- has_unclaimed_rewards: u.bool(),
1026
- final_available_count: u.number(),
1027
- total_remaining_engagements: u.number(),
1028
- cycle_remaining_engagements: u.number(),
1029
- eligible: u.bool().optional(),
1030
- actions: u.array(u.object({
1031
- action_type: u.string(),
1032
- allowed: u.bool()
967
+ extra_data: f.record(f.unknown()).optional()
968
+ }), In = f.object({
969
+ engagement_id: f.number(),
970
+ user_id: f.string(),
971
+ event_id: f.number(),
972
+ feature_id: f.number(),
973
+ sequence: f.number(),
974
+ data: R.clone().optional(),
975
+ server_id: f.string().optional(),
976
+ role_id: f.string().optional(),
977
+ created_at: f.number(),
978
+ rewards: f.array(z).optional()
979
+ }).lock(), Ln = T.Referral, Rn = f.object({
980
+ required_invitees: f.number(),
981
+ rewards: f.array(z)
982
+ }), zn = f.object({
983
+ ...P.shape,
984
+ feature_type: f.string().enum(Ln),
985
+ config: f.object({
986
+ max_recent_invitees: f.number(),
987
+ referral_tier: f.array(Rn)
988
+ })
989
+ }), Bn = T.Register, Vn = f.object({
990
+ ...P.shape,
991
+ feature_type: f.string().enum(Bn)
992
+ }), Hn = T.Share, Un = f.object({
993
+ ...P.shape,
994
+ feature_type: f.string().enum(Hn),
995
+ config: f.object({
996
+ share_platform: f.string(),
997
+ jump_url: f.string().optional(),
998
+ icon_url: f.string().optional()
999
+ })
1000
+ }), Wn = T.Subscribe, Gn = f.object({
1001
+ ...P.shape,
1002
+ feature_type: f.string().enum(Wn),
1003
+ config: f.object({ weixin_template_ids: f.array(f.string()) })
1004
+ }), Kn = T.Survey, qn = f.object({
1005
+ ...P.shape,
1006
+ feature_type: f.string().enum(Kn),
1007
+ config: f.object({
1008
+ survey_id: f.string(),
1009
+ survey_url: f.string()
1010
+ })
1011
+ }), Jn = T.Team, Yn = f.object({
1012
+ ...P.shape,
1013
+ feature_type: f.string().enum(Jn),
1014
+ config: f.object({
1015
+ max_members: f.number().min(1),
1016
+ min_members: f.number().min(1)
1017
+ })
1018
+ }), Xn = T.Ugc, Zn = f.object({
1019
+ ...P.shape,
1020
+ feature_type: f.string().enum(Xn),
1021
+ config: f.object({
1022
+ allowed_social_medias: f.array(f.string()).optional(),
1023
+ acceptance_rewards: f.array(N).optional()
1024
+ })
1025
+ }), Qn = T.UgcLike, $n = f.object({
1026
+ ...P.shape,
1027
+ feature_type: f.string().enum(Qn),
1028
+ config: f.object({ ugc_feature_id: f.number() })
1029
+ }), er = T.Vote, tr = f.object({
1030
+ sn: f.string(),
1031
+ name: f.string(),
1032
+ img_urls: f.array(f.string()).optional(),
1033
+ video_urls: f.array(f.string()).optional(),
1034
+ descriptions: f.array(f.string()).optional(),
1035
+ jump_url: f.string(),
1036
+ amount: f.number(),
1037
+ finalists: f.bool(),
1038
+ last_vote_time: f.number()
1039
+ }), nr = f.object({
1040
+ ...P.shape,
1041
+ feature_type: f.string().enum(er),
1042
+ config: f.object({
1043
+ vote_feature_ids: f.array(f.number()),
1044
+ submission_feature_ids: f.array(f.number()),
1045
+ finalists_amount: f.number(),
1046
+ source: Qe,
1047
+ options: f.array(tr),
1048
+ rewards: f.array(N)
1049
+ })
1050
+ }), rr = f.object({
1051
+ allowed: f.bool(),
1052
+ registered: f.bool()
1053
+ }), ir = f.object({
1054
+ feature_id: f.number(),
1055
+ can_engage: f.bool(),
1056
+ has_unclaimed_rewards: f.bool(),
1057
+ final_available_count: f.number(),
1058
+ total_remaining_engagements: f.number(),
1059
+ cycle_remaining_engagements: f.number(),
1060
+ eligible: f.bool().optional(),
1061
+ actions: f.array(f.object({
1062
+ action_type: f.string(),
1063
+ allowed: f.bool()
1033
1064
  })).optional()
1034
- }), Xn = u.object({
1035
- engagement_id: u.number(),
1036
- engagement: u.object({
1037
- engagement_id: u.number(),
1038
- sequence: u.number(),
1039
- feature_id: u.number(),
1040
- data: z.clone().optional()
1065
+ }), ar = f.object({
1066
+ engagement_id: f.number(),
1067
+ engagement: f.object({
1068
+ engagement_id: f.number(),
1069
+ sequence: f.number(),
1070
+ feature_id: f.number(),
1071
+ data: R.clone().optional()
1041
1072
  }).optional(),
1042
- rewards: u.array(Kn).optional(),
1043
- scan: u.bool().optional()
1044
- }), Zn = u.object({
1045
- reward_id: u.number(),
1073
+ rewards: f.array(Fn).optional(),
1074
+ scan: f.bool().optional()
1075
+ }), or = f.object({
1076
+ reward_id: f.number(),
1046
1077
  reward_status: k
1047
- }), Qn = T.Vote2, $n = u.object({
1048
- candidate_id: u.string(),
1049
- display_name: u.string(),
1050
- images: u.array(u.string()).optional(),
1051
- videos: u.array(u.string()).optional(),
1052
- description: u.string().optional(),
1053
- jump_url: u.string()
1054
- }), er = u.object({
1078
+ }), sr = T.Vote2, cr = f.object({
1079
+ candidate_id: f.string(),
1080
+ display_name: f.string(),
1081
+ images: f.array(f.string()).optional(),
1082
+ videos: f.array(f.string()).optional(),
1083
+ description: f.string().optional(),
1084
+ jump_url: f.string()
1085
+ }), lr = f.object({
1055
1086
  ...P.shape,
1056
- feature_type: u.string().enum(Qn),
1057
- config: u.object({
1058
- vote_item_id: u.number().optional(),
1059
- candidates: u.array($n),
1060
- vote_since: u.number(),
1061
- vote_until: u.number(),
1062
- rewards_since: u.number(),
1063
- rewards_until: u.number(),
1064
- winner_rewards: u.array(N).optional(),
1065
- consolation_rewards: u.array(N).optional(),
1066
- max_votes_per_user_per_candidate_per_cycle: u.number().optional()
1087
+ feature_type: f.string().enum(sr),
1088
+ config: f.object({
1089
+ vote_item_id: f.number().optional(),
1090
+ candidates: f.array(cr),
1091
+ vote_since: f.number(),
1092
+ vote_until: f.number(),
1093
+ rewards_since: f.number(),
1094
+ rewards_until: f.number(),
1095
+ winner_rewards: f.array(N).optional(),
1096
+ consolation_rewards: f.array(N).optional(),
1097
+ max_votes_per_user_per_candidate_per_cycle: f.number().optional()
1067
1098
  })
1068
- }), tr = T.ZeroChatgpt, nr = u.object({
1099
+ }), ur = T.ZeroChatgpt, dr = f.object({
1069
1100
  ...P.shape,
1070
- feature_type: u.string().enum(tr)
1071
- }), rr = u.union(yt, xt, Tt, Dt, kt, Mt, Pt, It, Bt, Ht, Wt, Kt, Zt, $t, tn, rn, on, pn, er, Ct, nr, cn, un, Yt).key("feature_type").satisfies(), ir = u.object({
1072
- event_name: u.string(),
1073
- rules: u.string(),
1074
- since: u.number(),
1075
- until: u.number(),
1076
- visit_count: u.number().optional(),
1077
- features: u.array(rr)
1078
- }).lock(), ar = u.guard(ir), or = u.guard(Jn), B = l({ count: u.number() }), sr = l({ first_visit: u.bool() }), cr = l({ engagements: u.union(u.array(Wn), u.array(An)) }), lr = l({ status: u.array(Yn) }), ur = l({ engagements_counts: u.record(u.number()) }), dr = l({
1079
- engagements: u.array(qn),
1080
- next_token: u.string().optional()
1081
- }), fr = u.guard(Xn), pr = l({ claimed_items: u.array(Zn) }), mr = l({ rewards: u.array(L) }), hr = l({ reward_status: k }), gr = l({
1082
- user_rewards: u.array(L),
1083
- next_token: u.string().optional()
1084
- }), _r = l({ unclaimed: u.number() }), vr = l({ scene: u.string() }), yr = l({ params: u.string() }), br = l({ img: u.string() }), xr = u.guard(wn), Sr = u.guard(Bn), Cr = u.guard(u.object({ candidate_votes: u.array(Vn) })), wr = u.guard(I), Tr = u.guard(Fn), Er = u.guard(Pn), Dr = u.guard(In), Or = u.guard(Ln), kr = u.guard(Rn), Ar = u.guard(En);
1101
+ feature_type: f.string().enum(ur)
1102
+ }), fr = f.union(xt, Ct, Dt, kt, jt, Pt, It, Rt, Ht, Wt, Kt, Jt, Vn, Un, Gn, qn, Yn, nr, lr, Tt, dr, Zn, $n, Zt, zn).key("feature_type").satisfies(), pr = f.object({
1103
+ event_name: f.string(),
1104
+ rules: f.string(),
1105
+ since: f.number(),
1106
+ until: f.number(),
1107
+ visit_count: f.number().optional(),
1108
+ features: f.array(fr)
1109
+ }).lock(), mr = f.guard(pr), hr = f.guard(rr), B = d({ count: f.number() }), gr = d({ first_visit: f.bool() }), _r = d({ engagements: f.union(f.array(Pn), f.array(yn)) }), vr = d({ status: f.array(ir) }), yr = d({ engagements_counts: f.record(f.number()) }), br = d({
1110
+ engagements: f.array(In),
1111
+ next_token: f.string().optional()
1112
+ }), xr = f.guard(ar), Sr = d({ claimed_items: f.array(or) }), Cr = d({ rewards: f.array(L) }), wr = d({ reward_status: k }), Tr = d({
1113
+ user_rewards: f.array(L),
1114
+ next_token: f.string().optional()
1115
+ }), Er = d({ unclaimed: f.number() }), Dr = d({ scene: f.string() }), Or = d({ params: f.string() }), kr = d({ img: f.string() }), Ar = f.guard(ln), jr = f.guard(An), Mr = f.guard(f.object({ candidate_votes: f.array(jn) })), Nr = f.guard(I), Pr = f.guard(wn), Fr = f.guard(Cn), Ir = f.guard(Tn), Lr = f.guard(En), Rr = f.guard(Dn), zr = f.guard(dn), Br = f.guard(hn);
1085
1116
  //#endregion
1086
1117
  //#region src/event.methods.ts
1087
- async function jr(e, t, n) {
1118
+ async function Vr(e, t, n) {
1088
1119
  let { data: r } = await this.req.get("verify-mobile-allowed", {
1089
1120
  game_id: e,
1090
1121
  mobile: t
1091
- }, or, n);
1122
+ }, hr, n);
1092
1123
  return r;
1093
1124
  }
1094
- async function Mr(e) {
1095
- let { data: t } = await this.req.get(`event/${this.event}/event-config`, null, ar, e);
1125
+ async function Hr(e) {
1126
+ let { data: t } = await this.req.get(`event/${this.event}/event-config`, null, mr, e);
1096
1127
  return t;
1097
1128
  }
1098
- async function Nr(e, t) {
1129
+ async function Ur(e, t) {
1099
1130
  let { data: n } = await this.req.get(`event/${this.event}/feature-engagement-count`, {
1100
1131
  feature_id: e,
1101
1132
  type: "user"
1102
1133
  }, B, t);
1103
1134
  return n?.count ?? null;
1104
1135
  }
1105
- async function Pr(e, t) {
1136
+ async function Wr(e, t) {
1106
1137
  let { data: n } = await this.req.get(`event/${this.event}/feature-engagement-count`, {
1107
1138
  feature_id: e,
1108
1139
  type: "engagement"
1109
1140
  }, B, t);
1110
1141
  return n?.count ?? null;
1111
1142
  }
1112
- async function Fr(e, t) {
1113
- let { data: n } = await this.req.get(`event/${this.event}/feature-engagements`, { feature_id: e }, cr, t);
1143
+ async function Gr(e, t) {
1144
+ let { data: n } = await this.req.get(`event/${this.event}/feature-engagements`, { feature_id: e }, _r, t);
1114
1145
  return n?.engagements || [];
1115
1146
  }
1116
- async function Ir(e, t) {
1147
+ async function Kr(e, t) {
1117
1148
  await this.token.autoLogin();
1118
- let { data: n, code: r, message: i } = await this.req.post(`event/${this.event}/visit`, a(e || {}), sr, t);
1149
+ let { data: n, code: r, message: i } = await this.req.post(`event/${this.event}/visit`, a(e || {}), gr, t);
1119
1150
  return n ?? {
1120
1151
  message: i,
1121
1152
  error: r
1122
1153
  };
1123
1154
  }
1124
- async function Lr(e, t) {
1155
+ async function qr(e, t) {
1125
1156
  if (!await this.token.autoLogin()) return [];
1126
1157
  let { data: n } = await this.req.get("event/user-feature-status", {
1127
1158
  ...e,
1128
1159
  event_id: this.event
1129
- }, lr, {
1160
+ }, vr, {
1130
1161
  ...t,
1131
1162
  message: !1
1132
1163
  });
1133
1164
  return n?.status || [];
1134
1165
  }
1135
- async function Rr(e, t) {
1166
+ async function Jr(e, t) {
1136
1167
  if (!await this.token.autoLogin()) return {};
1137
1168
  let { data: n } = await this.req.get("event/user-engagements-count", {
1138
1169
  ...t,
1139
1170
  event_id: this.event,
1140
1171
  feature_id: e
1141
- }, ur, { message: !1 });
1172
+ }, yr, { message: !1 });
1142
1173
  return n?.engagements_counts || {};
1143
1174
  }
1144
- async function zr(e, t, n) {
1175
+ async function Yr(e, t, n) {
1145
1176
  if (!await this.token.autoLogin()) return {
1146
1177
  engagements: [],
1147
1178
  next_token: ""
@@ -1151,36 +1182,36 @@ async function zr(e, t, n) {
1151
1182
  ...t,
1152
1183
  event_id: this.event,
1153
1184
  feature_id: e
1154
- }, dr, n);
1185
+ }, br, n);
1155
1186
  return {
1156
1187
  engagements: r?.engagements || [],
1157
1188
  next_token: r?.next_token || ""
1158
1189
  };
1159
1190
  }
1160
- async function Br(e, t, n, r) {
1191
+ async function Xr(e, t, n, r) {
1161
1192
  await this.token.autoLogin();
1162
1193
  let { data: i, code: o, message: s } = await this.req.post(`event/${this.event}/engage`, a({
1163
1194
  feature_id: e,
1164
1195
  engagement: t,
1165
1196
  ...n
1166
- }), fr, r);
1197
+ }), xr, r);
1167
1198
  return i ?? {
1168
1199
  message: s,
1169
1200
  error: o
1170
1201
  };
1171
1202
  }
1172
- async function Vr(e, t) {
1203
+ async function Zr(e, t) {
1173
1204
  await this.token.autoLogin();
1174
1205
  let { data: n, code: r, message: i } = await this.req.post("event/claim-rewards", a({
1175
1206
  ...e,
1176
1207
  server_id: e.server_id ? +e.server_id : void 0
1177
- }), pr, t);
1208
+ }), Sr, t);
1178
1209
  return n?.claimed_items || {
1179
1210
  message: i,
1180
1211
  error: r
1181
1212
  };
1182
1213
  }
1183
- async function Hr(e, t) {
1214
+ async function Qr(e, t) {
1184
1215
  if (!await this.token.autoLogin()) return null;
1185
1216
  let { ok: n, code: r, message: i } = await this.req.post(`event/${this.event}/user-reward-address`, e, null, t);
1186
1217
  return n || {
@@ -1188,23 +1219,23 @@ async function Hr(e, t) {
1188
1219
  error: r
1189
1220
  };
1190
1221
  }
1191
- async function Ur(e, t) {
1222
+ async function $r(e, t) {
1192
1223
  if (!await this.token.autoLogin()) return null;
1193
- let { data: n } = await this.req.get("event/unlimit-qrcode-scene", { params: e }, vr, t);
1224
+ let { data: n } = await this.req.get("event/unlimit-qrcode-scene", { params: e }, Dr, t);
1194
1225
  return n?.scene ?? null;
1195
1226
  }
1196
- async function Wr(e, t) {
1197
- let { data: n } = await this.req.get("event/params-by-qrcode-scene", { scene: e }, yr, t);
1227
+ async function ei(e, t) {
1228
+ let { data: n } = await this.req.get("event/params-by-qrcode-scene", { scene: e }, Or, t);
1198
1229
  return n?.params ?? null;
1199
1230
  }
1200
- async function Gr(e, t) {
1231
+ async function ti(e, t) {
1201
1232
  if (!await this.token.autoLogin()) return null;
1202
- let { data: n } = await this.req.post("event/unlimit-qrcode", a(e), br, t);
1233
+ let { data: n } = await this.req.post("event/unlimit-qrcode", a(e), kr, t);
1203
1234
  return n?.img ?? null;
1204
1235
  }
1205
- async function Kr(e, t) {
1236
+ async function ni(e, t) {
1206
1237
  if (!await this.token.autoLogin()) return null;
1207
- let { data: n, code: r, message: i } = await this.req.get(`event/${this.event}/quest-progress`, { feature_id: e }, xr, {
1238
+ let { data: n, code: r, message: i } = await this.req.get(`event/${this.event}/quest-progress`, { feature_id: e }, Ar, {
1208
1239
  message: !1,
1209
1240
  ...t
1210
1241
  });
@@ -1213,75 +1244,75 @@ async function Kr(e, t) {
1213
1244
  error: r
1214
1245
  };
1215
1246
  }
1216
- async function qr(e, t) {
1247
+ async function ri(e, t) {
1217
1248
  if (!await this.token.autoLogin()) return null;
1218
1249
  let { data: n, code: r, message: i } = await this.req.post("event/vote2/rewards", {
1219
1250
  feature_id: e,
1220
1251
  event_id: this.event
1221
- }, Sr, t);
1252
+ }, jr, t);
1222
1253
  return n || {
1223
1254
  message: i,
1224
1255
  code: r
1225
1256
  };
1226
1257
  }
1227
- async function Jr(e, t) {
1258
+ async function ii(e, t) {
1228
1259
  if (!await this.token.autoLogin()) return [];
1229
1260
  let { data: n } = await this.req.get("event/vote2/leaderboard", {
1230
1261
  feature_id: e,
1231
1262
  event_id: this.event
1232
- }, Cr, t);
1263
+ }, Mr, t);
1233
1264
  return n?.candidate_votes || [];
1234
1265
  }
1235
- async function Yr(e, t) {
1266
+ async function ai(e, t) {
1236
1267
  if (!await this.token.autoLogin()) return null;
1237
1268
  let { data: n, code: r, message: i } = await this.req.get("event/cashback/query", {
1238
1269
  feature_id: e,
1239
1270
  event_id: this.event
1240
- }, wr, t);
1271
+ }, Nr, t);
1241
1272
  return n || {
1242
1273
  message: i,
1243
1274
  error: r
1244
1275
  };
1245
1276
  }
1246
- async function Xr(e, t) {
1277
+ async function oi(e, t) {
1247
1278
  if (!await this.token.autoLogin()) return null;
1248
1279
  let { data: n, code: r, message: i } = await this.req.get("event/ugc/my", {
1249
1280
  max_results: 20,
1250
1281
  ...e
1251
- }, Tr, t);
1282
+ }, Pr, t);
1252
1283
  return n || {
1253
1284
  message: i,
1254
1285
  error: r
1255
1286
  };
1256
1287
  }
1257
- async function Zr(e, t) {
1288
+ async function si(e, t) {
1258
1289
  if (!await this.token.autoLogin()) return null;
1259
- let { data: n, code: r, message: i } = await this.req.get("event/ugc/my-count", { ...e }, Dr, t);
1290
+ let { data: n, code: r, message: i } = await this.req.get("event/ugc/my-count", { ...e }, Ir, t);
1260
1291
  return n || {
1261
1292
  message: i,
1262
1293
  error: r
1263
1294
  };
1264
1295
  }
1265
- async function Qr(e, t) {
1296
+ async function ci(e, t) {
1266
1297
  await this.token.autoLogin();
1267
1298
  let { data: n, code: r, message: i } = await this.req.post("event/claim-rewards-v2", a({
1268
1299
  ...e,
1269
1300
  server_id: e.server_id ? +e.server_id : void 0
1270
- }), mr, t);
1301
+ }), Cr, t);
1271
1302
  return n?.rewards || {
1272
1303
  message: i,
1273
1304
  error: r
1274
1305
  };
1275
1306
  }
1276
- async function $r(e, t) {
1307
+ async function li(e, t) {
1277
1308
  await this.token.autoLogin();
1278
- let { data: n, code: r, message: i } = await this.req.post("event/claim-weixin-hongbao", { reward_id: e }, hr, t);
1309
+ let { data: n, code: r, message: i } = await this.req.post("event/claim-weixin-hongbao", { reward_id: e }, wr, t);
1279
1310
  return n || {
1280
1311
  message: i,
1281
1312
  error: r
1282
1313
  };
1283
1314
  }
1284
- async function ei(e, t) {
1315
+ async function ui(e, t) {
1285
1316
  if (!this.token.isLoggedIn) return { error: "not_logged_in" };
1286
1317
  let { ok: n, code: r, message: i } = await this.req.post("verify-activation-key", { activation_key: e }, null, {
1287
1318
  message: !1,
@@ -1292,7 +1323,7 @@ async function ei(e, t) {
1292
1323
  error: r
1293
1324
  };
1294
1325
  }
1295
- async function ti(e, t) {
1326
+ async function di(e, t) {
1296
1327
  if (!await this.token.autoLogin()) return {
1297
1328
  user_rewards: [],
1298
1329
  next_token: ""
@@ -1301,73 +1332,84 @@ async function ti(e, t) {
1301
1332
  max_results: 20,
1302
1333
  ...e,
1303
1334
  event_id: this.event
1304
- }), gr, t);
1335
+ }), Tr, t);
1305
1336
  return {
1306
1337
  user_rewards: n?.user_rewards || [],
1307
1338
  next_token: n?.next_token || ""
1308
1339
  };
1309
1340
  }
1310
- async function ni(e, t) {
1341
+ async function fi(e, t) {
1311
1342
  if (!await this.token.autoLogin()) return { unclaimed: 0 };
1312
- let { data: n } = await this.req.get("event/user-rewards-count", { ...e }, _r, t);
1343
+ let { data: n } = await this.req.get("event/user-rewards-count", { ...e }, Er, t);
1313
1344
  return { unclaimed: n?.unclaimed || 0 };
1314
1345
  }
1315
- async function ri(e, t) {
1346
+ async function pi(e, t) {
1316
1347
  if (!await this.token.autoLogin()) return null;
1317
1348
  let { data: n } = await this.req.get(`event/${this.event}/user-item-count`, { item_id: e }, B, t);
1318
1349
  return n?.count ?? null;
1319
1350
  }
1320
- async function ii(e, t, n) {
1351
+ async function mi(e, t, n) {
1321
1352
  if (!await this.token.autoLogin()) return null;
1322
1353
  let { data: r, code: i, message: a } = await this.req.post("event/ugc/upload-image", {
1323
1354
  feature_id: e,
1324
1355
  ...t,
1325
1356
  event_id: this.event
1326
- }, Or, n);
1357
+ }, Lr, n);
1327
1358
  return r || {
1328
1359
  message: a,
1329
1360
  error: i
1330
1361
  };
1331
1362
  }
1332
- async function ai(e, t) {
1363
+ async function hi(e, t) {
1333
1364
  let { data: n, code: r, message: i } = await this.req.get("event/ugc/recommendation", {
1334
1365
  feature_id: e,
1335
1366
  event_id: this.event
1336
- }, Tr, t);
1367
+ }, Pr, t);
1337
1368
  return n || {
1338
1369
  message: i,
1339
1370
  error: r
1340
1371
  };
1341
1372
  }
1342
- async function oi(e, t, n) {
1373
+ async function gi(e, t, n) {
1343
1374
  let { data: r, code: i, message: a } = await this.req.get("event/ugc/ugcs", {
1344
1375
  event_id: this.event,
1345
1376
  feature_id: e,
1346
1377
  max_results: 20,
1347
1378
  ...t
1348
- }, Er, n);
1379
+ }, Fr, n);
1349
1380
  return r || {
1350
1381
  message: a,
1351
1382
  error: i
1352
1383
  };
1353
1384
  }
1354
- async function si(e, t) {
1385
+ async function _i(e, t) {
1355
1386
  if (!await this.token.autoLogin()) return null;
1356
1387
  let { data: n, code: r, message: i } = await this.req.get("event/ugc/leaderboard", {
1357
1388
  feature_id: e,
1358
1389
  event_id: this.event
1359
- }, kr, t);
1390
+ }, Rr, t);
1360
1391
  return n || {
1361
1392
  message: i,
1362
1393
  error: r
1363
1394
  };
1364
1395
  }
1365
- async function ci(e, t) {
1396
+ async function vi(e, t) {
1366
1397
  if (!await this.token.autoLogin()) return null;
1367
1398
  let { data: n, code: r, message: i } = await this.req.get("event/redeem/item-stocks", {
1368
1399
  event_id: this.event,
1369
1400
  feature_id: e
1370
- }, Ar, t);
1401
+ }, zr, t);
1402
+ return n || {
1403
+ message: i,
1404
+ error: r
1405
+ };
1406
+ }
1407
+ async function yi(e, t) {
1408
+ if (!await this.token.autoLogin()) return null;
1409
+ let { data: n, code: r, message: i } = await this.req.post("event/referral/rewards", {
1410
+ event_id: this.event,
1411
+ feature_id: e
1412
+ }, Br, t);
1371
1413
  return n || {
1372
1414
  message: i,
1373
1415
  error: r
@@ -1375,15 +1417,14 @@ async function ci(e, t) {
1375
1417
  }
1376
1418
  //#endregion
1377
1419
  //#region src/ggd.enums.ts
1378
- var li = {
1420
+ var bi = {
1379
1421
  Waiting: 1,
1380
1422
  Playing: 2
1381
- }, ui = u.number().enum(li).lock(), di = class {
1423
+ }, xi = f.number().enum(bi).lock(), Si = class {
1382
1424
  req;
1383
1425
  constructor(e, t) {
1384
- let n = d(e) ? e : `https://${o(e)}`;
1385
1426
  this.req = t({
1386
- baseURL: `${n}/v1/ggd`,
1427
+ baseURL: `${oe(e) ? e : `https://${o(e)}`}/v1/ggd`,
1387
1428
  timeout: 1e4,
1388
1429
  maxRetry: 2,
1389
1430
  retryInterval: "2EB",
@@ -1397,38 +1438,50 @@ var li = {
1397
1438
  }
1398
1439
  });
1399
1440
  }
1400
- async describeRoomByCode(e) {
1401
- let { data: t, ok: n, code: r, message: i } = await this.req.get("describe-room", { invitation_code: e || s("invitation_code") }, l({
1402
- room_id: u.string(),
1403
- inviter_role_id: u.number(),
1404
- room_status: ui,
1405
- room_mode: u.string(),
1406
- room_tags: u.array(u.string()),
1407
- max_members: u.number(),
1408
- members: u.array(u.object({
1409
- role_id: u.number(),
1410
- role_name: u.string(),
1411
- avatar_url: u.string()
1412
- }))
1441
+ async describeRoomByCode(e, t, n) {
1442
+ let r = String(n || s("expires_at")), i = e || s("invitation_code"), a = t || s("server_id");
1443
+ if (!i && !a || !/^\d+$/.test(r)) return {
1444
+ error: "invitation_code_invalid",
1445
+ message: "邀请链接无效"
1446
+ };
1447
+ if (r && Date.now() > Number(r) * 1e3) return {
1448
+ error: "invitation_code_expired",
1449
+ message: "邀请链接已过期"
1450
+ };
1451
+ let { data: o, ok: c, code: l, message: u } = await this.req.get("describe-room", {
1452
+ invitation_code: i,
1453
+ server_id: a
1454
+ }, d({
1455
+ room_id: f.string(),
1456
+ inviter_role_id: f.number(),
1457
+ room_status: xi,
1458
+ room_mode: f.string().optional(),
1459
+ room_tags: f.array(f.string()).optional(),
1460
+ max_members: f.number().optional(),
1461
+ members: f.array(f.object({
1462
+ role_id: f.number(),
1463
+ role_name: f.string(),
1464
+ avatar_url: f.string()
1465
+ })).optional()
1413
1466
  }), { message: !1 });
1414
- return n && t ? t : {
1415
- error: r,
1416
- message: i
1467
+ return c && o ? o : {
1468
+ error: l,
1469
+ message: u
1417
1470
  };
1418
1471
  }
1419
- }, fi = {
1472
+ }, Ci = {
1420
1473
  All: "all",
1421
1474
  Limit: "limit"
1422
- }, pi = u.string().enum(fi).lock(), mi = {
1475
+ }, wi = f.string().enum(Ci).lock(), Ti = {
1423
1476
  Pending: "pending",
1424
1477
  Approved: "approved",
1425
1478
  Failed: "failed",
1426
1479
  Suspect: "suspect"
1427
- }, V = u.string().enum(mi).lock(), hi = {
1480
+ }, V = f.string().enum(Ti).lock(), Ei = {
1428
1481
  System: "system",
1429
1482
  Comment: "comment",
1430
1483
  Like: "like"
1431
- }, gi = u.string().enum(hi).lock(), H = {
1484
+ }, Di = f.string().enum(Ei).lock(), H = {
1432
1485
  System: "system",
1433
1486
  PostPinned: "post_pinned",
1434
1487
  PostHighlighted: "post_highlighted",
@@ -1441,188 +1494,188 @@ var li = {
1441
1494
  ReplyReplied: "reply_replied",
1442
1495
  ReplyLiked: "reply_liked",
1443
1496
  ReplyDeleted: "reply_deleted"
1444
- }, _i = u.string().enum(H).lock(), U = u.object({
1445
- forum_id: u.number(),
1446
- icon_url: u.string(),
1447
- name: u.string(),
1448
- tags: u.array(u.string()),
1449
- sort: u.number(),
1450
- mode: pi,
1451
- member_ids: u.array(u.number())
1452
- }).lock(), W = u.object({
1453
- topic_id: u.number(),
1454
- cover_url: u.string(),
1455
- name: u.string(),
1456
- description: u.string(),
1457
- tags: u.array(u.string()),
1458
- post_num: u.number()
1459
- }).lock(), G = u.object({
1460
- post_id: u.number(),
1497
+ }, Oi = f.string().enum(H).lock(), U = f.object({
1498
+ forum_id: f.number(),
1499
+ icon_url: f.string(),
1500
+ name: f.string(),
1501
+ tags: f.array(f.string()),
1502
+ sort: f.number(),
1503
+ mode: wi,
1504
+ member_ids: f.array(f.number())
1505
+ }).lock(), W = f.object({
1506
+ topic_id: f.number(),
1507
+ cover_url: f.string(),
1508
+ name: f.string(),
1509
+ description: f.string(),
1510
+ tags: f.array(f.string()),
1511
+ post_num: f.number()
1512
+ }).lock(), G = f.object({
1513
+ post_id: f.number(),
1461
1514
  forum: U,
1462
- posted_by: u.string(),
1463
- nickname: u.string(),
1464
- avatar_url: u.string(),
1465
- title: u.string().optional(),
1466
- content: u.string(),
1467
- content_text_count: u.number(),
1468
- summary: u.string(),
1469
- like_num: u.number(),
1470
- comments_num: u.number(),
1471
- liked: u.bool(),
1472
- image_urls: u.array(u.string()),
1473
- topics: u.array(W),
1474
- event_ids: u.array(u.number()),
1475
- is_pinned: u.bool(),
1476
- is_highlighted: u.bool(),
1515
+ posted_by: f.string(),
1516
+ nickname: f.string(),
1517
+ avatar_url: f.string(),
1518
+ title: f.string().optional(),
1519
+ content: f.string(),
1520
+ content_text_count: f.number(),
1521
+ summary: f.string(),
1522
+ like_num: f.number(),
1523
+ comments_num: f.number(),
1524
+ liked: f.bool(),
1525
+ image_urls: f.array(f.string()),
1526
+ topics: f.array(W),
1527
+ event_ids: f.array(f.number()),
1528
+ is_pinned: f.bool(),
1529
+ is_highlighted: f.bool(),
1477
1530
  status: V,
1478
- create_time: u.number()
1479
- }).lock(), K = u.object({ err_msg: u.string().optional() }).optional().lock(), vi = u.object({
1480
- reply_id: u.number(),
1481
- reply_content: u.string().optional(),
1482
- replied_by: u.string(),
1483
- nickname: u.string(),
1484
- avatar_url: u.string()
1485
- }).lock(), q = u.object({
1486
- reply_id: u.number(),
1487
- comment_id: u.number(),
1488
- comment_content: u.string().optional(),
1489
- commented_by: u.string().optional(),
1490
- commented_by_nickname: u.string().optional(),
1491
- commented_by_avatar_url: u.string().optional(),
1492
- replied_by: u.string(),
1493
- nickname: u.string(),
1494
- avatar_url: u.string(),
1495
- content: u.string(),
1496
- like_num: u.number(),
1497
- liked: u.bool(),
1498
- reply_to: vi,
1499
- create_time: u.number()
1500
- }).lock(), J = u.object({
1501
- comment_id: u.number(),
1502
- post_id: u.number(),
1503
- post_subject: u.string().optional(),
1504
- post_summary: u.string().optional(),
1505
- post_image_url: u.string().optional(),
1506
- posted_by: u.string().optional(),
1507
- posted_by_nickname: u.string().optional(),
1508
- posted_by_avatar_url: u.string().optional(),
1509
- commented_by: u.string(),
1510
- nickname: u.string(),
1511
- avatar_url: u.string(),
1512
- content: u.string(),
1513
- like_num: u.number(),
1514
- reply_num: u.number(),
1515
- liked: u.bool(),
1516
- image_url: u.string(),
1517
- create_time: u.number(),
1531
+ create_time: f.number()
1532
+ }).lock(), K = f.object({ err_msg: f.string().optional() }).optional().lock(), ki = f.object({
1533
+ reply_id: f.number(),
1534
+ reply_content: f.string().optional(),
1535
+ replied_by: f.string(),
1536
+ nickname: f.string(),
1537
+ avatar_url: f.string()
1538
+ }).lock(), q = f.object({
1539
+ reply_id: f.number(),
1540
+ comment_id: f.number(),
1541
+ comment_content: f.string().optional(),
1542
+ commented_by: f.string().optional(),
1543
+ commented_by_nickname: f.string().optional(),
1544
+ commented_by_avatar_url: f.string().optional(),
1545
+ replied_by: f.string(),
1546
+ nickname: f.string(),
1547
+ avatar_url: f.string(),
1548
+ content: f.string(),
1549
+ like_num: f.number(),
1550
+ liked: f.bool(),
1551
+ reply_to: ki,
1552
+ create_time: f.number()
1553
+ }).lock(), J = f.object({
1554
+ comment_id: f.number(),
1555
+ post_id: f.number(),
1556
+ post_subject: f.string().optional(),
1557
+ post_summary: f.string().optional(),
1558
+ post_image_url: f.string().optional(),
1559
+ posted_by: f.string().optional(),
1560
+ posted_by_nickname: f.string().optional(),
1561
+ posted_by_avatar_url: f.string().optional(),
1562
+ commented_by: f.string(),
1563
+ nickname: f.string(),
1564
+ avatar_url: f.string(),
1565
+ content: f.string(),
1566
+ like_num: f.number(),
1567
+ reply_num: f.number(),
1568
+ liked: f.bool(),
1569
+ image_url: f.string(),
1570
+ create_time: f.number(),
1518
1571
  status: V,
1519
- replies: u.array(q).optional()
1520
- }).lock(), yi = u.object({
1521
- image_url: u.string(),
1522
- upload_url: u.string(),
1523
- existed: u.bool()
1524
- }).lock(), Y = u.object({
1525
- notification_id: u.string(),
1526
- notification_type: _i,
1527
- is_read: u.bool(),
1528
- create_time: u.number(),
1529
- origin_user_id: u.string(),
1530
- origin_user_name: u.string(),
1531
- origin_user_avatar_url: u.string()
1532
- }).lock(), bi = u.object({
1533
- system_message_subject: u.string(),
1534
- system_message_content: u.string()
1535
- }).lock(), X = u.object({
1536
- post_id: u.number(),
1537
- post_subject: u.string(),
1538
- post_summary: u.string(),
1539
- post_image_url: u.string()
1540
- }).lock(), Z = u.object({
1541
- comment_id: u.number(),
1542
- comment_content: u.string()
1543
- }).lock(), Q = u.object({
1544
- reply_id: u.number(),
1545
- reply_content: u.string()
1546
- }).lock(), xi = u.object({
1572
+ replies: f.array(q).optional()
1573
+ }).lock(), Ai = f.object({
1574
+ image_url: f.string(),
1575
+ upload_url: f.string(),
1576
+ existed: f.bool()
1577
+ }).lock(), Y = f.object({
1578
+ notification_id: f.string(),
1579
+ notification_type: Oi,
1580
+ is_read: f.bool(),
1581
+ create_time: f.number(),
1582
+ origin_user_id: f.string(),
1583
+ origin_user_name: f.string(),
1584
+ origin_user_avatar_url: f.string()
1585
+ }).lock(), ji = f.object({
1586
+ system_message_subject: f.string(),
1587
+ system_message_content: f.string()
1588
+ }).lock(), X = f.object({
1589
+ post_id: f.number(),
1590
+ post_subject: f.string(),
1591
+ post_summary: f.string(),
1592
+ post_image_url: f.string()
1593
+ }).lock(), Z = f.object({
1594
+ comment_id: f.number(),
1595
+ comment_content: f.string()
1596
+ }).lock(), Q = f.object({
1597
+ reply_id: f.number(),
1598
+ reply_content: f.string()
1599
+ }).lock(), Mi = f.object({
1547
1600
  ...Y.shape,
1548
- ...bi.shape,
1549
- notification_type: u.string().enum(H.System)
1550
- }), Si = u.object({
1601
+ ...ji.shape,
1602
+ notification_type: f.string().enum(H.System)
1603
+ }), Ni = f.object({
1551
1604
  ...Y.shape,
1552
1605
  ...X.shape,
1553
- notification_type: u.string().enum(H.PostPinned, H.PostHighlighted, H.PostDeleted, H.PostLiked)
1554
- }), Ci = u.object({
1606
+ notification_type: f.string().enum(H.PostPinned, H.PostHighlighted, H.PostDeleted, H.PostLiked)
1607
+ }), Pi = f.object({
1555
1608
  ...Y.shape,
1556
1609
  ...X.shape,
1557
1610
  ...Z.shape,
1558
- notification_type: u.string().enum(H.PostCommented)
1559
- }), wi = u.object({
1611
+ notification_type: f.string().enum(H.PostCommented)
1612
+ }), Fi = f.object({
1560
1613
  ...Y.shape,
1561
1614
  ...Z.shape,
1562
1615
  ...Q.shape,
1563
- notification_type: u.string().enum(H.CommentReplied)
1564
- }), Ti = u.object({
1616
+ notification_type: f.string().enum(H.CommentReplied)
1617
+ }), Ii = f.object({
1565
1618
  ...Y.shape,
1566
1619
  ...Z.shape,
1567
1620
  ...X.shape,
1568
- notification_type: u.string().enum(H.CommentLiked, H.CommentDeleted)
1569
- }), Ei = u.object({
1621
+ notification_type: f.string().enum(H.CommentLiked, H.CommentDeleted)
1622
+ }), Li = f.object({
1570
1623
  ...Y.shape,
1571
1624
  ...Q.shape,
1572
- notification_type: u.string().enum(H.ReplyReplied),
1573
- comment_id: u.number(),
1574
- reply_to_reply_id: u.number(),
1575
- reply_to_reply_content: u.string()
1576
- }), Di = u.object({
1625
+ notification_type: f.string().enum(H.ReplyReplied),
1626
+ comment_id: f.number(),
1627
+ reply_to_reply_id: f.number(),
1628
+ reply_to_reply_content: f.string()
1629
+ }), Ri = f.object({
1577
1630
  ...Y.shape,
1578
1631
  ...Q.shape,
1579
1632
  ...Z.shape,
1580
- notification_type: u.string().enum(H.ReplyLiked, H.ReplyDeleted)
1581
- }), Oi = u.union(xi, Si, Ci, wi, Ti, Ei, Di).satisfies().lock(), ki = l({ forums: u.array(U) }), Ai = l({ topics: u.array(W) }), ji = l({ topic: W }), Mi = l({ post: G }), Ni = l({
1582
- posts: u.array(G),
1583
- next_token: u.string().optional()
1584
- }), Pi = l({
1633
+ notification_type: f.string().enum(H.ReplyLiked, H.ReplyDeleted)
1634
+ }), zi = f.union(Mi, Ni, Pi, Fi, Ii, Li, Ri).satisfies().lock(), Bi = d({ forums: f.array(U) }), Vi = d({ topics: f.array(W) }), Hi = d({ topic: W }), Ui = d({ post: G }), Wi = d({
1635
+ posts: f.array(G),
1636
+ next_token: f.string().optional()
1637
+ }), Gi = d({
1585
1638
  post: G.clone().optional(),
1586
1639
  antispam: K.clone().optional()
1587
- }), Fi = l({
1588
- replies: u.array(q),
1589
- next_token: u.string().optional()
1590
- }), Ii = l({ reply: q }), Li = l({
1640
+ }), Ki = d({
1641
+ replies: f.array(q),
1642
+ next_token: f.string().optional()
1643
+ }), qi = d({ reply: q }), Ji = d({
1591
1644
  reply: q.clone().optional(),
1592
1645
  antispam: K.clone().optional()
1593
- }), Ri = l({ comment: J }), zi = l({
1594
- comments: u.array(J),
1595
- next_token: u.string().optional()
1596
- }), Bi = l({
1646
+ }), Yi = d({ comment: J }), Xi = d({
1647
+ comments: f.array(J),
1648
+ next_token: f.string().optional()
1649
+ }), Zi = d({
1597
1650
  comment: J.clone().optional(),
1598
1651
  antispam: J.clone().optional()
1599
- }), Vi = u.guard(yi), Hi = l({
1600
- notifications: u.array(Oi),
1601
- next_token: u.string().optional()
1602
- }), Ui = l({
1603
- system: u.number(),
1604
- comment: u.number(),
1605
- like: u.number()
1606
- }), Wi = class {
1652
+ }), Qi = f.guard(Ai), $i = d({
1653
+ notifications: f.array(zi),
1654
+ next_token: f.string().optional()
1655
+ }), ea = d({
1656
+ system: f.number(),
1657
+ comment: f.number(),
1658
+ like: f.number()
1659
+ }), ta = class {
1607
1660
  token;
1608
1661
  req;
1609
1662
  constructor(e) {
1610
1663
  this.token = e, this.req = e.req;
1611
1664
  }
1612
1665
  async getForums(e) {
1613
- let { data: t } = await this.req.get("community/forums", null, ki, e);
1666
+ let { data: t } = await this.req.get("community/forums", null, Bi, e);
1614
1667
  return t?.forums || [];
1615
1668
  }
1616
1669
  async getTopics(e) {
1617
- let { data: t } = await this.req.get("community/topics", null, Ai, e);
1670
+ let { data: t } = await this.req.get("community/topics", null, Vi, e);
1618
1671
  return t?.topics || [];
1619
1672
  }
1620
1673
  async getTopic(e, t) {
1621
- let { data: n, code: r } = await this.req.get("community/topic", { topic_id: e }, ji, t);
1674
+ let { data: n, code: r } = await this.req.get("community/topic", { topic_id: e }, Hi, t);
1622
1675
  return n?.topic ?? { error: r };
1623
1676
  }
1624
1677
  async getPosts(e, t) {
1625
- let { data: n, code: r, message: i } = await this.req.get("community/posts", e || null, Ni, t);
1678
+ let { data: n, code: r, message: i } = await this.req.get("community/posts", e || null, Wi, t);
1626
1679
  return n ?? {
1627
1680
  message: i,
1628
1681
  error: r
@@ -1633,35 +1686,35 @@ var li = {
1633
1686
  forum_id: e,
1634
1687
  max_results: t,
1635
1688
  next_token: n
1636
- }, Ni, r);
1689
+ }, Wi, r);
1637
1690
  return i ?? {
1638
1691
  message: o,
1639
1692
  error: a
1640
1693
  };
1641
1694
  }
1642
1695
  async getPost(e, t) {
1643
- let { data: n, code: r, message: i } = await this.req.get("community/post", { post_id: e }, Mi, t);
1696
+ let { data: n, code: r, message: i } = await this.req.get("community/post", { post_id: e }, Ui, t);
1644
1697
  return n?.post ?? {
1645
1698
  message: i,
1646
1699
  error: r
1647
1700
  };
1648
1701
  }
1649
1702
  async post(e, t) {
1650
- let { data: n, code: r, message: i } = await this.req.post("community/post", a(e), Pi, t);
1703
+ let { data: n, code: r, message: i } = await this.req.post("community/post", a(e), Gi, t);
1651
1704
  return n ?? {
1652
1705
  message: i,
1653
1706
  error: r
1654
1707
  };
1655
1708
  }
1656
1709
  async getComments(e, t) {
1657
- let { data: n, code: r, message: i } = await this.req.get("community/comments", e, zi, t);
1710
+ let { data: n, code: r, message: i } = await this.req.get("community/comments", e, Xi, t);
1658
1711
  return n ?? {
1659
1712
  message: i,
1660
1713
  error: r
1661
1714
  };
1662
1715
  }
1663
1716
  async getComment(e, t) {
1664
- let { data: n, code: r, message: i } = await this.req.get("community/comment", { comment_id: e }, Ri, t);
1717
+ let { data: n, code: r, message: i } = await this.req.get("community/comment", { comment_id: e }, Yi, t);
1665
1718
  return n?.comment ?? {
1666
1719
  message: i,
1667
1720
  error: r
@@ -1669,7 +1722,7 @@ var li = {
1669
1722
  }
1670
1723
  async comment(e, t) {
1671
1724
  await this.token.autoLogin();
1672
- let { data: n, code: r, message: i } = await this.req.post("community/comment", a(e), Bi, t);
1725
+ let { data: n, code: r, message: i } = await this.req.post("community/comment", a(e), Zi, t);
1673
1726
  return n ?? {
1674
1727
  message: i,
1675
1728
  error: r
@@ -1679,14 +1732,14 @@ var li = {
1679
1732
  let { data: n } = await this.req.get("community/replies", {
1680
1733
  max_results: 20,
1681
1734
  ...e
1682
- }, Fi, t);
1735
+ }, Ki, t);
1683
1736
  return {
1684
1737
  replies: n?.replies || [],
1685
1738
  next_token: n?.next_token || ""
1686
1739
  };
1687
1740
  }
1688
1741
  async getReply(e, t) {
1689
- let { data: n, code: r, message: i } = await this.req.get("community/reply", { reply_id: e }, Ii, t);
1742
+ let { data: n, code: r, message: i } = await this.req.get("community/reply", { reply_id: e }, qi, t);
1690
1743
  return n?.reply ?? {
1691
1744
  message: i,
1692
1745
  error: r
@@ -1694,7 +1747,7 @@ var li = {
1694
1747
  }
1695
1748
  async reply(e, t) {
1696
1749
  await this.token.autoLogin();
1697
- let { data: n, code: r, message: i } = await this.req.post("community/reply", a(e), Li, t);
1750
+ let { data: n, code: r, message: i } = await this.req.post("community/reply", a(e), Ji, t);
1698
1751
  return n ?? {
1699
1752
  message: i,
1700
1753
  error: r
@@ -1724,7 +1777,7 @@ var li = {
1724
1777
  }
1725
1778
  async getMediaPresignedUrl(e, t) {
1726
1779
  await this.token.autoLogin();
1727
- let { data: n } = await this.req.get("community/media-presign-url", e, Vi, t);
1780
+ let { data: n } = await this.req.get("community/media-presign-url", e, Qi, t);
1728
1781
  return n;
1729
1782
  }
1730
1783
  async getNotifications(e, t) {
@@ -1732,7 +1785,7 @@ var li = {
1732
1785
  let { data: n } = await this.req.get("community/notifications", {
1733
1786
  max_results: 20,
1734
1787
  ...e
1735
- }, Hi, t);
1788
+ }, $i, t);
1736
1789
  return {
1737
1790
  notifications: n?.notifications || [],
1738
1791
  next_token: n?.next_token || ""
@@ -1740,7 +1793,7 @@ var li = {
1740
1793
  }
1741
1794
  async getUnreadNotificationsCount(e) {
1742
1795
  if (!await this.token.autoLogin()) return null;
1743
- let { data: t } = await this.req.get("community/unread-notifications-count", null, Ui, e);
1796
+ let { data: t } = await this.req.get("community/unread-notifications-count", null, ea, e);
1744
1797
  return t;
1745
1798
  }
1746
1799
  async clearUnreadNotifications(e, t) {
@@ -1748,11 +1801,11 @@ var li = {
1748
1801
  let { ok: n } = await this.req.post("community/clear-unread-notifications", { category: e }, null, t);
1749
1802
  return n;
1750
1803
  }
1751
- }, Gi = l({
1752
- nonce_str: u.string(),
1753
- timestamp: u.number(),
1754
- signature: u.string()
1755
- }), Ki = /* @__PURE__ */ function(e) {
1804
+ }, na = d({
1805
+ nonce_str: f.string(),
1806
+ timestamp: f.number(),
1807
+ signature: f.string()
1808
+ }), ra = /* @__PURE__ */ function(e) {
1756
1809
  return e.RedirectUriDisMatch = "10003", e.AppidError = "10016", e.AuthorizationError = "10015", e.NoRightForScope = "10005", e.Frequently = "10009", e.AppBanded = "10004", e.ShouldFollow = "10006", e.ScopeNull = "10010", e.RedirectUriNull = "10011", e.AppidNull = "10012", e.StateNull = "10013", e;
1757
1810
  }({});
1758
1811
  //#endregion
@@ -1762,7 +1815,7 @@ function $(e) {
1762
1815
  }
1763
1816
  //#endregion
1764
1817
  //#region src/weixin.ts
1765
- var qi = "wx_login_cache", Ji = class {
1818
+ var ia = "wx_login_cache", aa = class {
1766
1819
  token;
1767
1820
  _appid;
1768
1821
  req;
@@ -1773,23 +1826,23 @@ var qi = "wx_login_cache", Ji = class {
1773
1826
  return this._appid;
1774
1827
  }
1775
1828
  async getLoginCache() {
1776
- let e = this.token.storage.get(qi);
1829
+ let e = this.token.storage.get(ia);
1777
1830
  if (!e) return null;
1778
1831
  let t = i(e);
1779
1832
  return $(t) ? (this.token.weixinToken = t.weixin_token, await this.token.autoLogin(), t) : null;
1780
1833
  }
1781
1834
  async login(e) {
1782
- if (!c()) throw Error("当前环境非微信小程序");
1835
+ if (!u()) throw Error("当前环境非微信小程序");
1783
1836
  let t = await this.getLoginCache();
1784
1837
  if (t) return t;
1785
- let n = await ce(), { data: r, code: i, message: a } = await this.req.post("weixin/login", {
1838
+ let n = await se(), { data: r, code: i, message: a } = await this.req.post("weixin/login", {
1786
1839
  code: n,
1787
1840
  appid: this.appid
1788
1841
  }, $, {
1789
1842
  ...e,
1790
1843
  message: !1
1791
1844
  });
1792
- return r && (this.token.weixinToken = r.weixin_token, this.token.storage.set(qi, JSON.stringify(r))), r ?? {
1845
+ return r && (this.token.weixinToken = r.weixin_token, this.token.storage.set(ia, JSON.stringify(r))), r ?? {
1793
1846
  message: a,
1794
1847
  error: i
1795
1848
  };
@@ -1797,7 +1850,7 @@ var qi = "wx_login_cache", Ji = class {
1797
1850
  async webLogin(e = "snsapi_userinfo", t) {
1798
1851
  let n = s("code"), r = Date.now(), i = +s("state");
1799
1852
  if (!n || !i || i < r - 1e3 * 60 * 5 || i > r) {
1800
- let t = ee(["code", "state"]);
1853
+ let t = c(["code", "state"]);
1801
1854
  location.replace(`https://open.weixin.qq.com/connect/oauth2/authorize?appid=${this.appid}&redirect_uri=${encodeURIComponent(t)}&response_type=code&scope=${e}&state=${r}#wechat_redirect`);
1802
1855
  return;
1803
1856
  }
@@ -1805,15 +1858,15 @@ var qi = "wx_login_cache", Ji = class {
1805
1858
  message: "Error: " + n,
1806
1859
  error: n
1807
1860
  };
1808
- let a = ee(["code", "state"]);
1861
+ let a = c(["code", "state"]);
1809
1862
  "replaceState" in history && history.replaceState({}, "", a);
1810
- let { data: o, code: te, message: c } = await this.req.post("weixin/login", {
1863
+ let { data: o, code: l, message: u } = await this.req.post("weixin/login", {
1811
1864
  code: n,
1812
1865
  appid: this.appid
1813
1866
  }, $, t);
1814
1867
  return o && (this.token.weixinToken = o.weixin_token, await this.token.autoLogin()), o ?? {
1815
- message: c,
1816
- error: te
1868
+ message: u,
1869
+ error: l
1817
1870
  };
1818
1871
  }
1819
1872
  async linkPlayer(e, t, n) {
@@ -1831,7 +1884,7 @@ var qi = "wx_login_cache", Ji = class {
1831
1884
  let { data: t } = await this.req.get("weixin/offiaccount/jssdk-sign", {
1832
1885
  appid: this.appid,
1833
1886
  url: location.href.split("#")[0]
1834
- }, Gi, e);
1887
+ }, na, e);
1835
1888
  return t ? {
1836
1889
  appid: this.appid,
1837
1890
  nonceStr: t.nonce_str,
@@ -1841,4 +1894,4 @@ var qi = "wx_login_cache", Ji = class {
1841
1894
  }
1842
1895
  };
1843
1896
  //#endregion
1844
- export { K as AntispamValidator, le as AuthToken, Vn as CandidateVoteValidator, I as CashbackEngagementDataValidator, mn as ClaimActivationKeyEngagementDataValidator, $e as ClaimRewardStatus, k as ClaimRewardStatusValidator, Zn as ClaimedItemValidator, h as ClubAddressValidator, He as ClubApi, g as ClubBenefitSummaryValidator, De as ClubBenefitValidator, me as ClubCreditChangeScene, he as ClubCreditChangeSceneValidator, fe as ClubCreditChangeType, pe as ClubCreditChangeTypeValidator, Ee as ClubCreditLogValidator, ye as ClubGlobalConfigValidator, ge as ClubItemType, p as ClubItemTypeValidator, be as ClubPlayerValidator, _ as ClubProductValidator, _e as ClubRedemptionStatus, ve as ClubRedemptionStatusValidator, Te as ClubUserCreditValidator, we as ClubUserProfileValidator, Wn as CommentEngagementValidator, J as CommentValidator, Wi as CommunityApi, Hn as ConversationValidator, Ge as EngageAccountType, Ke as EngageAccountTypeValidator, Xn as EngageResponseValidator, Kn as EngageRewardValidator, Ue as EventApi, ir as EventConfigValidator, yt as EventFeatureConfigOfCashbackValidator, xt as EventFeatureConfigOfCheckInValidator, Ct as EventFeatureConfigOfClaimActivationKeyValidator, Tt as EventFeatureConfigOfClaimRewardsValidator, Dt as EventFeatureConfigOfCommentValidator, kt as EventFeatureConfigOfFollowValidator, Mt as EventFeatureConfigOfGiftCodeValidator, Pt as EventFeatureConfigOfInviteValidator, It as EventFeatureConfigOfInvitedRegisterValidator, Ht as EventFeatureConfigOfLotteryDrawValidator, Bt as EventFeatureConfigOfLotteryValidator, Wt as EventFeatureConfigOfPreregisterValidator, Kt as EventFeatureConfigOfQuestValidator, Yt as EventFeatureConfigOfRedeemValidator, Zt as EventFeatureConfigOfRegisterValidator, $t as EventFeatureConfigOfShareValidator, tn as EventFeatureConfigOfSubscribeValidator, rn as EventFeatureConfigOfSurveyValidator, on as EventFeatureConfigOfTeamValidator, un as EventFeatureConfigOfUgcLikeValidator, cn as EventFeatureConfigOfUgcValidator, er as EventFeatureConfigOfVote2Validator, pn as EventFeatureConfigOfVoteValidator, rr as EventFeatureConfigValidator, qe as EventPeriodType, Je as EventPeriodTypeValidator, N as EventRewardItemConfigValidator, Ae as ExtraGameRewardValidator, ke as ExtraPhysicalShipmentValidator, Jt as FeatureRedeemItemConfigValidator, _t as FeatureRewardValidator, T as FeatureType, Ye as FeatureTypeValidator, fi as ForumMode, pi as ForumModeValidator, U as ForumValidator, di as GGDPublicApi, li as GGDRoomStatus, ui as GGDRoomStatusValidator, S as GamerItemType, C as GamerItemTypeValidator, ue as Gender, de as GenderValidator, hn as GiftCodeEngagementDataValidator, gn as InviteEngagementDataValidator, ot as LotteryDrawAction, st as LotteryDrawActionValidator, bn as LotteryDrawEngagementDataValidator, _n as LotteryEngagementDataValidator, j as LotteryTicketStatus, rt as LotteryTicketStatusValidator, Y as NotificationBaseValidator, hi as NotificationCategory, gi as NotificationCategoryValidator, wi as NotificationCommentReplyValidator, Ti as NotificationCommentValidator, Z as NotificationPayloadCommentValidator, X as NotificationPayloadPostValidator, Q as NotificationPayloadReplyValidator, bi as NotificationPayloadSystemValidator, Ci as NotificationPostCommentValidator, Si as NotificationPostValidator, Ei as NotificationReplyRepliedValidator, Di as NotificationReplyValidator, xi as NotificationSystemValidator, H as NotificationType, _i as NotificationTypeValidator, Oi as NotificationValidator, Ce as PlayerRoleCardValidator, m as PlayerRoleValidator, mi as PostStatus, V as PostStatusValidator, G as PostValidator, xn as PreregisterEngagementDataValidator, yi as PresignedUrlResponseValidator, Cn as QuestEngagementDataValidator, Xe as QuestObjective, E as QuestObjectiveValidator, ct as QuestProgressAlgorithm, lt as QuestProgressAlgorithmValidator, wn as QuestProgressValidator, Tn as RedeemEngagementDataValidator, Oe as RedeemParamsValidator, En as RedeemStocksResponseValidator, je as RedemptionValidator, gt as RegularRewardValidator, vi as ReplyToValidator, q as ReplyValidator, We as RewardItemType, w as RewardItemTypeValidator, et as RewardSource, A as RewardSourceValidator, D as RewardStatus, O as RewardStatusValidator, Gn as RewardValidator, Se as RoleBaseInfoValidator, xe as ServerBaseInfoValidator, Dn as ShareEngagementDataValidator, kn as SurveyEngagementDataValidator, it as TeamAction, at as TeamActionValidator, Mn as TeamEngagementDataValidator, An as TeamEngagementValidator, jn as TeamMemberValidator, tt as TeamVisibility, nt as TeamVisibilityValidator, W as TopicValidator, In as UgcCountResponseValidator, Nn as UgcEngagementDataValidator, Rn as UgcLeaderboardResponseValidator, Pn as UgcRecordBaseResponseValidator, Fn as UgcRecordResponseValidator, pt as UgcReviewStatus, mt as UgcReviewStatusValidator, ft as UgcSocialMedia, M as UgcSocialMediaValidator, Ln as UgcUploadImageValidator, z as UserEngagementDataValidator, qn as UserEngagementValidator, Yn as UserFeatureStatusValidator, L as UserRewardValidator, Jn as VerifyMobileResultValidator, Bn as Vote2ClaimRewardsResponseValidator, zn as Vote2EngagementDataValidator, ut as Vote2RewardType, dt as Vote2RewardTypeValidator, R as VoteEngagementDataValidator, Ze as VoteOptionSource, Qe as VoteOptionSourceValidator, Ji as WeixinApi, On as WeixinSubscribeEngagementDataValidator, Ki as WeixinWebLoginErrorCode, Un as ZeroChatGPTDataValidator, Vr as claimRewards, Qr as claimRewardsV2, $r as claimWeixinHongbao, Br as engage, Gr as generateUnlimitQrcode, Yr as getCashbackQuery, Mr as getConfig, Fr as getEngagements, Pr as getEngagementsCount, Nr as getEngagementsUserCount, Wr as getParamsByQrcodeScene, Kr as getQuestProgress, ci as getRedeemItemStocks, si as getUgcLeaderboard, Zr as getUgcMyCount, ai as getUgcRecommendation, Xr as getUgcRecord, oi as getUgcs, Ur as getUnlimitQrcodeScene, Rr as getUserEngagementCount, zr as getUserEngagements, Lr as getUserFeatureStatus, ri as getUserItemCount, ti as getUserRewards, ni as getUserRewardsCount, Jr as getVote2Leaderboard, Gi as isWeixinSignResponse, Hr as submitUserRewardAddress, ii as ugcUploadImage, ei as verifyActivationKey, jr as verifyMobileAllowed, Ir as visit, qr as vote2Rewards };
1897
+ export { K as AntispamValidator, ce as AuthToken, jn as CandidateVoteValidator, I as CashbackEngagementDataValidator, Qt as ClaimActivationKeyEngagementDataValidator, $e as ClaimRewardStatus, k as ClaimRewardStatusValidator, or as ClaimedItemValidator, _ as ClubAddressValidator, He as ClubApi, v as ClubBenefitSummaryValidator, Te as ClubBenefitValidator, pe as ClubCreditChangeScene, me as ClubCreditChangeSceneValidator, de as ClubCreditChangeType, fe as ClubCreditChangeTypeValidator, we as ClubCreditLogValidator, ve as ClubGlobalConfigValidator, he as ClubItemType, m as ClubItemTypeValidator, ye as ClubPlayerValidator, y as ClubProductValidator, ge as ClubRedemptionStatus, _e as ClubRedemptionStatusValidator, Ce as ClubUserCreditValidator, Se as ClubUserProfileValidator, Pn as CommentEngagementValidator, J as CommentValidator, ta as CommunityApi, Mn as ConversationValidator, Ge as EngageAccountType, Ke as EngageAccountTypeValidator, ar as EngageResponseValidator, Fn as EngageRewardValidator, Ue as EventApi, pr as EventConfigValidator, xt as EventFeatureConfigOfCashbackValidator, Ct as EventFeatureConfigOfCheckInValidator, Tt as EventFeatureConfigOfClaimActivationKeyValidator, Dt as EventFeatureConfigOfClaimRewardsValidator, kt as EventFeatureConfigOfCommentValidator, jt as EventFeatureConfigOfFollowValidator, Pt as EventFeatureConfigOfGiftCodeValidator, It as EventFeatureConfigOfInviteValidator, Rt as EventFeatureConfigOfInvitedRegisterValidator, Wt as EventFeatureConfigOfLotteryDrawValidator, Ht as EventFeatureConfigOfLotteryValidator, Kt as EventFeatureConfigOfPreregisterValidator, Jt as EventFeatureConfigOfQuestValidator, Zt as EventFeatureConfigOfRedeemValidator, zn as EventFeatureConfigOfReferralValidator, Vn as EventFeatureConfigOfRegisterValidator, Un as EventFeatureConfigOfShareValidator, Gn as EventFeatureConfigOfSubscribeValidator, qn as EventFeatureConfigOfSurveyValidator, Yn as EventFeatureConfigOfTeamValidator, $n as EventFeatureConfigOfUgcLikeValidator, Zn as EventFeatureConfigOfUgcValidator, lr as EventFeatureConfigOfVote2Validator, nr as EventFeatureConfigOfVoteValidator, fr as EventFeatureConfigValidator, qe as EventPeriodType, Je as EventPeriodTypeValidator, N as EventRewardItemConfigValidator, Oe as ExtraGameRewardValidator, De as ExtraPhysicalShipmentValidator, Xt as FeatureRedeemItemConfigValidator, Rn as FeatureReferralTierItemValidator, yt as FeatureRewardValidator, T as FeatureType, Ye as FeatureTypeValidator, Ci as ForumMode, wi as ForumModeValidator, U as ForumValidator, Si as GGDPublicApi, bi as GGDRoomStatus, xi as GGDRoomStatusValidator, S as GamerItemType, C as GamerItemTypeValidator, le as Gender, ue as GenderValidator, hn as GenerateReferralRewardsResponseValidator, $t as GiftCodeEngagementDataValidator, en as InviteEngagementDataValidator, ct as LotteryDrawAction, lt as LotteryDrawActionValidator, an as LotteryDrawEngagementDataValidator, tn as LotteryEngagementDataValidator, j as LotteryTicketStatus, rt as LotteryTicketStatusValidator, Y as NotificationBaseValidator, Ei as NotificationCategory, Di as NotificationCategoryValidator, Fi as NotificationCommentReplyValidator, Ii as NotificationCommentValidator, Z as NotificationPayloadCommentValidator, X as NotificationPayloadPostValidator, Q as NotificationPayloadReplyValidator, ji as NotificationPayloadSystemValidator, Pi as NotificationPostCommentValidator, Ni as NotificationPostValidator, Li as NotificationReplyRepliedValidator, Ri as NotificationReplyValidator, Mi as NotificationSystemValidator, H as NotificationType, Oi as NotificationTypeValidator, zi as NotificationValidator, xe as PlayerRoleCardValidator, g as PlayerRoleValidator, Ti as PostStatus, V as PostStatusValidator, G as PostValidator, on as PreregisterEngagementDataValidator, Ai as PresignedUrlResponseValidator, cn as QuestEngagementDataValidator, Xe as QuestObjective, E as QuestObjectiveValidator, ut as QuestProgressAlgorithm, dt as QuestProgressAlgorithmValidator, ln as QuestProgressValidator, un as RedeemEngagementDataValidator, Ee as RedeemParamsValidator, dn as RedeemStocksResponseValidator, ke as RedemptionValidator, ot as ReferralAction, st as ReferralActionValidator, pn as ReferralEngagementDataValidator, fn as ReferralInviteValidator, mn as ReferralTierStatusValidator, vt as RegularRewardValidator, ki as ReplyToValidator, q as ReplyValidator, We as RewardItemType, w as RewardItemTypeValidator, et as RewardSource, A as RewardSourceValidator, D as RewardStatus, O as RewardStatusValidator, z as RewardValidator, be as RoleBaseInfoValidator, h as ServerBaseInfoValidator, gn as ShareEngagementDataValidator, vn as SurveyEngagementDataValidator, it as TeamAction, at as TeamActionValidator, xn as TeamEngagementDataValidator, yn as TeamEngagementValidator, bn as TeamMemberValidator, tt as TeamVisibility, nt as TeamVisibilityValidator, W as TopicValidator, Tn as UgcCountResponseValidator, Sn as UgcEngagementDataValidator, Dn as UgcLeaderboardResponseValidator, Cn as UgcRecordBaseResponseValidator, wn as UgcRecordResponseValidator, ht as UgcReviewStatus, gt as UgcReviewStatusValidator, mt as UgcSocialMedia, M as UgcSocialMediaValidator, En as UgcUploadImageValidator, R as UserEngagementDataValidator, In as UserEngagementValidator, ir as UserFeatureStatusValidator, L as UserRewardValidator, rr as VerifyMobileResultValidator, An as Vote2ClaimRewardsResponseValidator, kn as Vote2EngagementDataValidator, ft as Vote2RewardType, pt as Vote2RewardTypeValidator, On as VoteEngagementDataValidator, Ze as VoteOptionSource, Qe as VoteOptionSourceValidator, aa as WeixinApi, _n as WeixinSubscribeEngagementDataValidator, ra as WeixinWebLoginErrorCode, Nn as ZeroChatGPTDataValidator, Zr as claimRewards, ci as claimRewardsV2, li as claimWeixinHongbao, Xr as engage, yi as generateReferralRewards, ti as generateUnlimitQrcode, ai as getCashbackQuery, Hr as getConfig, Gr as getEngagements, Wr as getEngagementsCount, Ur as getEngagementsUserCount, ei as getParamsByQrcodeScene, ni as getQuestProgress, vi as getRedeemItemStocks, _i as getUgcLeaderboard, si as getUgcMyCount, hi as getUgcRecommendation, oi as getUgcRecord, gi as getUgcs, $r as getUnlimitQrcodeScene, Jr as getUserEngagementCount, Yr as getUserEngagements, qr as getUserFeatureStatus, pi as getUserItemCount, di as getUserRewards, fi as getUserRewardsCount, ii as getVote2Leaderboard, na as isWeixinSignResponse, Qr as submitUserRewardAddress, mi as ugcUploadImage, ui as verifyActivationKey, Vr as verifyMobileAllowed, Kr as visit, ri as vote2Rewards };