polyv-live-api-sdk 1.0.0
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/auth/index.d.ts +9 -0
- package/dist/auth/index.d.ts.map +1 -0
- package/dist/auth/signature.d.ts +67 -0
- package/dist/auth/signature.d.ts.map +1 -0
- package/dist/client.d.ts +209 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/constants/error-codes.d.ts +134 -0
- package/dist/constants/error-codes.d.ts.map +1 -0
- package/dist/constants/index.d.ts +8 -0
- package/dist/constants/index.d.ts.map +1 -0
- package/dist/errors/index.d.ts +11 -0
- package/dist/errors/index.d.ts.map +1 -0
- package/dist/errors/polyv-api-error.d.ts +71 -0
- package/dist/errors/polyv-api-error.d.ts.map +1 -0
- package/dist/errors/polyv-error.d.ts +31 -0
- package/dist/errors/polyv-error.d.ts.map +1 -0
- package/dist/errors/polyv-validation-error.d.ts +72 -0
- package/dist/errors/polyv-validation-error.d.ts.map +1 -0
- package/dist/errors/type-guards.d.ts +19 -0
- package/dist/errors/type-guards.d.ts.map +1 -0
- package/dist/errors/types.d.ts +13 -0
- package/dist/errors/types.d.ts.map +1 -0
- package/dist/index.cjs +15295 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +19501 -0
- package/dist/index.d.ts +18 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +15258 -0
- package/dist/index.js.map +1 -0
- package/dist/services/account.service.d.ts +402 -0
- package/dist/services/account.service.d.ts.map +1 -0
- package/dist/services/channel.service.d.ts +2033 -0
- package/dist/services/channel.service.d.ts.map +1 -0
- package/dist/services/chat.service.d.ts +592 -0
- package/dist/services/chat.service.d.ts.map +1 -0
- package/dist/services/finance.service.d.ts +160 -0
- package/dist/services/finance.service.d.ts.map +1 -0
- package/dist/services/group.service.d.ts +191 -0
- package/dist/services/group.service.d.ts.map +1 -0
- package/dist/services/index.d.ts +27 -0
- package/dist/services/index.d.ts.map +1 -0
- package/dist/services/live-interaction.service.d.ts +474 -0
- package/dist/services/live-interaction.service.d.ts.map +1 -0
- package/dist/services/other.service.d.ts +687 -0
- package/dist/services/other.service.d.ts.map +1 -0
- package/dist/services/platform.service.d.ts +190 -0
- package/dist/services/platform.service.d.ts.map +1 -0
- package/dist/services/player.service.d.ts +195 -0
- package/dist/services/player.service.d.ts.map +1 -0
- package/dist/services/v4/ai.service.d.ts +205 -0
- package/dist/services/v4/ai.service.d.ts.map +1 -0
- package/dist/services/v4/channel.service.d.ts +854 -0
- package/dist/services/v4/channel.service.d.ts.map +1 -0
- package/dist/services/v4/chat.service.d.ts +199 -0
- package/dist/services/v4/chat.service.d.ts.map +1 -0
- package/dist/services/v4/global.service.d.ts +86 -0
- package/dist/services/v4/global.service.d.ts.map +1 -0
- package/dist/services/v4/group.service.d.ts +132 -0
- package/dist/services/v4/group.service.d.ts.map +1 -0
- package/dist/services/v4/material.service.d.ts +85 -0
- package/dist/services/v4/material.service.d.ts.map +1 -0
- package/dist/services/v4/platform.service.d.ts +148 -0
- package/dist/services/v4/platform.service.d.ts.map +1 -0
- package/dist/services/v4/robot.service.d.ts +144 -0
- package/dist/services/v4/robot.service.d.ts.map +1 -0
- package/dist/services/v4/statistics.service.d.ts +61 -0
- package/dist/services/v4/statistics.service.d.ts.map +1 -0
- package/dist/services/v4/user.service.d.ts +1014 -0
- package/dist/services/v4/user.service.d.ts.map +1 -0
- package/dist/services/v4/webapp.service.d.ts +131 -0
- package/dist/services/v4/webapp.service.d.ts.map +1 -0
- package/dist/services/web.service.d.ts +758 -0
- package/dist/services/web.service.d.ts.map +1 -0
- package/dist/types/account.d.ts +287 -0
- package/dist/types/account.d.ts.map +1 -0
- package/dist/types/auth.d.ts +31 -0
- package/dist/types/auth.d.ts.map +1 -0
- package/dist/types/callback.d.ts +156 -0
- package/dist/types/callback.d.ts.map +1 -0
- package/dist/types/channel.d.ts +2263 -0
- package/dist/types/channel.d.ts.map +1 -0
- package/dist/types/chat-banned.d.ts +366 -0
- package/dist/types/chat-banned.d.ts.map +1 -0
- package/dist/types/chat-censor-role.d.ts +190 -0
- package/dist/types/chat-censor-role.d.ts.map +1 -0
- package/dist/types/chat.d.ts +142 -0
- package/dist/types/chat.d.ts.map +1 -0
- package/dist/types/client.d.ts +43 -0
- package/dist/types/client.d.ts.map +1 -0
- package/dist/types/common.d.ts +52 -0
- package/dist/types/common.d.ts.map +1 -0
- package/dist/types/finance.d.ts +252 -0
- package/dist/types/finance.d.ts.map +1 -0
- package/dist/types/group.d.ts +129 -0
- package/dist/types/group.d.ts.map +1 -0
- package/dist/types/index.d.ts +50 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/live-interaction.d.ts +301 -0
- package/dist/types/live-interaction.d.ts.map +1 -0
- package/dist/types/pagination.d.ts +37 -0
- package/dist/types/pagination.d.ts.map +1 -0
- package/dist/types/platform.d.ts +178 -0
- package/dist/types/platform.d.ts.map +1 -0
- package/dist/types/player.d.ts +177 -0
- package/dist/types/player.d.ts.map +1 -0
- package/dist/types/request.d.ts +45 -0
- package/dist/types/request.d.ts.map +1 -0
- package/dist/types/response.d.ts +58 -0
- package/dist/types/response.d.ts.map +1 -0
- package/dist/types/signature.d.ts +50 -0
- package/dist/types/signature.d.ts.map +1 -0
- package/dist/types/upload.d.ts +32 -0
- package/dist/types/upload.d.ts.map +1 -0
- package/dist/types/v4-ai.d.ts +379 -0
- package/dist/types/v4-ai.d.ts.map +1 -0
- package/dist/types/v4-channel.d.ts +2400 -0
- package/dist/types/v4-channel.d.ts.map +1 -0
- package/dist/types/v4-chat.d.ts +190 -0
- package/dist/types/v4-chat.d.ts.map +1 -0
- package/dist/types/v4-global.d.ts +150 -0
- package/dist/types/v4-global.d.ts.map +1 -0
- package/dist/types/v4-group.d.ts +212 -0
- package/dist/types/v4-group.d.ts.map +1 -0
- package/dist/types/v4-material.d.ts +141 -0
- package/dist/types/v4-material.d.ts.map +1 -0
- package/dist/types/v4-platform.d.ts +223 -0
- package/dist/types/v4-platform.d.ts.map +1 -0
- package/dist/types/v4-robot.d.ts +149 -0
- package/dist/types/v4-robot.d.ts.map +1 -0
- package/dist/types/v4-statistics.d.ts +87 -0
- package/dist/types/v4-statistics.d.ts.map +1 -0
- package/dist/types/v4-user.d.ts +1021 -0
- package/dist/types/v4-user.d.ts.map +1 -0
- package/dist/types/v4-webapp.d.ts +161 -0
- package/dist/types/v4-webapp.d.ts.map +1 -0
- package/dist/types/version.d.ts +21 -0
- package/dist/types/version.d.ts.map +1 -0
- package/dist/types/web.d.ts +868 -0
- package/dist/types/web.d.ts.map +1 -0
- package/dist/utils/env.d.ts +54 -0
- package/dist/utils/env.d.ts.map +1 -0
- package/dist/utils/index.d.ts +11 -0
- package/dist/utils/index.d.ts.map +1 -0
- package/dist/utils/pagination.d.ts +62 -0
- package/dist/utils/pagination.d.ts.map +1 -0
- package/dist/utils/signature.d.ts +67 -0
- package/dist/utils/signature.d.ts.map +1 -0
- package/package.json +76 -0
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* V4 Material Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for V4 Material APIs.
|
|
5
|
+
*
|
|
6
|
+
* @module types/v4-material
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Pagination parameters
|
|
10
|
+
*/
|
|
11
|
+
export interface MaterialPaginationParams {
|
|
12
|
+
/** Page number (>= 1) */
|
|
13
|
+
pageNumber: number;
|
|
14
|
+
/** Page size (1-1000) */
|
|
15
|
+
pageSize: number;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Paginated response
|
|
19
|
+
*/
|
|
20
|
+
export interface MaterialPaginatedResponse<T> {
|
|
21
|
+
/** Current page number */
|
|
22
|
+
pageNumber: number;
|
|
23
|
+
/** Page size */
|
|
24
|
+
pageSize: number;
|
|
25
|
+
/** Total pages */
|
|
26
|
+
totalPages: number;
|
|
27
|
+
/** Total items */
|
|
28
|
+
totalItems: number;
|
|
29
|
+
/** Content list */
|
|
30
|
+
contents: T[];
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Material extended data
|
|
34
|
+
*/
|
|
35
|
+
export interface MaterialExtData {
|
|
36
|
+
/** Screenshots */
|
|
37
|
+
screenshots?: string[];
|
|
38
|
+
/** Subtitles */
|
|
39
|
+
subtitles?: string[];
|
|
40
|
+
/** Other metadata */
|
|
41
|
+
[key: string]: unknown;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Material entity
|
|
45
|
+
*/
|
|
46
|
+
export interface Material {
|
|
47
|
+
/** Material ID */
|
|
48
|
+
id: string;
|
|
49
|
+
/** Access URL (with expiry) */
|
|
50
|
+
url?: string;
|
|
51
|
+
/** Material title */
|
|
52
|
+
title: string;
|
|
53
|
+
/** Material type (video/image/audio/document) */
|
|
54
|
+
type: string;
|
|
55
|
+
/** File size (bytes) */
|
|
56
|
+
fileSize?: number;
|
|
57
|
+
/** Duration in seconds (video only) */
|
|
58
|
+
duration?: number;
|
|
59
|
+
/** Source (upload/record/pptRecord/aiVideo/etc.) */
|
|
60
|
+
source?: string;
|
|
61
|
+
/** Extended data (screenshots, subtitles, etc.) */
|
|
62
|
+
extData?: MaterialExtData;
|
|
63
|
+
/** Category ID */
|
|
64
|
+
categoryId?: number;
|
|
65
|
+
/** Status (normal/recycle/auditing/etc.) */
|
|
66
|
+
status?: string;
|
|
67
|
+
/** Create timestamp (ms) */
|
|
68
|
+
createTime?: number;
|
|
69
|
+
/** Update timestamp (ms) */
|
|
70
|
+
updateTime?: number;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Parameters for listing materials
|
|
74
|
+
*/
|
|
75
|
+
export interface ListMaterialsParams extends MaterialPaginationParams {
|
|
76
|
+
/** Material type (required: video/image/audio/document) */
|
|
77
|
+
type: string;
|
|
78
|
+
/** Category ID filter */
|
|
79
|
+
categoryId?: number;
|
|
80
|
+
/** Title keyword filter */
|
|
81
|
+
title?: string;
|
|
82
|
+
/** Start create time filter (timestamp) */
|
|
83
|
+
startCreateTime?: number;
|
|
84
|
+
/** End create time filter (timestamp) */
|
|
85
|
+
endCreateTime?: number;
|
|
86
|
+
/** Expire second filter */
|
|
87
|
+
expireSecond?: number;
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* Response for listing materials
|
|
91
|
+
*/
|
|
92
|
+
export interface ListMaterialsResponse extends MaterialPaginatedResponse<Material> {
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* Parameters for deleting materials
|
|
96
|
+
*/
|
|
97
|
+
export interface DeleteMaterialsParams {
|
|
98
|
+
/** Material IDs to delete (required, 1-1000 items) */
|
|
99
|
+
materialIds: string[];
|
|
100
|
+
/** Delete completely (permanent delete) */
|
|
101
|
+
deleteCompletely?: string;
|
|
102
|
+
/** Allow partial delete if some fail */
|
|
103
|
+
allowPartialDelete?: string;
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Result for deleting materials
|
|
107
|
+
*/
|
|
108
|
+
export interface DeleteMaterialsResult {
|
|
109
|
+
/** Failed material IDs */
|
|
110
|
+
failedMaterialIds: string[];
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Material category entity
|
|
114
|
+
*/
|
|
115
|
+
export interface MaterialCategory {
|
|
116
|
+
/** Category ID */
|
|
117
|
+
id: number;
|
|
118
|
+
/** Category name */
|
|
119
|
+
title: string;
|
|
120
|
+
/** Category type (DEFAULT/CUSTOM/PLAYBACK/AI/DISK_VIDEO/etc.) */
|
|
121
|
+
type?: string;
|
|
122
|
+
/** Sub-category count */
|
|
123
|
+
subCount?: number;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Parameters for listing material categories
|
|
127
|
+
*/
|
|
128
|
+
export interface ListMaterialCategoriesParams {
|
|
129
|
+
/** Material type (required: video/image/audio/document) */
|
|
130
|
+
materialType: string;
|
|
131
|
+
/** Parent category ID (for sub-categories) */
|
|
132
|
+
parentId?: number;
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* Response for listing material categories
|
|
136
|
+
*/
|
|
137
|
+
export interface ListMaterialCategoriesResponse {
|
|
138
|
+
/** Category list */
|
|
139
|
+
contents: MaterialCategory[];
|
|
140
|
+
}
|
|
141
|
+
//# sourceMappingURL=v4-material.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"v4-material.d.ts","sourceRoot":"","sources":["../../src/types/v4-material.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,yBAAyB;IACzB,UAAU,EAAE,MAAM,CAAC;IACnB,yBAAyB;IACzB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,yBAAyB,CAAC,CAAC;IAC1C,0BAA0B;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,kBAAkB;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,kBAAkB;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,mBAAmB;IACnB,QAAQ,EAAE,CAAC,EAAE,CAAC;CACf;AAMD;;GAEG;AACH,MAAM,WAAW,eAAe;IAC9B,kBAAkB;IAClB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,gBAAgB;IAChB,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;IACrB,qBAAqB;IACrB,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CACxB;AAED;;GAEG;AACH,MAAM,WAAW,QAAQ;IACvB,kBAAkB;IAClB,EAAE,EAAE,MAAM,CAAC;IACX,+BAA+B;IAC/B,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,qBAAqB;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,iDAAiD;IACjD,IAAI,EAAE,MAAM,CAAC;IACb,wBAAwB;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;IA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ACd,iEAAiE;IACjE,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,yBAAyB;IACzB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,4BAA4B;IAC3C,2DAA2D;IAC3D,YAAY,EAAE,MAAM,CAAC;IACrB,8CAA8C;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC7C,oBAAoB;IACpB,QAAQ,EAAE,gBAAgB,EAAE,CAAC;CAC9B"}
|
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* V4 Platform Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for V4 Platform APIs (Coupon management).
|
|
5
|
+
*
|
|
6
|
+
* @module types/v4-platform
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Unconditional coupon rule
|
|
10
|
+
*
|
|
11
|
+
* Used when condition is UNCONDITIONAL - no minimum spend required
|
|
12
|
+
*/
|
|
13
|
+
export interface UnconditionalRule {
|
|
14
|
+
/** Whether this rule is enabled */
|
|
15
|
+
enable: boolean;
|
|
16
|
+
/** Discount value amount */
|
|
17
|
+
value: number;
|
|
18
|
+
/** Value unit - MONEY (yuan) or DISCOUNT (percent) */
|
|
19
|
+
unit: 'MONEY' | 'DISCOUNT';
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Full reduction coupon rule
|
|
23
|
+
*
|
|
24
|
+
* Used when condition is FULL_REDUCE - discount applied when spending meets threshold
|
|
25
|
+
*/
|
|
26
|
+
export interface FullReduceRule {
|
|
27
|
+
/** Whether this rule is enabled */
|
|
28
|
+
enable: boolean;
|
|
29
|
+
/** Minimum spend threshold to qualify for discount */
|
|
30
|
+
full: number;
|
|
31
|
+
/** Discount amount to reduce */
|
|
32
|
+
reduce: number;
|
|
33
|
+
/** Value unit - MONEY (yuan) or DISCOUNT (percent) */
|
|
34
|
+
unit: 'MONEY' | 'DISCOUNT';
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Coupon rule configuration
|
|
38
|
+
*
|
|
39
|
+
* Defines the discount condition and value for a coupon
|
|
40
|
+
*/
|
|
41
|
+
export interface CouponRule {
|
|
42
|
+
/** Coupon condition type - UNCONDITIONAL (no minimum) or FULL_REDUCE (minimum spend required) */
|
|
43
|
+
condition: 'UNCONDITIONAL' | 'FULL_REDUCE';
|
|
44
|
+
/** Unconditional rule (required when condition=UNCONDITIONAL) */
|
|
45
|
+
unconditional?: UnconditionalRule;
|
|
46
|
+
/** Full reduce rule (required when condition=FULL_REDUCE) */
|
|
47
|
+
fullReduce?: FullReduceRule;
|
|
48
|
+
/** Maximum claims per person (-1 for unlimited) */
|
|
49
|
+
limitPerPerson: number;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Coupon entity
|
|
53
|
+
*
|
|
54
|
+
* Represents a coupon in the system
|
|
55
|
+
*/
|
|
56
|
+
export interface Coupon {
|
|
57
|
+
/** Coupon ID */
|
|
58
|
+
couponId: string;
|
|
59
|
+
/** Coupon name (max 50 characters) */
|
|
60
|
+
name: string;
|
|
61
|
+
/** Receive start time (13-bit millisecond timestamp) */
|
|
62
|
+
receiveStartTime: number;
|
|
63
|
+
/** Receive end time (13-bit millisecond timestamp) */
|
|
64
|
+
receiveEndTime: number;
|
|
65
|
+
/** Use time type - RANGE (specific time range) or DAY (days after receive) */
|
|
66
|
+
useTimeType: 'RANGE' | 'DAY';
|
|
67
|
+
/** Use start time (13-bit timestamp, when useTimeType=RANGE) */
|
|
68
|
+
useStartTime?: number;
|
|
69
|
+
/** Use end time (13-bit timestamp, when useTimeType=RANGE) */
|
|
70
|
+
useEndTime?: number;
|
|
71
|
+
/** Days available after receive (when useTimeType=DAY) */
|
|
72
|
+
dayOfUse?: number;
|
|
73
|
+
/** Issue quantity available */
|
|
74
|
+
availableAmount: number;
|
|
75
|
+
/** Quantity already received */
|
|
76
|
+
receivedAmount: number;
|
|
77
|
+
/** Coupon rule configuration */
|
|
78
|
+
rule: CouponRule;
|
|
79
|
+
/** Coupon status - NOT_START, GOING, FINISHED, INVALID */
|
|
80
|
+
status: 'NOT_START' | 'GOING' | 'FINISHED' | 'INVALID';
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Parameters for creating a coupon
|
|
84
|
+
*/
|
|
85
|
+
export interface CreateCouponParams {
|
|
86
|
+
/** Coupon name (max 50 characters) */
|
|
87
|
+
name: string;
|
|
88
|
+
/** Receive start time (13-bit millisecond timestamp) */
|
|
89
|
+
receiveStartTime: number;
|
|
90
|
+
/** Receive end time (13-bit millisecond timestamp) */
|
|
91
|
+
receiveEndTime: number;
|
|
92
|
+
/** Use time type - RANGE (time range) or DAY (days) */
|
|
93
|
+
useTimeType: 'RANGE' | 'DAY';
|
|
94
|
+
/** Use start time (13-bit timestamp, required when useTimeType=RANGE) */
|
|
95
|
+
useStartTime?: number;
|
|
96
|
+
/** Use end time (13-bit timestamp, required when useTimeType=RANGE) */
|
|
97
|
+
useEndTime?: number;
|
|
98
|
+
/** Days available (required when useTimeType=DAY) */
|
|
99
|
+
dayOfUse?: number;
|
|
100
|
+
/** Coupon type - MAX_OUT (fixed discount) or DISCOUNT (percentage) */
|
|
101
|
+
type: 'MAX_OUT' | 'DISCOUNT';
|
|
102
|
+
/** Issue quantity (>= 0) */
|
|
103
|
+
availableAmount: number;
|
|
104
|
+
/** Coupon rule configuration */
|
|
105
|
+
rule: CouponRule;
|
|
106
|
+
}
|
|
107
|
+
/**
|
|
108
|
+
* Parameters for updating a coupon
|
|
109
|
+
*
|
|
110
|
+
* Note: Cannot update coupons with status FINISHED or INVALID
|
|
111
|
+
*/
|
|
112
|
+
export interface UpdateCouponParams {
|
|
113
|
+
/** Coupon ID to update */
|
|
114
|
+
couponId: string;
|
|
115
|
+
/** Coupon name (max 50 characters) */
|
|
116
|
+
name?: string;
|
|
117
|
+
/** Receive start time (13-bit millisecond timestamp) */
|
|
118
|
+
receiveStartTime?: number;
|
|
119
|
+
/** Receive end time (13-bit millisecond timestamp) */
|
|
120
|
+
receiveEndTime?: number;
|
|
121
|
+
/** Use time type - RANGE (time range) or DAY (days) */
|
|
122
|
+
useTimeType?: 'RANGE' | 'DAY';
|
|
123
|
+
/** Use start time (13-bit timestamp, when useTimeType=RANGE) */
|
|
124
|
+
useStartTime?: number;
|
|
125
|
+
/** Use end time (13-bit timestamp, when useTimeType=RANGE) */
|
|
126
|
+
useEndTime?: number;
|
|
127
|
+
/** Days available (when useTimeType=DAY) */
|
|
128
|
+
dayOfUse?: number;
|
|
129
|
+
/** Coupon type - MAX_OUT (fixed discount) or DISCOUNT (percentage) */
|
|
130
|
+
type?: 'MAX_OUT' | 'DISCOUNT';
|
|
131
|
+
/** Issue quantity (>= 0) */
|
|
132
|
+
availableAmount?: number;
|
|
133
|
+
/** Coupon rule configuration */
|
|
134
|
+
rule?: CouponRule;
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Parameters for searching coupons
|
|
138
|
+
*/
|
|
139
|
+
export interface SearchCouponsParams {
|
|
140
|
+
/** Page number (default 1, >= 1) */
|
|
141
|
+
pageNumber?: number;
|
|
142
|
+
/** Page size (default 10, 1-1000) */
|
|
143
|
+
pageSize?: number;
|
|
144
|
+
/** Filter by coupon ID */
|
|
145
|
+
couponId?: string;
|
|
146
|
+
/** Filter by coupon name (fuzzy match) */
|
|
147
|
+
name?: string;
|
|
148
|
+
/** Filter by status - NOT_START, GOING, FINISHED, INVALID */
|
|
149
|
+
status?: 'NOT_START' | 'GOING' | 'FINISHED' | 'INVALID';
|
|
150
|
+
}
|
|
151
|
+
/**
|
|
152
|
+
* Paginated response for coupon search
|
|
153
|
+
*/
|
|
154
|
+
export interface SearchCouponsResponse {
|
|
155
|
+
/** List of coupons */
|
|
156
|
+
contents: Coupon[];
|
|
157
|
+
/** Total number of items */
|
|
158
|
+
total: number;
|
|
159
|
+
/** Current page number */
|
|
160
|
+
pageNumber: number;
|
|
161
|
+
/** Page size */
|
|
162
|
+
pageSize: number;
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* Coupon viewer (recipient) information
|
|
166
|
+
*/
|
|
167
|
+
export interface CouponViewer {
|
|
168
|
+
/** Viewer ID */
|
|
169
|
+
viewerId: string;
|
|
170
|
+
/** Viewer nickname */
|
|
171
|
+
nickname: string;
|
|
172
|
+
/** Phone number */
|
|
173
|
+
mobile?: string;
|
|
174
|
+
/** Avatar URL */
|
|
175
|
+
avatar?: string;
|
|
176
|
+
/** Receive source - CHANNEL or AGGREGATE_PAGE */
|
|
177
|
+
receiveSource: 'CHANNEL' | 'AGGREGATE_PAGE';
|
|
178
|
+
/** Receive time (13-bit millisecond timestamp) */
|
|
179
|
+
receiveTime: number;
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* Parameters for searching coupon viewers
|
|
183
|
+
*/
|
|
184
|
+
export interface SearchCouponViewersParams {
|
|
185
|
+
/** Coupon ID (required) */
|
|
186
|
+
couponId: string;
|
|
187
|
+
/** Page number (default 1, >= 1) */
|
|
188
|
+
pageNumber?: number;
|
|
189
|
+
/** Page size (default 10, 1-1000) */
|
|
190
|
+
pageSize?: number;
|
|
191
|
+
/** Search keyword (viewer nickname or phone) */
|
|
192
|
+
keyword?: string;
|
|
193
|
+
/** Filter by receive source - CHANNEL or AGGREGATE_PAGE */
|
|
194
|
+
receiveSource?: 'CHANNEL' | 'AGGREGATE_PAGE';
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* Paginated response for coupon viewer search
|
|
198
|
+
*/
|
|
199
|
+
export interface SearchCouponViewersResponse {
|
|
200
|
+
/** List of coupon viewers */
|
|
201
|
+
contents: CouponViewer[];
|
|
202
|
+
/** Total number of items */
|
|
203
|
+
total: number;
|
|
204
|
+
/** Current page number */
|
|
205
|
+
pageNumber: number;
|
|
206
|
+
/** Page size */
|
|
207
|
+
pageSize: number;
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* Parameters for batch deleting coupons
|
|
211
|
+
*/
|
|
212
|
+
export interface DeleteCouponsBatchParams {
|
|
213
|
+
/** Array of coupon IDs to delete (max 200) */
|
|
214
|
+
couponIds: string[];
|
|
215
|
+
}
|
|
216
|
+
/**
|
|
217
|
+
* Parameters for batch updating coupon status
|
|
218
|
+
*/
|
|
219
|
+
export interface UpdateCouponsStatusBatchParams {
|
|
220
|
+
/** Array of coupon IDs to update status (max 200) */
|
|
221
|
+
couponIds: string[];
|
|
222
|
+
}
|
|
223
|
+
//# sourceMappingURL=v4-platform.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"v4-platform.d.ts","sourceRoot":"","sources":["../../src/types/v4-platform.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH;;;;GAIG;AACH,MAAM,WAAW,iBAAiB;IAChC,mCAAmC;IACnC,MAAM,EAAE,OAAO,CAAC;IAChB,4BAA4B;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,sDAAsD;IACtD,IAAI,EAAE,OAAO,GAAG,UAAU,CAAC;CAC5B;AAED;;;;GAIG;AACH,MAAM,WAAW,cAAc;IAC7B,mCAAmC;IACnC,MAAM,EAAE,OAAO,CAAC;IAChB,sDAAsD;IACtD,IAAI,EAAE,MAAM,CAAC;IACb,gCAAgC;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,sDAAsD;IACtD,IAAI,EAAE,OAAO,GAAG,UAAU,CAAC;CAC5B;AAED;;;;GAIG;AACH,MAAM,WAAW,UAAU;IACzB,iGAAiG;IACjG,SAAS,EAAE,eAAe,GAAG,aAAa,CAAC;IAC3C,iEAAiE;IACjE,aAAa,CAAC,EAAE,iBAAiB,CAAC;IAClC,6DAA6D;IAC7D,UAAU,CAAC,EAAE,cAAc,CAAC;IAC5B,mDAAmD;IACnD,cAAc,EAAE,MAAM,CAAC;CACxB;AAMD;;;;GAIG;AACH,MAAM,WAAW,MAAM;IACrB,gBAAgB;IAChB,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B,mBAAmB;IACnB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,iBAAiB;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,iDAAiD;IACjD,aAAa,EAAE,SAAS,GAAG,gBAAgB,CAAC;IAC5C,kDAAkD;IAClD,WAAW,EAAE,MAAM,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC,2BAA2B;IAC3B,QAAQ,EAAE,MAAM,CAAC;IACjB,oCAAoC;IACpC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,qCAAqC;IACrC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gDAAgD;IAChD,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,2DAA2D;IAC3D,aAAa,CAAC,EAAE,SAAS,GAAG,gBAAgB,CAAC;CAC9C;AAED;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,6BAA6B;IAC7B,QAAQ,EAAE,YAAY,EAAE,CAAC;IACzB,4BAA4B;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,0BAA0B;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB;IAChB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,8CAA8C;IAC9C,SAAS,EAAE,MAAM,EAAE,CAAC;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC7C,qDAAqD;IACrD,SAAS,EAAE,MAAM,EAAE,CAAC;CACrB"}
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* V4 Robot Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for V4 Robot APIs.
|
|
5
|
+
*
|
|
6
|
+
* @module types/v4-robot
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Robot entity
|
|
10
|
+
*/
|
|
11
|
+
export interface Robot {
|
|
12
|
+
/** Robot ID */
|
|
13
|
+
id: number;
|
|
14
|
+
/** Robot name (max 20 chars, no emoji) */
|
|
15
|
+
name: string;
|
|
16
|
+
/** Avatar URL */
|
|
17
|
+
avatar: string;
|
|
18
|
+
/** Last modified timestamp (milliseconds) */
|
|
19
|
+
lastModified: number;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Parameters for listing robots
|
|
23
|
+
*/
|
|
24
|
+
export interface ListRobotsParams {
|
|
25
|
+
/** Page number (optional, default 1) */
|
|
26
|
+
pageNumber?: number;
|
|
27
|
+
/** Page size (optional, default 10) */
|
|
28
|
+
pageSize?: number;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Response for listing robots
|
|
32
|
+
*/
|
|
33
|
+
export interface ListRobotsResponse {
|
|
34
|
+
/** Current page number */
|
|
35
|
+
pageNumber: number;
|
|
36
|
+
/** Page size */
|
|
37
|
+
pageSize: number;
|
|
38
|
+
/** Total pages */
|
|
39
|
+
totalPages: number;
|
|
40
|
+
/** Total items */
|
|
41
|
+
totalItems: number;
|
|
42
|
+
/** Robot list */
|
|
43
|
+
contents: Robot[];
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Item for batch saving robots
|
|
47
|
+
*/
|
|
48
|
+
export interface SaveRobotItem {
|
|
49
|
+
/** Robot name (max 20 chars, no emoji) */
|
|
50
|
+
name: string;
|
|
51
|
+
/** Avatar URL (optional) */
|
|
52
|
+
avatar?: string;
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Parameters for batch saving robots
|
|
56
|
+
*/
|
|
57
|
+
export interface BatchSaveRobotsParams {
|
|
58
|
+
/** Robot list (max 200) */
|
|
59
|
+
robots: SaveRobotItem[];
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Response for batch saving robots
|
|
63
|
+
*/
|
|
64
|
+
export interface BatchSaveRobotsResponse {
|
|
65
|
+
/** Whether successful */
|
|
66
|
+
success: boolean;
|
|
67
|
+
/** Number of saved robots */
|
|
68
|
+
savedCount: number;
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Parameters for batch deleting robots
|
|
72
|
+
*/
|
|
73
|
+
export interface BatchDeleteRobotsParams {
|
|
74
|
+
/** Robot IDs to delete (max 200) */
|
|
75
|
+
ids: number[];
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Add robot model type
|
|
79
|
+
*/
|
|
80
|
+
export type AddRobotModel = 'timely' | 'fixed_time';
|
|
81
|
+
/**
|
|
82
|
+
* Channel robot setting entity
|
|
83
|
+
*/
|
|
84
|
+
export interface RobotSetting {
|
|
85
|
+
/** Channel ID */
|
|
86
|
+
channelId: number;
|
|
87
|
+
/** Number of robots */
|
|
88
|
+
robotNumber: number;
|
|
89
|
+
/** Add robot model */
|
|
90
|
+
addRobotModel: AddRobotModel;
|
|
91
|
+
/** Virtual booking number */
|
|
92
|
+
virtualBookingNumber: number;
|
|
93
|
+
/** Change time in seconds (for fixed_time model) */
|
|
94
|
+
changeTime: number;
|
|
95
|
+
/** Left time in seconds */
|
|
96
|
+
leftTime: number;
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Parameters for getting channel robot settings
|
|
100
|
+
*/
|
|
101
|
+
export interface GetRobotSettingParams {
|
|
102
|
+
/** Channel ID */
|
|
103
|
+
channelId: string;
|
|
104
|
+
}
|
|
105
|
+
/**
|
|
106
|
+
* Parameters for updating channel robot settings
|
|
107
|
+
*/
|
|
108
|
+
export interface UpdateRobotSettingParams {
|
|
109
|
+
/** Channel ID */
|
|
110
|
+
channelId: string;
|
|
111
|
+
/** Number of robots */
|
|
112
|
+
robotNumber: number;
|
|
113
|
+
/** Add robot model */
|
|
114
|
+
addRobotModel: AddRobotModel;
|
|
115
|
+
/** Change time in seconds (required when addRobotModel='fixed_time', range: 20-18000) */
|
|
116
|
+
changeTime?: number;
|
|
117
|
+
/** Virtual booking number (optional) */
|
|
118
|
+
virtualBookingNumber?: number;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* Channel robot stats entity
|
|
122
|
+
*/
|
|
123
|
+
export interface RobotStats {
|
|
124
|
+
/** Real viewer count */
|
|
125
|
+
realViewerCount: number;
|
|
126
|
+
/** Robot count */
|
|
127
|
+
robotCount: number;
|
|
128
|
+
/** Display count */
|
|
129
|
+
displayCount: number;
|
|
130
|
+
/** Real subscribe count */
|
|
131
|
+
realSubscribeCount: number;
|
|
132
|
+
/** Page views */
|
|
133
|
+
pv: number;
|
|
134
|
+
}
|
|
135
|
+
/**
|
|
136
|
+
* Parameters for getting channel robot stats
|
|
137
|
+
*/
|
|
138
|
+
export interface GetRobotStatsParams {
|
|
139
|
+
/** Channel ID */
|
|
140
|
+
channelId: string;
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Parameters for pausing channel robots
|
|
144
|
+
*/
|
|
145
|
+
export interface PauseRobotParams {
|
|
146
|
+
/** Channel ID */
|
|
147
|
+
channelId: string;
|
|
148
|
+
}
|
|
149
|
+
//# sourceMappingURL=v4-robot.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"v4-robot.d.ts","sourceRoot":"","sources":["../../src/types/v4-robot.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH;;GAEG;AACH,MAAM,WAAW,KAAK;IACpB,eAAe;IACf,EAAE,EAAE,MAAM,CAAC;IACX,0CAA0C;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,iBAAiB;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,6CAA6C;IAC7C,YAAY,EAAE,MAAM,CAAC;CACtB;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,wCAAwC;IACxC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,uCAAuC;IACvC,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,0BAA0B;IAC1B,UAAU,EAAE,MAAM,CAAC;IACnB,gBAAgB;IAChB,QAAQ,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sBAAsB;IACtB,aAAa,EAAE,aAAa,CAAC;IAC7B,yFAAyF;IACzF,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,wCAAwC;IACxC,oBAAoB,CAAC,EAAE,MAAM,CAAC;CAC/B;AAED;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,wBAAwB;IACxB,eAAe,EAAE,MAAM,CAAC;IACxB,kBAAkB;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,oBAAoB;IACpB,YAAY,EAAE,MAAM,CAAC;IACrB,2BAA2B;IAC3B,kBAAkB,EAAE,MAAM,CAAC;IAC3B,iBAAiB;IACjB,EAAE,EAAE,MAAM,CAAC;CACZ;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,iBAAiB;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,iBAAiB;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* V4 Statistics Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for V4 Statistics APIs.
|
|
5
|
+
*
|
|
6
|
+
* @module types/v4-statistics
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Session statistics summary entity
|
|
10
|
+
*/
|
|
11
|
+
export interface SessionStatsSummary {
|
|
12
|
+
/** Record ID */
|
|
13
|
+
id: number;
|
|
14
|
+
/** Channel ID */
|
|
15
|
+
channelId: number;
|
|
16
|
+
/** Session ID */
|
|
17
|
+
sessionId: string;
|
|
18
|
+
/** Session name */
|
|
19
|
+
name: string;
|
|
20
|
+
/** Live start time (timestamp in milliseconds) */
|
|
21
|
+
startTime: string;
|
|
22
|
+
/** Live end time (timestamp in milliseconds) */
|
|
23
|
+
endTime: string;
|
|
24
|
+
/** Broadcast duration (seconds) */
|
|
25
|
+
startDuration: number;
|
|
26
|
+
/** Unique viewer count */
|
|
27
|
+
uniqueViewer: number;
|
|
28
|
+
/** View count */
|
|
29
|
+
videoView: number;
|
|
30
|
+
/** PC unique viewer count */
|
|
31
|
+
pcUniqueViewer: number;
|
|
32
|
+
/** Mobile unique viewer count */
|
|
33
|
+
mobileUniqueViewer: number;
|
|
34
|
+
/** Total watch duration (minutes) */
|
|
35
|
+
totalPlayDuration: number;
|
|
36
|
+
/** Average watch duration (minutes) */
|
|
37
|
+
averagePlayDuration: number;
|
|
38
|
+
/** Maximum concurrent viewers */
|
|
39
|
+
maxConcurrencyCount: number;
|
|
40
|
+
/** Playback duration (minutes) */
|
|
41
|
+
playDuration: number;
|
|
42
|
+
/** Playback count */
|
|
43
|
+
playCount: number;
|
|
44
|
+
/** Playback viewer count */
|
|
45
|
+
viewerCount: number;
|
|
46
|
+
/** Attendance type: 0=no data, 1=registration, 2=whitelist */
|
|
47
|
+
attendanceType: number;
|
|
48
|
+
/** Expected attendance (registered/whitelisted) */
|
|
49
|
+
attendanceExpected: number;
|
|
50
|
+
/** Actual attendance */
|
|
51
|
+
attendanceActual: number;
|
|
52
|
+
/** POLYV user ID */
|
|
53
|
+
userId: string;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* Parameters for getting session stats summary list
|
|
57
|
+
*/
|
|
58
|
+
export interface GetSessionStatsSummaryListParams {
|
|
59
|
+
/** Channel ID filter */
|
|
60
|
+
channelId?: string;
|
|
61
|
+
/** Session name or ID (fuzzy match) */
|
|
62
|
+
keyword?: string;
|
|
63
|
+
/** Start time (timestamp in milliseconds) */
|
|
64
|
+
startTime?: string;
|
|
65
|
+
/** End time (timestamp in milliseconds) */
|
|
66
|
+
endTime?: string;
|
|
67
|
+
/** Page number (default: 1, must be >= 1) */
|
|
68
|
+
pageNumber?: number;
|
|
69
|
+
/** Page size (default: 10, must be 1-1000) */
|
|
70
|
+
pageSize?: number;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Response for getting session stats summary list
|
|
74
|
+
*/
|
|
75
|
+
export interface GetSessionStatsSummaryListResponse {
|
|
76
|
+
/** Current page number */
|
|
77
|
+
pageNumber: number;
|
|
78
|
+
/** Page size */
|
|
79
|
+
pageSize: number;
|
|
80
|
+
/** Total pages */
|
|
81
|
+
totalPages: number;
|
|
82
|
+
/** Total items */
|
|
83
|
+
totalItems: number;
|
|
84
|
+
/** Session stats summary list */
|
|
85
|
+
contents: SessionStatsSummary[];
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=v4-statistics.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"v4-statistics.d.ts","sourceRoot":"","sources":["../../src/types/v4-statistics.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,gBAAgB;IAChB,EAAE,EAAE,MAAM,CAAC;IACX,iBAAiB;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,iBAAiB;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,kDAAkD;IAClD,SAAS,EAAE,MAAM,CAAC;IAClB,gDAAgD;IAChD,OAAO,EAAE,MAAM,CAAC;IAChB,mCAAmC;IACnC,aAAa,EAAE,MAAM,CAAC;IACtB,0BAA0B;IAC1B,YAAY,EAAE,MAAM,CAAC;IACrB,iBAAiB;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,6BAA6B;IAC7B,cAAc,EAAE,MAAM,CAAC;IACvB,iCAAiC;IACjC,kBAAkB,EAAE,MAAM,CAAC;IAC3B,qCAAqC;IACrC,iBAAiB,EAAE,MAAM,CAAC;IAC1B,uCAAuC;IACvC,mBAAmB,EAAE,MAAM,CAAC;IAC5B,iCAAiC;IACjC,mBAAmB,EAAE,MAAM,CAAC;IAC5B,kCAAkC;IAClC,YAAY,EAAE,MAAM,CAAC;IACrB,qBAAqB;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,4BAA4B;IAC5B,WAAW,EAAE,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