@seayoo-web/gamer-api 2.3.1 → 2.3.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.
Files changed (55) hide show
  1. package/package.json +11 -4
  2. package/types/index.d.ts +5 -0
  3. package/types/src/club.define.d.ts +371 -0
  4. package/types/src/club.enums.d.ts +104 -0
  5. package/types/src/club.guards.d.ts +33 -0
  6. package/types/src/community.define.d.ts +331 -0
  7. package/types/src/community.enums.d.ts +99 -0
  8. package/types/src/community.guards.d.ts +52 -0
  9. package/types/src/event.config/feature.base.d.ts +23 -0
  10. package/types/src/event.config/feature.cashback.d.ts +18 -0
  11. package/types/src/event.config/feature.checkIn.d.ts +7 -0
  12. package/types/src/event.config/feature.claimActivationKey.d.ts +7 -0
  13. package/types/src/event.config/feature.claimRewards.d.ts +7 -0
  14. package/types/src/event.config/feature.comment.d.ts +14 -0
  15. package/types/src/event.config/feature.d.ts +40 -0
  16. package/types/src/event.config/feature.follow.d.ts +24 -0
  17. package/types/src/event.config/feature.giftcode.d.ts +24 -0
  18. package/types/src/event.config/feature.invite.d.ts +12 -0
  19. package/types/src/event.config/feature.invitedRegister.d.ts +7 -0
  20. package/types/src/event.config/feature.lotteryDraw.d.ts +14 -0
  21. package/types/src/event.config/feature.preregister.d.ts +7 -0
  22. package/types/src/event.config/feature.quest.d.ts +31 -0
  23. package/types/src/event.config/feature.register.d.ts +7 -0
  24. package/types/src/event.config/feature.share.d.ts +16 -0
  25. package/types/src/event.config/feature.subscribe.d.ts +12 -0
  26. package/types/src/event.config/feature.survey.d.ts +14 -0
  27. package/types/src/event.config/feature.team.d.ts +14 -0
  28. package/types/src/event.config/feature.vote.d.ts +44 -0
  29. package/types/src/event.config/index.d.ts +23 -0
  30. package/types/src/event.define.d.ts +48 -0
  31. package/types/src/event.engage/engage.cashback.d.ts +9 -0
  32. package/types/src/event.engage/engage.claimActivationKey.d.ts +5 -0
  33. package/types/src/event.engage/engage.comment.d.ts +22 -0
  34. package/types/src/event.engage/engage.d.ts +49 -0
  35. package/types/src/event.engage/engage.giftcode.d.ts +5 -0
  36. package/types/src/event.engage/engage.invite.d.ts +9 -0
  37. package/types/src/event.engage/engage.lottery.d.ts +9 -0
  38. package/types/src/event.engage/engage.lotteryDraw.d.ts +40 -0
  39. package/types/src/event.engage/engage.lotteryDraw.reward.d.ts +38 -0
  40. package/types/src/event.engage/engage.preregister.d.ts +11 -0
  41. package/types/src/event.engage/engage.quest.d.ts +28 -0
  42. package/types/src/event.engage/engage.share.d.ts +9 -0
  43. package/types/src/event.engage/engage.subscribe.d.ts +14 -0
  44. package/types/src/event.engage/engage.survey.d.ts +7 -0
  45. package/types/src/event.engage/engage.team.d.ts +53 -0
  46. package/types/src/event.engage/engage.vote.d.ts +9 -0
  47. package/types/src/event.engage/reward.d.ts +52 -0
  48. package/types/src/event.enums.d.ts +392 -0
  49. package/types/src/event.guards.d.ts +38 -0
  50. package/types/src/token.d.ts +93 -0
  51. package/types/src/token.define.d.ts +31 -0
  52. package/types/src/token.guards.d.ts +5 -0
  53. package/types/src/utils.d.ts +12 -0
  54. package/types/src/weixin.define.d.ts +46 -0
  55. package/types/src/weixin.guards.d.ts +2 -0
