@seayoo-web/gamer-api 2.14.5 → 2.15.1
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 +392 -338
- package/package.json +2 -2
- package/types/src/event.config/feature.d.ts +4 -2
- package/types/src/event.config/feature.redeem.d.ts +24 -0
- package/types/src/event.d.ts +9 -0
- package/types/src/event.engage/engage.d.ts +4 -2
- package/types/src/event.engage/engage.redeem.d.ts +25 -0
- package/types/src/event.engage/index.d.ts +4 -4
- package/types/src/event.enums.d.ts +8 -2
- package/types/src/event.guards.d.ts +1 -0
- package/types/src/utils.d.ts +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { isComboWebView as de } from "@seayoo-web/combo-webview";
|
|
2
|
-
import { isPlainObject as h, supportWx as _, useConsole as ge, usePromise as pe, pruneURL as _e, supportWindow as be, queryString as S, pruneObject as c, omitFields as U, parseJSON as ye, removePara as
|
|
2
|
+
import { isPlainObject as h, supportWx as _, useConsole as ge, usePromise as pe, pruneURL as _e, supportWindow as be, queryString as S, pruneObject as c, omitFields as U, parseJSON as ye, removePara as G } from "@seayoo-web/utils";
|
|
3
3
|
import { v as e, objectGuard as s } from "@seayoo-web/validator";
|
|
4
4
|
function he(i) {
|
|
5
5
|
return h(i, "gamer_token") && typeof i.gamer_token == "string";
|
|
@@ -35,7 +35,7 @@ const ve = {
|
|
|
35
35
|
remove(i) {
|
|
36
36
|
localStorage.removeItem(i);
|
|
37
37
|
}
|
|
38
|
-
},
|
|
38
|
+
}, Re = {
|
|
39
39
|
get(i) {
|
|
40
40
|
try {
|
|
41
41
|
if (_()) return wx.getStorageSync(i) || "";
|
|
@@ -59,7 +59,7 @@ const ve = {
|
|
|
59
59
|
}
|
|
60
60
|
}
|
|
61
61
|
}, f = "gamer_token";
|
|
62
|
-
class
|
|
62
|
+
class ba {
|
|
63
63
|
$NetRequest;
|
|
64
64
|
$idToken = "";
|
|
65
65
|
$weixinToken = "";
|
|
@@ -67,7 +67,7 @@ class la {
|
|
|
67
67
|
req;
|
|
68
68
|
storage;
|
|
69
69
|
constructor(t, n) {
|
|
70
|
-
this.storage = _() ?
|
|
70
|
+
this.storage = _() ? Re : ve;
|
|
71
71
|
const r = we(t) ? t : `https://${_e(t)}`;
|
|
72
72
|
if (this.$NetRequest = n, this.req = n({
|
|
73
73
|
baseURL: `${r}/v1`,
|
|
@@ -240,14 +240,14 @@ class la {
|
|
|
240
240
|
return n;
|
|
241
241
|
}
|
|
242
242
|
}
|
|
243
|
-
const
|
|
243
|
+
const Ce = {
|
|
244
244
|
/** 未知 */
|
|
245
245
|
Unknown: "unknown",
|
|
246
246
|
/** 男 */
|
|
247
247
|
Male: "male",
|
|
248
248
|
/** 女 */
|
|
249
249
|
Female: "female"
|
|
250
|
-
},
|
|
250
|
+
}, Ve = e.string().enum(Ce).lock(), je = {
|
|
251
251
|
/** 积分增加 */
|
|
252
252
|
Increase: "increase",
|
|
253
253
|
/** 积分减少 */
|
|
@@ -333,7 +333,7 @@ const Ve = {
|
|
|
333
333
|
name: e.string(),
|
|
334
334
|
avatar_url: e.string(),
|
|
335
335
|
bio: e.string(),
|
|
336
|
-
gender:
|
|
336
|
+
gender: Ve,
|
|
337
337
|
birthday: e.object({ year: e.number(), month: e.number(), day: e.number() }),
|
|
338
338
|
social_medias: e.record(
|
|
339
339
|
e.object({
|
|
@@ -350,12 +350,12 @@ const Ve = {
|
|
|
350
350
|
district: e.string(),
|
|
351
351
|
address: e.string(),
|
|
352
352
|
is_default: e.bool()
|
|
353
|
-
}).lock(),
|
|
353
|
+
}).lock(), Ae = e.object({
|
|
354
354
|
increased_credit: e.number(),
|
|
355
355
|
decreased_credit: e.number(),
|
|
356
356
|
expired_credit: e.number(),
|
|
357
357
|
balance_credit: e.number()
|
|
358
|
-
}).lock(),
|
|
358
|
+
}).lock(), Ge = e.object({
|
|
359
359
|
id: e.number(),
|
|
360
360
|
change_type: Te,
|
|
361
361
|
change_scene: xe,
|
|
@@ -401,7 +401,7 @@ const Ve = {
|
|
|
401
401
|
}).lock(), Oe = e.object({
|
|
402
402
|
...U(X.shape, "tag"),
|
|
403
403
|
product: Y.clone().optional()
|
|
404
|
-
}).lock(),
|
|
404
|
+
}).lock(), ya = e.union(
|
|
405
405
|
e.object({
|
|
406
406
|
server_id: e.string(),
|
|
407
407
|
role_id: e.string()
|
|
@@ -436,8 +436,8 @@ const Ve = {
|
|
|
436
436
|
status: Ue,
|
|
437
437
|
created_at: e.number(),
|
|
438
438
|
extra_data: e.union(Ne.clone(), Qe.clone()).satisfies().optional()
|
|
439
|
-
}), Me = e.guard(Pe), N = s({ player: Ee }), Ke = s({ roles: e.array(J) }), T = s({ role_card: Ie }), Q = e.guard(De), B = e.guard(Z), He = s({ addresses: e.array(Z) }), ze = e.guard(
|
|
440
|
-
credit_logs: e.array(
|
|
439
|
+
}), Me = e.guard(Pe), N = s({ player: Ee }), Ke = s({ roles: e.array(J) }), T = s({ role_card: Ie }), Q = e.guard(De), B = e.guard(Z), He = s({ addresses: e.array(Z) }), ze = e.guard(Ae), Je = s({
|
|
440
|
+
credit_logs: e.array(Ge),
|
|
441
441
|
next_token: e.string().optional()
|
|
442
442
|
}), Ze = s({ products: e.array(Y) }), Xe = s({ benefits: e.array(X) }), Ye = s({ benefit: Oe }), We = s({
|
|
443
443
|
redemptions: e.array(Be),
|
|
@@ -447,7 +447,7 @@ const Ve = {
|
|
|
447
447
|
image_upload_url: e.string().optional(),
|
|
448
448
|
image_id: e.string()
|
|
449
449
|
});
|
|
450
|
-
class
|
|
450
|
+
class ha {
|
|
451
451
|
token;
|
|
452
452
|
req;
|
|
453
453
|
constructor(t) {
|
|
@@ -755,7 +755,7 @@ const v = {
|
|
|
755
755
|
ExternalCode: "external_gift_code",
|
|
756
756
|
/** 空奖励 */
|
|
757
757
|
VoidItem: "void_item"
|
|
758
|
-
}, W = e.string().enum(v).lock(),
|
|
758
|
+
}, W = e.string().enum(v).lock(), fa = v, ee = W, tt = {
|
|
759
759
|
/** 世游通行证 ID / Combo ID */
|
|
760
760
|
UserId: "user_id",
|
|
761
761
|
/** 游戏角色 ID */
|
|
@@ -811,7 +811,9 @@ const v = {
|
|
|
811
811
|
/** 投稿 */
|
|
812
812
|
Ugc: "ugc",
|
|
813
813
|
/** 投稿点赞 */
|
|
814
|
-
UgcLike: "ugc_like"
|
|
814
|
+
UgcLike: "ugc_like",
|
|
815
|
+
/** 兑换 */
|
|
816
|
+
Redeem: "redeem"
|
|
815
817
|
}, ot = e.string().enum(u).lock(), it = {
|
|
816
818
|
/** 累计游戏内活跃值 */
|
|
817
819
|
Active: "player_active_points",
|
|
@@ -833,8 +835,12 @@ const v = {
|
|
|
833
835
|
PlayerLevel: "player_level",
|
|
834
836
|
/** 活动道具累计获取 */
|
|
835
837
|
EventItems: "event_items",
|
|
836
|
-
|
|
837
|
-
GameTask: "game_task"
|
|
838
|
+
/** 游戏内任务 */
|
|
839
|
+
GameTask: "game_task",
|
|
840
|
+
/** 游戏内充值金额 */
|
|
841
|
+
OrderAmountInApp: "order_in_app_total_amount",
|
|
842
|
+
/** 支付中心充值金额 */
|
|
843
|
+
OrderAmountInPayCenter: "order_seayoo_web_total_amount"
|
|
838
844
|
}, te = e.string().enum(it).lock(), st = {
|
|
839
845
|
/** 官方上传 */
|
|
840
846
|
System: "system",
|
|
@@ -853,7 +859,7 @@ const v = {
|
|
|
853
859
|
Failed: "failed",
|
|
854
860
|
/** 奖励已发货 */
|
|
855
861
|
Delivered: "delivered"
|
|
856
|
-
},
|
|
862
|
+
}, wa = e.string().enum(d).lock(), ut = {
|
|
857
863
|
/** 奖励未领取 */
|
|
858
864
|
Unclaimed: d.Unclaimed,
|
|
859
865
|
/** 奖励已领取 */
|
|
@@ -894,7 +900,7 @@ const v = {
|
|
|
894
900
|
Claimed: "claimed",
|
|
895
901
|
/** 领奖失败 */
|
|
896
902
|
Fail: "fail"
|
|
897
|
-
},
|
|
903
|
+
}, ka = e.string().enum(w).lock(), pt = {
|
|
898
904
|
/** 发起组队 */
|
|
899
905
|
Assemble: "assemble",
|
|
900
906
|
/** 加入队伍 */
|
|
@@ -905,14 +911,14 @@ const v = {
|
|
|
905
911
|
ChangeVisibility: "change_visibility",
|
|
906
912
|
/** 查询组队信息 */
|
|
907
913
|
Query: "query"
|
|
908
|
-
},
|
|
914
|
+
}, va = e.string().enum(pt).lock(), _t = {
|
|
909
915
|
/** 查询抽奖券 */
|
|
910
916
|
Query: "query",
|
|
911
917
|
/** 开奖 */
|
|
912
918
|
Draw: "draw",
|
|
913
919
|
/** 领奖 */
|
|
914
920
|
Claim: "claim"
|
|
915
|
-
},
|
|
921
|
+
}, Ra = e.string().enum(_t).lock(), bt = {
|
|
916
922
|
/** 将所有队员的进度值求和,作为队伍进度值 */
|
|
917
923
|
Sum: "sum",
|
|
918
924
|
/** 以进度值倒序排名第 N 的队员的进度值,作为队伍进度值。如果队伍人数不足 N,则队伍进度值为 0。N 的值来自于配置字段 top_n */
|
|
@@ -946,25 +952,25 @@ const v = {
|
|
|
946
952
|
Accepted: "accepted",
|
|
947
953
|
/** 已拒绝 */
|
|
948
954
|
Rejected: "rejected"
|
|
949
|
-
}, vt = e.string().enum(kt).lock(),
|
|
955
|
+
}, vt = e.string().enum(kt).lock(), Rt = e.string().enum(v), b = e.object({
|
|
950
956
|
reward_item_id: e.number(),
|
|
951
957
|
reward_amount: e.number(),
|
|
952
958
|
reward_item_name: e.string(),
|
|
953
959
|
reward_item_icon_url: e.string(),
|
|
954
960
|
reward_item_desc: e.string().optional(),
|
|
955
|
-
reward_item_type:
|
|
961
|
+
reward_item_type: Rt,
|
|
956
962
|
reward_item_rating: e.number()
|
|
957
|
-
}).lock(),
|
|
963
|
+
}).lock(), Ct = e.object({
|
|
958
964
|
engage_count: e.number(),
|
|
959
|
-
rewards: e.array(
|
|
960
|
-
}).lock(),
|
|
965
|
+
rewards: e.array(b)
|
|
966
|
+
}).lock(), Vt = e.union(
|
|
961
967
|
e.object({
|
|
962
968
|
feature_reward_type: e.string().enum("every"),
|
|
963
|
-
reward_details: e.array(
|
|
969
|
+
reward_details: e.array(b)
|
|
964
970
|
}),
|
|
965
971
|
e.object({
|
|
966
972
|
feature_reward_type: e.string().enum("regular"),
|
|
967
|
-
reward_details: e.array(
|
|
973
|
+
reward_details: e.array(Ct)
|
|
968
974
|
})
|
|
969
975
|
).satisfies().lock(), l = e.object({
|
|
970
976
|
feature_name: e.string(),
|
|
@@ -976,7 +982,7 @@ const v = {
|
|
|
976
982
|
since: e.number(),
|
|
977
983
|
until: e.number(),
|
|
978
984
|
engage_account: nt,
|
|
979
|
-
feature_rewards:
|
|
985
|
+
feature_rewards: Vt.clone().optional(),
|
|
980
986
|
sort: e.number().optional()
|
|
981
987
|
}), jt = u.Cashback, Tt = e.object({
|
|
982
988
|
...l.shape,
|
|
@@ -1013,15 +1019,15 @@ const v = {
|
|
|
1013
1019
|
qr_code_url: e.string().optional(),
|
|
1014
1020
|
platform_desc: e.string().optional()
|
|
1015
1021
|
})
|
|
1016
|
-
}), Dt = u.GiftCode,
|
|
1022
|
+
}), Dt = u.GiftCode, At = e.object({
|
|
1017
1023
|
name: e.string(),
|
|
1018
1024
|
icon_url: e.string(),
|
|
1019
1025
|
count: e.number()
|
|
1020
|
-
}),
|
|
1026
|
+
}), Gt = e.object({
|
|
1021
1027
|
...l.shape,
|
|
1022
1028
|
feature_type: e.string().enum(Dt),
|
|
1023
1029
|
config: e.object({
|
|
1024
|
-
gift_items: e.array(
|
|
1030
|
+
gift_items: e.array(At),
|
|
1025
1031
|
mp_url: e.string().optional(),
|
|
1026
1032
|
mp_qrcode_url: e.string().optional()
|
|
1027
1033
|
})
|
|
@@ -1083,51 +1089,62 @@ const v = {
|
|
|
1083
1089
|
event_item_id: e.number().optional()
|
|
1084
1090
|
}).optional()
|
|
1085
1091
|
})
|
|
1086
|
-
}), tn = u.
|
|
1092
|
+
}), tn = u.Redeem, nn = e.object({
|
|
1093
|
+
price: e.number(),
|
|
1094
|
+
per_user_limit: e.number(),
|
|
1095
|
+
item: b
|
|
1096
|
+
}), rn = e.object({
|
|
1097
|
+
...l.shape,
|
|
1098
|
+
feature_type: e.string().enum(tn),
|
|
1099
|
+
config: e.object({
|
|
1100
|
+
event_item_id: e.number(),
|
|
1101
|
+
redeem_catalog: e.array(nn)
|
|
1102
|
+
})
|
|
1103
|
+
}), an = u.Register, on = e.object({
|
|
1087
1104
|
...l.shape,
|
|
1088
|
-
feature_type: e.string().enum(
|
|
1089
|
-
}),
|
|
1105
|
+
feature_type: e.string().enum(an)
|
|
1106
|
+
}), sn = u.Share, cn = e.object({
|
|
1090
1107
|
...l.shape,
|
|
1091
|
-
feature_type: e.string().enum(
|
|
1108
|
+
feature_type: e.string().enum(sn),
|
|
1092
1109
|
config: e.object({
|
|
1093
1110
|
share_platform: e.string(),
|
|
1094
1111
|
jump_url: e.string().optional(),
|
|
1095
1112
|
icon_url: e.string().optional()
|
|
1096
1113
|
})
|
|
1097
|
-
}),
|
|
1114
|
+
}), un = u.Subscribe, ln = e.object({
|
|
1098
1115
|
...l.shape,
|
|
1099
|
-
feature_type: e.string().enum(
|
|
1116
|
+
feature_type: e.string().enum(un),
|
|
1100
1117
|
config: e.object({
|
|
1101
1118
|
weixin_template_ids: e.array(e.string())
|
|
1102
1119
|
})
|
|
1103
|
-
}),
|
|
1120
|
+
}), mn = u.Survey, dn = e.object({
|
|
1104
1121
|
...l.shape,
|
|
1105
|
-
feature_type: e.string().enum(
|
|
1122
|
+
feature_type: e.string().enum(mn),
|
|
1106
1123
|
config: e.object({
|
|
1107
1124
|
survey_id: e.string(),
|
|
1108
1125
|
survey_url: e.string()
|
|
1109
1126
|
})
|
|
1110
|
-
}),
|
|
1127
|
+
}), gn = u.Team, pn = e.object({
|
|
1111
1128
|
...l.shape,
|
|
1112
|
-
feature_type: e.string().enum(
|
|
1129
|
+
feature_type: e.string().enum(gn),
|
|
1113
1130
|
config: e.object({
|
|
1114
1131
|
max_members: e.number().min(1),
|
|
1115
1132
|
min_members: e.number().min(1)
|
|
1116
1133
|
})
|
|
1117
|
-
}),
|
|
1134
|
+
}), _n = u.Ugc, bn = e.object({
|
|
1118
1135
|
...l.shape,
|
|
1119
|
-
feature_type: e.string().enum(
|
|
1136
|
+
feature_type: e.string().enum(_n),
|
|
1120
1137
|
config: e.object({
|
|
1121
1138
|
allowed_social_medias: e.array(e.string()).optional(),
|
|
1122
|
-
acceptance_rewards: e.array(
|
|
1139
|
+
acceptance_rewards: e.array(b).optional()
|
|
1123
1140
|
})
|
|
1124
|
-
}),
|
|
1141
|
+
}), yn = u.UgcLike, hn = e.object({
|
|
1125
1142
|
...l.shape,
|
|
1126
|
-
feature_type: e.string().enum(
|
|
1143
|
+
feature_type: e.string().enum(yn),
|
|
1127
1144
|
config: e.object({
|
|
1128
1145
|
ugc_feature_id: e.number()
|
|
1129
1146
|
})
|
|
1130
|
-
}),
|
|
1147
|
+
}), fn = u.Vote, wn = e.object({
|
|
1131
1148
|
sn: e.string(),
|
|
1132
1149
|
name: e.string(),
|
|
1133
1150
|
img_urls: e.array(e.string()).optional(),
|
|
@@ -1137,86 +1154,87 @@ const v = {
|
|
|
1137
1154
|
amount: e.number(),
|
|
1138
1155
|
finalists: e.bool(),
|
|
1139
1156
|
last_vote_time: e.number()
|
|
1140
|
-
}),
|
|
1157
|
+
}), kn = e.object({
|
|
1141
1158
|
...l.shape,
|
|
1142
|
-
feature_type: e.string().enum(
|
|
1159
|
+
feature_type: e.string().enum(fn),
|
|
1143
1160
|
config: e.object({
|
|
1144
1161
|
vote_feature_ids: e.array(e.number()),
|
|
1145
1162
|
submission_feature_ids: e.array(e.number()),
|
|
1146
1163
|
finalists_amount: e.number(),
|
|
1147
1164
|
source: ct,
|
|
1148
|
-
options: e.array(
|
|
1149
|
-
rewards: e.array(
|
|
1165
|
+
options: e.array(wn),
|
|
1166
|
+
rewards: e.array(b)
|
|
1150
1167
|
})
|
|
1151
|
-
}),
|
|
1168
|
+
}), vn = u.Vote2, Rn = e.object({
|
|
1152
1169
|
candidate_id: e.string(),
|
|
1153
1170
|
display_name: e.string(),
|
|
1154
1171
|
images: e.array(e.string()).optional(),
|
|
1155
1172
|
videos: e.array(e.string()).optional(),
|
|
1156
1173
|
description: e.string().optional(),
|
|
1157
1174
|
jump_url: e.string()
|
|
1158
|
-
}),
|
|
1175
|
+
}), Cn = e.object({
|
|
1159
1176
|
...l.shape,
|
|
1160
|
-
feature_type: e.string().enum(
|
|
1177
|
+
feature_type: e.string().enum(vn),
|
|
1161
1178
|
config: e.object({
|
|
1162
1179
|
vote_item_id: e.number().optional(),
|
|
1163
|
-
candidates: e.array(
|
|
1180
|
+
candidates: e.array(Rn),
|
|
1164
1181
|
vote_since: e.number(),
|
|
1165
1182
|
vote_until: e.number(),
|
|
1166
1183
|
rewards_since: e.number(),
|
|
1167
1184
|
rewards_until: e.number(),
|
|
1168
|
-
winner_rewards: e.array(
|
|
1169
|
-
consolation_rewards: e.array(
|
|
1185
|
+
winner_rewards: e.array(b).optional(),
|
|
1186
|
+
consolation_rewards: e.array(b).optional()
|
|
1170
1187
|
})
|
|
1171
|
-
}),
|
|
1188
|
+
}), Vn = u.ZeroChatgpt, jn = e.object({
|
|
1172
1189
|
...l.shape,
|
|
1173
|
-
feature_type: e.string().enum(
|
|
1174
|
-
}),
|
|
1190
|
+
feature_type: e.string().enum(Vn)
|
|
1191
|
+
}), Tn = e.union(
|
|
1175
1192
|
Tt,
|
|
1176
1193
|
xt,
|
|
1177
1194
|
Pt,
|
|
1178
1195
|
$t,
|
|
1179
1196
|
It,
|
|
1180
|
-
|
|
1197
|
+
Gt,
|
|
1181
1198
|
Nt,
|
|
1182
1199
|
Bt,
|
|
1183
1200
|
zt,
|
|
1184
1201
|
Zt,
|
|
1185
1202
|
Yt,
|
|
1186
1203
|
en,
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
hn,
|
|
1204
|
+
on,
|
|
1205
|
+
cn,
|
|
1206
|
+
ln,
|
|
1207
|
+
dn,
|
|
1208
|
+
pn,
|
|
1193
1209
|
kn,
|
|
1194
|
-
St,
|
|
1195
1210
|
Cn,
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1211
|
+
St,
|
|
1212
|
+
jn,
|
|
1213
|
+
bn,
|
|
1214
|
+
hn,
|
|
1215
|
+
rn
|
|
1216
|
+
).key("feature_type").satisfies(), qn = e.object({
|
|
1199
1217
|
event_name: e.string(),
|
|
1200
1218
|
rules: e.string(),
|
|
1201
1219
|
since: e.number(),
|
|
1202
1220
|
until: e.number(),
|
|
1203
1221
|
visit_count: e.number().optional(),
|
|
1204
|
-
features: e.array(
|
|
1222
|
+
features: e.array(Tn)
|
|
1205
1223
|
}).lock(), q = e.union(e.string().pattern("NumberString", /^\d+$/), e.number()), ae = e.object({
|
|
1206
1224
|
order_total_amount: q,
|
|
1207
1225
|
cashback_total_amount: q,
|
|
1208
1226
|
game_item_count: q
|
|
1209
|
-
}),
|
|
1227
|
+
}), xn = e.object({
|
|
1210
1228
|
activation_key: e.string().disallow("")
|
|
1211
|
-
}),
|
|
1229
|
+
}), Ln = e.object({
|
|
1212
1230
|
gift_code: e.string()
|
|
1213
|
-
}),
|
|
1231
|
+
}), Sn = e.object({
|
|
1214
1232
|
user_id: e.string(),
|
|
1215
1233
|
name: e.string().optional(),
|
|
1216
1234
|
avatar_url: e.string().optional()
|
|
1217
|
-
}),
|
|
1235
|
+
}), Un = e.object({
|
|
1218
1236
|
lottery_count: e.number()
|
|
1219
|
-
}),
|
|
1237
|
+
}), R = e.object({
|
|
1220
1238
|
reward_id: e.number(),
|
|
1221
1239
|
reward_item_id: e.number(),
|
|
1222
1240
|
reward_source: E,
|
|
@@ -1234,26 +1252,26 @@ const v = {
|
|
|
1234
1252
|
feature_type: ot,
|
|
1235
1253
|
receive_time: e.number(),
|
|
1236
1254
|
extra_data: e.record(e.unknown()).optional()
|
|
1237
|
-
}),
|
|
1255
|
+
}), Pn = e.string().enum(w.Unknown, w.Pending), En = e.union(
|
|
1238
1256
|
e.object({
|
|
1239
1257
|
ticket: e.string(),
|
|
1240
|
-
status:
|
|
1258
|
+
status: Pn
|
|
1241
1259
|
}),
|
|
1242
1260
|
e.object({
|
|
1243
1261
|
ticket: e.string(),
|
|
1244
1262
|
status: e.string().enum(U(w, "Unknown", "Pending")),
|
|
1245
|
-
reward:
|
|
1263
|
+
reward: R
|
|
1246
1264
|
})
|
|
1247
|
-
).satisfies(),
|
|
1248
|
-
tickets: e.array(
|
|
1249
|
-
}),
|
|
1265
|
+
).satisfies(), $n = e.object({
|
|
1266
|
+
tickets: e.array(En)
|
|
1267
|
+
}), Fn = e.object({
|
|
1250
1268
|
platforms: e.array(e.string())
|
|
1251
1269
|
}), oe = e.object({
|
|
1252
1270
|
role_name: e.string(),
|
|
1253
1271
|
is_leader: e.bool(),
|
|
1254
1272
|
is_myself: e.bool().optional(),
|
|
1255
1273
|
progress: e.number().optional()
|
|
1256
|
-
}).lock(),
|
|
1274
|
+
}).lock(), In = e.object({
|
|
1257
1275
|
objective: te,
|
|
1258
1276
|
progress: e.number(),
|
|
1259
1277
|
completion_value: e.number().optional(),
|
|
@@ -1262,28 +1280,40 @@ const v = {
|
|
|
1262
1280
|
completion_value: e.number().optional(),
|
|
1263
1281
|
players: e.array(oe)
|
|
1264
1282
|
}).optional()
|
|
1265
|
-
}),
|
|
1283
|
+
}), Dn = e.object({
|
|
1266
1284
|
progress: e.number(),
|
|
1267
1285
|
team: e.object({
|
|
1268
1286
|
progress: e.number(),
|
|
1269
1287
|
team_members: e.array(oe).optional()
|
|
1270
1288
|
}).optional()
|
|
1271
|
-
}),
|
|
1289
|
+
}), An = e.object({
|
|
1290
|
+
item_id: e.number(),
|
|
1291
|
+
item_count: e.number(),
|
|
1292
|
+
redeem_count: e.number()
|
|
1293
|
+
}), Gn = e.object({
|
|
1294
|
+
item_stocks: e.array(
|
|
1295
|
+
e.object({
|
|
1296
|
+
item_id: e.number(),
|
|
1297
|
+
item_stock: e.number(),
|
|
1298
|
+
user_limit: e.number()
|
|
1299
|
+
})
|
|
1300
|
+
)
|
|
1301
|
+
}), On = e.object({
|
|
1272
1302
|
platform: e.string()
|
|
1273
|
-
}),
|
|
1303
|
+
}), Nn = e.object({
|
|
1274
1304
|
weixin_openid: e.string()
|
|
1275
|
-
}),
|
|
1305
|
+
}), Qn = e.object({
|
|
1276
1306
|
serial_number: e.number()
|
|
1277
|
-
}),
|
|
1307
|
+
}), Bn = e.object({
|
|
1278
1308
|
team_code: e.string(),
|
|
1279
1309
|
leader_name: e.string(),
|
|
1280
1310
|
total_members: e.number()
|
|
1281
|
-
}),
|
|
1311
|
+
}), Ca = e.object({
|
|
1282
1312
|
is_leader: e.bool(),
|
|
1283
1313
|
is_myself: e.bool().optional(),
|
|
1284
1314
|
role_name: e.string(),
|
|
1285
1315
|
server_name: e.string()
|
|
1286
|
-
}),
|
|
1316
|
+
}), Mn = e.object({
|
|
1287
1317
|
team_code: e.string(),
|
|
1288
1318
|
visibility: gt,
|
|
1289
1319
|
members: e.array(
|
|
@@ -1293,14 +1323,14 @@ const v = {
|
|
|
1293
1323
|
server_name: e.string()
|
|
1294
1324
|
})
|
|
1295
1325
|
)
|
|
1296
|
-
}),
|
|
1326
|
+
}), Kn = e.object({
|
|
1297
1327
|
ugc_id: e.number(),
|
|
1298
1328
|
title: e.string(),
|
|
1299
1329
|
content: e.string().optional(),
|
|
1300
1330
|
image_urls: e.array(e.string()).optional(),
|
|
1301
1331
|
social_media: re.clone().optional(),
|
|
1302
1332
|
social_media_url: e.string().optional()
|
|
1303
|
-
}),
|
|
1333
|
+
}), Hn = e.object({
|
|
1304
1334
|
ugcs: e.array(
|
|
1305
1335
|
e.object({
|
|
1306
1336
|
ugc_id: e.number(),
|
|
@@ -1323,13 +1353,13 @@ const v = {
|
|
|
1323
1353
|
})
|
|
1324
1354
|
).optional(),
|
|
1325
1355
|
next_token: e.string().optional()
|
|
1326
|
-
}),
|
|
1356
|
+
}), zn = e.object({
|
|
1327
1357
|
total_count: e.number()
|
|
1328
|
-
}),
|
|
1358
|
+
}), Jn = e.object({
|
|
1329
1359
|
existed: e.bool(),
|
|
1330
1360
|
upload_url: e.string().optional(),
|
|
1331
1361
|
image_url: e.string()
|
|
1332
|
-
}),
|
|
1362
|
+
}), Zn = e.object({
|
|
1333
1363
|
ugcs: e.array(
|
|
1334
1364
|
e.object({
|
|
1335
1365
|
ugc_id: e.number(),
|
|
@@ -1342,27 +1372,27 @@ const v = {
|
|
|
1342
1372
|
role_name: e.string().optional()
|
|
1343
1373
|
})
|
|
1344
1374
|
).optional()
|
|
1345
|
-
}),
|
|
1375
|
+
}), Xn = e.object({
|
|
1346
1376
|
option_sn: e.string()
|
|
1347
|
-
}),
|
|
1377
|
+
}), Yn = e.object({
|
|
1348
1378
|
candidate_id: e.string(),
|
|
1349
1379
|
total_votes: e.number().optional(),
|
|
1350
1380
|
my_votes: e.number().optional(),
|
|
1351
1381
|
votes: e.number().optional()
|
|
1352
|
-
}),
|
|
1382
|
+
}), Wn = e.object({
|
|
1353
1383
|
rewards_type: ft,
|
|
1354
|
-
rewards: e.array(
|
|
1355
|
-
}),
|
|
1384
|
+
rewards: e.array(R).optional()
|
|
1385
|
+
}), er = e.object({
|
|
1356
1386
|
candidate_id: e.string(),
|
|
1357
1387
|
is_winner: e.bool(),
|
|
1358
1388
|
total_votes: e.number(),
|
|
1359
1389
|
my_votes: e.number()
|
|
1360
|
-
}),
|
|
1390
|
+
}), tr = e.object({
|
|
1361
1391
|
role: e.string(),
|
|
1362
1392
|
content: e.string()
|
|
1363
|
-
}),
|
|
1364
|
-
conversations: e.array(
|
|
1365
|
-
}),
|
|
1393
|
+
}), nr = e.object({
|
|
1394
|
+
conversations: e.array(tr)
|
|
1395
|
+
}), rr = e.object({
|
|
1366
1396
|
user_id: e.string(),
|
|
1367
1397
|
name: e.string(),
|
|
1368
1398
|
avatar_url: e.string(),
|
|
@@ -1370,27 +1400,28 @@ const v = {
|
|
|
1370
1400
|
video_note: e.number(),
|
|
1371
1401
|
created_at: e.number()
|
|
1372
1402
|
}), $ = e.union(
|
|
1373
|
-
Pn,
|
|
1374
|
-
xn,
|
|
1375
|
-
Dn,
|
|
1376
|
-
qn,
|
|
1377
1403
|
Fn,
|
|
1378
|
-
Kn,
|
|
1379
|
-
Hn,
|
|
1380
|
-
In,
|
|
1381
|
-
ae,
|
|
1382
|
-
Tn,
|
|
1383
|
-
An,
|
|
1384
|
-
En,
|
|
1385
1404
|
Un,
|
|
1386
|
-
|
|
1387
|
-
|
|
1405
|
+
Qn,
|
|
1406
|
+
Sn,
|
|
1388
1407
|
On,
|
|
1408
|
+
Xn,
|
|
1409
|
+
Yn,
|
|
1410
|
+
Nn,
|
|
1411
|
+
ae,
|
|
1412
|
+
Ln,
|
|
1413
|
+
Mn,
|
|
1414
|
+
In,
|
|
1415
|
+
$n,
|
|
1416
|
+
xn,
|
|
1417
|
+
nr,
|
|
1418
|
+
Kn,
|
|
1419
|
+
An,
|
|
1389
1420
|
e.custom(
|
|
1390
1421
|
"EmptyObject",
|
|
1391
1422
|
(i) => h(i) && Object.keys(i).length === 0
|
|
1392
1423
|
)
|
|
1393
|
-
).satisfies().lock(),
|
|
1424
|
+
).satisfies().lock(), ar = e.object({
|
|
1394
1425
|
reward_id: e.number(),
|
|
1395
1426
|
reward_item_id: e.number(),
|
|
1396
1427
|
reward_item_type: ee,
|
|
@@ -1403,7 +1434,7 @@ const v = {
|
|
|
1403
1434
|
reward_item_rating: e.number(),
|
|
1404
1435
|
receive_time: e.number(),
|
|
1405
1436
|
extra_data: e.union(...$.validators, e.record(e.unknown())).satisfies().optional()
|
|
1406
|
-
}),
|
|
1437
|
+
}), or = e.object({
|
|
1407
1438
|
reward_id: e.number(),
|
|
1408
1439
|
reward_item_id: e.number(),
|
|
1409
1440
|
reward_item_name: e.string(),
|
|
@@ -1415,7 +1446,7 @@ const v = {
|
|
|
1415
1446
|
reward_status: ne,
|
|
1416
1447
|
reward_source: E,
|
|
1417
1448
|
extra_data: e.record(e.unknown()).optional()
|
|
1418
|
-
}),
|
|
1449
|
+
}), ir = e.object({
|
|
1419
1450
|
engagement_id: e.number(),
|
|
1420
1451
|
user_id: e.string(),
|
|
1421
1452
|
event_id: e.number(),
|
|
@@ -1425,18 +1456,18 @@ const v = {
|
|
|
1425
1456
|
server_id: e.string().optional(),
|
|
1426
1457
|
role_id: e.string().optional(),
|
|
1427
1458
|
created_at: e.number(),
|
|
1428
|
-
rewards: e.array(
|
|
1429
|
-
}).lock(),
|
|
1459
|
+
rewards: e.array(ar).optional()
|
|
1460
|
+
}).lock(), sr = e.object({
|
|
1430
1461
|
allowed: e.bool(),
|
|
1431
1462
|
registered: e.bool()
|
|
1432
|
-
}),
|
|
1463
|
+
}), cr = e.object({
|
|
1433
1464
|
feature_id: e.number(),
|
|
1434
1465
|
can_engage: e.bool(),
|
|
1435
1466
|
has_unclaimed_rewards: e.bool(),
|
|
1436
1467
|
final_available_count: e.number(),
|
|
1437
1468
|
total_remaining_engagements: e.number(),
|
|
1438
1469
|
cycle_remaining_engagements: e.number()
|
|
1439
|
-
}),
|
|
1470
|
+
}), ur = e.object({
|
|
1440
1471
|
engagement_id: e.number(),
|
|
1441
1472
|
engagement: e.object({
|
|
1442
1473
|
engagement_id: e.number(),
|
|
@@ -1444,43 +1475,43 @@ const v = {
|
|
|
1444
1475
|
feature_id: e.number(),
|
|
1445
1476
|
data: $.clone().optional()
|
|
1446
1477
|
}).optional(),
|
|
1447
|
-
rewards: e.array(
|
|
1478
|
+
rewards: e.array(or).optional(),
|
|
1448
1479
|
scan: e.bool().optional()
|
|
1449
|
-
}),
|
|
1480
|
+
}), lr = e.object({
|
|
1450
1481
|
reward_id: e.number(),
|
|
1451
1482
|
reward_status: P
|
|
1452
|
-
}),
|
|
1453
|
-
engagements: e.union(e.array(
|
|
1454
|
-
}), lr = s({
|
|
1455
|
-
status: e.array(rr)
|
|
1456
|
-
}), mr = s({
|
|
1457
|
-
engagements_counts: e.record(e.number())
|
|
1458
|
-
}), dr = s({
|
|
1459
|
-
engagements: e.array(tr),
|
|
1460
|
-
next_token: e.string().optional()
|
|
1461
|
-
}), gr = e.guard(ar), pr = s({
|
|
1462
|
-
claimed_items: e.array(or)
|
|
1483
|
+
}), mr = e.guard(qn), dr = e.guard(sr), x = s({ count: e.number() }), gr = s({ first_visit: e.bool() }), pr = s({
|
|
1484
|
+
engagements: e.union(e.array(rr), e.array(Bn))
|
|
1463
1485
|
}), _r = s({
|
|
1464
|
-
|
|
1486
|
+
status: e.array(cr)
|
|
1465
1487
|
}), br = s({
|
|
1466
|
-
|
|
1488
|
+
engagements_counts: e.record(e.number())
|
|
1467
1489
|
}), yr = s({
|
|
1468
|
-
|
|
1490
|
+
engagements: e.array(ir),
|
|
1469
1491
|
next_token: e.string().optional()
|
|
1470
|
-
}), hr = s({
|
|
1492
|
+
}), hr = e.guard(ur), fr = s({
|
|
1493
|
+
claimed_items: e.array(lr)
|
|
1494
|
+
}), wr = s({
|
|
1495
|
+
rewards: e.array(R)
|
|
1496
|
+
}), kr = s({
|
|
1497
|
+
reward_status: P
|
|
1498
|
+
}), vr = s({
|
|
1499
|
+
user_rewards: e.array(R),
|
|
1500
|
+
next_token: e.string().optional()
|
|
1501
|
+
}), Rr = s({
|
|
1471
1502
|
unclaimed: e.number()
|
|
1472
|
-
}),
|
|
1503
|
+
}), Cr = s({
|
|
1473
1504
|
scene: e.string()
|
|
1474
|
-
}),
|
|
1505
|
+
}), Vr = s({
|
|
1475
1506
|
params: e.string()
|
|
1476
|
-
}),
|
|
1507
|
+
}), jr = s({
|
|
1477
1508
|
img: e.string()
|
|
1478
|
-
}),
|
|
1509
|
+
}), Tr = e.guard(Dn), qr = e.guard(Wn), xr = e.guard(
|
|
1479
1510
|
e.object({
|
|
1480
|
-
candidate_votes: e.array(
|
|
1511
|
+
candidate_votes: e.array(er)
|
|
1481
1512
|
})
|
|
1482
|
-
),
|
|
1483
|
-
class
|
|
1513
|
+
), Lr = e.guard(ae), M = e.guard(Hn), Sr = e.guard(zn), Ur = e.guard(Jn), Pr = e.guard(Zn), Er = e.guard(Gn);
|
|
1514
|
+
class Va {
|
|
1484
1515
|
token;
|
|
1485
1516
|
event = 0;
|
|
1486
1517
|
req;
|
|
@@ -1493,7 +1524,7 @@ class fa {
|
|
|
1493
1524
|
* https://kdocs.cn/l/cf2mO2uRLqh9?linkname=OWGSPF3Ysl
|
|
1494
1525
|
*/
|
|
1495
1526
|
async verifyMobileAllowed(t, n, r) {
|
|
1496
|
-
const { data: a } = await this.req.get("verify-mobile-allowed",
|
|
1527
|
+
const { data: a } = await this.req.get("verify-mobile-allowed", dr, {
|
|
1497
1528
|
...r,
|
|
1498
1529
|
params: { game_id: t, mobile: n }
|
|
1499
1530
|
});
|
|
@@ -1505,7 +1536,7 @@ class fa {
|
|
|
1505
1536
|
* https://kdocs.cn/l/ckWFDcOsYEUA?linkname=wFXxtdNKPm
|
|
1506
1537
|
*/
|
|
1507
1538
|
async getConfig(t) {
|
|
1508
|
-
const { data: n } = await this.req.get(`event/${this.event}/event-config`,
|
|
1539
|
+
const { data: n } = await this.req.get(`event/${this.event}/event-config`, mr, t);
|
|
1509
1540
|
return n;
|
|
1510
1541
|
}
|
|
1511
1542
|
/**
|
|
@@ -1540,7 +1571,7 @@ class fa {
|
|
|
1540
1571
|
* https://kdocs.cn/l/ckWFDcOsYEUA?linkname=THtZ4ewIQW
|
|
1541
1572
|
*/
|
|
1542
1573
|
async getEngagements(t, n) {
|
|
1543
|
-
const { data: r } = await this.req.get(`event/${this.event}/feature-engagements`,
|
|
1574
|
+
const { data: r } = await this.req.get(`event/${this.event}/feature-engagements`, pr, {
|
|
1544
1575
|
...n,
|
|
1545
1576
|
params: { feature_id: t }
|
|
1546
1577
|
});
|
|
@@ -1556,7 +1587,7 @@ class fa {
|
|
|
1556
1587
|
const { data: r, code: a, message: o } = await this.req.post(
|
|
1557
1588
|
`event/${this.event}/visit`,
|
|
1558
1589
|
c(t || {}),
|
|
1559
|
-
|
|
1590
|
+
gr,
|
|
1560
1591
|
n
|
|
1561
1592
|
);
|
|
1562
1593
|
return r ?? {
|
|
@@ -1573,7 +1604,7 @@ class fa {
|
|
|
1573
1604
|
*/
|
|
1574
1605
|
async getUserFeatureStatus(t, n) {
|
|
1575
1606
|
if (!await this.token.autoLogin()) return [];
|
|
1576
|
-
const { data: r } = await this.req.get("event/user-feature-status",
|
|
1607
|
+
const { data: r } = await this.req.get("event/user-feature-status", _r, {
|
|
1577
1608
|
...n,
|
|
1578
1609
|
message: !1,
|
|
1579
1610
|
params: c({ ...t, event_id: this.event })
|
|
@@ -1587,7 +1618,7 @@ class fa {
|
|
|
1587
1618
|
*/
|
|
1588
1619
|
async getUserEngagementCount(t, n) {
|
|
1589
1620
|
if (!await this.token.autoLogin()) return {};
|
|
1590
|
-
const { data: r } = await this.req.get("event/user-engagements-count",
|
|
1621
|
+
const { data: r } = await this.req.get("event/user-engagements-count", br, {
|
|
1591
1622
|
message: !1,
|
|
1592
1623
|
params: c({ ...n, event_id: this.event, feature_id: t })
|
|
1593
1624
|
});
|
|
@@ -1606,7 +1637,7 @@ class fa {
|
|
|
1606
1637
|
engagements: [],
|
|
1607
1638
|
next_token: ""
|
|
1608
1639
|
};
|
|
1609
|
-
const { data: a } = await this.req.get("event/user-engagements",
|
|
1640
|
+
const { data: a } = await this.req.get("event/user-engagements", yr, {
|
|
1610
1641
|
...r,
|
|
1611
1642
|
params: c({
|
|
1612
1643
|
max_results: 20,
|
|
@@ -1638,7 +1669,7 @@ class fa {
|
|
|
1638
1669
|
engagement: n,
|
|
1639
1670
|
...r
|
|
1640
1671
|
}),
|
|
1641
|
-
|
|
1672
|
+
hr,
|
|
1642
1673
|
a
|
|
1643
1674
|
);
|
|
1644
1675
|
return o ?? {
|
|
@@ -1661,7 +1692,7 @@ class fa {
|
|
|
1661
1692
|
...t,
|
|
1662
1693
|
server_id: t.server_id ? +t.server_id : void 0
|
|
1663
1694
|
}),
|
|
1664
|
-
|
|
1695
|
+
fr,
|
|
1665
1696
|
n
|
|
1666
1697
|
);
|
|
1667
1698
|
return r?.claimed_items || {
|
|
@@ -1682,7 +1713,7 @@ class fa {
|
|
|
1682
1713
|
...t,
|
|
1683
1714
|
server_id: t.server_id ? +t.server_id : void 0
|
|
1684
1715
|
}),
|
|
1685
|
-
|
|
1716
|
+
wr,
|
|
1686
1717
|
n
|
|
1687
1718
|
);
|
|
1688
1719
|
return r?.rewards || {
|
|
@@ -1700,7 +1731,7 @@ class fa {
|
|
|
1700
1731
|
const { data: r, code: a, message: o } = await this.req.post(
|
|
1701
1732
|
"event/claim-weixin-hongbao",
|
|
1702
1733
|
{ reward_id: t },
|
|
1703
|
-
|
|
1734
|
+
kr,
|
|
1704
1735
|
n
|
|
1705
1736
|
);
|
|
1706
1737
|
return r || {
|
|
@@ -1741,7 +1772,7 @@ class fa {
|
|
|
1741
1772
|
const { data: r } = await this.req.post(
|
|
1742
1773
|
"event/user-rewards",
|
|
1743
1774
|
c({ max_results: 20, ...t, event_id: this.event }),
|
|
1744
|
-
|
|
1775
|
+
vr,
|
|
1745
1776
|
n
|
|
1746
1777
|
);
|
|
1747
1778
|
return {
|
|
@@ -1759,7 +1790,7 @@ class fa {
|
|
|
1759
1790
|
return {
|
|
1760
1791
|
unclaimed: 0
|
|
1761
1792
|
};
|
|
1762
|
-
const { data: r } = await this.req.get("event/user-rewards-count",
|
|
1793
|
+
const { data: r } = await this.req.get("event/user-rewards-count", Rr, {
|
|
1763
1794
|
...n,
|
|
1764
1795
|
params: c({ ...t })
|
|
1765
1796
|
});
|
|
@@ -1807,7 +1838,7 @@ class fa {
|
|
|
1807
1838
|
*/
|
|
1808
1839
|
async getUnlimitQrcodeScene(t, n) {
|
|
1809
1840
|
if (!await this.token.autoLogin()) return null;
|
|
1810
|
-
const { data: r } = await this.req.get("event/unlimit-qrcode-scene",
|
|
1841
|
+
const { data: r } = await this.req.get("event/unlimit-qrcode-scene", Cr, {
|
|
1811
1842
|
...n,
|
|
1812
1843
|
params: { params: t }
|
|
1813
1844
|
});
|
|
@@ -1821,7 +1852,7 @@ class fa {
|
|
|
1821
1852
|
* @param scene - 小程序码 scene 值
|
|
1822
1853
|
*/
|
|
1823
1854
|
async getParamsByQrcodeScene(t, n) {
|
|
1824
|
-
const { data: r } = await this.req.get("event/params-by-qrcode-scene",
|
|
1855
|
+
const { data: r } = await this.req.get("event/params-by-qrcode-scene", Vr, {
|
|
1825
1856
|
...n,
|
|
1826
1857
|
params: { scene: t }
|
|
1827
1858
|
});
|
|
@@ -1837,7 +1868,7 @@ class fa {
|
|
|
1837
1868
|
const { data: r } = await this.req.post(
|
|
1838
1869
|
"event/unlimit-qrcode",
|
|
1839
1870
|
c(t),
|
|
1840
|
-
|
|
1871
|
+
jr,
|
|
1841
1872
|
n
|
|
1842
1873
|
);
|
|
1843
1874
|
return r?.img ?? null;
|
|
@@ -1849,7 +1880,7 @@ class fa {
|
|
|
1849
1880
|
*/
|
|
1850
1881
|
async getQuestProgress(t, n) {
|
|
1851
1882
|
if (!await this.token.autoLogin()) return null;
|
|
1852
|
-
const { data: r, code: a, message: o } = await this.req.get(`event/${this.event}/quest-progress`,
|
|
1883
|
+
const { data: r, code: a, message: o } = await this.req.get(`event/${this.event}/quest-progress`, Tr, {
|
|
1853
1884
|
message: !1,
|
|
1854
1885
|
...n,
|
|
1855
1886
|
params: { feature_id: t }
|
|
@@ -1871,7 +1902,7 @@ class fa {
|
|
|
1871
1902
|
const { data: r, code: a, message: o } = await this.req.post(
|
|
1872
1903
|
"event/vote2/rewards",
|
|
1873
1904
|
{ feature_id: t, event_id: this.event },
|
|
1874
|
-
|
|
1905
|
+
qr,
|
|
1875
1906
|
n
|
|
1876
1907
|
);
|
|
1877
1908
|
return r || {
|
|
@@ -1886,7 +1917,7 @@ class fa {
|
|
|
1886
1917
|
*/
|
|
1887
1918
|
async getVote2Leaderboard(t, n) {
|
|
1888
1919
|
if (!await this.token.autoLogin()) return [];
|
|
1889
|
-
const { data: r } = await this.req.get("event/vote2/leaderboard",
|
|
1920
|
+
const { data: r } = await this.req.get("event/vote2/leaderboard", xr, {
|
|
1890
1921
|
...n,
|
|
1891
1922
|
params: { feature_id: t, event_id: this.event }
|
|
1892
1923
|
});
|
|
@@ -1899,7 +1930,7 @@ class fa {
|
|
|
1899
1930
|
*/
|
|
1900
1931
|
async getCashbackQuery(t, n) {
|
|
1901
1932
|
if (!await this.token.autoLogin()) return null;
|
|
1902
|
-
const { data: r, code: a, message: o } = await this.req.get("event/cashback/query",
|
|
1933
|
+
const { data: r, code: a, message: o } = await this.req.get("event/cashback/query", Lr, {
|
|
1903
1934
|
...n,
|
|
1904
1935
|
params: { feature_id: t, event_id: this.event }
|
|
1905
1936
|
});
|
|
@@ -1934,7 +1965,7 @@ class fa {
|
|
|
1934
1965
|
*/
|
|
1935
1966
|
async getUgcMyCount(t, n) {
|
|
1936
1967
|
if (!await this.token.autoLogin()) return null;
|
|
1937
|
-
const { data: r, code: a, message: o } = await this.req.get("event/ugc/my-count",
|
|
1968
|
+
const { data: r, code: a, message: o } = await this.req.get("event/ugc/my-count", Sr, {
|
|
1938
1969
|
...n,
|
|
1939
1970
|
params: {
|
|
1940
1971
|
...t
|
|
@@ -1959,7 +1990,7 @@ class fa {
|
|
|
1959
1990
|
const { data: a, code: o, message: g } = await this.req.post(
|
|
1960
1991
|
"event/ugc/upload-image",
|
|
1961
1992
|
{ feature_id: t, ...n, event_id: this.event },
|
|
1962
|
-
|
|
1993
|
+
Ur,
|
|
1963
1994
|
r
|
|
1964
1995
|
);
|
|
1965
1996
|
return a || {
|
|
@@ -1998,7 +2029,7 @@ class fa {
|
|
|
1998
2029
|
*/
|
|
1999
2030
|
async getUgcLeaderboard(t, n) {
|
|
2000
2031
|
if (!await this.token.autoLogin()) return null;
|
|
2001
|
-
const { data: r, code: a, message: o } = await this.req.get("event/ugc/leaderboard",
|
|
2032
|
+
const { data: r, code: a, message: o } = await this.req.get("event/ugc/leaderboard", Pr, {
|
|
2002
2033
|
...n,
|
|
2003
2034
|
params: {
|
|
2004
2035
|
feature_id: t,
|
|
@@ -2010,13 +2041,32 @@ class fa {
|
|
|
2010
2041
|
error: a
|
|
2011
2042
|
};
|
|
2012
2043
|
}
|
|
2044
|
+
/**
|
|
2045
|
+
* 查询兑换玩法的物品剩余库存(含用户可兑换数量)
|
|
2046
|
+
*
|
|
2047
|
+
* https://www.kdocs.cn/l/ckWFDcOsYEUA?linkname=gOqT9svLF7
|
|
2048
|
+
*/
|
|
2049
|
+
async getRedeemItemStocks(t, n) {
|
|
2050
|
+
if (!await this.token.autoLogin()) return null;
|
|
2051
|
+
const { data: r, code: a, message: o } = await this.req.get("event/redeem/item-stocks", Er, {
|
|
2052
|
+
...n,
|
|
2053
|
+
params: {
|
|
2054
|
+
event_id: this.event,
|
|
2055
|
+
feature_id: t
|
|
2056
|
+
}
|
|
2057
|
+
});
|
|
2058
|
+
return r || {
|
|
2059
|
+
message: o,
|
|
2060
|
+
error: a
|
|
2061
|
+
};
|
|
2062
|
+
}
|
|
2013
2063
|
}
|
|
2014
|
-
const
|
|
2064
|
+
const $r = {
|
|
2015
2065
|
/** 所有人均可以发帖 */
|
|
2016
2066
|
All: "all",
|
|
2017
2067
|
/** 指定用户可发帖 */
|
|
2018
2068
|
Limit: "limit"
|
|
2019
|
-
},
|
|
2069
|
+
}, Fr = e.string().enum($r).lock(), Ir = {
|
|
2020
2070
|
/** 待审核(仅自己可见) */
|
|
2021
2071
|
Pending: "pending",
|
|
2022
2072
|
/** 审核通过 */
|
|
@@ -2025,14 +2075,14 @@ const xr = {
|
|
|
2025
2075
|
Failed: "failed",
|
|
2026
2076
|
/** 嫌疑(仅自己可见) */
|
|
2027
2077
|
Suspect: "suspect"
|
|
2028
|
-
}, ie = e.string().enum(
|
|
2078
|
+
}, ie = e.string().enum(Ir).lock(), Dr = {
|
|
2029
2079
|
/** 系统通知 */
|
|
2030
2080
|
System: "system",
|
|
2031
2081
|
/** 评论我的 */
|
|
2032
2082
|
Comment: "comment",
|
|
2033
2083
|
/** 点赞通知 */
|
|
2034
2084
|
Like: "like"
|
|
2035
|
-
},
|
|
2085
|
+
}, ja = e.string().enum(Dr).lock(), m = {
|
|
2036
2086
|
/** 系统通知 */
|
|
2037
2087
|
System: "system",
|
|
2038
2088
|
/** 帖子被置顶 */
|
|
@@ -2057,13 +2107,13 @@ const xr = {
|
|
|
2057
2107
|
ReplyLiked: "reply_liked",
|
|
2058
2108
|
/** 回复被删除 */
|
|
2059
2109
|
ReplyDeleted: "reply_deleted"
|
|
2060
|
-
},
|
|
2110
|
+
}, Ar = e.string().enum(m).lock(), se = e.object({
|
|
2061
2111
|
forum_id: e.number(),
|
|
2062
2112
|
icon_url: e.string(),
|
|
2063
2113
|
name: e.string(),
|
|
2064
2114
|
tags: e.array(e.string()),
|
|
2065
2115
|
sort: e.number(),
|
|
2066
|
-
mode:
|
|
2116
|
+
mode: Fr,
|
|
2067
2117
|
member_ids: e.array(e.number())
|
|
2068
2118
|
}).lock(), F = e.object({
|
|
2069
2119
|
topic_id: e.number(),
|
|
@@ -2094,13 +2144,13 @@ const xr = {
|
|
|
2094
2144
|
create_time: e.number()
|
|
2095
2145
|
}).lock(), ce = e.object({
|
|
2096
2146
|
err_msg: e.string().optional()
|
|
2097
|
-
}).optional().lock(),
|
|
2147
|
+
}).optional().lock(), Gr = e.object({
|
|
2098
2148
|
reply_id: e.number(),
|
|
2099
2149
|
reply_content: e.string().optional(),
|
|
2100
2150
|
replied_by: e.string(),
|
|
2101
2151
|
nickname: e.string(),
|
|
2102
2152
|
avatar_url: e.string()
|
|
2103
|
-
}).lock(),
|
|
2153
|
+
}).lock(), C = e.object({
|
|
2104
2154
|
reply_id: e.number(),
|
|
2105
2155
|
comment_id: e.number(),
|
|
2106
2156
|
comment_content: e.string().optional(),
|
|
@@ -2113,7 +2163,7 @@ const xr = {
|
|
|
2113
2163
|
content: e.string(),
|
|
2114
2164
|
like_num: e.number(),
|
|
2115
2165
|
liked: e.bool(),
|
|
2116
|
-
reply_to:
|
|
2166
|
+
reply_to: Gr,
|
|
2117
2167
|
create_time: e.number()
|
|
2118
2168
|
}).lock(), k = e.object({
|
|
2119
2169
|
comment_id: e.number(),
|
|
@@ -2134,20 +2184,20 @@ const xr = {
|
|
|
2134
2184
|
image_url: e.string(),
|
|
2135
2185
|
create_time: e.number(),
|
|
2136
2186
|
status: ie,
|
|
2137
|
-
replies: e.array(
|
|
2138
|
-
}).lock(),
|
|
2187
|
+
replies: e.array(C).optional()
|
|
2188
|
+
}).lock(), Or = e.object({
|
|
2139
2189
|
image_url: e.string(),
|
|
2140
2190
|
upload_url: e.string(),
|
|
2141
2191
|
existed: e.bool()
|
|
2142
|
-
}).lock(),
|
|
2192
|
+
}).lock(), y = e.object({
|
|
2143
2193
|
notification_id: e.string(),
|
|
2144
|
-
notification_type:
|
|
2194
|
+
notification_type: Ar,
|
|
2145
2195
|
is_read: e.bool(),
|
|
2146
2196
|
create_time: e.number(),
|
|
2147
2197
|
origin_user_id: e.string(),
|
|
2148
2198
|
origin_user_name: e.string(),
|
|
2149
2199
|
origin_user_avatar_url: e.string()
|
|
2150
|
-
}).lock(),
|
|
2200
|
+
}).lock(), Nr = e.object({
|
|
2151
2201
|
system_message_subject: e.string(),
|
|
2152
2202
|
system_message_content: e.string()
|
|
2153
2203
|
}).lock(), D = e.object({
|
|
@@ -2155,18 +2205,18 @@ const xr = {
|
|
|
2155
2205
|
post_subject: e.string(),
|
|
2156
2206
|
post_summary: e.string(),
|
|
2157
2207
|
post_image_url: e.string()
|
|
2158
|
-
}).lock(),
|
|
2208
|
+
}).lock(), V = e.object({
|
|
2159
2209
|
comment_id: e.number(),
|
|
2160
2210
|
comment_content: e.string()
|
|
2161
|
-
}).lock(),
|
|
2211
|
+
}).lock(), A = e.object({
|
|
2162
2212
|
reply_id: e.number(),
|
|
2163
2213
|
reply_content: e.string()
|
|
2164
|
-
}).lock(),
|
|
2165
|
-
...
|
|
2166
|
-
...
|
|
2214
|
+
}).lock(), Qr = e.object({
|
|
2215
|
+
...y.shape,
|
|
2216
|
+
...Nr.shape,
|
|
2167
2217
|
notification_type: e.string().enum(m.System)
|
|
2168
|
-
}),
|
|
2169
|
-
...
|
|
2218
|
+
}), Br = e.object({
|
|
2219
|
+
...y.shape,
|
|
2170
2220
|
...D.shape,
|
|
2171
2221
|
notification_type: e.string().enum(
|
|
2172
2222
|
m.PostPinned,
|
|
@@ -2174,68 +2224,68 @@ const xr = {
|
|
|
2174
2224
|
m.PostDeleted,
|
|
2175
2225
|
m.PostLiked
|
|
2176
2226
|
)
|
|
2177
|
-
}),
|
|
2178
|
-
...
|
|
2227
|
+
}), Mr = e.object({
|
|
2228
|
+
...y.shape,
|
|
2179
2229
|
...D.shape,
|
|
2180
|
-
...
|
|
2230
|
+
...V.shape,
|
|
2181
2231
|
notification_type: e.string().enum(m.PostCommented)
|
|
2182
|
-
}),
|
|
2183
|
-
...
|
|
2184
|
-
...
|
|
2185
|
-
...
|
|
2232
|
+
}), Kr = e.object({
|
|
2233
|
+
...y.shape,
|
|
2234
|
+
...V.shape,
|
|
2235
|
+
...A.shape,
|
|
2186
2236
|
notification_type: e.string().enum(m.CommentReplied)
|
|
2187
|
-
}),
|
|
2188
|
-
...
|
|
2189
|
-
...
|
|
2237
|
+
}), Hr = e.object({
|
|
2238
|
+
...y.shape,
|
|
2239
|
+
...V.shape,
|
|
2190
2240
|
...D.shape,
|
|
2191
2241
|
notification_type: e.string().enum(m.CommentLiked, m.CommentDeleted)
|
|
2192
|
-
}),
|
|
2193
|
-
...
|
|
2194
|
-
...
|
|
2242
|
+
}), zr = e.object({
|
|
2243
|
+
...y.shape,
|
|
2244
|
+
...A.shape,
|
|
2195
2245
|
notification_type: e.string().enum(m.ReplyReplied),
|
|
2196
2246
|
comment_id: e.number(),
|
|
2197
2247
|
reply_to_reply_id: e.number(),
|
|
2198
2248
|
reply_to_reply_content: e.string()
|
|
2199
|
-
}),
|
|
2200
|
-
...
|
|
2201
|
-
...
|
|
2202
|
-
...
|
|
2249
|
+
}), Jr = e.object({
|
|
2250
|
+
...y.shape,
|
|
2251
|
+
...A.shape,
|
|
2252
|
+
...V.shape,
|
|
2203
2253
|
notification_type: e.string().enum(m.ReplyLiked, m.ReplyDeleted)
|
|
2204
|
-
}),
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
).satisfies().lock(),
|
|
2254
|
+
}), Zr = e.union(
|
|
2255
|
+
Qr,
|
|
2256
|
+
Br,
|
|
2257
|
+
Mr,
|
|
2258
|
+
Kr,
|
|
2259
|
+
Hr,
|
|
2260
|
+
zr,
|
|
2261
|
+
Jr
|
|
2262
|
+
).satisfies().lock(), Xr = s({ forums: e.array(se) }), Yr = s({ topics: e.array(F) }), Wr = s({ topic: F }), ea = s({ post: I }), K = s({
|
|
2213
2263
|
posts: e.array(I),
|
|
2214
2264
|
next_token: e.string().optional()
|
|
2215
|
-
}),
|
|
2265
|
+
}), ta = s({
|
|
2216
2266
|
post: I.clone().optional(),
|
|
2217
2267
|
antispam: ce.clone().optional()
|
|
2218
|
-
}),
|
|
2219
|
-
replies: e.array(
|
|
2268
|
+
}), na = s({
|
|
2269
|
+
replies: e.array(C),
|
|
2220
2270
|
next_token: e.string().optional()
|
|
2221
|
-
}),
|
|
2222
|
-
reply:
|
|
2271
|
+
}), ra = s({ reply: C }), aa = s({
|
|
2272
|
+
reply: C.clone().optional(),
|
|
2223
2273
|
antispam: ce.clone().optional()
|
|
2224
|
-
}),
|
|
2274
|
+
}), oa = s({ comment: k }), ia = s({
|
|
2225
2275
|
comments: e.array(k),
|
|
2226
2276
|
next_token: e.string().optional()
|
|
2227
|
-
}),
|
|
2277
|
+
}), sa = s({
|
|
2228
2278
|
comment: k.clone().optional(),
|
|
2229
2279
|
antispam: k.clone().optional()
|
|
2230
|
-
}),
|
|
2231
|
-
notifications: e.array(
|
|
2280
|
+
}), ca = e.guard(Or), ua = s({
|
|
2281
|
+
notifications: e.array(Zr),
|
|
2232
2282
|
next_token: e.string().optional()
|
|
2233
|
-
}),
|
|
2283
|
+
}), la = s({
|
|
2234
2284
|
system: e.number(),
|
|
2235
2285
|
comment: e.number(),
|
|
2236
2286
|
like: e.number()
|
|
2237
2287
|
});
|
|
2238
|
-
class
|
|
2288
|
+
class Ta {
|
|
2239
2289
|
token;
|
|
2240
2290
|
req;
|
|
2241
2291
|
constructor(t) {
|
|
@@ -2247,7 +2297,7 @@ class ka {
|
|
|
2247
2297
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=QaqUa2K0z0
|
|
2248
2298
|
*/
|
|
2249
2299
|
async getForums(t) {
|
|
2250
|
-
const { data: n } = await this.req.get("community/forums",
|
|
2300
|
+
const { data: n } = await this.req.get("community/forums", Xr, t);
|
|
2251
2301
|
return n?.forums || [];
|
|
2252
2302
|
}
|
|
2253
2303
|
/**
|
|
@@ -2256,7 +2306,7 @@ class ka {
|
|
|
2256
2306
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=mIwpymAQom
|
|
2257
2307
|
*/
|
|
2258
2308
|
async getTopics(t) {
|
|
2259
|
-
const { data: n } = await this.req.get("community/topics",
|
|
2309
|
+
const { data: n } = await this.req.get("community/topics", Yr, t);
|
|
2260
2310
|
return n?.topics || [];
|
|
2261
2311
|
}
|
|
2262
2312
|
/**
|
|
@@ -2265,7 +2315,7 @@ class ka {
|
|
|
2265
2315
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=Jvw7xMK31K
|
|
2266
2316
|
*/
|
|
2267
2317
|
async getTopic(t, n) {
|
|
2268
|
-
const { data: r, code: a } = await this.req.get("community/topic",
|
|
2318
|
+
const { data: r, code: a } = await this.req.get("community/topic", Wr, {
|
|
2269
2319
|
...n,
|
|
2270
2320
|
params: { topic_id: t }
|
|
2271
2321
|
});
|
|
@@ -2307,7 +2357,7 @@ class ka {
|
|
|
2307
2357
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=hj1AZy5rcP
|
|
2308
2358
|
*/
|
|
2309
2359
|
async getPost(t, n) {
|
|
2310
|
-
const { data: r, code: a, message: o } = await this.req.get("community/post",
|
|
2360
|
+
const { data: r, code: a, message: o } = await this.req.get("community/post", ea, {
|
|
2311
2361
|
...n,
|
|
2312
2362
|
params: { post_id: t }
|
|
2313
2363
|
});
|
|
@@ -2325,7 +2375,7 @@ class ka {
|
|
|
2325
2375
|
const { data: r, code: a, message: o } = await this.req.post(
|
|
2326
2376
|
"community/post",
|
|
2327
2377
|
c(t),
|
|
2328
|
-
|
|
2378
|
+
ta,
|
|
2329
2379
|
n
|
|
2330
2380
|
);
|
|
2331
2381
|
return r ?? {
|
|
@@ -2339,7 +2389,7 @@ class ka {
|
|
|
2339
2389
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=djKbX7lFdp
|
|
2340
2390
|
*/
|
|
2341
2391
|
async getComments(t, n) {
|
|
2342
|
-
const { data: r, code: a, message: o } = await this.req.get("community/comments",
|
|
2392
|
+
const { data: r, code: a, message: o } = await this.req.get("community/comments", ia, {
|
|
2343
2393
|
...n,
|
|
2344
2394
|
params: c(t)
|
|
2345
2395
|
});
|
|
@@ -2354,7 +2404,7 @@ class ka {
|
|
|
2354
2404
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=RIc7oxVGae
|
|
2355
2405
|
*/
|
|
2356
2406
|
async getComment(t, n) {
|
|
2357
|
-
const { data: r, code: a, message: o } = await this.req.get("community/comment",
|
|
2407
|
+
const { data: r, code: a, message: o } = await this.req.get("community/comment", oa, {
|
|
2358
2408
|
...n,
|
|
2359
2409
|
params: { comment_id: t }
|
|
2360
2410
|
});
|
|
@@ -2373,7 +2423,7 @@ class ka {
|
|
|
2373
2423
|
const { data: r, code: a, message: o } = await this.req.post(
|
|
2374
2424
|
"community/comment",
|
|
2375
2425
|
c(t),
|
|
2376
|
-
|
|
2426
|
+
sa,
|
|
2377
2427
|
n
|
|
2378
2428
|
);
|
|
2379
2429
|
return r ?? {
|
|
@@ -2387,7 +2437,7 @@ class ka {
|
|
|
2387
2437
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=sVKBbY83MY
|
|
2388
2438
|
*/
|
|
2389
2439
|
async getReplies(t, n) {
|
|
2390
|
-
const { data: r } = await this.req.get("community/replies",
|
|
2440
|
+
const { data: r } = await this.req.get("community/replies", na, {
|
|
2391
2441
|
...n,
|
|
2392
2442
|
params: c({ max_results: 20, ...t })
|
|
2393
2443
|
});
|
|
@@ -2402,7 +2452,7 @@ class ka {
|
|
|
2402
2452
|
* https://kdocs.cn/l/cbggfJodHLIz?linkname=kxhcSXD3MG
|
|
2403
2453
|
*/
|
|
2404
2454
|
async getReply(t, n) {
|
|
2405
|
-
const { data: r, code: a, message: o } = await this.req.get("community/reply",
|
|
2455
|
+
const { data: r, code: a, message: o } = await this.req.get("community/reply", ra, {
|
|
2406
2456
|
...n,
|
|
2407
2457
|
params: { reply_id: t }
|
|
2408
2458
|
});
|
|
@@ -2421,7 +2471,7 @@ class ka {
|
|
|
2421
2471
|
const { data: r, code: a, message: o } = await this.req.post(
|
|
2422
2472
|
"community/reply",
|
|
2423
2473
|
c(t),
|
|
2424
|
-
|
|
2474
|
+
aa,
|
|
2425
2475
|
n
|
|
2426
2476
|
);
|
|
2427
2477
|
return r ?? {
|
|
@@ -2472,7 +2522,7 @@ class ka {
|
|
|
2472
2522
|
*/
|
|
2473
2523
|
async getMediaPresignedUrl(t, n) {
|
|
2474
2524
|
await this.token.autoLogin();
|
|
2475
|
-
const { data: r } = await this.req.get("community/media-presign-url",
|
|
2525
|
+
const { data: r } = await this.req.get("community/media-presign-url", ca, {
|
|
2476
2526
|
...n,
|
|
2477
2527
|
params: t
|
|
2478
2528
|
});
|
|
@@ -2487,7 +2537,7 @@ class ka {
|
|
|
2487
2537
|
*/
|
|
2488
2538
|
async getNotifications(t, n) {
|
|
2489
2539
|
await this.token.autoLogin();
|
|
2490
|
-
const { data: r } = await this.req.get("community/notifications",
|
|
2540
|
+
const { data: r } = await this.req.get("community/notifications", ua, {
|
|
2491
2541
|
...n,
|
|
2492
2542
|
params: c({ max_results: 20, ...t })
|
|
2493
2543
|
});
|
|
@@ -2505,7 +2555,7 @@ class ka {
|
|
|
2505
2555
|
if (!await this.token.autoLogin()) return null;
|
|
2506
2556
|
const { data: n } = await this.req.get(
|
|
2507
2557
|
"community/unread-notifications-count",
|
|
2508
|
-
|
|
2558
|
+
la,
|
|
2509
2559
|
t
|
|
2510
2560
|
);
|
|
2511
2561
|
return n;
|
|
@@ -2521,17 +2571,17 @@ class ka {
|
|
|
2521
2571
|
return r;
|
|
2522
2572
|
}
|
|
2523
2573
|
}
|
|
2524
|
-
const
|
|
2574
|
+
const ma = s({
|
|
2525
2575
|
nonce_str: e.string(),
|
|
2526
2576
|
timestamp: e.number(),
|
|
2527
2577
|
signature: e.string()
|
|
2528
2578
|
});
|
|
2529
|
-
var
|
|
2579
|
+
var da = /* @__PURE__ */ ((i) => (i.RedirectUriDisMatch = "10003", i.AppidError = "10016", i.AuthorizationError = "10015", i.NoRightForScope = "10005", i.Frequently = "10009", i.AppBanded = "10004", i.ShouldFollow = "10006", i.ScopeNull = "10010", i.RedirectUriNull = "10011", i.AppidNull = "10012", i.StateNull = "10013", i))(da || {});
|
|
2530
2580
|
function L(i) {
|
|
2531
2581
|
return h(i, "open_id", "union_id", "weixin_token");
|
|
2532
2582
|
}
|
|
2533
2583
|
const H = "wx_login_cache";
|
|
2534
|
-
class
|
|
2584
|
+
class qa {
|
|
2535
2585
|
token;
|
|
2536
2586
|
$appid;
|
|
2537
2587
|
req;
|
|
@@ -2621,7 +2671,7 @@ class va {
|
|
|
2621
2671
|
async webLogin(t = "snsapi_userinfo", n) {
|
|
2622
2672
|
const r = S("code"), a = Date.now(), o = +S("state");
|
|
2623
2673
|
if (!r || !o || o < a - 1e3 * 60 * 5 || o > a) {
|
|
2624
|
-
const me =
|
|
2674
|
+
const me = G(["code", "state"]);
|
|
2625
2675
|
location.replace(
|
|
2626
2676
|
`https://open.weixin.qq.com/connect/oauth2/authorize?appid=${this.appid}&redirect_uri=${encodeURIComponent(me)}&response_type=code&scope=${t}&state=${a}#wechat_redirect`
|
|
2627
2677
|
);
|
|
@@ -2632,7 +2682,7 @@ class va {
|
|
|
2632
2682
|
message: "Error: " + r,
|
|
2633
2683
|
error: r
|
|
2634
2684
|
};
|
|
2635
|
-
const g =
|
|
2685
|
+
const g = G(["code", "state"]);
|
|
2636
2686
|
"replaceState" in history && history.replaceState({}, "", g);
|
|
2637
2687
|
const {
|
|
2638
2688
|
data: p,
|
|
@@ -2671,7 +2721,7 @@ class va {
|
|
|
2671
2721
|
* https://kdocs.cn/l/cf2mO2uRLqh9?linkname=CuWOqxr9Ue
|
|
2672
2722
|
*/
|
|
2673
2723
|
async getJSSDKConfig(t) {
|
|
2674
|
-
const { data: n } = await this.req.get("weixin/offiaccount/jssdk-sign",
|
|
2724
|
+
const { data: n } = await this.req.get("weixin/offiaccount/jssdk-sign", ma, {
|
|
2675
2725
|
...t,
|
|
2676
2726
|
params: {
|
|
2677
2727
|
appid: this.appid,
|
|
@@ -2688,22 +2738,22 @@ class va {
|
|
|
2688
2738
|
}
|
|
2689
2739
|
export {
|
|
2690
2740
|
ce as AntispamValidator,
|
|
2691
|
-
|
|
2692
|
-
|
|
2741
|
+
ba as AuthToken,
|
|
2742
|
+
er as CandidateVoteValidator,
|
|
2693
2743
|
ae as CashbackEngagementDataValidator,
|
|
2694
|
-
|
|
2744
|
+
xn as ClaimActivationKeyEngagementDataValidator,
|
|
2695
2745
|
lt as ClaimRewardStatus,
|
|
2696
2746
|
P as ClaimRewardStatusValidator,
|
|
2697
|
-
|
|
2747
|
+
lr as ClaimedItemValidator,
|
|
2698
2748
|
Z as ClubAddressValidator,
|
|
2699
|
-
|
|
2749
|
+
ha as ClubApi,
|
|
2700
2750
|
X as ClubBenefitSummaryValidator,
|
|
2701
2751
|
Oe as ClubBenefitValidator,
|
|
2702
2752
|
qe as ClubCreditChangeScene,
|
|
2703
2753
|
xe as ClubCreditChangeSceneValidator,
|
|
2704
2754
|
je as ClubCreditChangeType,
|
|
2705
2755
|
Te as ClubCreditChangeTypeValidator,
|
|
2706
|
-
|
|
2756
|
+
Ge as ClubCreditLogValidator,
|
|
2707
2757
|
Pe as ClubGlobalConfigValidator,
|
|
2708
2758
|
Le as ClubItemType,
|
|
2709
2759
|
z as ClubItemTypeValidator,
|
|
@@ -2711,144 +2761,148 @@ export {
|
|
|
2711
2761
|
Y as ClubProductValidator,
|
|
2712
2762
|
Se as ClubRedemptionStatus,
|
|
2713
2763
|
Ue as ClubRedemptionStatusValidator,
|
|
2714
|
-
|
|
2764
|
+
Ae as ClubUserCreditValidator,
|
|
2715
2765
|
De as ClubUserProfileValidator,
|
|
2716
|
-
|
|
2766
|
+
rr as CommentEngagementValidator,
|
|
2717
2767
|
k as CommentValidator,
|
|
2718
|
-
|
|
2719
|
-
|
|
2768
|
+
Ta as CommunityApi,
|
|
2769
|
+
tr as ConversationValidator,
|
|
2720
2770
|
tt as EngageAccountType,
|
|
2721
2771
|
nt as EngageAccountTypeValidator,
|
|
2722
|
-
|
|
2723
|
-
|
|
2724
|
-
|
|
2725
|
-
|
|
2772
|
+
ur as EngageResponseValidator,
|
|
2773
|
+
or as EngageRewardValidator,
|
|
2774
|
+
Va as EventApi,
|
|
2775
|
+
qn as EventConfigValidator,
|
|
2726
2776
|
Tt as EventFeatureConfigOfCashbackValidator,
|
|
2727
2777
|
xt as EventFeatureConfigOfCheckInValidator,
|
|
2728
2778
|
St as EventFeatureConfigOfClaimActivationKeyValidator,
|
|
2729
2779
|
Pt as EventFeatureConfigOfClaimRewardsValidator,
|
|
2730
2780
|
$t as EventFeatureConfigOfCommentValidator,
|
|
2731
2781
|
It as EventFeatureConfigOfFollowValidator,
|
|
2732
|
-
|
|
2782
|
+
Gt as EventFeatureConfigOfGiftCodeValidator,
|
|
2733
2783
|
Nt as EventFeatureConfigOfInviteValidator,
|
|
2734
2784
|
Bt as EventFeatureConfigOfInvitedRegisterValidator,
|
|
2735
2785
|
Zt as EventFeatureConfigOfLotteryDrawValidator,
|
|
2736
2786
|
zt as EventFeatureConfigOfLotteryValidator,
|
|
2737
2787
|
Yt as EventFeatureConfigOfPreregisterValidator,
|
|
2738
2788
|
en as EventFeatureConfigOfQuestValidator,
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2789
|
+
rn as EventFeatureConfigOfRedeemValidator,
|
|
2790
|
+
on as EventFeatureConfigOfRegisterValidator,
|
|
2791
|
+
cn as EventFeatureConfigOfShareValidator,
|
|
2792
|
+
ln as EventFeatureConfigOfSubscribeValidator,
|
|
2793
|
+
dn as EventFeatureConfigOfSurveyValidator,
|
|
2794
|
+
pn as EventFeatureConfigOfTeamValidator,
|
|
2795
|
+
hn as EventFeatureConfigOfUgcLikeValidator,
|
|
2796
|
+
bn as EventFeatureConfigOfUgcValidator,
|
|
2797
|
+
Cn as EventFeatureConfigOfVote2Validator,
|
|
2798
|
+
kn as EventFeatureConfigOfVoteValidator,
|
|
2799
|
+
Tn as EventFeatureConfigValidator,
|
|
2749
2800
|
rt as EventPeriodType,
|
|
2750
2801
|
at as EventPeriodTypeValidator,
|
|
2751
|
-
|
|
2802
|
+
b as EventRewardItemConfigValidator,
|
|
2752
2803
|
Qe as ExtraGameRewardValidator,
|
|
2753
2804
|
Ne as ExtraPhysicalShipmentValidator,
|
|
2754
|
-
|
|
2805
|
+
nn as FeatureRedeemItemConfigValidator,
|
|
2806
|
+
Vt as FeatureRewardValidator,
|
|
2755
2807
|
u as FeatureType,
|
|
2756
2808
|
ot as FeatureTypeValidator,
|
|
2757
|
-
|
|
2758
|
-
|
|
2809
|
+
$r as ForumMode,
|
|
2810
|
+
Fr as ForumModeValidator,
|
|
2759
2811
|
se as ForumValidator,
|
|
2760
2812
|
v as GamerItemType,
|
|
2761
2813
|
W as GamerItemTypeValidator,
|
|
2762
|
-
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2814
|
+
Ce as Gender,
|
|
2815
|
+
Ve as GenderValidator,
|
|
2816
|
+
Ln as GiftCodeEngagementDataValidator,
|
|
2817
|
+
Sn as InviteEngagementDataValidator,
|
|
2766
2818
|
_t as LotteryDrawAction,
|
|
2767
|
-
|
|
2768
|
-
|
|
2769
|
-
|
|
2819
|
+
Ra as LotteryDrawActionValidator,
|
|
2820
|
+
$n as LotteryDrawEngagementDataValidator,
|
|
2821
|
+
Un as LotteryEngagementDataValidator,
|
|
2770
2822
|
w as LotteryTicketStatus,
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2823
|
+
ka as LotteryTicketStatusValidator,
|
|
2824
|
+
y as NotificationBaseValidator,
|
|
2825
|
+
Dr as NotificationCategory,
|
|
2826
|
+
ja as NotificationCategoryValidator,
|
|
2827
|
+
Kr as NotificationCommentReplyValidator,
|
|
2828
|
+
Hr as NotificationCommentValidator,
|
|
2829
|
+
V as NotificationPayloadCommentValidator,
|
|
2778
2830
|
D as NotificationPayloadPostValidator,
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2831
|
+
A as NotificationPayloadReplyValidator,
|
|
2832
|
+
Nr as NotificationPayloadSystemValidator,
|
|
2833
|
+
Mr as NotificationPostCommentValidator,
|
|
2834
|
+
Br as NotificationPostValidator,
|
|
2835
|
+
zr as NotificationReplyRepliedValidator,
|
|
2836
|
+
Jr as NotificationReplyValidator,
|
|
2837
|
+
Qr as NotificationSystemValidator,
|
|
2786
2838
|
m as NotificationType,
|
|
2787
|
-
|
|
2788
|
-
|
|
2839
|
+
Ar as NotificationTypeValidator,
|
|
2840
|
+
Zr as NotificationValidator,
|
|
2789
2841
|
Ie as PlayerRoleCardValidator,
|
|
2790
2842
|
J as PlayerRoleValidator,
|
|
2791
|
-
|
|
2843
|
+
Ir as PostStatus,
|
|
2792
2844
|
ie as PostStatusValidator,
|
|
2793
2845
|
I as PostValidator,
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2846
|
+
Fn as PreregisterEngagementDataValidator,
|
|
2847
|
+
Or as PresignedUrlResponseValidator,
|
|
2848
|
+
In as QuestEngagementDataValidator,
|
|
2797
2849
|
it as QuestObjective,
|
|
2798
2850
|
te as QuestObjectiveValidator,
|
|
2799
2851
|
bt as QuestProgressAlgorithm,
|
|
2800
2852
|
yt as QuestProgressAlgorithmValidator,
|
|
2801
|
-
|
|
2802
|
-
|
|
2853
|
+
Dn as QuestProgressValidator,
|
|
2854
|
+
An as RedeemEngagementDataValidator,
|
|
2855
|
+
ya as RedeemParamsValidator,
|
|
2856
|
+
Gn as RedeemStocksResponseValidator,
|
|
2803
2857
|
Be as RedemptionValidator,
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2858
|
+
Ct as RegularRewardValidator,
|
|
2859
|
+
Gr as ReplyToValidator,
|
|
2860
|
+
C as ReplyValidator,
|
|
2861
|
+
fa as RewardItemType,
|
|
2808
2862
|
ee as RewardItemTypeValidator,
|
|
2809
2863
|
mt as RewardSource,
|
|
2810
2864
|
E as RewardSourceValidator,
|
|
2811
2865
|
d as RewardStatus,
|
|
2812
2866
|
ut as RewardStatusSuffix,
|
|
2813
2867
|
ne as RewardStatusSuffixValidator,
|
|
2814
|
-
|
|
2815
|
-
|
|
2868
|
+
wa as RewardStatusValidator,
|
|
2869
|
+
ar as RewardValidator,
|
|
2816
2870
|
Fe as RoleBaseInfoValidator,
|
|
2817
2871
|
$e as ServerBaseInfoValidator,
|
|
2818
|
-
|
|
2819
|
-
|
|
2872
|
+
On as ShareEngagementDataValidator,
|
|
2873
|
+
Qn as SurveyEngagementDataValidator,
|
|
2820
2874
|
pt as TeamAction,
|
|
2821
|
-
|
|
2822
|
-
|
|
2823
|
-
|
|
2824
|
-
|
|
2875
|
+
va as TeamActionValidator,
|
|
2876
|
+
Mn as TeamEngagementDataValidator,
|
|
2877
|
+
Bn as TeamEngagementValidator,
|
|
2878
|
+
Ca as TeamMemberValidator,
|
|
2825
2879
|
dt as TeamVisibility,
|
|
2826
2880
|
gt as TeamVisibilityValidator,
|
|
2827
2881
|
F as TopicValidator,
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2882
|
+
zn as UgcCountResponseValidator,
|
|
2883
|
+
Kn as UgcEngagementDataValidator,
|
|
2884
|
+
Zn as UgcLeaderboardResponseValidator,
|
|
2885
|
+
Hn as UgcRecordResponseValidator,
|
|
2832
2886
|
kt as UgcReviewStatus,
|
|
2833
2887
|
vt as UgcReviewStatusValidator,
|
|
2834
2888
|
wt as UgcSocialMedia,
|
|
2835
2889
|
re as UgcSocialMediaValidator,
|
|
2836
|
-
|
|
2890
|
+
Jn as UgcUploadImageValidator,
|
|
2837
2891
|
$ as UserEngagementDataValidator,
|
|
2838
|
-
|
|
2839
|
-
|
|
2840
|
-
|
|
2841
|
-
|
|
2842
|
-
|
|
2843
|
-
|
|
2892
|
+
ir as UserEngagementValidator,
|
|
2893
|
+
cr as UserFeatureStatusValidator,
|
|
2894
|
+
R as UserRewardValidator,
|
|
2895
|
+
sr as VerifyMobileResultValidator,
|
|
2896
|
+
Wn as Vote2ClaimRewardsResponseValidator,
|
|
2897
|
+
Yn as Vote2EngagementDataValidator,
|
|
2844
2898
|
ht as Vote2RewardType,
|
|
2845
2899
|
ft as Vote2RewardTypeValidator,
|
|
2846
|
-
|
|
2900
|
+
Xn as VoteEngagementDataValidator,
|
|
2847
2901
|
st as VoteOptionSource,
|
|
2848
2902
|
ct as VoteOptionSourceValidator,
|
|
2849
|
-
|
|
2850
|
-
|
|
2851
|
-
|
|
2852
|
-
|
|
2853
|
-
|
|
2903
|
+
qa as WeixinApi,
|
|
2904
|
+
Nn as WeixinSubscribeEngagementDataValidator,
|
|
2905
|
+
da as WeixinWebLoginErrorCode,
|
|
2906
|
+
nr as ZeroChatGPTDataValidator,
|
|
2907
|
+
ma as isWeixinSignResponse
|
|
2854
2908
|
};
|