@seayoo-web/gamer-api 2.16.1 → 2.16.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -244,7 +244,7 @@ const Re = {
244
244
  Issued: "issued",
245
245
  /** 发放失败 */
246
246
  Failed: "failed"
247
- }, Ue = e.string().enum(Le).lock(), Pe = e.object({
247
+ }, Ue = e.string().enum(Le).lock(), Se = e.object({
248
248
  default_avatar_url: e.string(),
249
249
  official_avatar_urls: e.array(e.string()),
250
250
  default_nickname: e.string(),
@@ -262,7 +262,7 @@ const Re = {
262
262
  exp_description: e.string(),
263
263
  credit_description: e.string(),
264
264
  send_role_mail_rate_limit: e.number()
265
- }).lock(), Se = e.object({
265
+ }).lock(), Pe = e.object({
266
266
  member_id: e.string(),
267
267
  player_id: e.string(),
268
268
  exp: e.number(),
@@ -399,7 +399,7 @@ const Re = {
399
399
  status: Ue,
400
400
  created_at: e.number(),
401
401
  extra_data: e.union(Oe.clone(), Ne.clone()).satisfies().optional()
402
- }), Be = e.guard(Pe), N = i({ player: Se }), Me = i({ roles: e.array(J) }), j = i({ role_card: Fe }), Q = e.guard(Ie), B = e.guard(Z), Ke = i({ addresses: e.array(Z) }), He = e.guard(De), ze = i({
402
+ }), Be = e.guard(Se), N = i({ player: Pe }), Me = i({ roles: e.array(J) }), j = i({ role_card: Fe }), Q = e.guard(Ie), B = e.guard(Z), Ke = i({ addresses: e.array(Z) }), He = e.guard(De), ze = i({
403
403
  credit_logs: e.array(Ae),
404
404
  next_token: e.string().optional()
405
405
  }), Je = i({ products: e.array(Y) }), Ze = i({ benefits: e.array(X) }), Xe = i({ benefit: Ge }), Ye = i({
@@ -811,7 +811,9 @@ const v = {
811
811
  /** 游戏内充值金额 */
812
812
  OrderAmountInApp: "order_in_app_total_amount",
813
813
  /** 支付中心充值金额 */
814
- OrderAmountInPayCenter: "order_seayoo_web_total_amount"
814
+ OrderAmountInPayCenter: "order_seayoo_web_total_amount",
815
+ /** 组队进度 */
816
+ TeamSize: "team_size"
815
817
  }, te = e.string().enum(ot).lock(), it = {
816
818
  /** 官方上传 */
817
819
  System: "system",
@@ -841,12 +843,12 @@ const v = {
841
843
  Failed: b.Failed,
842
844
  /** 奖励已发货 */
843
845
  Delivered: b.Delivered
844
- }, P = e.string().enum(ct).lock(), ut = {
846
+ }, S = e.string().enum(ct).lock(), ut = {
845
847
  /** 玩法产出奖励 */
846
848
  Output: "output",
847
849
  /** 玩法参与奖励 */
848
850
  Engage: "engage"
849
- }, S = e.string().enum(ut).lock(), lt = {
851
+ }, P = e.string().enum(ut).lock(), lt = {
850
852
  /** 私有队伍 */
851
853
  Private: "private",
852
854
  /** 公开队伍 */
@@ -964,9 +966,9 @@ const v = {
964
966
  }), Lt = u.ClaimRewards, Ut = e.object({
965
967
  ...l.shape,
966
968
  feature_type: e.string().enum(Lt)
967
- }), Pt = u.Comment, St = e.object({
969
+ }), St = u.Comment, Pt = e.object({
968
970
  ...l.shape,
969
- feature_type: e.string().enum(Pt),
971
+ feature_type: e.string().enum(St),
970
972
  config: e.object({
971
973
  comments: e.array(e.string()),
972
974
  send_rate: e.number()
@@ -1154,7 +1156,7 @@ const v = {
1154
1156
  Vt,
1155
1157
  Tt,
1156
1158
  Ut,
1157
- St,
1159
+ Pt,
1158
1160
  $t,
1159
1161
  Dt,
1160
1162
  Gt,
@@ -1199,14 +1201,14 @@ const v = {
1199
1201
  }), R = e.object({
1200
1202
  reward_id: e.number(),
1201
1203
  reward_item_id: e.number(),
1202
- reward_source: S,
1204
+ reward_source: P,
1203
1205
  reward_item_name: e.string(),
1204
1206
  reward_item_type: W,
1205
1207
  reward_item_icon_url: e.string(),
1206
1208
  reward_item_desc: e.string().optional(),
1207
1209
  reward_item_rating: e.number(),
1208
1210
  reward_amount: e.number(),
1209
- reward_status: P,
1211
+ reward_status: S,
1210
1212
  event_id: e.number(),
1211
1213
  event_name: e.string(),
1212
1214
  feature_id: e.number(),
@@ -1214,7 +1216,7 @@ const v = {
1214
1216
  feature_type: rt,
1215
1217
  receive_time: e.number(),
1216
1218
  extra_data: e.record(e.unknown()).optional()
1217
- }), Un = e.string().enum(w.Unknown, w.Pending), Pn = e.union(
1219
+ }), Un = e.string().enum(w.Unknown, w.Pending), Sn = e.union(
1218
1220
  e.object({
1219
1221
  ticket: e.string(),
1220
1222
  status: Un,
@@ -1226,8 +1228,8 @@ const v = {
1226
1228
  created_at: e.number(),
1227
1229
  reward: R
1228
1230
  })
1229
- ).satisfies(), Sn = e.object({
1230
- tickets: e.array(Pn)
1231
+ ).satisfies(), Pn = e.object({
1232
+ tickets: e.array(Sn)
1231
1233
  }), En = e.object({
1232
1234
  platforms: e.array(e.string())
1233
1235
  }), re = e.object({
@@ -1263,7 +1265,7 @@ const v = {
1263
1265
  })
1264
1266
  )
1265
1267
  }), An = e.object({
1266
- platform: e.string()
1268
+ platform: e.string().optional()
1267
1269
  }), Gn = e.object({
1268
1270
  weixin_openid: e.string()
1269
1271
  }), On = e.object({
@@ -1276,7 +1278,8 @@ const v = {
1276
1278
  is_leader: e.bool(),
1277
1279
  is_myself: e.bool().optional(),
1278
1280
  role_name: e.string(),
1279
- server_name: e.string()
1281
+ server_name: e.string(),
1282
+ avatar_url: e.string().optional()
1280
1283
  }), Qn = e.object({
1281
1284
  team_code: e.string(),
1282
1285
  visibility: mt,
@@ -1396,7 +1399,7 @@ const v = {
1396
1399
  qn,
1397
1400
  Qn,
1398
1401
  $n,
1399
- Sn,
1402
+ Pn,
1400
1403
  Tn,
1401
1404
  ta,
1402
1405
  Bn,
@@ -1411,7 +1414,7 @@ const v = {
1411
1414
  reward_item_type: ee,
1412
1415
  reward_count: e.number(),
1413
1416
  reward_status: ne,
1414
- reward_source: S,
1417
+ reward_source: P,
1415
1418
  reward_item_name: e.string(),
1416
1419
  reward_item_icon_url: e.string(),
1417
1420
  reward_item_desc: e.string().optional(),
@@ -1428,7 +1431,7 @@ const v = {
1428
1431
  reward_item_rating: e.number(),
1429
1432
  reward_amount: e.number(),
1430
1433
  reward_status: ne,
1431
- reward_source: S,
1434
+ reward_source: P,
1432
1435
  extra_data: e.record(e.unknown()).optional()
1433
1436
  }), oa = e.object({
1434
1437
  engagement_id: e.number(),
@@ -1463,7 +1466,7 @@ const v = {
1463
1466
  scan: e.bool().optional()
1464
1467
  }), ua = e.object({
1465
1468
  reward_id: e.number(),
1466
- reward_status: P
1469
+ reward_status: S
1467
1470
  }), la = e.guard(jn), ma = e.guard(ia), q = i({ count: e.number() }), da = i({ first_visit: e.bool() }), ga = i({
1468
1471
  engagements: e.union(e.array(na), e.array(Nn))
1469
1472
  }), pa = i({
@@ -1478,7 +1481,7 @@ const v = {
1478
1481
  }), fa = i({
1479
1482
  rewards: e.array(R)
1480
1483
  }), wa = i({
1481
- reward_status: P
1484
+ reward_status: S
1482
1485
  }), ka = i({
1483
1486
  user_rewards: e.array(R),
1484
1487
  next_token: e.string().optional()
@@ -1494,7 +1497,7 @@ const v = {
1494
1497
  e.object({
1495
1498
  candidate_votes: e.array(Wn)
1496
1499
  })
1497
- ), xa = e.guard(ae), M = e.guard(Kn), La = e.guard(Mn), Ua = e.guard(Hn), Pa = e.guard(zn), Sa = e.guard(Jn), Ea = e.guard(Dn);
1500
+ ), xa = e.guard(ae), M = e.guard(Kn), La = e.guard(Mn), Ua = e.guard(Hn), Sa = e.guard(zn), Pa = e.guard(Jn), Ea = e.guard(Dn);
1498
1501
  class Cr {
1499
1502
  token;
1500
1503
  event = 0;
@@ -1974,7 +1977,7 @@ class Cr {
1974
1977
  const { data: r, code: o, message: d } = await this.req.post(
1975
1978
  "event/ugc/upload-image",
1976
1979
  { feature_id: t, ...n, event_id: this.event },
1977
- Pa,
1980
+ Sa,
1978
1981
  a
1979
1982
  );
1980
1983
  return r || {
@@ -2032,7 +2035,7 @@ class Cr {
2032
2035
  */
2033
2036
  async getUgcLeaderboard(t, n) {
2034
2037
  if (!await this.token.autoLogin()) return null;
2035
- const { data: a, code: r, message: o } = await this.req.get("event/ugc/leaderboard", Sa, {
2038
+ const { data: a, code: r, message: o } = await this.req.get("event/ugc/leaderboard", Pa, {
2036
2039
  ...n,
2037
2040
  params: {
2038
2041
  feature_id: t,
@@ -2746,7 +2749,7 @@ export {
2746
2749
  ae as CashbackEngagementDataValidator,
2747
2750
  Tn as ClaimActivationKeyEngagementDataValidator,
2748
2751
  ct as ClaimRewardStatus,
2749
- P as ClaimRewardStatusValidator,
2752
+ S as ClaimRewardStatusValidator,
2750
2753
  ua as ClaimedItemValidator,
2751
2754
  Z as ClubAddressValidator,
2752
2755
  hr as ClubApi,
@@ -2757,10 +2760,10 @@ export {
2757
2760
  Ve as ClubCreditChangeType,
2758
2761
  je as ClubCreditChangeTypeValidator,
2759
2762
  Ae as ClubCreditLogValidator,
2760
- Pe as ClubGlobalConfigValidator,
2763
+ Se as ClubGlobalConfigValidator,
2761
2764
  xe as ClubItemType,
2762
2765
  z as ClubItemTypeValidator,
2763
- Se as ClubPlayerValidator,
2766
+ Pe as ClubPlayerValidator,
2764
2767
  Y as ClubProductValidator,
2765
2768
  Le as ClubRedemptionStatus,
2766
2769
  Ue as ClubRedemptionStatusValidator,
@@ -2780,7 +2783,7 @@ export {
2780
2783
  Tt as EventFeatureConfigOfCheckInValidator,
2781
2784
  xt as EventFeatureConfigOfClaimActivationKeyValidator,
2782
2785
  Ut as EventFeatureConfigOfClaimRewardsValidator,
2783
- St as EventFeatureConfigOfCommentValidator,
2786
+ Pt as EventFeatureConfigOfCommentValidator,
2784
2787
  $t as EventFeatureConfigOfFollowValidator,
2785
2788
  Dt as EventFeatureConfigOfGiftCodeValidator,
2786
2789
  Gt as EventFeatureConfigOfInviteValidator,
@@ -2820,7 +2823,7 @@ export {
2820
2823
  xn as InviteEngagementDataValidator,
2821
2824
  gt as LotteryDrawAction,
2822
2825
  vr as LotteryDrawActionValidator,
2823
- Sn as LotteryDrawEngagementDataValidator,
2826
+ Pn as LotteryDrawEngagementDataValidator,
2824
2827
  Ln as LotteryEngagementDataValidator,
2825
2828
  w as LotteryTicketStatus,
2826
2829
  wr as LotteryTicketStatusValidator,
@@ -2864,7 +2867,7 @@ export {
2864
2867
  fr as RewardItemType,
2865
2868
  ee as RewardItemTypeValidator,
2866
2869
  ut as RewardSource,
2867
- S as RewardSourceValidator,
2870
+ P as RewardSourceValidator,
2868
2871
  b as RewardStatus,
2869
2872
  ne as RewardStatusValidator,
2870
2873
  aa as RewardValidator,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@seayoo-web/gamer-api",
3
3
  "description": "agent for gamer api",
4
- "version": "2.16.1",
4
+ "version": "2.16.3",
5
5
  "type": "module",
6
6
  "source": "index.ts",
7
7
  "main": "./dist/index.js",
@@ -30,17 +30,17 @@
30
30
  "license": "MIT",
31
31
  "devDependencies": {
32
32
  "@types/node": "^22.13.1",
33
- "@seayoo-web/scripts": "3.1.7",
34
- "@seayoo-web/tsconfig": "1.0.5",
35
- "@seayoo-web/request": "3.4.2",
36
33
  "@seayoo-web/combo-webview": "2.8.0",
37
- "@seayoo-web/utils": "4.2.0",
34
+ "@seayoo-web/request": "3.4.3",
35
+ "@seayoo-web/tsconfig": "1.0.6",
36
+ "@seayoo-web/utils": "4.4.0",
37
+ "@seayoo-web/scripts": "3.1.9",
38
38
  "@seayoo-web/validator": "2.3.0"
39
39
  },
40
40
  "peerDependencies": {
41
41
  "@seayoo-web/combo-webview": "^2.8.0",
42
- "@seayoo-web/validator": "^2.3.0",
43
- "@seayoo-web/utils": "^4.2.0"
42
+ "@seayoo-web/utils": "^4.4.0",
43
+ "@seayoo-web/validator": "^2.3.0"
44
44
  },
45
45
  "scripts": {
46
46
  "prebuild": "pnpm -F validator build && pnpm -F request build && pnpm -F combo-webview build",
@@ -127,6 +127,7 @@ export declare class EventApi {
127
127
  server_name?: string;
128
128
  role_id?: string;
129
129
  role_name?: string;
130
+ avatar_url?: string;
130
131
  }, requestOptions?: IRequestOptions): Promise<import("./event.define").EngageResponse | {
131
132
  message: string;
132
133
  error: RequestInternalError | InferEngagementError<T>;
@@ -1,9 +1,9 @@
1
1
  export interface ShareEngagementData {
2
2
  /** 用户分享到对应的平台 */
3
- platform: string;
3
+ platform?: string;
4
4
  }
5
5
  export declare const ShareEngagementDataValidator: import("@seayoo-web/validator").ObjectValidator<ShareEngagementData, false, false>;
6
6
  export interface ShareEngagementParam {
7
7
  /** 用户分享到对应的平台 */
8
- platform: string;
8
+ platform?: string;
9
9
  }
@@ -18,6 +18,8 @@ export interface TeamMember {
18
18
  role_name: string;
19
19
  /** 服务器名 */
20
20
  server_name: string;
21
+ /** 头像 URL */
22
+ avatar_url?: string;
21
23
  }
22
24
  export declare const TeamMemberValidator: import("@seayoo-web/validator").ObjectValidator<TeamMember, false, false>;
23
25
  export interface TeamEngagementData {
@@ -196,6 +196,8 @@ export declare const QuestObjective: {
196
196
  readonly OrderAmountInApp: "order_in_app_total_amount";
197
197
  /** 支付中心充值金额 */
198
198
  readonly OrderAmountInPayCenter: "order_seayoo_web_total_amount";
199
+ /** 组队进度 */
200
+ readonly TeamSize: "team_size";
199
201
  };
200
202
  export type QuestObjective = ValueOf<typeof QuestObjective>;
201
203
  export declare const QuestObjectiveValidator: import("@seayoo-web/validator").StringValidator<QuestObjective, false, false> & {