@@ -0,0 +1,331 @@
1
+ import { NotificationType, ForumMode, PostStatus } from "./community.enums";
2
+ /** spell-checker:ignore antispam */
3
+ export interface Forum {
4
+ /** 版块 id */
5
+ forum_id: number;
6
+ /** 版块图标 */
7
+ icon_url: string;
8
+ /** 版块名称 */
9
+ name: string;
10
+ /** 版块标签 */
11
+ tags: string[];
12
+ /** 版块排序权重, 数值越大排序越靠前 */
13
+ sort: number;
14
+ /** 发帖模式 */
15
+ mode: ForumMode;
16
+ /** 指定可发帖的用户 id */
17
+ member_ids: number[];
18
+ }
19
+ export declare const ForumValidator: import("@seayoo-web/utils").ObjectValidator<Forum, false, false> & {
20
+ plain: never;
21
+ optional: never;
22
+ maybeNull: never;
23
+ lock: never;
24
+ };
25
+ export interface Topic {
26
+ /** 话题 ID */
27
+ topic_id: number;
28
+ /** 话题图标,可能是空字符串 */
29
+ cover_url: string;
30
+ /** 话题名称 */
31
+ name: string;
32
+ /** 话题描述 */
33
+ description: string;
34
+ /** 话题标签 */
35
+ tags: string[];
36
+ /** 话题下帖子数量 */
37
+ post_num: number;
38
+ }
39
+ export declare const TopicValidator: import("@seayoo-web/utils").ObjectValidator<Topic, false, false> & {
40
+ plain: never;
41
+ optional: never;
42
+ maybeNull: never;
43
+ lock: never;
44
+ };
45
+ export interface Post {
46
+ /** 帖子 ID */
47
+ post_id: number;
48
+ /** 版块信息 */
49
+ forum: Forum;
50
+ /** 帖子发布者的 ID */
51
+ posted_by: string;
52
+ /** 帖子发布者的昵称 */
53
+ nickname: string;
54
+ /** 帖子发布者的头像 */
55
+ avatar_url: string;
56
+ /** 帖子标题 */
57
+ title?: string;
58
+ /** 帖子内容,富文本 HTML 格式 */
59
+ content: string;
60
+ /** 帖子内容纯文本长度,不含 html 标签部分 */
61
+ content_text_count: number;
62
+ /** 帖子内容,纯文本格式 */
63
+ summary: string;
64
+ /** 点赞数量 */
65
+ like_num: number;
66
+ /** 评论数量 */
67
+ comments_num: number;
68
+ /** 当前用户是否点赞 */
69
+ liked: boolean;
70
+ /** 帖子图片地址 */
71
+ image_urls: string[];
72
+ /** 帖子关联话题 */
73
+ topics: Topic[];
74
+ /** 帖子关联活动 ids */
75
+ event_ids: number[];
76
+ /** 帖子是否置顶 */
77
+ is_pinned: boolean;
78
+ /** 帖子是否标精 */
79
+ is_highlighted: boolean;
80
+ /** 帖子状态 */
81
+ status: PostStatus;
82
+ /** 帖子发布时间 */
83
+ create_time: number;
84
+ }
85
+ export declare const PostValidator: import("@seayoo-web/utils").ObjectValidator<Post, false, false> & {
86
+ plain: never;
87
+ optional: never;
88
+ maybeNull: never;
89
+ lock: never;
90
+ };
91
+ export interface Antispam {
92
+ /** 安全检测返回异常提示 */
93
+ err_msg?: string;
94
+ }
95
+ export declare const AntispamValidator: import("@seayoo-web/utils").ObjectValidator<Antispam, false, false> & {
96
+ plain: never;
97
+ optional: never;
98
+ maybeNull: never;
99
+ lock: never;
100
+ };
101
+ export interface ReplyTo {
102
+ /** 回复 ID */
103
+ reply_id: number;
104
+ /** 回复内容 */
105
+ reply_content?: string;
106
+ /** 回复者的 ID */
107
+ replied_by: string;
108
+ /** 回复者的昵称 */
109
+ nickname: string;
110
+ /** 回复者的头像 */
111
+ avatar_url: string;
112
+ }
113
+ export declare const ReplyToValidator: import("@seayoo-web/utils").ObjectValidator<ReplyTo, false, false> & {
114
+ plain: never;
115
+ optional: never;
116
+ maybeNull: never;
117
+ lock: never;
118
+ };
119
+ export interface Reply {
120
+ /** 回复 ID */
121
+ reply_id: number;
122
+ /** 评论 ID */
123
+ comment_id: number;
124
+ /** 评论内容 */
125
+ comment_content?: string;
126
+ /** 评论发布者的 ID */
127
+ commented_by?: string;
128
+ /** 评论发布者的昵称 */
129
+ commented_by_nickname?: string;
130
+ /** 评论发布者的头像 */
131
+ commented_by_avatar_url?: string;
132
+ /** 回复者的 ID */
133
+ replied_by: string;
134
+ /** 回复者的昵称 */
135
+ nickname: string;
136
+ /** 回复者的头像 */
137
+ avatar_url: string;
138
+ /** 回复内容 */
139
+ content: string;
140
+ /** 点赞数量 */
141
+ like_num: number;
142
+ /** 当前用户是否点赞 */
143
+ liked: boolean;
144
+ /** 回复的目标 */
145
+ reply_to: ReplyTo;
146
+ /** 回复发布时间 */
147
+ create_time: number;
148
+ }
149
+ export declare const ReplyValidator: import("@seayoo-web/utils").ObjectValidator<Reply, false, false> & {
150
+ plain: never;
151
+ optional: never;
152
+ maybeNull: never;
153
+ lock: never;
154
+ };
155
+ export interface Comment {
156
+ /** 评论 ID */
157
+ comment_id: number;
158
+ /** 帖子 ID */
159
+ post_id: number;
160
+ /** 帖子标题 */
161
+ post_subject?: string;
162
+ /** 帖子概要 */
163
+ post_summary?: string;
164
+ /** 帖子的首张图片地址 */
165
+ post_image_url?: string;
166
+ /** 帖子发布者的 ID */
167
+ posted_by?: string;
168
+ /** 帖子发布者的昵称 */
169
+ posted_by_nickname?: string;
170
+ /** 帖子发布者的头像 */
171
+ posted_by_avatar_url?: string;
172
+ /** 评论发布者的 ID */
173
+ commented_by: string;
174
+ /** 评论发布者的昵称 */
175
+ nickname: string;
176
+ /** 评论发布者的头像 */
177
+ avatar_url: string;
178
+ /** 评论内容 */
179
+ content: string;
180
+ /** 点赞数量 */
181
+ like_num: number;
182
+ /** 回复数量 */
183
+ reply_num: number;
184
+ /** 当前用户是否点赞 */
185
+ liked: boolean;
186
+ /** 评论图片地址 */
187
+ image_url: string;
188
+ /** 评论发布时间 */
189
+ create_time: number;
190
+ /** 评论状态 */
191
+ status: PostStatus;
192
+ /** 评论下最新两条回复 */
193
+ replies?: Reply[];
194
+ }
195
+ export declare const CommentValidator: import("@seayoo-web/utils").ObjectValidator<Comment, false, false> & {
196
+ plain: never;
197
+ optional: never;
198
+ maybeNull: never;
199
+ lock: never;
200
+ };
201
+ export interface PresignedUrlResponse {
202
+ /** 资源文件的真实地址 */
203
+ image_url: string;
204
+ /** 媒体文件临时上传地址(有效期 5min) */
205
+ upload_url: string;
206
+ /** 媒体文件是否已存在,已存在无需上传 */
207
+ existed: boolean;
208
+ }
209
+ export declare const PresignedUrlResponseValidator: import("@seayoo-web/utils").ObjectValidator<PresignedUrlResponse, false, false> & {
210
+ plain: never;
211
+ optional: never;
212
+ maybeNull: never;
213
+ lock: never;
214
+ };
215
+ export interface NotificationBase {
216
+ /** 通知的 ID */
217
+ notification_id: string;
218
+ /** 通知类型 */
219
+ notification_type: NotificationType;
220
+ /** 通知是否已读 */
221
+ is_read: boolean;
222
+ /** 通知产生时间 */
223
+ create_time: number;
224
+ /** 触发通知的用户 ID,系统管理员 ID 为 "0" */
225
+ origin_user_id: string;
226
+ /** 触发通知的用户昵称,如果是系统管理员也会包含此字段,会使用系统配置中管理员的信息 */
227
+ origin_user_name: string;
228
+ /** 触发通知的用户头像 */
229
+ origin_user_avatar_url: string;
230
+ }
231
+ export declare const NotificationBaseValidator: import("@seayoo-web/utils").ObjectValidator<NotificationBase, false, false> & {
232
+ plain: never;
233
+ optional: never;
234
+ maybeNull: never;
235
+ lock: never;
236
+ };
237
+ export interface NotificationPayloadSystem {
238
+ /** 系统通知的标题 */
239
+ system_message_subject: string;
240
+ /** 系统通知的内容 */
241
+ system_message_content: string;
242
+ }
243
+ export declare const NotificationPayloadSystemValidator: import("@seayoo-web/utils").ObjectValidator<NotificationPayloadSystem, false, false> & {
244
+ plain: never;
245
+ optional: never;
246
+ maybeNull: never;
247
+ lock: never;
248
+ };
249
+ export interface NotificationPayloadPost {
250
+ /** 帖子 ID */
251
+ post_id: number;
252
+ /** 帖子标题 */
253
+ post_subject: string;
254
+ /** 帖子概要 */
255
+ post_summary: string;
256
+ /** 帖子的首张图片地址 */
257
+ post_image_url: string;
258
+ }
259
+ export declare const NotificationPayloadPostValidator: import("@seayoo-web/utils").ObjectValidator<NotificationPayloadPost, false, false> & {
260
+ plain: never;
261
+ optional: never;
262
+ maybeNull: never;
263
+ lock: never;
264
+ };
265
+ export interface NotificationPayloadComment {
266
+ /** 评论 ID */
267
+ comment_id: number;
268
+ /** 评论内容 */
269
+ comment_content: string;
270
+ }
271
+ export declare const NotificationPayloadCommentValidator: import("@seayoo-web/utils").ObjectValidator<NotificationPayloadComment, false, false> & {
272
+ plain: never;
273
+ optional: never;
274
+ maybeNull: never;
275
+ lock: never;
276
+ };
277
+ export interface NotificationPayloadReply {
278
+ /** 回复 ID */
279
+ reply_id: number;
280
+ /** 回复内容 */
281
+ reply_content: string;
282
+ }
283
+ export declare const NotificationPayloadReplyValidator: import("@seayoo-web/utils").ObjectValidator<NotificationPayloadReply, false, false> & {
284
+ plain: never;
285
+ optional: never;
286
+ maybeNull: never;
287
+ lock: never;
288
+ };
289
+ export interface NotificationSystem extends NotificationBase, NotificationPayloadSystem {
290
+ notification_type: typeof NotificationType.System;
291
+ }
292
+ export declare const NotificationSystemValidator: import("@seayoo-web/utils").ObjectValidator<NotificationSystem, false, false>;
293
+ export interface NotificationPost extends NotificationBase, NotificationPayloadPost {
294
+ notification_type: typeof NotificationType.PostPinned | typeof NotificationType.PostHighlighted | typeof NotificationType.PostDeleted | typeof NotificationType.PostLiked;
295
+ }
296
+ export declare const NotificationPostValidator: import("@seayoo-web/utils").ObjectValidator<NotificationPost, false, false>;
297
+ export interface NotificationPostComment extends NotificationBase, NotificationPayloadPost, NotificationPayloadComment {
298
+ notification_type: typeof NotificationType.PostCommented;
299
+ }
300
+ export declare const NotificationPostCommentValidator: import("@seayoo-web/utils").ObjectValidator<NotificationPostComment, false, false>;
301
+ export interface NotificationCommentReply extends NotificationBase, NotificationPayloadComment, NotificationPayloadReply {
302
+ notification_type: typeof NotificationType.CommentReplied;
303
+ }
304
+ export declare const NotificationCommentReplyValidator: import("@seayoo-web/utils").ObjectValidator<NotificationCommentReply, false, false>;
305
+ export interface NotificationComment extends NotificationBase, NotificationPayloadComment, NotificationPayloadPost {
306
+ notification_type: typeof NotificationType.CommentLiked | typeof NotificationType.CommentDeleted;
307
+ }
308
+ export declare const NotificationCommentValidator: import("@seayoo-web/utils").ObjectValidator<NotificationComment, false, false>;
309
+ export interface NotificationReplyReplied extends NotificationBase, NotificationPayloadReply {
310
+ notification_type: typeof NotificationType.ReplyReplied;
311
+ /** 评论 ID */
312
+ comment_id: number;
313
+ /** 回复的回复 ID */
314
+ reply_to_reply_id: number;
315
+ /** 回复的回复内容 */
316
+ reply_to_reply_content: string;
317
+ }
318
+ export declare const NotificationReplyRepliedValidator: import("@seayoo-web/utils").ObjectValidator<NotificationReplyReplied, false, false>;
319
+ export interface NotificationReply extends NotificationBase, NotificationPayloadReply, NotificationPayloadComment {
320
+ notification_type: typeof NotificationType.ReplyLiked | typeof NotificationType.ReplyDeleted;
321
+ }
322
+ export declare const NotificationReplyValidator: import("@seayoo-web/utils").ObjectValidator<NotificationReply, false, false>;
323
+ /** 社区通知 */
324
+ export type Notification = NotificationSystem | NotificationPost | NotificationPostComment | NotificationCommentReply | NotificationComment | NotificationReplyReplied | NotificationReply;
325
+ export declare const NotificationValidator: import("@seayoo-web/utils").UnionValidator<[import("@seayoo-web/utils").ObjectValidator<NotificationSystem, false, false>, import("@seayoo-web/utils").ObjectValidator<NotificationPost, false, false>, import("@seayoo-web/utils").ObjectValidator<NotificationPostComment, false, false>, import("@seayoo-web/utils").ObjectValidator<NotificationCommentReply, false, false>, import("@seayoo-web/utils").ObjectValidator<NotificationComment, false, false>, import("@seayoo-web/utils").ObjectValidator<NotificationReplyReplied, false, false>, import("@seayoo-web/utils").ObjectValidator<NotificationReply, false, false>], false, false> & {
326
+ optional: never;
327
+ maybeNull: never;
328
+ key: never;
329
+ satisfies: never;
330
+ lock: never;
331
+ };
@@ -0,0 +1,99 @@
1
+ import { type ValueOf } from "@seayoo-web/utils";
2
+ /** 社区板块模式 */
3
+ export declare const ForumMode: {
4
+ /** 所有人均可以发帖 */
5
+ readonly All: "all";
6
+ /** 指定用户可发帖 */
7
+ readonly Limit: "limit";
8
+ };
9
+ export type ForumMode = ValueOf<typeof ForumMode>;
10
+ export declare const ForumModeValidator: import("@seayoo-web/utils").StringValidator<ForumMode, false, false> & {
11
+ pattern: never;
12
+ url: never;
13
+ dataUri: never;
14
+ enum: never;
15
+ disallow: never;
16
+ optional: never;
17
+ maybeNull: never;
18
+ lock: never;
19
+ };
20
+ /** 社区帖子状态 */
21
+ export declare const PostStatus: {
22
+ /** 待审核(仅自己可见) */
23
+ readonly Pending: "pending";
24
+ /** 审核通过 */
25
+ readonly Approved: "approved";
26
+ /** 审核不通过 */
27
+ readonly Failed: "failed";
28
+ /** 嫌疑(仅自己可见) */
29
+ readonly Suspect: "suspect";
30
+ };
31
+ export type PostStatus = ValueOf<typeof PostStatus>;
32
+ export declare const PostStatusValidator: import("@seayoo-web/utils").StringValidator<PostStatus, false, false> & {
33
+ pattern: never;
34
+ url: never;
35
+ dataUri: never;
36
+ enum: never;
37
+ disallow: never;
38
+ optional: never;
39
+ maybeNull: never;
40
+ lock: never;
41
+ };
42
+ /** 社区通知分类 */
43
+ export declare const NotificationCategory: {
44
+ /** 系统通知 */
45
+ readonly System: "system";
46
+ /** 评论我的 */
47
+ readonly Comment: "comment";
48
+ /** 点赞通知 */
49
+ readonly Like: "like";
50
+ };
51
+ export type NotificationCategory = ValueOf<typeof NotificationCategory>;
52
+ export declare const NotificationCategoryValidator: import("@seayoo-web/utils").StringValidator<NotificationCategory, false, false> & {
53
+ pattern: never;
54
+ url: never;
55
+ dataUri: never;
56
+ enum: never;
57
+ disallow: never;
58
+ optional: never;
59
+ maybeNull: never;
60
+ lock: never;
61
+ };
62
+ /** 社区通知类型 */
63
+ export declare const NotificationType: {
64
+ /** 系统通知 */
65
+ readonly System: "system";
66
+ /** 帖子被置顶 */
67
+ readonly PostPinned: "post_pinned";
68
+ /** 帖子被加精 */
69
+ readonly PostHighlighted: "post_highlighted";
70
+ /** 帖子被删除 */
71
+ readonly PostDeleted: "post_deleted";
72
+ /** 帖子被评论 */
73
+ readonly PostCommented: "post_commented";
74
+ /** 帖子被点赞 */
75
+ readonly PostLiked: "post_liked";
76
+ /** 评论被回复 */
77
+ readonly CommentReplied: "comment_replied";
78
+ /** 评论被点赞 */
79
+ readonly CommentLiked: "comment_liked";
80
+ /** 评论被删除 */
81
+ readonly CommentDeleted: "comment_deleted";
82
+ /** 回复被回复 */
83
+ readonly ReplyReplied: "reply_replied";
84
+ /** 回复被点赞 */
85
+ readonly ReplyLiked: "reply_liked";
86
+ /** 回复被删除 */
87
+ readonly ReplyDeleted: "reply_deleted";
88
+ };
89
+ export type NotificationType = ValueOf<typeof NotificationType>;
90
+ export declare const NotificationTypeValidator: import("@seayoo-web/utils").StringValidator<NotificationType, false, false> & {
91
+ pattern: never;
92
+ url: never;
93
+ dataUri: never;
94
+ enum: never;
95
+ disallow: never;
96
+ optional: never;
97
+ maybeNull: never;
98
+ lock: never;
99
+ };
@@ -0,0 +1,52 @@
1
+ export declare const isGetForumsResponse: (data: unknown) => data is {
2
+ forums: import("./community.define").Forum[];
3
+ };
4
+ export declare const isGetTopicsResponse: (data: unknown) => data is {
5
+ topics: import("./community.define").Topic[];
6
+ };
7
+ export declare const isGetTopicResponse: (data: unknown) => data is {
8
+ topic: import("./community.define").Topic;
9
+ };
10
+ export declare const isGetPostResponse: (data: unknown) => data is {
11
+ post: import("./community.define").Post;
12
+ };
13
+ export declare const isGetPostsResponse: (data: unknown) => data is {
14
+ posts: import("./community.define").Post[];
15
+ next_token: string | undefined;
16
+ };
17
+ export declare const isCreatePostResponse: (data: unknown) => data is {
18
+ post: import("./community.define").Post;
19
+ antispam: import("./community.define").Antispam;
20
+ };
21
+ export declare const isRelyListResponse: (data: unknown) => data is {
22
+ replies: import("./community.define").Reply[];
23
+ next_token: string | undefined;
24
+ };
25
+ export declare const isRelyResponse: (data: unknown) => data is {
26
+ reply: import("./community.define").Reply;
27
+ };
28
+ export declare const isCreateReplyResponse: (data: unknown) => data is {
29
+ reply: import("./community.define").Reply | undefined;
30
+ antispam: import("./community.define").Antispam | undefined;
31
+ };
32
+ export declare const isCommentResponse: (data: unknown) => data is {
33
+ comment: import("./community.define").Comment;
34
+ };
35
+ export declare const isCommentListResponse: (data: unknown) => data is {
36
+ comments: import("./community.define").Comment[];
37
+ next_token: string | undefined;
38
+ };
39
+ export declare const isCreateCommentResponse: (data: unknown) => data is {
40
+ comment: import("./community.define").Comment | undefined;
41
+ antispam: import("./community.define").Comment | undefined;
42
+ };
43
+ export declare const isGetPresignedUrlResponse: (data: unknown) => data is import("./community.define").PresignedUrlResponse;
44
+ export declare const isNotificationListWithToken: (data: unknown) => data is {
45
+ notifications: (import("./community.define").NotificationSystem | import("./community.define").NotificationPost | import("./community.define").NotificationPostComment | import("./community.define").NotificationCommentReply | import("./community.define").NotificationComment | import("./community.define").NotificationReplyReplied | import("./community.define").NotificationReply)[];
46
+ next_token: string | undefined;
47
+ };
48
+ export declare const isUnreadNotificationsCountResponse: (data: unknown) => data is {
49
+ system: number;
50
+ comment: number;
51
+ like: number;
52
+ };
@@ -0,0 +1,23 @@
1
+ import { type EngageAccountType, type EventPeriodType } from "../event.enums";
2
+ import { type FeatureReward } from "./reward";
3
+ export interface EventFeatureBaseConfig {
4
+ /** 玩法名称 */
5
+ feature_name: string;
6
+ /** 玩法 Id */
7
+ feature_id: number;
8
+ /** 玩法描述 */
9
+ description: string;
10
+ /** 玩法周期,即每多长时间可参与一次 */
11
+ cycle: EventPeriodType;
12
+ /** 允许的最大参与次数 */
13
+ limit: number;
14
+ /** 玩法开始时间 */
15
+ since: number;
16
+ /** 玩法结束时间 */
17
+ until: number;
18
+ /** 参与玩法维度账号类型 */
19
+ engage_account: EngageAccountType;
20
+ /** 玩法参与奖励 */
21
+ feature_rewards?: FeatureReward;
22
+ }
23
+ export declare const EventFeatureBaseConfigValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureBaseConfig, false, false>;
@@ -0,0 +1,18 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "cashback";
3
+ export interface FeatureCashbackConfig {
4
+ /** 计算充值总额的开始时间 */
5
+ order_start_time: number;
6
+ /** 计算充值总额的结束时间 */
7
+ order_end_time: number;
8
+ /** 可领取充值返还奖励的开始时间 */
9
+ claim_rewards_start_time: number;
10
+ /** 可领取充值返还奖励的结束时间 */
11
+ claim_rewards_end_time: number;
12
+ }
13
+ export type EventFeatureConfigOfCashback = EventFeatureBaseConfig & {
14
+ feature_type: typeof featureType;
15
+ config: FeatureCashbackConfig;
16
+ };
17
+ export declare const EventFeatureConfigOfCashbackValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfCashback, false, false>;
18
+ export {};
@@ -0,0 +1,7 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "check_in";
3
+ export type EventFeatureConfigOfCheckIn = EventFeatureBaseConfig & {
4
+ feature_type: typeof featureType;
5
+ };
6
+ export declare const EventFeatureConfigOfCheckInValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfCheckIn, false, false>;
7
+ export {};
@@ -0,0 +1,7 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "claim_activation_key";
3
+ export type EventFeatureConfigOfClaimActivationKey = EventFeatureBaseConfig & {
4
+ feature_type: typeof featureType;
5
+ };
6
+ export declare const EventFeatureConfigOfClaimActivationKeyValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfClaimActivationKey, false, false>;
7
+ export {};
@@ -0,0 +1,7 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "claim_rewards";
3
+ export type EventFeatureConfigOfClaimRewards = EventFeatureBaseConfig & {
4
+ feature_type: typeof featureType;
5
+ };
6
+ export declare const EventFeatureConfigOfClaimRewardsValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfClaimRewards, false, false>;
7
+ export {};
@@ -0,0 +1,14 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "comment";
3
+ export interface FeatureCommentConfig {
4
+ /** 活动配置的弹幕信息,用于快捷选择 */
5
+ comments: string[];
6
+ /** 发送频率限制,单位:秒 */
7
+ send_rate: number;
8
+ }
9
+ export type EventFeatureConfigOfComment = EventFeatureBaseConfig & {
10
+ feature_type: typeof featureType;
11
+ config: FeatureCommentConfig;
12
+ };
13
+ export declare const EventFeatureConfigOfCommentValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfComment, false, false>;
14
+ export {};
@@ -0,0 +1,40 @@
1
+ import { type EventFeatureConfigOfCashback } from "./feature.cashback";
2
+ import { type EventFeatureConfigOfCheckIn } from "./feature.checkIn";
3
+ import { type EventFeatureConfigOfClaimActivationKey } from "./feature.claimActivationKey";
4
+ import { type EventFeatureConfigOfClaimRewards } from "./feature.claimRewards";
5
+ import { type EventFeatureConfigOfComment } from "./feature.comment";
6
+ import { type EventFeatureConfigOfFollow } from "./feature.follow";
7
+ import { type EventFeatureConfigOfGiftCode } from "./feature.giftcode";
8
+ import { type EventFeatureConfigOfInvite } from "./feature.invite";
9
+ import { type EventFeatureConfigOfInvitedRegister } from "./feature.invitedRegister";
10
+ import { type EventFeatureConfigOfLottery } from "./feature.lottery";
11
+ import { type EventFeatureConfigOfLotteryDraw } from "./feature.lotteryDraw";
12
+ import { type EventFeatureConfigOfPreregister } from "./feature.preregister";
13
+ import { type EventFeatureConfigOfQuest } from "./feature.quest";
14
+ import { type EventFeatureConfigOfRegister } from "./feature.register";
15
+ import { type EventFeatureConfigOfShare } from "./feature.share";
16
+ import { type EventFeatureConfigOfSubscribe } from "./feature.subscribe";
17
+ import { type EventFeatureConfigOfSurvey } from "./feature.survey";
18
+ import { type EventFeatureConfigOfTeam } from "./feature.team";
19
+ import { type EventFeatureConfigOfVote } from "./feature.vote";
20
+ export * from "./feature.cashback";
21
+ export * from "./feature.checkIn";
22
+ export * from "./feature.claimRewards";
23
+ export * from "./feature.comment";
24
+ export * from "./feature.follow";
25
+ export * from "./feature.giftcode";
26
+ export * from "./feature.invite";
27
+ export * from "./feature.invitedRegister";
28
+ export * from "./feature.lottery";
29
+ export * from "./feature.lotteryDraw";
30
+ export * from "./feature.preregister";
31
+ export * from "./feature.quest";
32
+ export * from "./feature.register";
33
+ export * from "./feature.share";
34
+ export * from "./feature.subscribe";
35
+ export * from "./feature.survey";
36
+ export * from "./feature.team";
37
+ export * from "./feature.vote";
38
+ export * from "./feature.claimActivationKey";
39
+ export type EventFeatureConfig = EventFeatureConfigOfCashback | EventFeatureConfigOfCheckIn | EventFeatureConfigOfClaimRewards | EventFeatureConfigOfComment | EventFeatureConfigOfFollow | EventFeatureConfigOfGiftCode | EventFeatureConfigOfInvite | EventFeatureConfigOfInvitedRegister | EventFeatureConfigOfLottery | EventFeatureConfigOfLotteryDraw | EventFeatureConfigOfPreregister | EventFeatureConfigOfQuest | EventFeatureConfigOfRegister | EventFeatureConfigOfShare | EventFeatureConfigOfSubscribe | EventFeatureConfigOfSurvey | EventFeatureConfigOfTeam | EventFeatureConfigOfVote | EventFeatureConfigOfClaimActivationKey;
40
+ export declare const EventFeatureConfigValidator: import("@seayoo-web/utils").UnionValidator<[import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfCashback, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfCheckIn, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfClaimRewards, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfComment, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfFollow, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfGiftCode, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfInvite, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfInvitedRegister, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfLottery, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfLotteryDraw, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfPreregister, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfQuest, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfRegister, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfShare, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfSubscribe, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfSurvey, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfTeam, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfVote, false, false>, import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfClaimActivationKey, false, false>], false, false>;
@@ -0,0 +1,24 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "follow";
3
+ export interface FeatureFollowConfig {
4
+ /**
5
+ * 社交媒体平台的标识
6
+ *
7
+ * 比如 `bilibili`, `douyin`, `xiaohongshu`, `weibo`, `weixin_official_account`, `qq`
8
+ */
9
+ platform: string;
10
+ /** 社交媒体平台 icon */
11
+ platform_icon?: string;
12
+ /** 跳转链接 */
13
+ link?: string;
14
+ /** 二维码链接地址 */
15
+ qr_code_url?: string;
16
+ /** 社交媒体平台描述 */
17
+ platform_desc?: string;
18
+ }
19
+ export type EventFeatureConfigOfFollow = EventFeatureBaseConfig & {
20
+ feature_type: typeof featureType;
21
+ config: FeatureFollowConfig;
22
+ };
23
+ export declare const EventFeatureConfigOfFollowValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfFollow, false, false>;
24
+ export {};
@@ -0,0 +1,24 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "gift_code";
3
+ export interface EventGiftItemConfig {
4
+ /** 用于前端展示的游戏道具名称 */
5
+ name: string;
6
+ /** 用于前端展示的游戏道具图片地址 */
7
+ icon_url: string;
8
+ /** 用于前端展示的游戏道具数量 */
9
+ count: number;
10
+ }
11
+ export interface FeatureGiftCodeConfig {
12
+ /** 用于前端显示礼包码兑换后会获得的奖励内容 */
13
+ gift_items: EventGiftItemConfig[];
14
+ /** 社媒平台链接 */
15
+ mp_url?: string;
16
+ /** 社媒平台二维码 */
17
+ mp_qrcode_url?: string;
18
+ }
19
+ export type EventFeatureConfigOfGiftCode = EventFeatureBaseConfig & {
20
+ feature_type: typeof featureType;
21
+ config: FeatureGiftCodeConfig;
22
+ };
23
+ export declare const EventFeatureConfigOfGiftCodeValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfGiftCode, false, false>;
24
+ export {};
@@ -0,0 +1,12 @@
1
+ import { type EventFeatureBaseConfig } from "./feature.base";
2
+ declare const featureType: "invite";
3
+ export interface FeatureInviteConfig {
4
+ /** 邀请玩法配置分享链接 */
5
+ share_url: string;
6
+ }
7
+ export type EventFeatureConfigOfInvite = EventFeatureBaseConfig & {
8
+ feature_type: typeof featureType;
9
+ config: FeatureInviteConfig;
10
+ };
11
+ export declare const EventFeatureConfigOfInviteValidator: import("@seayoo-web/utils").ObjectValidator<EventFeatureConfigOfInvite, false, false>;
12
+ export {};