@djvlc/openapi-admin-client 1.6.10 → 1.6.12
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.d.mts +2640 -3207
- package/dist/index.d.ts +2640 -3207
- package/dist/index.js +2113 -2462
- package/dist/index.mjs +1942 -2241
- package/openapi/dist/admin-api.yaml +2240 -1997
- package/openapi/src/components/responses/_index.yaml +31 -6
- package/openapi/src/components/schemas/_index.yaml +489 -111
- package/openapi/src/openapi.yaml +19 -7
- package/openapi/src/paths/pages.yaml +346 -5
- package/package.json +2 -2
|
@@ -71,21 +71,8 @@ paths:
|
|
|
71
71
|
summary: 获取页面列表
|
|
72
72
|
description: 分页获取所有页面的基本信息
|
|
73
73
|
parameters:
|
|
74
|
-
-
|
|
75
|
-
|
|
76
|
-
schema: &ref_13
|
|
77
|
-
type: integer
|
|
78
|
-
minimum: 1
|
|
79
|
-
default: 1
|
|
80
|
-
description: 页码
|
|
81
|
-
- name: limit
|
|
82
|
-
in: query
|
|
83
|
-
schema: &ref_14
|
|
84
|
-
type: integer
|
|
85
|
-
minimum: 1
|
|
86
|
-
maximum: 100
|
|
87
|
-
default: 20
|
|
88
|
-
description: 每页数量
|
|
74
|
+
- $ref: '#/components/parameters/PageParam'
|
|
75
|
+
- $ref: '#/components/parameters/LimitParam'
|
|
89
76
|
- name: status
|
|
90
77
|
in: query
|
|
91
78
|
schema:
|
|
@@ -106,130 +93,11 @@ paths:
|
|
|
106
93
|
content:
|
|
107
94
|
application/json:
|
|
108
95
|
schema:
|
|
109
|
-
|
|
110
|
-
required: &ref_49
|
|
111
|
-
- data
|
|
112
|
-
- meta
|
|
113
|
-
properties: &ref_50
|
|
114
|
-
data:
|
|
115
|
-
type: array
|
|
116
|
-
items:
|
|
117
|
-
type: object
|
|
118
|
-
required: &ref_2
|
|
119
|
-
- id
|
|
120
|
-
- title
|
|
121
|
-
- status
|
|
122
|
-
- createdAt
|
|
123
|
-
- updatedAt
|
|
124
|
-
properties: &ref_3
|
|
125
|
-
id:
|
|
126
|
-
type: string
|
|
127
|
-
description: 页面 ID
|
|
128
|
-
title:
|
|
129
|
-
type: string
|
|
130
|
-
description: 页面标题
|
|
131
|
-
description:
|
|
132
|
-
type: string
|
|
133
|
-
description: 页面描述
|
|
134
|
-
status:
|
|
135
|
-
type: string
|
|
136
|
-
enum:
|
|
137
|
-
- draft
|
|
138
|
-
- published
|
|
139
|
-
- archived
|
|
140
|
-
description: 页面状态
|
|
141
|
-
tags:
|
|
142
|
-
type: array
|
|
143
|
-
items:
|
|
144
|
-
type: string
|
|
145
|
-
description: 标签
|
|
146
|
-
currentVersion:
|
|
147
|
-
type: string
|
|
148
|
-
description: 当前发布版本
|
|
149
|
-
createdAt:
|
|
150
|
-
type: string
|
|
151
|
-
format: date-time
|
|
152
|
-
description: 创建时间
|
|
153
|
-
updatedAt:
|
|
154
|
-
type: string
|
|
155
|
-
format: date-time
|
|
156
|
-
description: 更新时间
|
|
157
|
-
createdBy:
|
|
158
|
-
type: string
|
|
159
|
-
description: 创建者 ID
|
|
160
|
-
updatedBy:
|
|
161
|
-
type: string
|
|
162
|
-
description: 更新者 ID
|
|
163
|
-
meta:
|
|
164
|
-
type: object
|
|
165
|
-
required: &ref_15
|
|
166
|
-
- page
|
|
167
|
-
- limit
|
|
168
|
-
- total
|
|
169
|
-
- totalPages
|
|
170
|
-
properties: &ref_16
|
|
171
|
-
page:
|
|
172
|
-
type: integer
|
|
173
|
-
minimum: 1
|
|
174
|
-
description: 当前页码
|
|
175
|
-
limit:
|
|
176
|
-
type: integer
|
|
177
|
-
minimum: 1
|
|
178
|
-
maximum: 100
|
|
179
|
-
description: 每页数量
|
|
180
|
-
total:
|
|
181
|
-
type: integer
|
|
182
|
-
minimum: 0
|
|
183
|
-
description: 总记录数
|
|
184
|
-
totalPages:
|
|
185
|
-
type: integer
|
|
186
|
-
minimum: 0
|
|
187
|
-
description: 总页数
|
|
96
|
+
$ref: '#/components/schemas/PageListResponse'
|
|
188
97
|
'401':
|
|
189
|
-
|
|
190
|
-
content: &ref_4
|
|
191
|
-
application/json:
|
|
192
|
-
schema:
|
|
193
|
-
type: object
|
|
194
|
-
required: &ref_0
|
|
195
|
-
- code
|
|
196
|
-
- message
|
|
197
|
-
properties: &ref_1
|
|
198
|
-
code:
|
|
199
|
-
type: string
|
|
200
|
-
description: 错误码
|
|
201
|
-
message:
|
|
202
|
-
type: string
|
|
203
|
-
description: 错误消息
|
|
204
|
-
details:
|
|
205
|
-
type: array
|
|
206
|
-
items:
|
|
207
|
-
type: object
|
|
208
|
-
properties: &ref_51
|
|
209
|
-
field:
|
|
210
|
-
type: string
|
|
211
|
-
description: 字段名
|
|
212
|
-
message:
|
|
213
|
-
type: string
|
|
214
|
-
description: 字段错误信息
|
|
215
|
-
code:
|
|
216
|
-
type: string
|
|
217
|
-
description: 字段错误码
|
|
218
|
-
description: 错误详情
|
|
219
|
-
example:
|
|
220
|
-
code: UNAUTHORIZED
|
|
221
|
-
message: 请先登录
|
|
98
|
+
$ref: '#/components/responses/Unauthorized'
|
|
222
99
|
'500':
|
|
223
|
-
|
|
224
|
-
content: &ref_5
|
|
225
|
-
application/json:
|
|
226
|
-
schema:
|
|
227
|
-
type: object
|
|
228
|
-
required: *ref_0
|
|
229
|
-
properties: *ref_1
|
|
230
|
-
example:
|
|
231
|
-
code: INTERNAL_ERROR
|
|
232
|
-
message: 服务器内部错误,请稍后重试
|
|
100
|
+
$ref: '#/components/responses/InternalError'
|
|
233
101
|
/pages/create:
|
|
234
102
|
post:
|
|
235
103
|
tags:
|
|
@@ -242,62 +110,20 @@ paths:
|
|
|
242
110
|
content:
|
|
243
111
|
application/json:
|
|
244
112
|
schema:
|
|
245
|
-
|
|
246
|
-
required: &ref_52
|
|
247
|
-
- title
|
|
248
|
-
properties: &ref_53
|
|
249
|
-
title:
|
|
250
|
-
type: string
|
|
251
|
-
minLength: 1
|
|
252
|
-
maxLength: 255
|
|
253
|
-
description: 页面标题
|
|
254
|
-
description:
|
|
255
|
-
type: string
|
|
256
|
-
maxLength: 1024
|
|
257
|
-
description: 页面描述
|
|
258
|
-
tags:
|
|
259
|
-
type: array
|
|
260
|
-
items:
|
|
261
|
-
type: string
|
|
262
|
-
description: 标签
|
|
263
|
-
templateId:
|
|
264
|
-
type: string
|
|
265
|
-
description: 模板 ID(可选,从模板创建)
|
|
113
|
+
$ref: '#/components/schemas/CreatePageRequest'
|
|
266
114
|
responses:
|
|
267
115
|
'200':
|
|
268
116
|
description: 创建成功
|
|
269
117
|
content:
|
|
270
118
|
application/json:
|
|
271
119
|
schema:
|
|
272
|
-
|
|
273
|
-
required: &ref_6
|
|
274
|
-
- data
|
|
275
|
-
properties: &ref_7
|
|
276
|
-
data:
|
|
277
|
-
type: object
|
|
278
|
-
required: *ref_2
|
|
279
|
-
properties: *ref_3
|
|
120
|
+
$ref: '#/components/schemas/PageResponse'
|
|
280
121
|
'400':
|
|
281
|
-
|
|
282
|
-
content: &ref_9
|
|
283
|
-
application/json:
|
|
284
|
-
schema:
|
|
285
|
-
type: object
|
|
286
|
-
required: *ref_0
|
|
287
|
-
properties: *ref_1
|
|
288
|
-
example:
|
|
289
|
-
code: BAD_REQUEST
|
|
290
|
-
message: 请求参数无效
|
|
291
|
-
details:
|
|
292
|
-
- field: title
|
|
293
|
-
message: 标题不能为空
|
|
294
|
-
code: REQUIRED
|
|
122
|
+
$ref: '#/components/responses/BadRequest'
|
|
295
123
|
'401':
|
|
296
|
-
|
|
297
|
-
content: *ref_4
|
|
124
|
+
$ref: '#/components/responses/Unauthorized'
|
|
298
125
|
'500':
|
|
299
|
-
|
|
300
|
-
content: *ref_5
|
|
126
|
+
$ref: '#/components/responses/InternalError'
|
|
301
127
|
/pages/{pageId}:
|
|
302
128
|
get:
|
|
303
129
|
tags:
|
|
@@ -306,40 +132,20 @@ paths:
|
|
|
306
132
|
summary: 获取页面详情
|
|
307
133
|
description: 获取指定页面的完整信息
|
|
308
134
|
parameters:
|
|
309
|
-
-
|
|
310
|
-
in: path
|
|
311
|
-
required: true
|
|
312
|
-
schema: &ref_8
|
|
313
|
-
type: string
|
|
314
|
-
minLength: 1
|
|
315
|
-
maxLength: 128
|
|
316
|
-
description: 页面 ID
|
|
135
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
317
136
|
responses:
|
|
318
137
|
'200':
|
|
319
138
|
description: 成功
|
|
320
139
|
content:
|
|
321
140
|
application/json:
|
|
322
141
|
schema:
|
|
323
|
-
|
|
324
|
-
required: *ref_6
|
|
325
|
-
properties: *ref_7
|
|
142
|
+
$ref: '#/components/schemas/PageResponse'
|
|
326
143
|
'401':
|
|
327
|
-
|
|
328
|
-
content: *ref_4
|
|
144
|
+
$ref: '#/components/responses/Unauthorized'
|
|
329
145
|
'404':
|
|
330
|
-
|
|
331
|
-
content: &ref_10
|
|
332
|
-
application/json:
|
|
333
|
-
schema:
|
|
334
|
-
type: object
|
|
335
|
-
required: *ref_0
|
|
336
|
-
properties: *ref_1
|
|
337
|
-
example:
|
|
338
|
-
code: NOT_FOUND
|
|
339
|
-
message: 资源不存在
|
|
146
|
+
$ref: '#/components/responses/NotFound'
|
|
340
147
|
'500':
|
|
341
|
-
|
|
342
|
-
content: *ref_5
|
|
148
|
+
$ref: '#/components/responses/InternalError'
|
|
343
149
|
/pages/{pageId}/update:
|
|
344
150
|
post:
|
|
345
151
|
tags:
|
|
@@ -348,53 +154,28 @@ paths:
|
|
|
348
154
|
summary: 更新页面信息
|
|
349
155
|
description: 更新页面的元数据(不包括页面内容)
|
|
350
156
|
parameters:
|
|
351
|
-
-
|
|
352
|
-
in: path
|
|
353
|
-
required: true
|
|
354
|
-
schema: *ref_8
|
|
355
|
-
description: 页面 ID
|
|
157
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
356
158
|
requestBody:
|
|
357
159
|
required: true
|
|
358
160
|
content:
|
|
359
161
|
application/json:
|
|
360
162
|
schema:
|
|
361
|
-
|
|
362
|
-
properties: &ref_54
|
|
363
|
-
title:
|
|
364
|
-
type: string
|
|
365
|
-
minLength: 1
|
|
366
|
-
maxLength: 255
|
|
367
|
-
description: 页面标题
|
|
368
|
-
description:
|
|
369
|
-
type: string
|
|
370
|
-
maxLength: 1024
|
|
371
|
-
description: 页面描述
|
|
372
|
-
tags:
|
|
373
|
-
type: array
|
|
374
|
-
items:
|
|
375
|
-
type: string
|
|
376
|
-
description: 标签
|
|
163
|
+
$ref: '#/components/schemas/UpdatePageRequest'
|
|
377
164
|
responses:
|
|
378
165
|
'200':
|
|
379
166
|
description: 更新成功
|
|
380
167
|
content:
|
|
381
168
|
application/json:
|
|
382
169
|
schema:
|
|
383
|
-
|
|
384
|
-
required: *ref_6
|
|
385
|
-
properties: *ref_7
|
|
170
|
+
$ref: '#/components/schemas/PageResponse'
|
|
386
171
|
'400':
|
|
387
|
-
|
|
388
|
-
content: *ref_9
|
|
172
|
+
$ref: '#/components/responses/BadRequest'
|
|
389
173
|
'401':
|
|
390
|
-
|
|
391
|
-
content: *ref_4
|
|
174
|
+
$ref: '#/components/responses/Unauthorized'
|
|
392
175
|
'404':
|
|
393
|
-
|
|
394
|
-
content: *ref_10
|
|
176
|
+
$ref: '#/components/responses/NotFound'
|
|
395
177
|
'500':
|
|
396
|
-
|
|
397
|
-
content: *ref_5
|
|
178
|
+
$ref: '#/components/responses/InternalError'
|
|
398
179
|
/pages/{pageId}/delete:
|
|
399
180
|
post:
|
|
400
181
|
tags:
|
|
@@ -403,11 +184,7 @@ paths:
|
|
|
403
184
|
summary: 删除页面
|
|
404
185
|
description: 软删除页面(可恢复)
|
|
405
186
|
parameters:
|
|
406
|
-
-
|
|
407
|
-
in: path
|
|
408
|
-
required: true
|
|
409
|
-
schema: *ref_8
|
|
410
|
-
description: 页面 ID
|
|
187
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
411
188
|
requestBody:
|
|
412
189
|
content:
|
|
413
190
|
application/json:
|
|
@@ -423,154 +200,243 @@ paths:
|
|
|
423
200
|
content:
|
|
424
201
|
application/json:
|
|
425
202
|
schema:
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
203
|
+
allOf:
|
|
204
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
205
|
+
- type: object
|
|
206
|
+
properties:
|
|
207
|
+
data:
|
|
208
|
+
type: object
|
|
209
|
+
properties:
|
|
210
|
+
success:
|
|
211
|
+
type: boolean
|
|
432
212
|
'401':
|
|
433
|
-
|
|
434
|
-
content: *ref_4
|
|
213
|
+
$ref: '#/components/responses/Unauthorized'
|
|
435
214
|
'404':
|
|
436
|
-
|
|
437
|
-
content: *ref_10
|
|
215
|
+
$ref: '#/components/responses/NotFound'
|
|
438
216
|
'500':
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
217
|
+
$ref: '#/components/responses/InternalError'
|
|
218
|
+
/pages/{pageId}/duplicate:
|
|
219
|
+
post:
|
|
220
|
+
tags:
|
|
221
|
+
- Pages
|
|
222
|
+
operationId: duplicatePage
|
|
223
|
+
summary: 复制页面
|
|
224
|
+
description: 复制一个页面,生成新的页面副本
|
|
225
|
+
parameters:
|
|
226
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
227
|
+
responses:
|
|
228
|
+
'200':
|
|
229
|
+
description: 复制成功
|
|
230
|
+
content:
|
|
231
|
+
application/json:
|
|
232
|
+
schema:
|
|
233
|
+
$ref: '#/components/schemas/PageResponse'
|
|
234
|
+
'401':
|
|
235
|
+
$ref: '#/components/responses/Unauthorized'
|
|
236
|
+
'404':
|
|
237
|
+
$ref: '#/components/responses/NotFound'
|
|
238
|
+
/pages/{pageId}/preview:
|
|
442
239
|
get:
|
|
443
240
|
tags:
|
|
444
|
-
-
|
|
445
|
-
operationId:
|
|
446
|
-
summary:
|
|
447
|
-
description:
|
|
241
|
+
- Preview
|
|
242
|
+
operationId: getPreview
|
|
243
|
+
summary: 预览页面
|
|
244
|
+
description: 获取页面预览数据
|
|
448
245
|
parameters:
|
|
449
|
-
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
schema:
|
|
453
|
-
|
|
246
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
247
|
+
- name: device
|
|
248
|
+
in: query
|
|
249
|
+
schema:
|
|
250
|
+
type: string
|
|
251
|
+
enum:
|
|
252
|
+
- h5
|
|
253
|
+
- tablet
|
|
254
|
+
- pc
|
|
255
|
+
- responsive
|
|
256
|
+
description: 预览设备类型
|
|
454
257
|
responses:
|
|
455
258
|
'200':
|
|
456
|
-
description:
|
|
259
|
+
description: 获取成功
|
|
457
260
|
content:
|
|
458
261
|
application/json:
|
|
459
262
|
schema:
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
type: object
|
|
466
|
-
required: &ref_56
|
|
467
|
-
- pageId
|
|
468
|
-
- content
|
|
469
|
-
- updatedAt
|
|
470
|
-
properties: &ref_57
|
|
471
|
-
pageId:
|
|
472
|
-
type: string
|
|
473
|
-
description: 页面 ID
|
|
474
|
-
content:
|
|
263
|
+
allOf:
|
|
264
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
265
|
+
- type: object
|
|
266
|
+
properties:
|
|
267
|
+
data:
|
|
475
268
|
type: object
|
|
476
|
-
description:
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
269
|
+
description: 预览数据
|
|
270
|
+
'401':
|
|
271
|
+
$ref: '#/components/responses/Unauthorized'
|
|
272
|
+
'404':
|
|
273
|
+
$ref: '#/components/responses/NotFound'
|
|
274
|
+
/pages/{pageId}/stats:
|
|
275
|
+
get:
|
|
276
|
+
tags:
|
|
277
|
+
- Pages
|
|
278
|
+
operationId: getPageStats
|
|
279
|
+
summary: 获取页面统计信息
|
|
280
|
+
description: 获取页面的访问次数、版本数量等统计数据
|
|
281
|
+
parameters:
|
|
282
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
283
|
+
responses:
|
|
284
|
+
'200':
|
|
285
|
+
description: 获取成功
|
|
286
|
+
content:
|
|
287
|
+
application/json:
|
|
288
|
+
schema:
|
|
289
|
+
allOf:
|
|
290
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
291
|
+
- type: object
|
|
292
|
+
properties:
|
|
293
|
+
data:
|
|
488
294
|
type: object
|
|
489
|
-
properties:
|
|
490
|
-
|
|
491
|
-
type:
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
format: date-time
|
|
496
|
-
description: 锁定时间
|
|
497
|
-
expiresAt:
|
|
295
|
+
properties:
|
|
296
|
+
viewCount:
|
|
297
|
+
type: integer
|
|
298
|
+
versionCount:
|
|
299
|
+
type: integer
|
|
300
|
+
lastPublishedAt:
|
|
498
301
|
type: string
|
|
499
302
|
format: date-time
|
|
500
|
-
description: 锁定过期时间
|
|
501
303
|
'401':
|
|
502
|
-
|
|
503
|
-
|
|
304
|
+
$ref: '#/components/responses/Unauthorized'
|
|
305
|
+
'404':
|
|
306
|
+
$ref: '#/components/responses/NotFound'
|
|
307
|
+
/pages/{pageId}/archive:
|
|
308
|
+
post:
|
|
309
|
+
tags:
|
|
310
|
+
- Pages
|
|
311
|
+
operationId: archivePage
|
|
312
|
+
summary: 归档页面
|
|
313
|
+
description: 将页面归档,归档后页面不可编辑和发布
|
|
314
|
+
parameters:
|
|
315
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
316
|
+
responses:
|
|
317
|
+
'200':
|
|
318
|
+
description: 归档成功
|
|
319
|
+
content:
|
|
320
|
+
application/json:
|
|
321
|
+
schema:
|
|
322
|
+
$ref: '#/components/schemas/PageResponse'
|
|
323
|
+
'401':
|
|
324
|
+
$ref: '#/components/responses/Unauthorized'
|
|
325
|
+
'404':
|
|
326
|
+
$ref: '#/components/responses/NotFound'
|
|
327
|
+
/pages/{pageId}/restore:
|
|
328
|
+
post:
|
|
329
|
+
tags:
|
|
330
|
+
- Pages
|
|
331
|
+
operationId: restorePage
|
|
332
|
+
summary: 恢复归档页面
|
|
333
|
+
description: 将已归档的页面恢复为正常状态
|
|
334
|
+
parameters:
|
|
335
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
336
|
+
responses:
|
|
337
|
+
'200':
|
|
338
|
+
description: 恢复成功
|
|
339
|
+
content:
|
|
340
|
+
application/json:
|
|
341
|
+
schema:
|
|
342
|
+
$ref: '#/components/schemas/PageResponse'
|
|
343
|
+
'401':
|
|
344
|
+
$ref: '#/components/responses/Unauthorized'
|
|
504
345
|
'404':
|
|
505
|
-
|
|
506
|
-
|
|
346
|
+
$ref: '#/components/responses/NotFound'
|
|
347
|
+
/pages/batch/delete:
|
|
348
|
+
post:
|
|
349
|
+
tags:
|
|
350
|
+
- Pages
|
|
351
|
+
operationId: batchDeletePages
|
|
352
|
+
summary: 批量删除页面
|
|
353
|
+
description: 批量软删除页面(可恢复)
|
|
354
|
+
requestBody:
|
|
355
|
+
required: true
|
|
356
|
+
content:
|
|
357
|
+
application/json:
|
|
358
|
+
schema:
|
|
359
|
+
type: object
|
|
360
|
+
required:
|
|
361
|
+
- uids
|
|
362
|
+
properties:
|
|
363
|
+
uids:
|
|
364
|
+
type: array
|
|
365
|
+
items:
|
|
366
|
+
type: string
|
|
367
|
+
minItems: 1
|
|
368
|
+
maxItems: 100
|
|
369
|
+
description: 页面 UID 列表(最多 100 个)
|
|
370
|
+
responses:
|
|
371
|
+
'200':
|
|
372
|
+
description: 批量删除成功
|
|
373
|
+
content:
|
|
374
|
+
application/json:
|
|
375
|
+
schema:
|
|
376
|
+
allOf:
|
|
377
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
378
|
+
- type: object
|
|
379
|
+
properties:
|
|
380
|
+
data:
|
|
381
|
+
type: object
|
|
382
|
+
properties:
|
|
383
|
+
deletedCount:
|
|
384
|
+
type: integer
|
|
385
|
+
description: 成功删除的数量
|
|
386
|
+
'400':
|
|
387
|
+
$ref: '#/components/responses/BadRequest'
|
|
388
|
+
'401':
|
|
389
|
+
$ref: '#/components/responses/Unauthorized'
|
|
507
390
|
'500':
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
391
|
+
$ref: '#/components/responses/InternalError'
|
|
392
|
+
/pages/{pageId}/draft:
|
|
393
|
+
get:
|
|
394
|
+
tags:
|
|
395
|
+
- Drafts
|
|
396
|
+
operationId: getDraft
|
|
397
|
+
summary: 获取页面草稿
|
|
398
|
+
description: 获取页面的当前草稿(包含完整 Schema)
|
|
399
|
+
parameters:
|
|
400
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
401
|
+
responses:
|
|
402
|
+
'200':
|
|
403
|
+
description: 成功
|
|
404
|
+
content:
|
|
405
|
+
application/json:
|
|
406
|
+
schema:
|
|
407
|
+
$ref: '#/components/schemas/DraftResponse'
|
|
408
|
+
'401':
|
|
409
|
+
$ref: '#/components/responses/Unauthorized'
|
|
410
|
+
'404':
|
|
411
|
+
$ref: '#/components/responses/NotFound'
|
|
412
|
+
/pages/{pageId}/schema:
|
|
511
413
|
post:
|
|
512
414
|
tags:
|
|
513
415
|
- Drafts
|
|
514
416
|
operationId: saveDraft
|
|
515
|
-
summary:
|
|
516
|
-
description:
|
|
417
|
+
summary: 保存页面草稿
|
|
418
|
+
description: 更新页面的 Schema(编辑器自动保存)
|
|
517
419
|
parameters:
|
|
518
|
-
-
|
|
519
|
-
in: path
|
|
520
|
-
required: true
|
|
521
|
-
schema: *ref_8
|
|
522
|
-
description: 页面 ID
|
|
420
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
523
421
|
requestBody:
|
|
524
422
|
required: true
|
|
525
423
|
content:
|
|
526
424
|
application/json:
|
|
527
425
|
schema:
|
|
528
|
-
|
|
529
|
-
required: &ref_58
|
|
530
|
-
- content
|
|
531
|
-
properties: &ref_59
|
|
532
|
-
content:
|
|
533
|
-
type: object
|
|
534
|
-
description: 页面 Schema 内容
|
|
535
|
-
baseVersion:
|
|
536
|
-
type: string
|
|
537
|
-
description: 基于的版本号(用于冲突检测)
|
|
538
|
-
force:
|
|
539
|
-
type: boolean
|
|
540
|
-
default: false
|
|
541
|
-
description: 是否强制保存(忽略冲突)
|
|
426
|
+
$ref: '#/components/schemas/SaveDraftRequest'
|
|
542
427
|
responses:
|
|
543
428
|
'200':
|
|
544
429
|
description: 保存成功
|
|
545
430
|
content:
|
|
546
431
|
application/json:
|
|
547
432
|
schema:
|
|
548
|
-
|
|
549
|
-
required: *ref_11
|
|
550
|
-
properties: *ref_12
|
|
433
|
+
$ref: '#/components/schemas/DraftResponse'
|
|
551
434
|
'400':
|
|
552
|
-
|
|
553
|
-
content: *ref_9
|
|
435
|
+
$ref: '#/components/responses/BadRequest'
|
|
554
436
|
'401':
|
|
555
|
-
|
|
556
|
-
content: *ref_4
|
|
437
|
+
$ref: '#/components/responses/Unauthorized'
|
|
557
438
|
'404':
|
|
558
|
-
|
|
559
|
-
content: *ref_10
|
|
560
|
-
'409':
|
|
561
|
-
description: 资源冲突
|
|
562
|
-
content: &ref_19
|
|
563
|
-
application/json:
|
|
564
|
-
schema:
|
|
565
|
-
type: object
|
|
566
|
-
required: *ref_0
|
|
567
|
-
properties: *ref_1
|
|
568
|
-
example:
|
|
569
|
-
code: CONFLICT
|
|
570
|
-
message: 资源已被其他用户修改,请刷新后重试
|
|
571
|
-
'500':
|
|
572
|
-
description: 服务器内部错误
|
|
573
|
-
content: *ref_5
|
|
439
|
+
$ref: '#/components/responses/NotFound'
|
|
574
440
|
/pages/{pageId}/draft/discard:
|
|
575
441
|
post:
|
|
576
442
|
tags:
|
|
@@ -579,11 +445,7 @@ paths:
|
|
|
579
445
|
summary: 丢弃草稿
|
|
580
446
|
description: 丢弃当前草稿,恢复到最后发布的版本
|
|
581
447
|
parameters:
|
|
582
|
-
-
|
|
583
|
-
in: path
|
|
584
|
-
required: true
|
|
585
|
-
schema: *ref_8
|
|
586
|
-
description: 页面 ID
|
|
448
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
587
449
|
requestBody:
|
|
588
450
|
content:
|
|
589
451
|
application/json:
|
|
@@ -606,14 +468,11 @@ paths:
|
|
|
606
468
|
message:
|
|
607
469
|
type: string
|
|
608
470
|
'401':
|
|
609
|
-
|
|
610
|
-
content: *ref_4
|
|
471
|
+
$ref: '#/components/responses/Unauthorized'
|
|
611
472
|
'404':
|
|
612
|
-
|
|
613
|
-
content: *ref_10
|
|
473
|
+
$ref: '#/components/responses/NotFound'
|
|
614
474
|
'500':
|
|
615
|
-
|
|
616
|
-
content: *ref_5
|
|
475
|
+
$ref: '#/components/responses/InternalError'
|
|
617
476
|
/pages/{pageId}/versions:
|
|
618
477
|
get:
|
|
619
478
|
tags:
|
|
@@ -622,85 +481,22 @@ paths:
|
|
|
622
481
|
summary: 获取版本列表
|
|
623
482
|
description: 获取指定页面的所有版本
|
|
624
483
|
parameters:
|
|
625
|
-
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
schema: *ref_8
|
|
629
|
-
description: 页面 ID
|
|
630
|
-
- name: page
|
|
631
|
-
in: query
|
|
632
|
-
schema: *ref_13
|
|
633
|
-
description: 页码
|
|
634
|
-
- name: limit
|
|
635
|
-
in: query
|
|
636
|
-
schema: *ref_14
|
|
637
|
-
description: 每页数量
|
|
484
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
485
|
+
- $ref: '#/components/parameters/PageParam'
|
|
486
|
+
- $ref: '#/components/parameters/LimitParam'
|
|
638
487
|
responses:
|
|
639
488
|
'200':
|
|
640
489
|
description: 成功
|
|
641
490
|
content:
|
|
642
491
|
application/json:
|
|
643
492
|
schema:
|
|
644
|
-
|
|
645
|
-
required: &ref_60
|
|
646
|
-
- data
|
|
647
|
-
- meta
|
|
648
|
-
properties: &ref_61
|
|
649
|
-
data:
|
|
650
|
-
type: array
|
|
651
|
-
items:
|
|
652
|
-
type: object
|
|
653
|
-
required: &ref_17
|
|
654
|
-
- id
|
|
655
|
-
- version
|
|
656
|
-
- status
|
|
657
|
-
- createdAt
|
|
658
|
-
properties: &ref_18
|
|
659
|
-
id:
|
|
660
|
-
type: string
|
|
661
|
-
description: 版本 ID
|
|
662
|
-
version:
|
|
663
|
-
type: string
|
|
664
|
-
pattern: ^\d+\.\d+\.\d+$
|
|
665
|
-
description: 语义化版本号
|
|
666
|
-
status:
|
|
667
|
-
type: string
|
|
668
|
-
enum:
|
|
669
|
-
- active
|
|
670
|
-
- inactive
|
|
671
|
-
- deprecated
|
|
672
|
-
description: 版本状态
|
|
673
|
-
changelog:
|
|
674
|
-
type: string
|
|
675
|
-
description: 变更日志
|
|
676
|
-
integrity:
|
|
677
|
-
type: string
|
|
678
|
-
description: 完整性哈希
|
|
679
|
-
createdAt:
|
|
680
|
-
type: string
|
|
681
|
-
format: date-time
|
|
682
|
-
description: 创建时间
|
|
683
|
-
createdBy:
|
|
684
|
-
type: string
|
|
685
|
-
description: 创建者 ID
|
|
686
|
-
rolloutPercentage:
|
|
687
|
-
type: integer
|
|
688
|
-
minimum: 0
|
|
689
|
-
maximum: 100
|
|
690
|
-
description: 灰度发布百分比
|
|
691
|
-
meta:
|
|
692
|
-
type: object
|
|
693
|
-
required: *ref_15
|
|
694
|
-
properties: *ref_16
|
|
493
|
+
$ref: '#/components/schemas/VersionListResponse'
|
|
695
494
|
'401':
|
|
696
|
-
|
|
697
|
-
content: *ref_4
|
|
495
|
+
$ref: '#/components/responses/Unauthorized'
|
|
698
496
|
'404':
|
|
699
|
-
|
|
700
|
-
content: *ref_10
|
|
497
|
+
$ref: '#/components/responses/NotFound'
|
|
701
498
|
'500':
|
|
702
|
-
|
|
703
|
-
content: *ref_5
|
|
499
|
+
$ref: '#/components/responses/InternalError'
|
|
704
500
|
/pages/{pageId}/versions/{versionId}:
|
|
705
501
|
get:
|
|
706
502
|
tags:
|
|
@@ -709,274 +505,139 @@ paths:
|
|
|
709
505
|
summary: 获取版本详情
|
|
710
506
|
description: 获取指定版本的完整内容
|
|
711
507
|
parameters:
|
|
712
|
-
-
|
|
713
|
-
|
|
714
|
-
required: true
|
|
715
|
-
schema: *ref_8
|
|
716
|
-
description: 页面 ID
|
|
717
|
-
- name: versionId
|
|
718
|
-
in: path
|
|
719
|
-
required: true
|
|
720
|
-
schema: &ref_25
|
|
721
|
-
type: string
|
|
722
|
-
description: 版本 ID
|
|
508
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
509
|
+
- $ref: '#/components/parameters/VersionIdPath'
|
|
723
510
|
responses:
|
|
724
511
|
'200':
|
|
725
512
|
description: 成功
|
|
726
513
|
content:
|
|
727
514
|
application/json:
|
|
728
515
|
schema:
|
|
729
|
-
|
|
730
|
-
required: &ref_62
|
|
731
|
-
- data
|
|
732
|
-
properties: &ref_63
|
|
733
|
-
data:
|
|
734
|
-
allOf:
|
|
735
|
-
- type: object
|
|
736
|
-
required: *ref_17
|
|
737
|
-
properties: *ref_18
|
|
738
|
-
- type: object
|
|
739
|
-
properties:
|
|
740
|
-
content:
|
|
741
|
-
type: object
|
|
742
|
-
description: 页面 Schema 内容
|
|
516
|
+
$ref: '#/components/schemas/VersionResponse'
|
|
743
517
|
'401':
|
|
744
|
-
|
|
745
|
-
content: *ref_4
|
|
518
|
+
$ref: '#/components/responses/Unauthorized'
|
|
746
519
|
'404':
|
|
747
|
-
|
|
748
|
-
content: *ref_10
|
|
520
|
+
$ref: '#/components/responses/NotFound'
|
|
749
521
|
'500':
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
post:
|
|
522
|
+
$ref: '#/components/responses/InternalError'
|
|
523
|
+
/pages/{pageId}/versions/{versionId1}/compare/{versionId2}:
|
|
524
|
+
get:
|
|
754
525
|
tags:
|
|
755
526
|
- Versions
|
|
756
|
-
operationId:
|
|
757
|
-
summary:
|
|
758
|
-
description:
|
|
527
|
+
operationId: compareVersions
|
|
528
|
+
summary: 比较两个版本
|
|
529
|
+
description: 获取两个版本的 Schema 用于对比
|
|
759
530
|
parameters:
|
|
760
|
-
-
|
|
531
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
532
|
+
- name: versionId1
|
|
761
533
|
in: path
|
|
762
534
|
required: true
|
|
763
|
-
schema:
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
changelog:
|
|
773
|
-
type: string
|
|
774
|
-
maxLength: 2048
|
|
775
|
-
description: 变更日志
|
|
776
|
-
versionBump:
|
|
777
|
-
type: string
|
|
778
|
-
enum:
|
|
779
|
-
- major
|
|
780
|
-
- minor
|
|
781
|
-
- patch
|
|
782
|
-
default: patch
|
|
783
|
-
description: 版本号升级类型
|
|
784
|
-
rollout:
|
|
785
|
-
type: object
|
|
786
|
-
properties: &ref_28
|
|
787
|
-
percentage:
|
|
788
|
-
type: integer
|
|
789
|
-
minimum: 0
|
|
790
|
-
maximum: 100
|
|
791
|
-
default: 100
|
|
792
|
-
description: 灰度发布百分比
|
|
793
|
-
targetGroups:
|
|
794
|
-
type: array
|
|
795
|
-
items:
|
|
796
|
-
type: string
|
|
797
|
-
description: 目标用户组
|
|
535
|
+
schema:
|
|
536
|
+
type: string
|
|
537
|
+
description: 版本1 ID
|
|
538
|
+
- name: versionId2
|
|
539
|
+
in: path
|
|
540
|
+
required: true
|
|
541
|
+
schema:
|
|
542
|
+
type: string
|
|
543
|
+
description: 版本2 ID
|
|
798
544
|
responses:
|
|
799
|
-
'
|
|
800
|
-
description:
|
|
545
|
+
'200':
|
|
546
|
+
description: 查询成功
|
|
801
547
|
content:
|
|
802
548
|
application/json:
|
|
803
549
|
schema:
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
550
|
+
allOf:
|
|
551
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
552
|
+
- type: object
|
|
553
|
+
properties:
|
|
554
|
+
data:
|
|
555
|
+
type: object
|
|
556
|
+
properties:
|
|
557
|
+
version1:
|
|
558
|
+
type: object
|
|
559
|
+
version2:
|
|
560
|
+
type: object
|
|
561
|
+
diff:
|
|
562
|
+
type: object
|
|
815
563
|
'401':
|
|
816
|
-
|
|
817
|
-
content: *ref_4
|
|
564
|
+
$ref: '#/components/responses/Unauthorized'
|
|
818
565
|
'404':
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
'409':
|
|
822
|
-
description: 资源冲突
|
|
823
|
-
content: *ref_19
|
|
824
|
-
'500':
|
|
825
|
-
description: 服务器内部错误
|
|
826
|
-
content: *ref_5
|
|
827
|
-
/pages/{pageId}/rollback:
|
|
566
|
+
$ref: '#/components/responses/NotFound'
|
|
567
|
+
/pages/{pageId}/publish:
|
|
828
568
|
post:
|
|
829
569
|
tags:
|
|
830
570
|
- Versions
|
|
831
|
-
operationId:
|
|
832
|
-
summary:
|
|
833
|
-
description:
|
|
571
|
+
operationId: publishPage
|
|
572
|
+
summary: 发布页面
|
|
573
|
+
description: |
|
|
574
|
+
发布页面到指定环境,使用 Transactional Outbox 模式。
|
|
575
|
+
|
|
576
|
+
发布流程(根据设计总纲 V2):
|
|
577
|
+
1. 读取草稿
|
|
578
|
+
2. 发布期校验(Schema 校验、表达式 lint、组件 compat 校验、Definitions 绑定校验)
|
|
579
|
+
3. 生成 pageVersionId(不可变)
|
|
580
|
+
4. 写入 Command Tables(page_versions, manifests)+ Outbox
|
|
581
|
+
5. Worker 消费 Outbox,投影写入 Query Tables + CDN
|
|
834
582
|
parameters:
|
|
835
|
-
-
|
|
836
|
-
in: path
|
|
837
|
-
required: true
|
|
838
|
-
schema: *ref_8
|
|
839
|
-
description: 页面 ID
|
|
583
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
840
584
|
requestBody:
|
|
841
585
|
required: true
|
|
842
586
|
content:
|
|
843
587
|
application/json:
|
|
844
588
|
schema:
|
|
845
|
-
|
|
846
|
-
required: &ref_65
|
|
847
|
-
- targetVersion
|
|
848
|
-
properties: &ref_66
|
|
849
|
-
targetVersion:
|
|
850
|
-
type: string
|
|
851
|
-
description: 目标版本 ID 或版本号
|
|
852
|
-
reason:
|
|
853
|
-
type: string
|
|
854
|
-
maxLength: 1024
|
|
855
|
-
description: 回滚原因
|
|
589
|
+
$ref: '#/components/schemas/PublishRequest'
|
|
856
590
|
responses:
|
|
857
591
|
'200':
|
|
858
|
-
description:
|
|
592
|
+
description: 发布成功
|
|
859
593
|
content:
|
|
860
594
|
application/json:
|
|
861
595
|
schema:
|
|
862
|
-
|
|
863
|
-
required: *ref_20
|
|
864
|
-
properties: *ref_21
|
|
596
|
+
$ref: '#/components/schemas/PublishResponse'
|
|
865
597
|
'400':
|
|
866
|
-
|
|
867
|
-
content: *ref_9
|
|
598
|
+
$ref: '#/components/responses/BadRequest'
|
|
868
599
|
'401':
|
|
869
|
-
|
|
870
|
-
content: *ref_4
|
|
600
|
+
$ref: '#/components/responses/Unauthorized'
|
|
871
601
|
'404':
|
|
872
|
-
|
|
873
|
-
content: *ref_10
|
|
602
|
+
$ref: '#/components/responses/NotFound'
|
|
874
603
|
'500':
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
/pages/{pageId}/preview:
|
|
604
|
+
$ref: '#/components/responses/InternalError'
|
|
605
|
+
/pages/{pageId}/rollback:
|
|
878
606
|
post:
|
|
879
607
|
tags:
|
|
880
|
-
-
|
|
881
|
-
|
|
882
|
-
|
|
608
|
+
- Versions
|
|
609
|
+
operationId: rollbackPage
|
|
610
|
+
summary: 回滚到指定版本
|
|
883
611
|
description: |
|
|
884
|
-
|
|
612
|
+
将页面回滚到指定的历史版本(秒级生效)。
|
|
885
613
|
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
614
|
+
回滚流程:
|
|
615
|
+
1. 验证目标版本存在
|
|
616
|
+
2. 更新 page_pointers 指向目标版本(秒级生效)
|
|
617
|
+
3. 写入 Outbox 事件
|
|
890
618
|
parameters:
|
|
891
|
-
-
|
|
892
|
-
in: path
|
|
893
|
-
required: true
|
|
894
|
-
schema: *ref_8
|
|
895
|
-
description: 页面 ID
|
|
619
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
896
620
|
requestBody:
|
|
621
|
+
required: true
|
|
897
622
|
content:
|
|
898
623
|
application/json:
|
|
899
624
|
schema:
|
|
900
|
-
|
|
901
|
-
properties:
|
|
902
|
-
expiresIn:
|
|
903
|
-
type: integer
|
|
904
|
-
minimum: 60
|
|
905
|
-
maximum: 86400
|
|
906
|
-
default: 1800
|
|
907
|
-
description: 过期时间(秒),默认 30 分钟
|
|
908
|
-
deviceType:
|
|
909
|
-
type: string
|
|
910
|
-
enum:
|
|
911
|
-
- mobile
|
|
912
|
-
- tablet
|
|
913
|
-
- desktop
|
|
914
|
-
description: 预览设备类型
|
|
915
|
-
context:
|
|
916
|
-
type: object
|
|
917
|
-
additionalProperties: true
|
|
918
|
-
description: 预览上下文数据
|
|
625
|
+
$ref: '#/components/schemas/RollbackRequest'
|
|
919
626
|
responses:
|
|
920
|
-
'
|
|
921
|
-
description:
|
|
627
|
+
'200':
|
|
628
|
+
description: 回滚成功
|
|
922
629
|
content:
|
|
923
630
|
application/json:
|
|
924
631
|
schema:
|
|
925
|
-
|
|
926
|
-
properties:
|
|
927
|
-
success:
|
|
928
|
-
type: boolean
|
|
929
|
-
data:
|
|
930
|
-
type: object
|
|
931
|
-
required: &ref_22
|
|
932
|
-
- token
|
|
933
|
-
- pageId
|
|
934
|
-
- expiresAt
|
|
935
|
-
properties: &ref_23
|
|
936
|
-
token:
|
|
937
|
-
type: string
|
|
938
|
-
description: 预览 Token
|
|
939
|
-
pageId:
|
|
940
|
-
type: string
|
|
941
|
-
description: 页面 ID
|
|
942
|
-
draftVersion:
|
|
943
|
-
type: string
|
|
944
|
-
description: 草稿版本标识
|
|
945
|
-
previewUrl:
|
|
946
|
-
type: string
|
|
947
|
-
format: uri
|
|
948
|
-
description: 预览 URL
|
|
949
|
-
deviceType:
|
|
950
|
-
type: string
|
|
951
|
-
enum:
|
|
952
|
-
- mobile
|
|
953
|
-
- tablet
|
|
954
|
-
- desktop
|
|
955
|
-
description: 预览设备类型
|
|
956
|
-
context:
|
|
957
|
-
type: object
|
|
958
|
-
additionalProperties: true
|
|
959
|
-
description: 预览上下文
|
|
960
|
-
createdAt:
|
|
961
|
-
type: string
|
|
962
|
-
format: date-time
|
|
963
|
-
description: 创建时间
|
|
964
|
-
expiresAt:
|
|
965
|
-
type: string
|
|
966
|
-
format: date-time
|
|
967
|
-
description: 过期时间
|
|
968
|
-
createdBy:
|
|
969
|
-
type: string
|
|
970
|
-
description: 创建者 ID
|
|
632
|
+
$ref: '#/components/schemas/PublishResponse'
|
|
971
633
|
'400':
|
|
972
|
-
|
|
973
|
-
content: *ref_9
|
|
634
|
+
$ref: '#/components/responses/BadRequest'
|
|
974
635
|
'401':
|
|
975
|
-
|
|
976
|
-
content: *ref_4
|
|
636
|
+
$ref: '#/components/responses/Unauthorized'
|
|
977
637
|
'404':
|
|
978
|
-
|
|
979
|
-
|
|
638
|
+
$ref: '#/components/responses/NotFound'
|
|
639
|
+
'500':
|
|
640
|
+
$ref: '#/components/responses/InternalError'
|
|
980
641
|
/pages/{pageId}/preview/tokens:
|
|
981
642
|
get:
|
|
982
643
|
tags:
|
|
@@ -985,11 +646,7 @@ paths:
|
|
|
985
646
|
operationId: listPreviewTokens
|
|
986
647
|
description: 获取指定页面的所有有效预览 Token
|
|
987
648
|
parameters:
|
|
988
|
-
-
|
|
989
|
-
in: path
|
|
990
|
-
required: true
|
|
991
|
-
schema: *ref_8
|
|
992
|
-
description: 页面 ID
|
|
649
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
993
650
|
responses:
|
|
994
651
|
'200':
|
|
995
652
|
description: 成功
|
|
@@ -1003,9 +660,7 @@ paths:
|
|
|
1003
660
|
data:
|
|
1004
661
|
type: array
|
|
1005
662
|
items:
|
|
1006
|
-
|
|
1007
|
-
required: *ref_22
|
|
1008
|
-
properties: *ref_23
|
|
663
|
+
$ref: '#/components/schemas/PreviewTokenInfo'
|
|
1009
664
|
/preview/tokens/{token}:
|
|
1010
665
|
get:
|
|
1011
666
|
tags:
|
|
@@ -1031,12 +686,9 @@ paths:
|
|
|
1031
686
|
success:
|
|
1032
687
|
type: boolean
|
|
1033
688
|
data:
|
|
1034
|
-
|
|
1035
|
-
required: *ref_22
|
|
1036
|
-
properties: *ref_23
|
|
689
|
+
$ref: '#/components/schemas/PreviewTokenInfo'
|
|
1037
690
|
'404':
|
|
1038
|
-
|
|
1039
|
-
content: *ref_10
|
|
691
|
+
$ref: '#/components/responses/NotFound'
|
|
1040
692
|
/preview/tokens/{token}/revoke:
|
|
1041
693
|
post:
|
|
1042
694
|
tags:
|
|
@@ -1073,8 +725,7 @@ paths:
|
|
|
1073
725
|
message:
|
|
1074
726
|
type: string
|
|
1075
727
|
'404':
|
|
1076
|
-
|
|
1077
|
-
content: *ref_10
|
|
728
|
+
$ref: '#/components/responses/NotFound'
|
|
1078
729
|
/components:
|
|
1079
730
|
get:
|
|
1080
731
|
tags:
|
|
@@ -1083,14 +734,8 @@ paths:
|
|
|
1083
734
|
summary: 获取组件列表
|
|
1084
735
|
description: 获取平台中所有可用的组件
|
|
1085
736
|
parameters:
|
|
1086
|
-
-
|
|
1087
|
-
|
|
1088
|
-
schema: *ref_13
|
|
1089
|
-
description: 页码
|
|
1090
|
-
- name: limit
|
|
1091
|
-
in: query
|
|
1092
|
-
schema: *ref_14
|
|
1093
|
-
description: 每页数量
|
|
737
|
+
- $ref: '#/components/parameters/PageParam'
|
|
738
|
+
- $ref: '#/components/parameters/LimitParam'
|
|
1094
739
|
- name: category
|
|
1095
740
|
in: query
|
|
1096
741
|
schema:
|
|
@@ -1111,59 +756,11 @@ paths:
|
|
|
1111
756
|
content:
|
|
1112
757
|
application/json:
|
|
1113
758
|
schema:
|
|
1114
|
-
|
|
1115
|
-
required: &ref_69
|
|
1116
|
-
- data
|
|
1117
|
-
- meta
|
|
1118
|
-
properties: &ref_70
|
|
1119
|
-
data:
|
|
1120
|
-
type: array
|
|
1121
|
-
items:
|
|
1122
|
-
type: object
|
|
1123
|
-
required: &ref_67
|
|
1124
|
-
- id
|
|
1125
|
-
- name
|
|
1126
|
-
- category
|
|
1127
|
-
- status
|
|
1128
|
-
properties: &ref_68
|
|
1129
|
-
id:
|
|
1130
|
-
type: string
|
|
1131
|
-
description: 组件 ID
|
|
1132
|
-
name:
|
|
1133
|
-
type: string
|
|
1134
|
-
description: 组件名称
|
|
1135
|
-
displayName:
|
|
1136
|
-
type: string
|
|
1137
|
-
description: 显示名称
|
|
1138
|
-
description:
|
|
1139
|
-
type: string
|
|
1140
|
-
description: 组件描述
|
|
1141
|
-
category:
|
|
1142
|
-
type: string
|
|
1143
|
-
description: 组件分类
|
|
1144
|
-
status:
|
|
1145
|
-
type: string
|
|
1146
|
-
enum:
|
|
1147
|
-
- active
|
|
1148
|
-
- deprecated
|
|
1149
|
-
- disabled
|
|
1150
|
-
description: 组件状态
|
|
1151
|
-
latestVersion:
|
|
1152
|
-
type: string
|
|
1153
|
-
description: 最新版本号
|
|
1154
|
-
icon:
|
|
1155
|
-
type: string
|
|
1156
|
-
description: 图标 URL
|
|
1157
|
-
meta:
|
|
1158
|
-
type: object
|
|
1159
|
-
required: *ref_15
|
|
1160
|
-
properties: *ref_16
|
|
759
|
+
$ref: '#/components/schemas/ComponentListResponse'
|
|
1161
760
|
'401':
|
|
1162
|
-
|
|
1163
|
-
content: *ref_4
|
|
761
|
+
$ref: '#/components/responses/Unauthorized'
|
|
1164
762
|
'500':
|
|
1165
|
-
|
|
1166
|
-
content: *ref_5
|
|
763
|
+
$ref: '#/components/responses/InternalError'
|
|
1167
764
|
/components/{componentId}/versions:
|
|
1168
765
|
get:
|
|
1169
766
|
tags:
|
|
@@ -1172,78 +769,22 @@ paths:
|
|
|
1172
769
|
summary: 获取组件版本列表
|
|
1173
770
|
description: 获取指定组件的所有版本
|
|
1174
771
|
parameters:
|
|
1175
|
-
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
schema: &ref_24
|
|
1179
|
-
type: string
|
|
1180
|
-
description: 组件 ID
|
|
1181
|
-
- name: page
|
|
1182
|
-
in: query
|
|
1183
|
-
schema: *ref_13
|
|
1184
|
-
description: 页码
|
|
1185
|
-
- name: limit
|
|
1186
|
-
in: query
|
|
1187
|
-
schema: *ref_14
|
|
1188
|
-
description: 每页数量
|
|
772
|
+
- $ref: '#/components/parameters/ComponentIdPath'
|
|
773
|
+
- $ref: '#/components/parameters/PageParam'
|
|
774
|
+
- $ref: '#/components/parameters/LimitParam'
|
|
1189
775
|
responses:
|
|
1190
776
|
'200':
|
|
1191
777
|
description: 成功
|
|
1192
778
|
content:
|
|
1193
779
|
application/json:
|
|
1194
780
|
schema:
|
|
1195
|
-
|
|
1196
|
-
required: &ref_71
|
|
1197
|
-
- data
|
|
1198
|
-
- meta
|
|
1199
|
-
properties: &ref_72
|
|
1200
|
-
data:
|
|
1201
|
-
type: array
|
|
1202
|
-
items:
|
|
1203
|
-
type: object
|
|
1204
|
-
required: &ref_26
|
|
1205
|
-
- id
|
|
1206
|
-
- version
|
|
1207
|
-
- status
|
|
1208
|
-
- createdAt
|
|
1209
|
-
properties: &ref_27
|
|
1210
|
-
id:
|
|
1211
|
-
type: string
|
|
1212
|
-
description: 版本 ID
|
|
1213
|
-
version:
|
|
1214
|
-
type: string
|
|
1215
|
-
pattern: ^\d+\.\d+\.\d+$
|
|
1216
|
-
description: 语义化版本号
|
|
1217
|
-
status:
|
|
1218
|
-
type: string
|
|
1219
|
-
enum:
|
|
1220
|
-
- active
|
|
1221
|
-
- deprecated
|
|
1222
|
-
- disabled
|
|
1223
|
-
description: 版本状态
|
|
1224
|
-
changelog:
|
|
1225
|
-
type: string
|
|
1226
|
-
description: 变更日志
|
|
1227
|
-
integrity:
|
|
1228
|
-
type: string
|
|
1229
|
-
description: 完整性哈希
|
|
1230
|
-
createdAt:
|
|
1231
|
-
type: string
|
|
1232
|
-
format: date-time
|
|
1233
|
-
description: 创建时间
|
|
1234
|
-
meta:
|
|
1235
|
-
type: object
|
|
1236
|
-
required: *ref_15
|
|
1237
|
-
properties: *ref_16
|
|
781
|
+
$ref: '#/components/schemas/ComponentVersionListResponse'
|
|
1238
782
|
'401':
|
|
1239
|
-
|
|
1240
|
-
content: *ref_4
|
|
783
|
+
$ref: '#/components/responses/Unauthorized'
|
|
1241
784
|
'404':
|
|
1242
|
-
|
|
1243
|
-
content: *ref_10
|
|
785
|
+
$ref: '#/components/responses/NotFound'
|
|
1244
786
|
'500':
|
|
1245
|
-
|
|
1246
|
-
content: *ref_5
|
|
787
|
+
$ref: '#/components/responses/InternalError'
|
|
1247
788
|
/components/{componentId}/versions/{versionId}/status/update:
|
|
1248
789
|
post:
|
|
1249
790
|
tags:
|
|
@@ -1252,62 +793,29 @@ paths:
|
|
|
1252
793
|
summary: 更新组件版本状态
|
|
1253
794
|
description: 更新指定组件版本的状态(启用/禁用/废弃)
|
|
1254
795
|
parameters:
|
|
1255
|
-
-
|
|
1256
|
-
|
|
1257
|
-
required: true
|
|
1258
|
-
schema: *ref_24
|
|
1259
|
-
description: 组件 ID
|
|
1260
|
-
- name: versionId
|
|
1261
|
-
in: path
|
|
1262
|
-
required: true
|
|
1263
|
-
schema: *ref_25
|
|
1264
|
-
description: 版本 ID
|
|
796
|
+
- $ref: '#/components/parameters/ComponentIdPath'
|
|
797
|
+
- $ref: '#/components/parameters/VersionIdPath'
|
|
1265
798
|
requestBody:
|
|
1266
799
|
required: true
|
|
1267
800
|
content:
|
|
1268
801
|
application/json:
|
|
1269
802
|
schema:
|
|
1270
|
-
|
|
1271
|
-
required: &ref_73
|
|
1272
|
-
- status
|
|
1273
|
-
properties: &ref_74
|
|
1274
|
-
status:
|
|
1275
|
-
type: string
|
|
1276
|
-
enum:
|
|
1277
|
-
- active
|
|
1278
|
-
- deprecated
|
|
1279
|
-
- disabled
|
|
1280
|
-
description: 新状态
|
|
1281
|
-
reason:
|
|
1282
|
-
type: string
|
|
1283
|
-
maxLength: 1024
|
|
1284
|
-
description: 状态变更原因
|
|
803
|
+
$ref: '#/components/schemas/UpdateComponentStatusRequest'
|
|
1285
804
|
responses:
|
|
1286
805
|
'200':
|
|
1287
806
|
description: 更新成功
|
|
1288
807
|
content:
|
|
1289
808
|
application/json:
|
|
1290
809
|
schema:
|
|
1291
|
-
|
|
1292
|
-
required: &ref_75
|
|
1293
|
-
- data
|
|
1294
|
-
properties: &ref_76
|
|
1295
|
-
data:
|
|
1296
|
-
type: object
|
|
1297
|
-
required: *ref_26
|
|
1298
|
-
properties: *ref_27
|
|
810
|
+
$ref: '#/components/schemas/ComponentVersionResponse'
|
|
1299
811
|
'400':
|
|
1300
|
-
|
|
1301
|
-
content: *ref_9
|
|
812
|
+
$ref: '#/components/responses/BadRequest'
|
|
1302
813
|
'401':
|
|
1303
|
-
|
|
1304
|
-
content: *ref_4
|
|
814
|
+
$ref: '#/components/responses/Unauthorized'
|
|
1305
815
|
'404':
|
|
1306
|
-
|
|
1307
|
-
content: *ref_10
|
|
816
|
+
$ref: '#/components/responses/NotFound'
|
|
1308
817
|
'500':
|
|
1309
|
-
|
|
1310
|
-
content: *ref_5
|
|
818
|
+
$ref: '#/components/responses/InternalError'
|
|
1311
819
|
/pages/{pageId}/rollout:
|
|
1312
820
|
get:
|
|
1313
821
|
tags:
|
|
@@ -1331,11 +839,9 @@ paths:
|
|
|
1331
839
|
success:
|
|
1332
840
|
type: boolean
|
|
1333
841
|
data:
|
|
1334
|
-
|
|
1335
|
-
properties: *ref_28
|
|
842
|
+
$ref: '#/components/schemas/RolloutConfig'
|
|
1336
843
|
'404':
|
|
1337
|
-
|
|
1338
|
-
content: *ref_10
|
|
844
|
+
$ref: '#/components/responses/NotFound'
|
|
1339
845
|
/pages/{pageId}/rollout/update:
|
|
1340
846
|
post:
|
|
1341
847
|
tags:
|
|
@@ -1353,21 +859,7 @@ paths:
|
|
|
1353
859
|
content:
|
|
1354
860
|
application/json:
|
|
1355
861
|
schema:
|
|
1356
|
-
|
|
1357
|
-
properties: &ref_77
|
|
1358
|
-
percentage:
|
|
1359
|
-
type: integer
|
|
1360
|
-
minimum: 0
|
|
1361
|
-
maximum: 100
|
|
1362
|
-
description: 灰度发布百分比
|
|
1363
|
-
targetGroups:
|
|
1364
|
-
type: array
|
|
1365
|
-
items:
|
|
1366
|
-
type: string
|
|
1367
|
-
description: 目标用户组
|
|
1368
|
-
enabled:
|
|
1369
|
-
type: boolean
|
|
1370
|
-
description: 是否启用
|
|
862
|
+
$ref: '#/components/schemas/UpdateRolloutRequest'
|
|
1371
863
|
responses:
|
|
1372
864
|
'200':
|
|
1373
865
|
description: 更新成功
|
|
@@ -1379,14 +871,11 @@ paths:
|
|
|
1379
871
|
success:
|
|
1380
872
|
type: boolean
|
|
1381
873
|
data:
|
|
1382
|
-
|
|
1383
|
-
properties: *ref_28
|
|
874
|
+
$ref: '#/components/schemas/RolloutConfig'
|
|
1384
875
|
'400':
|
|
1385
|
-
|
|
1386
|
-
content: *ref_9
|
|
876
|
+
$ref: '#/components/responses/BadRequest'
|
|
1387
877
|
'404':
|
|
1388
|
-
|
|
1389
|
-
content: *ref_10
|
|
878
|
+
$ref: '#/components/responses/NotFound'
|
|
1390
879
|
/pages/{pageId}/rollout/remove:
|
|
1391
880
|
post:
|
|
1392
881
|
tags:
|
|
@@ -1422,8 +911,7 @@ paths:
|
|
|
1422
911
|
message:
|
|
1423
912
|
type: string
|
|
1424
913
|
'404':
|
|
1425
|
-
|
|
1426
|
-
content: *ref_10
|
|
914
|
+
$ref: '#/components/responses/NotFound'
|
|
1427
915
|
/pages/{pageId}/rollout/strategies/add:
|
|
1428
916
|
post:
|
|
1429
917
|
tags:
|
|
@@ -1441,37 +929,7 @@ paths:
|
|
|
1441
929
|
content:
|
|
1442
930
|
application/json:
|
|
1443
931
|
schema:
|
|
1444
|
-
|
|
1445
|
-
required: &ref_78
|
|
1446
|
-
- name
|
|
1447
|
-
- type
|
|
1448
|
-
- config
|
|
1449
|
-
properties: &ref_79
|
|
1450
|
-
name:
|
|
1451
|
-
type: string
|
|
1452
|
-
minLength: 1
|
|
1453
|
-
maxLength: 255
|
|
1454
|
-
description: 策略名称
|
|
1455
|
-
type:
|
|
1456
|
-
type: string
|
|
1457
|
-
enum:
|
|
1458
|
-
- percentage
|
|
1459
|
-
- userGroup
|
|
1460
|
-
- feature
|
|
1461
|
-
- gradual
|
|
1462
|
-
description: 策略类型
|
|
1463
|
-
config:
|
|
1464
|
-
type: object
|
|
1465
|
-
additionalProperties: true
|
|
1466
|
-
description: 策略配置
|
|
1467
|
-
priority:
|
|
1468
|
-
type: integer
|
|
1469
|
-
minimum: 0
|
|
1470
|
-
description: 优先级
|
|
1471
|
-
enabled:
|
|
1472
|
-
type: boolean
|
|
1473
|
-
default: true
|
|
1474
|
-
description: 是否启用
|
|
932
|
+
$ref: '#/components/schemas/AddRolloutStrategyRequest'
|
|
1475
933
|
responses:
|
|
1476
934
|
'200':
|
|
1477
935
|
description: 添加成功
|
|
@@ -1483,46 +941,7 @@ paths:
|
|
|
1483
941
|
success:
|
|
1484
942
|
type: boolean
|
|
1485
943
|
data:
|
|
1486
|
-
|
|
1487
|
-
required: &ref_29
|
|
1488
|
-
- id
|
|
1489
|
-
- name
|
|
1490
|
-
- type
|
|
1491
|
-
- config
|
|
1492
|
-
properties: &ref_30
|
|
1493
|
-
id:
|
|
1494
|
-
type: string
|
|
1495
|
-
description: 策略 ID
|
|
1496
|
-
name:
|
|
1497
|
-
type: string
|
|
1498
|
-
description: 策略名称
|
|
1499
|
-
type:
|
|
1500
|
-
type: string
|
|
1501
|
-
enum:
|
|
1502
|
-
- percentage
|
|
1503
|
-
- userGroup
|
|
1504
|
-
- feature
|
|
1505
|
-
- gradual
|
|
1506
|
-
description: 策略类型
|
|
1507
|
-
config:
|
|
1508
|
-
type: object
|
|
1509
|
-
additionalProperties: true
|
|
1510
|
-
description: 策略配置
|
|
1511
|
-
priority:
|
|
1512
|
-
type: integer
|
|
1513
|
-
minimum: 0
|
|
1514
|
-
description: 优先级
|
|
1515
|
-
enabled:
|
|
1516
|
-
type: boolean
|
|
1517
|
-
description: 是否启用
|
|
1518
|
-
createdAt:
|
|
1519
|
-
type: string
|
|
1520
|
-
format: date-time
|
|
1521
|
-
description: 创建时间
|
|
1522
|
-
updatedAt:
|
|
1523
|
-
type: string
|
|
1524
|
-
format: date-time
|
|
1525
|
-
description: 更新时间
|
|
944
|
+
$ref: '#/components/schemas/RolloutStrategy'
|
|
1526
945
|
/pages/{pageId}/rollout/strategies/{strategyId}/update:
|
|
1527
946
|
post:
|
|
1528
947
|
tags:
|
|
@@ -1545,24 +964,7 @@ paths:
|
|
|
1545
964
|
content:
|
|
1546
965
|
application/json:
|
|
1547
966
|
schema:
|
|
1548
|
-
|
|
1549
|
-
properties: &ref_80
|
|
1550
|
-
name:
|
|
1551
|
-
type: string
|
|
1552
|
-
minLength: 1
|
|
1553
|
-
maxLength: 255
|
|
1554
|
-
description: 策略名称
|
|
1555
|
-
config:
|
|
1556
|
-
type: object
|
|
1557
|
-
additionalProperties: true
|
|
1558
|
-
description: 策略配置
|
|
1559
|
-
priority:
|
|
1560
|
-
type: integer
|
|
1561
|
-
minimum: 0
|
|
1562
|
-
description: 优先级
|
|
1563
|
-
enabled:
|
|
1564
|
-
type: boolean
|
|
1565
|
-
description: 是否启用
|
|
967
|
+
$ref: '#/components/schemas/UpdateRolloutStrategyRequest'
|
|
1566
968
|
responses:
|
|
1567
969
|
'200':
|
|
1568
970
|
description: 更新成功
|
|
@@ -1574,9 +976,7 @@ paths:
|
|
|
1574
976
|
success:
|
|
1575
977
|
type: boolean
|
|
1576
978
|
data:
|
|
1577
|
-
|
|
1578
|
-
required: *ref_29
|
|
1579
|
-
properties: *ref_30
|
|
979
|
+
$ref: '#/components/schemas/RolloutStrategy'
|
|
1580
980
|
/pages/{pageId}/rollout/strategies/{strategyId}/remove:
|
|
1581
981
|
post:
|
|
1582
982
|
tags:
|
|
@@ -1668,66 +1068,11 @@ paths:
|
|
|
1668
1068
|
data:
|
|
1669
1069
|
type: array
|
|
1670
1070
|
items:
|
|
1671
|
-
|
|
1672
|
-
required: &ref_31
|
|
1673
|
-
- id
|
|
1674
|
-
- name
|
|
1675
|
-
- actionType
|
|
1676
|
-
- status
|
|
1677
|
-
- createdAt
|
|
1678
|
-
properties: &ref_32
|
|
1679
|
-
id:
|
|
1680
|
-
type: string
|
|
1681
|
-
description: 定义 ID
|
|
1682
|
-
name:
|
|
1683
|
-
type: string
|
|
1684
|
-
description: 动作名称
|
|
1685
|
-
displayName:
|
|
1686
|
-
type: string
|
|
1687
|
-
description: 显示名称
|
|
1688
|
-
actionType:
|
|
1689
|
-
type: string
|
|
1690
|
-
enum:
|
|
1691
|
-
- claim
|
|
1692
|
-
- signin
|
|
1693
|
-
- lottery
|
|
1694
|
-
- reserve
|
|
1695
|
-
- bind
|
|
1696
|
-
- task_complete
|
|
1697
|
-
- vote
|
|
1698
|
-
- share
|
|
1699
|
-
- form_submit
|
|
1700
|
-
- custom
|
|
1701
|
-
description: 动作类型
|
|
1702
|
-
description:
|
|
1703
|
-
type: string
|
|
1704
|
-
description: 描述
|
|
1705
|
-
status:
|
|
1706
|
-
type: string
|
|
1707
|
-
enum:
|
|
1708
|
-
- draft
|
|
1709
|
-
- stable
|
|
1710
|
-
- deprecated
|
|
1711
|
-
- blocked
|
|
1712
|
-
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
1713
|
-
latestVersion:
|
|
1714
|
-
type: string
|
|
1715
|
-
description: 最新版本
|
|
1716
|
-
createdAt:
|
|
1717
|
-
type: string
|
|
1718
|
-
format: date-time
|
|
1719
|
-
description: 创建时间
|
|
1720
|
-
updatedAt:
|
|
1721
|
-
type: string
|
|
1722
|
-
format: date-time
|
|
1723
|
-
description: 更新时间
|
|
1071
|
+
$ref: '#/components/schemas/ActionDefinitionInfo'
|
|
1724
1072
|
meta:
|
|
1725
|
-
|
|
1726
|
-
required: *ref_15
|
|
1727
|
-
properties: *ref_16
|
|
1073
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
1728
1074
|
'401':
|
|
1729
|
-
|
|
1730
|
-
content: *ref_4
|
|
1075
|
+
$ref: '#/components/responses/Unauthorized'
|
|
1731
1076
|
post:
|
|
1732
1077
|
tags:
|
|
1733
1078
|
- Definitions
|
|
@@ -1738,41 +1083,7 @@ paths:
|
|
|
1738
1083
|
content:
|
|
1739
1084
|
application/json:
|
|
1740
1085
|
schema:
|
|
1741
|
-
|
|
1742
|
-
required: &ref_81
|
|
1743
|
-
- name
|
|
1744
|
-
- actionType
|
|
1745
|
-
properties: &ref_82
|
|
1746
|
-
name:
|
|
1747
|
-
type: string
|
|
1748
|
-
minLength: 1
|
|
1749
|
-
maxLength: 255
|
|
1750
|
-
description: 动作名称
|
|
1751
|
-
displayName:
|
|
1752
|
-
type: string
|
|
1753
|
-
maxLength: 255
|
|
1754
|
-
description: 显示名称
|
|
1755
|
-
actionType:
|
|
1756
|
-
type: string
|
|
1757
|
-
enum:
|
|
1758
|
-
- claim
|
|
1759
|
-
- signin
|
|
1760
|
-
- lottery
|
|
1761
|
-
- reserve
|
|
1762
|
-
- bind
|
|
1763
|
-
- task_complete
|
|
1764
|
-
- vote
|
|
1765
|
-
- share
|
|
1766
|
-
- form_submit
|
|
1767
|
-
- custom
|
|
1768
|
-
description: 动作类型
|
|
1769
|
-
description:
|
|
1770
|
-
type: string
|
|
1771
|
-
maxLength: 1024
|
|
1772
|
-
description: 描述
|
|
1773
|
-
spec:
|
|
1774
|
-
type: object
|
|
1775
|
-
description: 动作规范定义
|
|
1086
|
+
$ref: '#/components/schemas/CreateActionDefinitionRequest'
|
|
1776
1087
|
responses:
|
|
1777
1088
|
'201':
|
|
1778
1089
|
description: 创建成功
|
|
@@ -1784,15 +1095,11 @@ paths:
|
|
|
1784
1095
|
success:
|
|
1785
1096
|
type: boolean
|
|
1786
1097
|
data:
|
|
1787
|
-
|
|
1788
|
-
required: *ref_31
|
|
1789
|
-
properties: *ref_32
|
|
1098
|
+
$ref: '#/components/schemas/ActionDefinitionInfo'
|
|
1790
1099
|
'400':
|
|
1791
|
-
|
|
1792
|
-
content: *ref_9
|
|
1100
|
+
$ref: '#/components/responses/BadRequest'
|
|
1793
1101
|
'401':
|
|
1794
|
-
|
|
1795
|
-
content: *ref_4
|
|
1102
|
+
$ref: '#/components/responses/Unauthorized'
|
|
1796
1103
|
/definitions/actions/{definitionId}:
|
|
1797
1104
|
get:
|
|
1798
1105
|
tags:
|
|
@@ -1816,102 +1123,9 @@ paths:
|
|
|
1816
1123
|
success:
|
|
1817
1124
|
type: boolean
|
|
1818
1125
|
data:
|
|
1819
|
-
|
|
1820
|
-
required: &ref_83
|
|
1821
|
-
- id
|
|
1822
|
-
- name
|
|
1823
|
-
- actionType
|
|
1824
|
-
- status
|
|
1825
|
-
- spec
|
|
1826
|
-
- createdAt
|
|
1827
|
-
properties: &ref_84
|
|
1828
|
-
id:
|
|
1829
|
-
type: string
|
|
1830
|
-
description: 定义 ID
|
|
1831
|
-
name:
|
|
1832
|
-
type: string
|
|
1833
|
-
description: 动作名称
|
|
1834
|
-
displayName:
|
|
1835
|
-
type: string
|
|
1836
|
-
description: 显示名称
|
|
1837
|
-
actionType:
|
|
1838
|
-
type: string
|
|
1839
|
-
enum:
|
|
1840
|
-
- claim
|
|
1841
|
-
- signin
|
|
1842
|
-
- lottery
|
|
1843
|
-
- reserve
|
|
1844
|
-
- bind
|
|
1845
|
-
- task_complete
|
|
1846
|
-
- vote
|
|
1847
|
-
- share
|
|
1848
|
-
- form_submit
|
|
1849
|
-
- custom
|
|
1850
|
-
description: 动作类型
|
|
1851
|
-
description:
|
|
1852
|
-
type: string
|
|
1853
|
-
description: 描述
|
|
1854
|
-
status:
|
|
1855
|
-
type: string
|
|
1856
|
-
enum:
|
|
1857
|
-
- draft
|
|
1858
|
-
- stable
|
|
1859
|
-
- deprecated
|
|
1860
|
-
- blocked
|
|
1861
|
-
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
1862
|
-
spec:
|
|
1863
|
-
type: object
|
|
1864
|
-
description: 动作规范定义
|
|
1865
|
-
versions:
|
|
1866
|
-
type: array
|
|
1867
|
-
items:
|
|
1868
|
-
type: object
|
|
1869
|
-
required: &ref_33
|
|
1870
|
-
- id
|
|
1871
|
-
- version
|
|
1872
|
-
- status
|
|
1873
|
-
- createdAt
|
|
1874
|
-
properties: &ref_34
|
|
1875
|
-
id:
|
|
1876
|
-
type: string
|
|
1877
|
-
description: 版本 ID
|
|
1878
|
-
version:
|
|
1879
|
-
type: string
|
|
1880
|
-
pattern: ^\d+\.\d+\.\d+$
|
|
1881
|
-
description: 语义化版本号
|
|
1882
|
-
status:
|
|
1883
|
-
type: string
|
|
1884
|
-
enum:
|
|
1885
|
-
- draft
|
|
1886
|
-
- stable
|
|
1887
|
-
- deprecated
|
|
1888
|
-
- blocked
|
|
1889
|
-
description: 版本状态(状态机:draft → stable → deprecated → blocked)
|
|
1890
|
-
changelog:
|
|
1891
|
-
type: string
|
|
1892
|
-
description: 变更日志
|
|
1893
|
-
integrity:
|
|
1894
|
-
type: string
|
|
1895
|
-
description: 完整性哈希
|
|
1896
|
-
createdAt:
|
|
1897
|
-
type: string
|
|
1898
|
-
format: date-time
|
|
1899
|
-
description: 创建时间
|
|
1900
|
-
createdBy:
|
|
1901
|
-
type: string
|
|
1902
|
-
description: 创建者 ID
|
|
1903
|
-
description: 版本列表
|
|
1904
|
-
createdAt:
|
|
1905
|
-
type: string
|
|
1906
|
-
format: date-time
|
|
1907
|
-
description: 创建时间
|
|
1908
|
-
updatedAt:
|
|
1909
|
-
type: string
|
|
1910
|
-
format: date-time
|
|
1911
|
-
description: 更新时间
|
|
1126
|
+
$ref: '#/components/schemas/ActionDefinitionDetail'
|
|
1912
1127
|
'404':
|
|
1913
|
-
|
|
1914
|
-
content: *ref_10
|
|
1128
|
+
$ref: '#/components/responses/NotFound'
|
|
1915
1129
|
/definitions/actions/{definitionId}/update:
|
|
1916
1130
|
post:
|
|
1917
1131
|
tags:
|
|
@@ -1929,27 +1143,7 @@ paths:
|
|
|
1929
1143
|
content:
|
|
1930
1144
|
application/json:
|
|
1931
1145
|
schema:
|
|
1932
|
-
|
|
1933
|
-
properties: &ref_85
|
|
1934
|
-
displayName:
|
|
1935
|
-
type: string
|
|
1936
|
-
maxLength: 255
|
|
1937
|
-
description: 显示名称
|
|
1938
|
-
description:
|
|
1939
|
-
type: string
|
|
1940
|
-
maxLength: 1024
|
|
1941
|
-
description: 描述
|
|
1942
|
-
spec:
|
|
1943
|
-
type: object
|
|
1944
|
-
description: 动作规范定义
|
|
1945
|
-
status:
|
|
1946
|
-
type: string
|
|
1947
|
-
enum:
|
|
1948
|
-
- draft
|
|
1949
|
-
- stable
|
|
1950
|
-
- deprecated
|
|
1951
|
-
- blocked
|
|
1952
|
-
description: 状态
|
|
1146
|
+
$ref: '#/components/schemas/UpdateActionDefinitionRequest'
|
|
1953
1147
|
responses:
|
|
1954
1148
|
'200':
|
|
1955
1149
|
description: 更新成功
|
|
@@ -1961,15 +1155,11 @@ paths:
|
|
|
1961
1155
|
success:
|
|
1962
1156
|
type: boolean
|
|
1963
1157
|
data:
|
|
1964
|
-
|
|
1965
|
-
required: *ref_31
|
|
1966
|
-
properties: *ref_32
|
|
1158
|
+
$ref: '#/components/schemas/ActionDefinitionInfo'
|
|
1967
1159
|
'400':
|
|
1968
|
-
|
|
1969
|
-
content: *ref_9
|
|
1160
|
+
$ref: '#/components/responses/BadRequest'
|
|
1970
1161
|
'404':
|
|
1971
|
-
|
|
1972
|
-
content: *ref_10
|
|
1162
|
+
$ref: '#/components/responses/NotFound'
|
|
1973
1163
|
/definitions/actions/{definitionId}/delete:
|
|
1974
1164
|
post:
|
|
1975
1165
|
tags:
|
|
@@ -1987,11 +1177,9 @@ paths:
|
|
|
1987
1177
|
'204':
|
|
1988
1178
|
description: 删除成功
|
|
1989
1179
|
'404':
|
|
1990
|
-
|
|
1991
|
-
content: *ref_10
|
|
1180
|
+
$ref: '#/components/responses/NotFound'
|
|
1992
1181
|
'409':
|
|
1993
|
-
|
|
1994
|
-
content: *ref_19
|
|
1182
|
+
$ref: '#/components/responses/Conflict'
|
|
1995
1183
|
/definitions/actions/{definitionId}/versions:
|
|
1996
1184
|
get:
|
|
1997
1185
|
tags:
|
|
@@ -2035,13 +1223,9 @@ paths:
|
|
|
2035
1223
|
data:
|
|
2036
1224
|
type: array
|
|
2037
1225
|
items:
|
|
2038
|
-
|
|
2039
|
-
required: *ref_33
|
|
2040
|
-
properties: *ref_34
|
|
1226
|
+
$ref: '#/components/schemas/DefinitionVersionInfo'
|
|
2041
1227
|
meta:
|
|
2042
|
-
|
|
2043
|
-
required: *ref_15
|
|
2044
|
-
properties: *ref_16
|
|
1228
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
2045
1229
|
post:
|
|
2046
1230
|
tags:
|
|
2047
1231
|
- Definitions
|
|
@@ -2061,20 +1245,7 @@ paths:
|
|
|
2061
1245
|
content:
|
|
2062
1246
|
application/json:
|
|
2063
1247
|
schema:
|
|
2064
|
-
|
|
2065
|
-
properties: &ref_37
|
|
2066
|
-
changelog:
|
|
2067
|
-
type: string
|
|
2068
|
-
maxLength: 2048
|
|
2069
|
-
description: 变更日志
|
|
2070
|
-
versionBump:
|
|
2071
|
-
type: string
|
|
2072
|
-
enum:
|
|
2073
|
-
- major
|
|
2074
|
-
- minor
|
|
2075
|
-
- patch
|
|
2076
|
-
default: patch
|
|
2077
|
-
description: 版本号升级类型
|
|
1248
|
+
$ref: '#/components/schemas/PublishDefinitionVersionRequest'
|
|
2078
1249
|
responses:
|
|
2079
1250
|
'201':
|
|
2080
1251
|
description: 发布成功
|
|
@@ -2086,15 +1257,11 @@ paths:
|
|
|
2086
1257
|
success:
|
|
2087
1258
|
type: boolean
|
|
2088
1259
|
data:
|
|
2089
|
-
|
|
2090
|
-
required: *ref_33
|
|
2091
|
-
properties: *ref_34
|
|
1260
|
+
$ref: '#/components/schemas/DefinitionVersionInfo'
|
|
2092
1261
|
'400':
|
|
2093
|
-
|
|
2094
|
-
content: *ref_9
|
|
1262
|
+
$ref: '#/components/responses/BadRequest'
|
|
2095
1263
|
'404':
|
|
2096
|
-
|
|
2097
|
-
content: *ref_10
|
|
1264
|
+
$ref: '#/components/responses/NotFound'
|
|
2098
1265
|
/definitions/queries:
|
|
2099
1266
|
get:
|
|
2100
1267
|
tags:
|
|
@@ -2143,58 +1310,9 @@ paths:
|
|
|
2143
1310
|
data:
|
|
2144
1311
|
type: array
|
|
2145
1312
|
items:
|
|
2146
|
-
|
|
2147
|
-
required: &ref_35
|
|
2148
|
-
- id
|
|
2149
|
-
- name
|
|
2150
|
-
- sourceType
|
|
2151
|
-
- status
|
|
2152
|
-
- createdAt
|
|
2153
|
-
properties: &ref_36
|
|
2154
|
-
id:
|
|
2155
|
-
type: string
|
|
2156
|
-
description: 定义 ID
|
|
2157
|
-
name:
|
|
2158
|
-
type: string
|
|
2159
|
-
description: 查询名称
|
|
2160
|
-
displayName:
|
|
2161
|
-
type: string
|
|
2162
|
-
description: 显示名称
|
|
2163
|
-
sourceType:
|
|
2164
|
-
type: string
|
|
2165
|
-
enum:
|
|
2166
|
-
- http
|
|
2167
|
-
- graphql
|
|
2168
|
-
- database
|
|
2169
|
-
- internal
|
|
2170
|
-
- aggregation
|
|
2171
|
-
description: 数据源类型
|
|
2172
|
-
description:
|
|
2173
|
-
type: string
|
|
2174
|
-
description: 描述
|
|
2175
|
-
status:
|
|
2176
|
-
type: string
|
|
2177
|
-
enum:
|
|
2178
|
-
- draft
|
|
2179
|
-
- stable
|
|
2180
|
-
- deprecated
|
|
2181
|
-
- blocked
|
|
2182
|
-
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
2183
|
-
latestVersion:
|
|
2184
|
-
type: string
|
|
2185
|
-
description: 最新版本
|
|
2186
|
-
createdAt:
|
|
2187
|
-
type: string
|
|
2188
|
-
format: date-time
|
|
2189
|
-
description: 创建时间
|
|
2190
|
-
updatedAt:
|
|
2191
|
-
type: string
|
|
2192
|
-
format: date-time
|
|
2193
|
-
description: 更新时间
|
|
1313
|
+
$ref: '#/components/schemas/DataQueryDefinitionInfo'
|
|
2194
1314
|
meta:
|
|
2195
|
-
|
|
2196
|
-
required: *ref_15
|
|
2197
|
-
properties: *ref_16
|
|
1315
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
2198
1316
|
post:
|
|
2199
1317
|
tags:
|
|
2200
1318
|
- Definitions
|
|
@@ -2205,36 +1323,7 @@ paths:
|
|
|
2205
1323
|
content:
|
|
2206
1324
|
application/json:
|
|
2207
1325
|
schema:
|
|
2208
|
-
|
|
2209
|
-
required: &ref_86
|
|
2210
|
-
- name
|
|
2211
|
-
- sourceType
|
|
2212
|
-
properties: &ref_87
|
|
2213
|
-
name:
|
|
2214
|
-
type: string
|
|
2215
|
-
minLength: 1
|
|
2216
|
-
maxLength: 255
|
|
2217
|
-
description: 查询名称
|
|
2218
|
-
displayName:
|
|
2219
|
-
type: string
|
|
2220
|
-
maxLength: 255
|
|
2221
|
-
description: 显示名称
|
|
2222
|
-
sourceType:
|
|
2223
|
-
type: string
|
|
2224
|
-
enum:
|
|
2225
|
-
- http
|
|
2226
|
-
- graphql
|
|
2227
|
-
- database
|
|
2228
|
-
- internal
|
|
2229
|
-
- aggregation
|
|
2230
|
-
description: 数据源类型
|
|
2231
|
-
description:
|
|
2232
|
-
type: string
|
|
2233
|
-
maxLength: 1024
|
|
2234
|
-
description: 描述
|
|
2235
|
-
spec:
|
|
2236
|
-
type: object
|
|
2237
|
-
description: 查询规范定义
|
|
1326
|
+
$ref: '#/components/schemas/CreateDataQueryDefinitionRequest'
|
|
2238
1327
|
responses:
|
|
2239
1328
|
'201':
|
|
2240
1329
|
description: 创建成功
|
|
@@ -2246,15 +1335,11 @@ paths:
|
|
|
2246
1335
|
success:
|
|
2247
1336
|
type: boolean
|
|
2248
1337
|
data:
|
|
2249
|
-
|
|
2250
|
-
required: *ref_35
|
|
2251
|
-
properties: *ref_36
|
|
1338
|
+
$ref: '#/components/schemas/DataQueryDefinitionInfo'
|
|
2252
1339
|
'400':
|
|
2253
|
-
|
|
2254
|
-
content: *ref_9
|
|
1340
|
+
$ref: '#/components/responses/BadRequest'
|
|
2255
1341
|
'401':
|
|
2256
|
-
|
|
2257
|
-
content: *ref_4
|
|
1342
|
+
$ref: '#/components/responses/Unauthorized'
|
|
2258
1343
|
/definitions/queries/{definitionId}:
|
|
2259
1344
|
get:
|
|
2260
1345
|
tags:
|
|
@@ -2278,65 +1363,9 @@ paths:
|
|
|
2278
1363
|
success:
|
|
2279
1364
|
type: boolean
|
|
2280
1365
|
data:
|
|
2281
|
-
|
|
2282
|
-
required: &ref_88
|
|
2283
|
-
- id
|
|
2284
|
-
- name
|
|
2285
|
-
- sourceType
|
|
2286
|
-
- status
|
|
2287
|
-
- spec
|
|
2288
|
-
- createdAt
|
|
2289
|
-
properties: &ref_89
|
|
2290
|
-
id:
|
|
2291
|
-
type: string
|
|
2292
|
-
description: 定义 ID
|
|
2293
|
-
name:
|
|
2294
|
-
type: string
|
|
2295
|
-
description: 查询名称
|
|
2296
|
-
displayName:
|
|
2297
|
-
type: string
|
|
2298
|
-
description: 显示名称
|
|
2299
|
-
sourceType:
|
|
2300
|
-
type: string
|
|
2301
|
-
enum:
|
|
2302
|
-
- http
|
|
2303
|
-
- graphql
|
|
2304
|
-
- database
|
|
2305
|
-
- internal
|
|
2306
|
-
- aggregation
|
|
2307
|
-
description: 数据源类型
|
|
2308
|
-
description:
|
|
2309
|
-
type: string
|
|
2310
|
-
description: 描述
|
|
2311
|
-
status:
|
|
2312
|
-
type: string
|
|
2313
|
-
enum:
|
|
2314
|
-
- draft
|
|
2315
|
-
- stable
|
|
2316
|
-
- deprecated
|
|
2317
|
-
- blocked
|
|
2318
|
-
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
2319
|
-
spec:
|
|
2320
|
-
type: object
|
|
2321
|
-
description: 查询规范定义
|
|
2322
|
-
versions:
|
|
2323
|
-
type: array
|
|
2324
|
-
items:
|
|
2325
|
-
type: object
|
|
2326
|
-
required: *ref_33
|
|
2327
|
-
properties: *ref_34
|
|
2328
|
-
description: 版本列表
|
|
2329
|
-
createdAt:
|
|
2330
|
-
type: string
|
|
2331
|
-
format: date-time
|
|
2332
|
-
description: 创建时间
|
|
2333
|
-
updatedAt:
|
|
2334
|
-
type: string
|
|
2335
|
-
format: date-time
|
|
2336
|
-
description: 更新时间
|
|
1366
|
+
$ref: '#/components/schemas/DataQueryDefinitionDetail'
|
|
2337
1367
|
'404':
|
|
2338
|
-
|
|
2339
|
-
content: *ref_10
|
|
1368
|
+
$ref: '#/components/responses/NotFound'
|
|
2340
1369
|
/definitions/queries/{definitionId}/update:
|
|
2341
1370
|
post:
|
|
2342
1371
|
tags:
|
|
@@ -2354,27 +1383,7 @@ paths:
|
|
|
2354
1383
|
content:
|
|
2355
1384
|
application/json:
|
|
2356
1385
|
schema:
|
|
2357
|
-
|
|
2358
|
-
properties: &ref_90
|
|
2359
|
-
displayName:
|
|
2360
|
-
type: string
|
|
2361
|
-
maxLength: 255
|
|
2362
|
-
description: 显示名称
|
|
2363
|
-
description:
|
|
2364
|
-
type: string
|
|
2365
|
-
maxLength: 1024
|
|
2366
|
-
description: 描述
|
|
2367
|
-
spec:
|
|
2368
|
-
type: object
|
|
2369
|
-
description: 查询规范定义
|
|
2370
|
-
status:
|
|
2371
|
-
type: string
|
|
2372
|
-
enum:
|
|
2373
|
-
- draft
|
|
2374
|
-
- stable
|
|
2375
|
-
- deprecated
|
|
2376
|
-
- blocked
|
|
2377
|
-
description: 状态
|
|
1386
|
+
$ref: '#/components/schemas/UpdateDataQueryDefinitionRequest'
|
|
2378
1387
|
responses:
|
|
2379
1388
|
'200':
|
|
2380
1389
|
description: 更新成功
|
|
@@ -2386,15 +1395,11 @@ paths:
|
|
|
2386
1395
|
success:
|
|
2387
1396
|
type: boolean
|
|
2388
1397
|
data:
|
|
2389
|
-
|
|
2390
|
-
required: *ref_35
|
|
2391
|
-
properties: *ref_36
|
|
1398
|
+
$ref: '#/components/schemas/DataQueryDefinitionInfo'
|
|
2392
1399
|
'400':
|
|
2393
|
-
|
|
2394
|
-
content: *ref_9
|
|
1400
|
+
$ref: '#/components/responses/BadRequest'
|
|
2395
1401
|
'404':
|
|
2396
|
-
|
|
2397
|
-
content: *ref_10
|
|
1402
|
+
$ref: '#/components/responses/NotFound'
|
|
2398
1403
|
/definitions/queries/{definitionId}/delete:
|
|
2399
1404
|
post:
|
|
2400
1405
|
tags:
|
|
@@ -2412,11 +1417,9 @@ paths:
|
|
|
2412
1417
|
'204':
|
|
2413
1418
|
description: 删除成功
|
|
2414
1419
|
'404':
|
|
2415
|
-
|
|
2416
|
-
content: *ref_10
|
|
1420
|
+
$ref: '#/components/responses/NotFound'
|
|
2417
1421
|
'409':
|
|
2418
|
-
|
|
2419
|
-
content: *ref_19
|
|
1422
|
+
$ref: '#/components/responses/Conflict'
|
|
2420
1423
|
/definitions/queries/{definitionId}/versions:
|
|
2421
1424
|
get:
|
|
2422
1425
|
tags:
|
|
@@ -2451,9 +1454,7 @@ paths:
|
|
|
2451
1454
|
data:
|
|
2452
1455
|
type: array
|
|
2453
1456
|
items:
|
|
2454
|
-
|
|
2455
|
-
required: *ref_33
|
|
2456
|
-
properties: *ref_34
|
|
1457
|
+
$ref: '#/components/schemas/DefinitionVersionInfo'
|
|
2457
1458
|
post:
|
|
2458
1459
|
tags:
|
|
2459
1460
|
- Definitions
|
|
@@ -2473,8 +1474,7 @@ paths:
|
|
|
2473
1474
|
content:
|
|
2474
1475
|
application/json:
|
|
2475
1476
|
schema:
|
|
2476
|
-
|
|
2477
|
-
properties: *ref_37
|
|
1477
|
+
$ref: '#/components/schemas/PublishDefinitionVersionRequest'
|
|
2478
1478
|
responses:
|
|
2479
1479
|
'201':
|
|
2480
1480
|
description: 发布成功
|
|
@@ -2486,15 +1486,11 @@ paths:
|
|
|
2486
1486
|
success:
|
|
2487
1487
|
type: boolean
|
|
2488
1488
|
data:
|
|
2489
|
-
|
|
2490
|
-
required: *ref_33
|
|
2491
|
-
properties: *ref_34
|
|
1489
|
+
$ref: '#/components/schemas/DefinitionVersionInfo'
|
|
2492
1490
|
'400':
|
|
2493
|
-
|
|
2494
|
-
content: *ref_9
|
|
1491
|
+
$ref: '#/components/responses/BadRequest'
|
|
2495
1492
|
'404':
|
|
2496
|
-
|
|
2497
|
-
content: *ref_10
|
|
1493
|
+
$ref: '#/components/responses/NotFound'
|
|
2498
1494
|
/activities:
|
|
2499
1495
|
get:
|
|
2500
1496
|
tags:
|
|
@@ -2548,59 +1544,10 @@ paths:
|
|
|
2548
1544
|
type: boolean
|
|
2549
1545
|
data:
|
|
2550
1546
|
type: array
|
|
2551
|
-
items:
|
|
2552
|
-
|
|
2553
|
-
required: &ref_38
|
|
2554
|
-
- id
|
|
2555
|
-
- name
|
|
2556
|
-
- type
|
|
2557
|
-
- status
|
|
2558
|
-
- createdAt
|
|
2559
|
-
properties: &ref_39
|
|
2560
|
-
id:
|
|
2561
|
-
type: string
|
|
2562
|
-
description: 活动 ID
|
|
2563
|
-
name:
|
|
2564
|
-
type: string
|
|
2565
|
-
description: 活动名称
|
|
2566
|
-
type:
|
|
2567
|
-
type: string
|
|
2568
|
-
enum:
|
|
2569
|
-
- signin
|
|
2570
|
-
- lottery
|
|
2571
|
-
- redpack
|
|
2572
|
-
- coupon
|
|
2573
|
-
- custom
|
|
2574
|
-
description: 活动类型
|
|
2575
|
-
status:
|
|
2576
|
-
type: string
|
|
2577
|
-
enum:
|
|
2578
|
-
- draft
|
|
2579
|
-
- scheduled
|
|
2580
|
-
- active
|
|
2581
|
-
- paused
|
|
2582
|
-
- ended
|
|
2583
|
-
description: 活动状态
|
|
2584
|
-
startTime:
|
|
2585
|
-
type: string
|
|
2586
|
-
format: date-time
|
|
2587
|
-
description: 开始时间
|
|
2588
|
-
endTime:
|
|
2589
|
-
type: string
|
|
2590
|
-
format: date-time
|
|
2591
|
-
description: 结束时间
|
|
2592
|
-
createdAt:
|
|
2593
|
-
type: string
|
|
2594
|
-
format: date-time
|
|
2595
|
-
description: 创建时间
|
|
2596
|
-
updatedAt:
|
|
2597
|
-
type: string
|
|
2598
|
-
format: date-time
|
|
2599
|
-
description: 更新时间
|
|
1547
|
+
items:
|
|
1548
|
+
$ref: '#/components/schemas/ActivityInfo'
|
|
2600
1549
|
meta:
|
|
2601
|
-
|
|
2602
|
-
required: *ref_15
|
|
2603
|
-
properties: *ref_16
|
|
1550
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
2604
1551
|
post:
|
|
2605
1552
|
tags:
|
|
2606
1553
|
- Activities
|
|
@@ -2611,45 +1558,7 @@ paths:
|
|
|
2611
1558
|
content:
|
|
2612
1559
|
application/json:
|
|
2613
1560
|
schema:
|
|
2614
|
-
|
|
2615
|
-
required: &ref_91
|
|
2616
|
-
- name
|
|
2617
|
-
- type
|
|
2618
|
-
properties: &ref_92
|
|
2619
|
-
name:
|
|
2620
|
-
type: string
|
|
2621
|
-
minLength: 1
|
|
2622
|
-
maxLength: 255
|
|
2623
|
-
description: 活动名称
|
|
2624
|
-
type:
|
|
2625
|
-
type: string
|
|
2626
|
-
enum:
|
|
2627
|
-
- signin
|
|
2628
|
-
- lottery
|
|
2629
|
-
- redpack
|
|
2630
|
-
- coupon
|
|
2631
|
-
- custom
|
|
2632
|
-
description: 活动类型
|
|
2633
|
-
description:
|
|
2634
|
-
type: string
|
|
2635
|
-
maxLength: 1024
|
|
2636
|
-
description: 活动描述
|
|
2637
|
-
config:
|
|
2638
|
-
type: object
|
|
2639
|
-
additionalProperties: true
|
|
2640
|
-
description: 活动配置
|
|
2641
|
-
rules:
|
|
2642
|
-
type: object
|
|
2643
|
-
additionalProperties: true
|
|
2644
|
-
description: 活动规则
|
|
2645
|
-
startTime:
|
|
2646
|
-
type: string
|
|
2647
|
-
format: date-time
|
|
2648
|
-
description: 开始时间
|
|
2649
|
-
endTime:
|
|
2650
|
-
type: string
|
|
2651
|
-
format: date-time
|
|
2652
|
-
description: 结束时间
|
|
1561
|
+
$ref: '#/components/schemas/CreateActivityRequest'
|
|
2653
1562
|
responses:
|
|
2654
1563
|
'201':
|
|
2655
1564
|
description: 创建成功
|
|
@@ -2661,9 +1570,7 @@ paths:
|
|
|
2661
1570
|
success:
|
|
2662
1571
|
type: boolean
|
|
2663
1572
|
data:
|
|
2664
|
-
|
|
2665
|
-
required: *ref_38
|
|
2666
|
-
properties: *ref_39
|
|
1573
|
+
$ref: '#/components/schemas/ActivityInfo'
|
|
2667
1574
|
/activities/{activityId}:
|
|
2668
1575
|
get:
|
|
2669
1576
|
tags:
|
|
@@ -2687,72 +1594,9 @@ paths:
|
|
|
2687
1594
|
success:
|
|
2688
1595
|
type: boolean
|
|
2689
1596
|
data:
|
|
2690
|
-
|
|
2691
|
-
required: &ref_93
|
|
2692
|
-
- id
|
|
2693
|
-
- name
|
|
2694
|
-
- type
|
|
2695
|
-
- status
|
|
2696
|
-
- config
|
|
2697
|
-
- createdAt
|
|
2698
|
-
properties: &ref_94
|
|
2699
|
-
id:
|
|
2700
|
-
type: string
|
|
2701
|
-
description: 活动 ID
|
|
2702
|
-
name:
|
|
2703
|
-
type: string
|
|
2704
|
-
description: 活动名称
|
|
2705
|
-
type:
|
|
2706
|
-
type: string
|
|
2707
|
-
enum:
|
|
2708
|
-
- signin
|
|
2709
|
-
- lottery
|
|
2710
|
-
- redpack
|
|
2711
|
-
- coupon
|
|
2712
|
-
- custom
|
|
2713
|
-
description: 活动类型
|
|
2714
|
-
status:
|
|
2715
|
-
type: string
|
|
2716
|
-
enum:
|
|
2717
|
-
- draft
|
|
2718
|
-
- scheduled
|
|
2719
|
-
- active
|
|
2720
|
-
- paused
|
|
2721
|
-
- ended
|
|
2722
|
-
description: 活动状态
|
|
2723
|
-
description:
|
|
2724
|
-
type: string
|
|
2725
|
-
description: 活动描述
|
|
2726
|
-
config:
|
|
2727
|
-
type: object
|
|
2728
|
-
additionalProperties: true
|
|
2729
|
-
description: 活动配置
|
|
2730
|
-
rules:
|
|
2731
|
-
type: object
|
|
2732
|
-
additionalProperties: true
|
|
2733
|
-
description: 活动规则
|
|
2734
|
-
startTime:
|
|
2735
|
-
type: string
|
|
2736
|
-
format: date-time
|
|
2737
|
-
description: 开始时间
|
|
2738
|
-
endTime:
|
|
2739
|
-
type: string
|
|
2740
|
-
format: date-time
|
|
2741
|
-
description: 结束时间
|
|
2742
|
-
createdAt:
|
|
2743
|
-
type: string
|
|
2744
|
-
format: date-time
|
|
2745
|
-
description: 创建时间
|
|
2746
|
-
updatedAt:
|
|
2747
|
-
type: string
|
|
2748
|
-
format: date-time
|
|
2749
|
-
description: 更新时间
|
|
2750
|
-
createdBy:
|
|
2751
|
-
type: string
|
|
2752
|
-
description: 创建者 ID
|
|
1597
|
+
$ref: '#/components/schemas/ActivityDetail'
|
|
2753
1598
|
'404':
|
|
2754
|
-
|
|
2755
|
-
content: *ref_10
|
|
1599
|
+
$ref: '#/components/responses/NotFound'
|
|
2756
1600
|
/activities/{activityId}/update:
|
|
2757
1601
|
post:
|
|
2758
1602
|
tags:
|
|
@@ -2770,33 +1614,7 @@ paths:
|
|
|
2770
1614
|
content:
|
|
2771
1615
|
application/json:
|
|
2772
1616
|
schema:
|
|
2773
|
-
|
|
2774
|
-
properties: &ref_95
|
|
2775
|
-
name:
|
|
2776
|
-
type: string
|
|
2777
|
-
minLength: 1
|
|
2778
|
-
maxLength: 255
|
|
2779
|
-
description: 活动名称
|
|
2780
|
-
description:
|
|
2781
|
-
type: string
|
|
2782
|
-
maxLength: 1024
|
|
2783
|
-
description: 活动描述
|
|
2784
|
-
config:
|
|
2785
|
-
type: object
|
|
2786
|
-
additionalProperties: true
|
|
2787
|
-
description: 活动配置
|
|
2788
|
-
rules:
|
|
2789
|
-
type: object
|
|
2790
|
-
additionalProperties: true
|
|
2791
|
-
description: 活动规则
|
|
2792
|
-
startTime:
|
|
2793
|
-
type: string
|
|
2794
|
-
format: date-time
|
|
2795
|
-
description: 开始时间
|
|
2796
|
-
endTime:
|
|
2797
|
-
type: string
|
|
2798
|
-
format: date-time
|
|
2799
|
-
description: 结束时间
|
|
1617
|
+
$ref: '#/components/schemas/UpdateActivityRequest'
|
|
2800
1618
|
responses:
|
|
2801
1619
|
'200':
|
|
2802
1620
|
description: 更新成功
|
|
@@ -2808,9 +1626,7 @@ paths:
|
|
|
2808
1626
|
success:
|
|
2809
1627
|
type: boolean
|
|
2810
1628
|
data:
|
|
2811
|
-
|
|
2812
|
-
required: *ref_38
|
|
2813
|
-
properties: *ref_39
|
|
1629
|
+
$ref: '#/components/schemas/ActivityInfo'
|
|
2814
1630
|
/activities/{activityId}/delete:
|
|
2815
1631
|
post:
|
|
2816
1632
|
tags:
|
|
@@ -2886,9 +1702,7 @@ paths:
|
|
|
2886
1702
|
success:
|
|
2887
1703
|
type: boolean
|
|
2888
1704
|
data:
|
|
2889
|
-
|
|
2890
|
-
required: *ref_38
|
|
2891
|
-
properties: *ref_39
|
|
1705
|
+
$ref: '#/components/schemas/ActivityInfo'
|
|
2892
1706
|
/activities/{activityId}/stats:
|
|
2893
1707
|
get:
|
|
2894
1708
|
tags:
|
|
@@ -2922,24 +1736,7 @@ paths:
|
|
|
2922
1736
|
success:
|
|
2923
1737
|
type: boolean
|
|
2924
1738
|
data:
|
|
2925
|
-
|
|
2926
|
-
properties: &ref_96
|
|
2927
|
-
totalParticipants:
|
|
2928
|
-
type: integer
|
|
2929
|
-
description: 总参与人数
|
|
2930
|
-
todayParticipants:
|
|
2931
|
-
type: integer
|
|
2932
|
-
description: 今日参与人数
|
|
2933
|
-
totalRewards:
|
|
2934
|
-
type: integer
|
|
2935
|
-
description: 总发放奖励数
|
|
2936
|
-
todayRewards:
|
|
2937
|
-
type: integer
|
|
2938
|
-
description: 今日发放奖励数
|
|
2939
|
-
conversionRate:
|
|
2940
|
-
type: number
|
|
2941
|
-
format: float
|
|
2942
|
-
description: 转化率
|
|
1739
|
+
$ref: '#/components/schemas/ActivityStats'
|
|
2943
1740
|
/audit:
|
|
2944
1741
|
get:
|
|
2945
1742
|
tags:
|
|
@@ -3035,59 +1832,13 @@ paths:
|
|
|
3035
1832
|
data:
|
|
3036
1833
|
type: array
|
|
3037
1834
|
items:
|
|
3038
|
-
|
|
3039
|
-
required: &ref_97
|
|
3040
|
-
- id
|
|
3041
|
-
- action
|
|
3042
|
-
- resource
|
|
3043
|
-
- timestamp
|
|
3044
|
-
properties: &ref_98
|
|
3045
|
-
id:
|
|
3046
|
-
type: string
|
|
3047
|
-
description: 日志 ID
|
|
3048
|
-
action:
|
|
3049
|
-
type: string
|
|
3050
|
-
description: 操作类型
|
|
3051
|
-
resource:
|
|
3052
|
-
type: string
|
|
3053
|
-
description: 资源类型
|
|
3054
|
-
resourceId:
|
|
3055
|
-
type: string
|
|
3056
|
-
description: 资源 ID
|
|
3057
|
-
userId:
|
|
3058
|
-
type: string
|
|
3059
|
-
description: 操作用户 ID
|
|
3060
|
-
userName:
|
|
3061
|
-
type: string
|
|
3062
|
-
description: 操作用户名
|
|
3063
|
-
timestamp:
|
|
3064
|
-
type: string
|
|
3065
|
-
format: date-time
|
|
3066
|
-
description: 操作时间
|
|
3067
|
-
status:
|
|
3068
|
-
type: string
|
|
3069
|
-
enum:
|
|
3070
|
-
- success
|
|
3071
|
-
- failed
|
|
3072
|
-
description: 操作状态
|
|
1835
|
+
$ref: '#/components/schemas/AuditLogEntry'
|
|
3073
1836
|
meta:
|
|
3074
|
-
|
|
3075
|
-
required: *ref_15
|
|
3076
|
-
properties: *ref_16
|
|
1837
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
3077
1838
|
'401':
|
|
3078
|
-
|
|
3079
|
-
content: *ref_4
|
|
1839
|
+
$ref: '#/components/responses/Unauthorized'
|
|
3080
1840
|
'403':
|
|
3081
|
-
|
|
3082
|
-
content: &ref_42
|
|
3083
|
-
application/json:
|
|
3084
|
-
schema:
|
|
3085
|
-
type: object
|
|
3086
|
-
required: *ref_0
|
|
3087
|
-
properties: *ref_1
|
|
3088
|
-
example:
|
|
3089
|
-
code: FORBIDDEN
|
|
3090
|
-
message: 您没有权限执行此操作
|
|
1841
|
+
$ref: '#/components/responses/Forbidden'
|
|
3091
1842
|
/audit/{auditId}:
|
|
3092
1843
|
get:
|
|
3093
1844
|
tags:
|
|
@@ -3111,65 +1862,9 @@ paths:
|
|
|
3111
1862
|
success:
|
|
3112
1863
|
type: boolean
|
|
3113
1864
|
data:
|
|
3114
|
-
|
|
3115
|
-
required: &ref_99
|
|
3116
|
-
- id
|
|
3117
|
-
- action
|
|
3118
|
-
- resource
|
|
3119
|
-
- timestamp
|
|
3120
|
-
properties: &ref_100
|
|
3121
|
-
id:
|
|
3122
|
-
type: string
|
|
3123
|
-
description: 日志 ID
|
|
3124
|
-
action:
|
|
3125
|
-
type: string
|
|
3126
|
-
description: 操作类型
|
|
3127
|
-
resource:
|
|
3128
|
-
type: string
|
|
3129
|
-
description: 资源类型
|
|
3130
|
-
resourceId:
|
|
3131
|
-
type: string
|
|
3132
|
-
description: 资源 ID
|
|
3133
|
-
userId:
|
|
3134
|
-
type: string
|
|
3135
|
-
description: 操作用户 ID
|
|
3136
|
-
userName:
|
|
3137
|
-
type: string
|
|
3138
|
-
description: 操作用户名
|
|
3139
|
-
timestamp:
|
|
3140
|
-
type: string
|
|
3141
|
-
format: date-time
|
|
3142
|
-
description: 操作时间
|
|
3143
|
-
status:
|
|
3144
|
-
type: string
|
|
3145
|
-
enum:
|
|
3146
|
-
- success
|
|
3147
|
-
- failed
|
|
3148
|
-
description: 操作状态
|
|
3149
|
-
changes:
|
|
3150
|
-
type: object
|
|
3151
|
-
properties:
|
|
3152
|
-
before:
|
|
3153
|
-
type: object
|
|
3154
|
-
additionalProperties: true
|
|
3155
|
-
description: 变更前数据
|
|
3156
|
-
after:
|
|
3157
|
-
type: object
|
|
3158
|
-
additionalProperties: true
|
|
3159
|
-
description: 变更后数据
|
|
3160
|
-
metadata:
|
|
3161
|
-
type: object
|
|
3162
|
-
additionalProperties: true
|
|
3163
|
-
description: 元数据
|
|
3164
|
-
ipAddress:
|
|
3165
|
-
type: string
|
|
3166
|
-
description: IP 地址
|
|
3167
|
-
userAgent:
|
|
3168
|
-
type: string
|
|
3169
|
-
description: User Agent
|
|
1865
|
+
$ref: '#/components/schemas/AuditLogDetail'
|
|
3170
1866
|
'404':
|
|
3171
|
-
|
|
3172
|
-
content: *ref_10
|
|
1867
|
+
$ref: '#/components/responses/NotFound'
|
|
3173
1868
|
/audit/stats:
|
|
3174
1869
|
get:
|
|
3175
1870
|
tags:
|
|
@@ -3210,24 +1905,7 @@ paths:
|
|
|
3210
1905
|
success:
|
|
3211
1906
|
type: boolean
|
|
3212
1907
|
data:
|
|
3213
|
-
|
|
3214
|
-
properties: &ref_101
|
|
3215
|
-
totalLogs:
|
|
3216
|
-
type: integer
|
|
3217
|
-
description: 总日志数
|
|
3218
|
-
todayLogs:
|
|
3219
|
-
type: integer
|
|
3220
|
-
description: 今日日志数
|
|
3221
|
-
actionBreakdown:
|
|
3222
|
-
type: object
|
|
3223
|
-
additionalProperties:
|
|
3224
|
-
type: integer
|
|
3225
|
-
description: 按操作类型统计
|
|
3226
|
-
resourceBreakdown:
|
|
3227
|
-
type: object
|
|
3228
|
-
additionalProperties:
|
|
3229
|
-
type: integer
|
|
3230
|
-
description: 按资源类型统计
|
|
1908
|
+
$ref: '#/components/schemas/AuditStats'
|
|
3231
1909
|
/operations/kill-switch:
|
|
3232
1910
|
get:
|
|
3233
1911
|
tags:
|
|
@@ -3241,37 +1919,11 @@ paths:
|
|
|
3241
1919
|
content:
|
|
3242
1920
|
application/json:
|
|
3243
1921
|
schema:
|
|
3244
|
-
|
|
3245
|
-
required: &ref_40
|
|
3246
|
-
- data
|
|
3247
|
-
properties: &ref_41
|
|
3248
|
-
data:
|
|
3249
|
-
type: object
|
|
3250
|
-
required:
|
|
3251
|
-
- enabled
|
|
3252
|
-
properties:
|
|
3253
|
-
enabled:
|
|
3254
|
-
type: boolean
|
|
3255
|
-
description: 是否启用全局 Kill Switch
|
|
3256
|
-
enabledAt:
|
|
3257
|
-
type: string
|
|
3258
|
-
format: date-time
|
|
3259
|
-
description: 启用时间
|
|
3260
|
-
enabledBy:
|
|
3261
|
-
type: string
|
|
3262
|
-
description: 启用者 ID
|
|
3263
|
-
reason:
|
|
3264
|
-
type: string
|
|
3265
|
-
description: 启用原因
|
|
3266
|
-
affectedPages:
|
|
3267
|
-
type: integer
|
|
3268
|
-
description: 受影响的页面数量
|
|
1922
|
+
$ref: '#/components/schemas/KillSwitchStatusResponse'
|
|
3269
1923
|
'401':
|
|
3270
|
-
|
|
3271
|
-
content: *ref_4
|
|
1924
|
+
$ref: '#/components/responses/Unauthorized'
|
|
3272
1925
|
'500':
|
|
3273
|
-
|
|
3274
|
-
content: *ref_5
|
|
1926
|
+
$ref: '#/components/responses/InternalError'
|
|
3275
1927
|
/operations/kill-switch/set:
|
|
3276
1928
|
post:
|
|
3277
1929
|
tags:
|
|
@@ -3284,42 +1936,22 @@ paths:
|
|
|
3284
1936
|
content:
|
|
3285
1937
|
application/json:
|
|
3286
1938
|
schema:
|
|
3287
|
-
|
|
3288
|
-
required: &ref_43
|
|
3289
|
-
- enabled
|
|
3290
|
-
properties: &ref_44
|
|
3291
|
-
enabled:
|
|
3292
|
-
type: boolean
|
|
3293
|
-
description: 是否启用 Kill Switch
|
|
3294
|
-
reason:
|
|
3295
|
-
type: string
|
|
3296
|
-
maxLength: 1024
|
|
3297
|
-
description: 原因
|
|
3298
|
-
fallbackUrl:
|
|
3299
|
-
type: string
|
|
3300
|
-
format: uri
|
|
3301
|
-
description: 降级跳转 URL(仅页面级别)
|
|
1939
|
+
$ref: '#/components/schemas/SetKillSwitchRequest'
|
|
3302
1940
|
responses:
|
|
3303
1941
|
'200':
|
|
3304
1942
|
description: 设置成功
|
|
3305
1943
|
content:
|
|
3306
1944
|
application/json:
|
|
3307
1945
|
schema:
|
|
3308
|
-
|
|
3309
|
-
required: *ref_40
|
|
3310
|
-
properties: *ref_41
|
|
1946
|
+
$ref: '#/components/schemas/KillSwitchStatusResponse'
|
|
3311
1947
|
'400':
|
|
3312
|
-
|
|
3313
|
-
content: *ref_9
|
|
1948
|
+
$ref: '#/components/responses/BadRequest'
|
|
3314
1949
|
'401':
|
|
3315
|
-
|
|
3316
|
-
content: *ref_4
|
|
1950
|
+
$ref: '#/components/responses/Unauthorized'
|
|
3317
1951
|
'403':
|
|
3318
|
-
|
|
3319
|
-
content: *ref_42
|
|
1952
|
+
$ref: '#/components/responses/Forbidden'
|
|
3320
1953
|
'500':
|
|
3321
|
-
|
|
3322
|
-
content: *ref_5
|
|
1954
|
+
$ref: '#/components/responses/InternalError'
|
|
3323
1955
|
/operations/kill-switch/{pageId}:
|
|
3324
1956
|
get:
|
|
3325
1957
|
tags:
|
|
@@ -3328,56 +1960,20 @@ paths:
|
|
|
3328
1960
|
summary: 获取页面 Kill Switch 状态
|
|
3329
1961
|
description: 获取指定页面的 Kill Switch 状态
|
|
3330
1962
|
parameters:
|
|
3331
|
-
-
|
|
3332
|
-
in: path
|
|
3333
|
-
required: true
|
|
3334
|
-
schema: *ref_8
|
|
3335
|
-
description: 页面 ID
|
|
1963
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
3336
1964
|
responses:
|
|
3337
1965
|
'200':
|
|
3338
1966
|
description: 成功
|
|
3339
1967
|
content:
|
|
3340
1968
|
application/json:
|
|
3341
1969
|
schema:
|
|
3342
|
-
|
|
3343
|
-
required: &ref_45
|
|
3344
|
-
- data
|
|
3345
|
-
properties: &ref_46
|
|
3346
|
-
data:
|
|
3347
|
-
type: object
|
|
3348
|
-
required:
|
|
3349
|
-
- pageId
|
|
3350
|
-
- enabled
|
|
3351
|
-
properties:
|
|
3352
|
-
pageId:
|
|
3353
|
-
type: string
|
|
3354
|
-
description: 页面 ID
|
|
3355
|
-
enabled:
|
|
3356
|
-
type: boolean
|
|
3357
|
-
description: 是否启用 Kill Switch
|
|
3358
|
-
enabledAt:
|
|
3359
|
-
type: string
|
|
3360
|
-
format: date-time
|
|
3361
|
-
description: 启用时间
|
|
3362
|
-
enabledBy:
|
|
3363
|
-
type: string
|
|
3364
|
-
description: 启用者 ID
|
|
3365
|
-
reason:
|
|
3366
|
-
type: string
|
|
3367
|
-
description: 启用原因
|
|
3368
|
-
fallbackUrl:
|
|
3369
|
-
type: string
|
|
3370
|
-
format: uri
|
|
3371
|
-
description: 降级跳转 URL
|
|
1970
|
+
$ref: '#/components/schemas/PageKillSwitchStatusResponse'
|
|
3372
1971
|
'401':
|
|
3373
|
-
|
|
3374
|
-
content: *ref_4
|
|
1972
|
+
$ref: '#/components/responses/Unauthorized'
|
|
3375
1973
|
'404':
|
|
3376
|
-
|
|
3377
|
-
content: *ref_10
|
|
1974
|
+
$ref: '#/components/responses/NotFound'
|
|
3378
1975
|
'500':
|
|
3379
|
-
|
|
3380
|
-
content: *ref_5
|
|
1976
|
+
$ref: '#/components/responses/InternalError'
|
|
3381
1977
|
/operations/kill-switch/{pageId}/set:
|
|
3382
1978
|
post:
|
|
3383
1979
|
tags:
|
|
@@ -3386,43 +1982,30 @@ paths:
|
|
|
3386
1982
|
summary: 设置页面 Kill Switch
|
|
3387
1983
|
description: 启用或禁用指定页面的 Kill Switch
|
|
3388
1984
|
parameters:
|
|
3389
|
-
-
|
|
3390
|
-
in: path
|
|
3391
|
-
required: true
|
|
3392
|
-
schema: *ref_8
|
|
3393
|
-
description: 页面 ID
|
|
1985
|
+
- $ref: '#/components/parameters/PageIdPath'
|
|
3394
1986
|
requestBody:
|
|
3395
1987
|
required: true
|
|
3396
1988
|
content:
|
|
3397
1989
|
application/json:
|
|
3398
1990
|
schema:
|
|
3399
|
-
|
|
3400
|
-
required: *ref_43
|
|
3401
|
-
properties: *ref_44
|
|
1991
|
+
$ref: '#/components/schemas/SetKillSwitchRequest'
|
|
3402
1992
|
responses:
|
|
3403
1993
|
'200':
|
|
3404
1994
|
description: 设置成功
|
|
3405
1995
|
content:
|
|
3406
1996
|
application/json:
|
|
3407
1997
|
schema:
|
|
3408
|
-
|
|
3409
|
-
required: *ref_45
|
|
3410
|
-
properties: *ref_46
|
|
1998
|
+
$ref: '#/components/schemas/PageKillSwitchStatusResponse'
|
|
3411
1999
|
'400':
|
|
3412
|
-
|
|
3413
|
-
content: *ref_9
|
|
2000
|
+
$ref: '#/components/responses/BadRequest'
|
|
3414
2001
|
'401':
|
|
3415
|
-
|
|
3416
|
-
content: *ref_4
|
|
2002
|
+
$ref: '#/components/responses/Unauthorized'
|
|
3417
2003
|
'403':
|
|
3418
|
-
|
|
3419
|
-
content: *ref_42
|
|
2004
|
+
$ref: '#/components/responses/Forbidden'
|
|
3420
2005
|
'404':
|
|
3421
|
-
|
|
3422
|
-
content: *ref_10
|
|
2006
|
+
$ref: '#/components/responses/NotFound'
|
|
3423
2007
|
'500':
|
|
3424
|
-
|
|
3425
|
-
content: *ref_5
|
|
2008
|
+
$ref: '#/components/responses/InternalError'
|
|
3426
2009
|
/health:
|
|
3427
2010
|
get:
|
|
3428
2011
|
tags:
|
|
@@ -3443,53 +2026,13 @@ paths:
|
|
|
3443
2026
|
content:
|
|
3444
2027
|
application/json:
|
|
3445
2028
|
schema:
|
|
3446
|
-
|
|
3447
|
-
required: &ref_47
|
|
3448
|
-
- status
|
|
3449
|
-
- version
|
|
3450
|
-
properties: &ref_48
|
|
3451
|
-
status:
|
|
3452
|
-
type: string
|
|
3453
|
-
enum:
|
|
3454
|
-
- healthy
|
|
3455
|
-
- degraded
|
|
3456
|
-
- unhealthy
|
|
3457
|
-
description: 服务状态
|
|
3458
|
-
version:
|
|
3459
|
-
type: string
|
|
3460
|
-
description: 服务版本
|
|
3461
|
-
uptime:
|
|
3462
|
-
type: integer
|
|
3463
|
-
description: 运行时间(秒)
|
|
3464
|
-
timestamp:
|
|
3465
|
-
type: string
|
|
3466
|
-
format: date-time
|
|
3467
|
-
description: 检查时间
|
|
3468
|
-
dependencies:
|
|
3469
|
-
type: object
|
|
3470
|
-
additionalProperties:
|
|
3471
|
-
type: object
|
|
3472
|
-
properties:
|
|
3473
|
-
status:
|
|
3474
|
-
type: string
|
|
3475
|
-
enum:
|
|
3476
|
-
- healthy
|
|
3477
|
-
- degraded
|
|
3478
|
-
- unhealthy
|
|
3479
|
-
latency:
|
|
3480
|
-
type: integer
|
|
3481
|
-
description: 延迟(毫秒)
|
|
3482
|
-
message:
|
|
3483
|
-
type: string
|
|
3484
|
-
description: 依赖服务状态
|
|
2029
|
+
$ref: '#/components/schemas/HealthResponse'
|
|
3485
2030
|
'503':
|
|
3486
2031
|
description: 服务不健康
|
|
3487
2032
|
content:
|
|
3488
2033
|
application/json:
|
|
3489
2034
|
schema:
|
|
3490
|
-
|
|
3491
|
-
required: *ref_47
|
|
3492
|
-
properties: *ref_48
|
|
2035
|
+
$ref: '#/components/schemas/HealthResponse'
|
|
3493
2036
|
security: []
|
|
3494
2037
|
/health/ready:
|
|
3495
2038
|
get:
|
|
@@ -3549,248 +2092,1948 @@ paths:
|
|
|
3549
2092
|
security: []
|
|
3550
2093
|
components:
|
|
3551
2094
|
schemas:
|
|
2095
|
+
SuccessResponse:
|
|
2096
|
+
type: object
|
|
2097
|
+
required:
|
|
2098
|
+
- success
|
|
2099
|
+
- code
|
|
2100
|
+
- message
|
|
2101
|
+
- data
|
|
2102
|
+
- timestamp
|
|
2103
|
+
- path
|
|
2104
|
+
description: 成功响应(ApiSuccessResponse,与 types/src/common/api.ts 保持一致)
|
|
2105
|
+
properties:
|
|
2106
|
+
success:
|
|
2107
|
+
type: boolean
|
|
2108
|
+
enum:
|
|
2109
|
+
- true
|
|
2110
|
+
example: true
|
|
2111
|
+
description: 是否成功(固定为 true)
|
|
2112
|
+
code:
|
|
2113
|
+
type: string
|
|
2114
|
+
example: OK
|
|
2115
|
+
description: 业务状态码
|
|
2116
|
+
message:
|
|
2117
|
+
type: string
|
|
2118
|
+
example: 操作成功
|
|
2119
|
+
description: 响应消息
|
|
2120
|
+
data:
|
|
2121
|
+
description: 响应数据(泛型 T)
|
|
2122
|
+
timestamp:
|
|
2123
|
+
type: integer
|
|
2124
|
+
format: int64
|
|
2125
|
+
example: 1702300000000
|
|
2126
|
+
description: 响应时间戳(Unix 毫秒时间戳,number)
|
|
2127
|
+
path:
|
|
2128
|
+
type: string
|
|
2129
|
+
example: /api/admin/pages
|
|
2130
|
+
description: 请求路径
|
|
2131
|
+
requestId:
|
|
2132
|
+
type: string
|
|
2133
|
+
example: uuid-string
|
|
2134
|
+
description: 请求 ID(可选)
|
|
3552
2135
|
PageInfo:
|
|
3553
2136
|
type: object
|
|
3554
|
-
required:
|
|
3555
|
-
|
|
2137
|
+
required:
|
|
2138
|
+
- id
|
|
2139
|
+
- title
|
|
2140
|
+
- status
|
|
2141
|
+
- createdAt
|
|
2142
|
+
- updatedAt
|
|
2143
|
+
properties:
|
|
2144
|
+
id:
|
|
2145
|
+
type: string
|
|
2146
|
+
description: 页面 ID
|
|
2147
|
+
title:
|
|
2148
|
+
type: string
|
|
2149
|
+
description: 页面标题
|
|
2150
|
+
description:
|
|
2151
|
+
type: string
|
|
2152
|
+
description: 页面描述
|
|
2153
|
+
status:
|
|
2154
|
+
type: string
|
|
2155
|
+
enum:
|
|
2156
|
+
- draft
|
|
2157
|
+
- published
|
|
2158
|
+
- archived
|
|
2159
|
+
description: 页面状态
|
|
2160
|
+
tags:
|
|
2161
|
+
type: array
|
|
2162
|
+
items:
|
|
2163
|
+
type: string
|
|
2164
|
+
description: 标签
|
|
2165
|
+
currentVersion:
|
|
2166
|
+
type: string
|
|
2167
|
+
description: 当前发布版本
|
|
2168
|
+
createdAt:
|
|
2169
|
+
type: string
|
|
2170
|
+
format: date-time
|
|
2171
|
+
description: 创建时间
|
|
2172
|
+
updatedAt:
|
|
2173
|
+
type: string
|
|
2174
|
+
format: date-time
|
|
2175
|
+
description: 更新时间
|
|
2176
|
+
createdBy:
|
|
2177
|
+
type: string
|
|
2178
|
+
description: 创建者 ID
|
|
2179
|
+
updatedBy:
|
|
2180
|
+
type: string
|
|
2181
|
+
description: 更新者 ID
|
|
3556
2182
|
PaginationMeta:
|
|
3557
2183
|
type: object
|
|
3558
|
-
required:
|
|
3559
|
-
|
|
2184
|
+
required:
|
|
2185
|
+
- page
|
|
2186
|
+
- limit
|
|
2187
|
+
- total
|
|
2188
|
+
- totalPages
|
|
2189
|
+
properties:
|
|
2190
|
+
page:
|
|
2191
|
+
type: integer
|
|
2192
|
+
minimum: 1
|
|
2193
|
+
description: 当前页码
|
|
2194
|
+
limit:
|
|
2195
|
+
type: integer
|
|
2196
|
+
minimum: 1
|
|
2197
|
+
maximum: 100
|
|
2198
|
+
description: 每页数量
|
|
2199
|
+
total:
|
|
2200
|
+
type: integer
|
|
2201
|
+
minimum: 0
|
|
2202
|
+
description: 总记录数
|
|
2203
|
+
totalPages:
|
|
2204
|
+
type: integer
|
|
2205
|
+
minimum: 0
|
|
2206
|
+
description: 总页数
|
|
3560
2207
|
PageListResponse:
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
2208
|
+
allOf:
|
|
2209
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
2210
|
+
- type: object
|
|
2211
|
+
properties:
|
|
2212
|
+
data:
|
|
2213
|
+
type: object
|
|
2214
|
+
required:
|
|
2215
|
+
- items
|
|
2216
|
+
- meta
|
|
2217
|
+
properties:
|
|
2218
|
+
items:
|
|
2219
|
+
type: array
|
|
2220
|
+
items:
|
|
2221
|
+
$ref: '#/components/schemas/PageInfo'
|
|
2222
|
+
meta:
|
|
2223
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
3567
2224
|
ErrorResponse:
|
|
3568
2225
|
type: object
|
|
3569
|
-
required:
|
|
3570
|
-
|
|
2226
|
+
required:
|
|
2227
|
+
- success
|
|
2228
|
+
- code
|
|
2229
|
+
- message
|
|
2230
|
+
- timestamp
|
|
2231
|
+
- path
|
|
2232
|
+
description: 错误响应(ApiErrorResponse,与 types/src/common/api.ts 保持一致)
|
|
2233
|
+
properties:
|
|
2234
|
+
success:
|
|
2235
|
+
type: boolean
|
|
2236
|
+
enum:
|
|
2237
|
+
- false
|
|
2238
|
+
example: false
|
|
2239
|
+
description: 是否成功(固定为 false)
|
|
2240
|
+
code:
|
|
2241
|
+
type: string
|
|
2242
|
+
example: VALIDATION_INVALID_PARAMS
|
|
2243
|
+
description: 错误码(ErrorCode | string)
|
|
2244
|
+
message:
|
|
2245
|
+
type: string
|
|
2246
|
+
example: 请求参数无效
|
|
2247
|
+
description: 错误消息(用户可读)
|
|
2248
|
+
data:
|
|
2249
|
+
description: 错误详情(验证错误时使用 ApiErrorDetail[],其他情况使用 unknown,放在 data 字段中)
|
|
2250
|
+
nullable: true
|
|
2251
|
+
timestamp:
|
|
2252
|
+
type: integer
|
|
2253
|
+
format: int64
|
|
2254
|
+
example: 1702300000000
|
|
2255
|
+
description: 响应时间戳(Unix 毫秒时间戳,number)
|
|
2256
|
+
path:
|
|
2257
|
+
type: string
|
|
2258
|
+
example: /api/admin/pages
|
|
2259
|
+
description: 请求路径
|
|
2260
|
+
requestId:
|
|
2261
|
+
type: string
|
|
2262
|
+
example: uuid-string
|
|
2263
|
+
description: 请求 ID(可选)
|
|
2264
|
+
traceId:
|
|
2265
|
+
type: string
|
|
2266
|
+
example: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
|
|
2267
|
+
description: 链路追踪 ID(可选,用于分布式追踪)
|
|
3571
2268
|
CreatePageRequest:
|
|
3572
2269
|
type: object
|
|
3573
|
-
required:
|
|
3574
|
-
|
|
2270
|
+
required:
|
|
2271
|
+
- title
|
|
2272
|
+
properties:
|
|
2273
|
+
title:
|
|
2274
|
+
type: string
|
|
2275
|
+
minLength: 1
|
|
2276
|
+
maxLength: 255
|
|
2277
|
+
description: 页面标题
|
|
2278
|
+
description:
|
|
2279
|
+
type: string
|
|
2280
|
+
maxLength: 1024
|
|
2281
|
+
description: 页面描述
|
|
2282
|
+
tags:
|
|
2283
|
+
type: array
|
|
2284
|
+
items:
|
|
2285
|
+
type: string
|
|
2286
|
+
description: 标签
|
|
2287
|
+
templateId:
|
|
2288
|
+
type: string
|
|
2289
|
+
description: 模板 ID(可选,从模板创建)
|
|
3575
2290
|
PageResponse:
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
2291
|
+
allOf:
|
|
2292
|
+
- $ref: '#/components/schemas/SuccessResponse'
|
|
2293
|
+
- type: object
|
|
2294
|
+
properties:
|
|
2295
|
+
data:
|
|
2296
|
+
$ref: '#/components/schemas/PageInfo'
|
|
3579
2297
|
UpdatePageRequest:
|
|
3580
2298
|
type: object
|
|
3581
|
-
properties:
|
|
3582
|
-
|
|
2299
|
+
properties:
|
|
2300
|
+
title:
|
|
2301
|
+
type: string
|
|
2302
|
+
minLength: 1
|
|
2303
|
+
maxLength: 255
|
|
2304
|
+
description: 页面标题
|
|
2305
|
+
description:
|
|
2306
|
+
type: string
|
|
2307
|
+
maxLength: 1024
|
|
2308
|
+
description: 页面描述
|
|
2309
|
+
tags:
|
|
2310
|
+
type: array
|
|
2311
|
+
items:
|
|
2312
|
+
type: string
|
|
2313
|
+
description: 标签
|
|
2314
|
+
PageSchema:
|
|
3583
2315
|
type: object
|
|
3584
|
-
|
|
2316
|
+
description: |
|
|
2317
|
+
页面 Schema(PageSchema)。完整定义与校验见 packages/schemas/schemas/page-schema.json 与 types/src/page/schema.ts。
|
|
2318
|
+
additionalProperties: true
|
|
3585
2319
|
DraftData:
|
|
3586
2320
|
type: object
|
|
3587
|
-
required:
|
|
3588
|
-
|
|
2321
|
+
required:
|
|
2322
|
+
- id
|
|
2323
|
+
- pageId
|
|
2324
|
+
- schema
|
|
2325
|
+
- isDirty
|
|
2326
|
+
- savedAt
|
|
2327
|
+
- savedBy
|
|
2328
|
+
- updatedAt
|
|
2329
|
+
description: 页面草稿(PageDraft,根据 types/src/page/draft.ts)
|
|
2330
|
+
properties:
|
|
2331
|
+
id:
|
|
2332
|
+
type: string
|
|
2333
|
+
description: 草稿 ID(UniqueId)
|
|
2334
|
+
pageId:
|
|
2335
|
+
type: string
|
|
2336
|
+
description: 页面 ID(UniqueId)
|
|
2337
|
+
schema:
|
|
2338
|
+
$ref: '#/components/schemas/PageSchema'
|
|
2339
|
+
description: 草稿内容(PageSchema,见 packages/schemas/schemas/page-schema.json)
|
|
2340
|
+
isDirty:
|
|
2341
|
+
type: boolean
|
|
2342
|
+
description: 是否有未保存的更改
|
|
2343
|
+
savedAt:
|
|
2344
|
+
type: string
|
|
2345
|
+
format: date-time
|
|
2346
|
+
description: 最后保存时间(ISODateTime)
|
|
2347
|
+
savedBy:
|
|
2348
|
+
type: string
|
|
2349
|
+
description: 最后保存者
|
|
2350
|
+
updatedAt:
|
|
2351
|
+
type: string
|
|
2352
|
+
format: date-time
|
|
2353
|
+
description: 更新时间(ISODateTime)
|
|
3589
2354
|
DraftResponse:
|
|
3590
2355
|
type: object
|
|
3591
|
-
required:
|
|
3592
|
-
|
|
2356
|
+
required:
|
|
2357
|
+
- data
|
|
2358
|
+
properties:
|
|
2359
|
+
data:
|
|
2360
|
+
$ref: '#/components/schemas/DraftData'
|
|
3593
2361
|
SaveDraftRequest:
|
|
3594
2362
|
type: object
|
|
3595
|
-
required:
|
|
3596
|
-
|
|
2363
|
+
required:
|
|
2364
|
+
- schema
|
|
2365
|
+
description: 保存草稿请求(根据 types/src/page/draft.ts)
|
|
2366
|
+
properties:
|
|
2367
|
+
schema:
|
|
2368
|
+
$ref: '#/components/schemas/PageSchema'
|
|
2369
|
+
description: 页面 Schema 内容(PageSchema,见 packages/schemas/schemas/page-schema.json)
|
|
2370
|
+
baseVersion:
|
|
2371
|
+
type: string
|
|
2372
|
+
description: 基于的版本号(用于冲突检测,UniqueId)
|
|
2373
|
+
force:
|
|
2374
|
+
type: boolean
|
|
2375
|
+
default: false
|
|
2376
|
+
description: 是否强制保存(忽略冲突)
|
|
3597
2377
|
VersionInfo:
|
|
3598
2378
|
type: object
|
|
3599
|
-
required:
|
|
3600
|
-
|
|
2379
|
+
required:
|
|
2380
|
+
- id
|
|
2381
|
+
- version
|
|
2382
|
+
- status
|
|
2383
|
+
- createdAt
|
|
2384
|
+
properties:
|
|
2385
|
+
id:
|
|
2386
|
+
type: string
|
|
2387
|
+
description: 版本 ID
|
|
2388
|
+
version:
|
|
2389
|
+
type: string
|
|
2390
|
+
pattern: ^\d+\.\d+\.\d+$
|
|
2391
|
+
description: 语义化版本号
|
|
2392
|
+
status:
|
|
2393
|
+
type: string
|
|
2394
|
+
enum:
|
|
2395
|
+
- active
|
|
2396
|
+
- inactive
|
|
2397
|
+
- deprecated
|
|
2398
|
+
description: 版本状态
|
|
2399
|
+
changelog:
|
|
2400
|
+
type: string
|
|
2401
|
+
description: 变更日志
|
|
2402
|
+
integrity:
|
|
2403
|
+
type: string
|
|
2404
|
+
description: 完整性哈希
|
|
2405
|
+
createdAt:
|
|
2406
|
+
type: string
|
|
2407
|
+
format: date-time
|
|
2408
|
+
description: 创建时间
|
|
2409
|
+
createdBy:
|
|
2410
|
+
type: string
|
|
2411
|
+
description: 创建者 ID
|
|
2412
|
+
rolloutPercentage:
|
|
2413
|
+
type: integer
|
|
2414
|
+
minimum: 0
|
|
2415
|
+
maximum: 100
|
|
2416
|
+
description: 灰度发布百分比
|
|
3601
2417
|
VersionListResponse:
|
|
3602
2418
|
type: object
|
|
3603
|
-
required:
|
|
3604
|
-
|
|
2419
|
+
required:
|
|
2420
|
+
- data
|
|
2421
|
+
- meta
|
|
2422
|
+
properties:
|
|
2423
|
+
data:
|
|
2424
|
+
type: array
|
|
2425
|
+
items:
|
|
2426
|
+
$ref: '#/components/schemas/VersionInfo'
|
|
2427
|
+
meta:
|
|
2428
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
3605
2429
|
VersionResponse:
|
|
3606
2430
|
type: object
|
|
3607
|
-
required:
|
|
3608
|
-
|
|
3609
|
-
|
|
3610
|
-
|
|
3611
|
-
|
|
2431
|
+
required:
|
|
2432
|
+
- data
|
|
2433
|
+
properties:
|
|
2434
|
+
data:
|
|
2435
|
+
allOf:
|
|
2436
|
+
- $ref: '#/components/schemas/VersionInfo'
|
|
2437
|
+
- type: object
|
|
2438
|
+
properties:
|
|
2439
|
+
content:
|
|
2440
|
+
type: object
|
|
2441
|
+
description: 页面 Schema 内容
|
|
2442
|
+
ConditionValue:
|
|
2443
|
+
description: 条件值(string | number | boolean | string[],运行时为 JSON 值)
|
|
2444
|
+
nullable: true
|
|
3612
2445
|
PublishRequest:
|
|
3613
2446
|
type: object
|
|
3614
|
-
|
|
2447
|
+
description: 发布页面请求(PublishConfig,根据设计总纲 V2 和 platform 实现)
|
|
2448
|
+
properties:
|
|
2449
|
+
channel:
|
|
2450
|
+
type: string
|
|
2451
|
+
enum:
|
|
2452
|
+
- preview
|
|
2453
|
+
- prod
|
|
2454
|
+
- gray
|
|
2455
|
+
default: prod
|
|
2456
|
+
description: 发布渠道PublishChannel(preview/prod/gray)
|
|
2457
|
+
description:
|
|
2458
|
+
type: string
|
|
2459
|
+
maxLength: 500
|
|
2460
|
+
description: 发布描述/备注
|
|
2461
|
+
publishConfig:
|
|
2462
|
+
type: object
|
|
2463
|
+
description: 发布配置(PublishConfig)
|
|
2464
|
+
properties:
|
|
2465
|
+
rollout:
|
|
2466
|
+
type: object
|
|
2467
|
+
description: 灰度配置(PublishRolloutConfig,单次发布时的临时配置)
|
|
2468
|
+
properties:
|
|
2469
|
+
strategy:
|
|
2470
|
+
type: object
|
|
2471
|
+
description: 灰度策略配置(RolloutStrategyConfig,支持 percentage/whitelist/blacklist/feature/time_window/ab_test/canary)
|
|
2472
|
+
oneOf:
|
|
2473
|
+
- type: object
|
|
2474
|
+
properties:
|
|
2475
|
+
type:
|
|
2476
|
+
type: string
|
|
2477
|
+
enum:
|
|
2478
|
+
- percentage
|
|
2479
|
+
percentage:
|
|
2480
|
+
type: integer
|
|
2481
|
+
minimum: 0
|
|
2482
|
+
maximum: 100
|
|
2483
|
+
bucketKey:
|
|
2484
|
+
type: string
|
|
2485
|
+
enum:
|
|
2486
|
+
- uid
|
|
2487
|
+
- device_id
|
|
2488
|
+
- session_id
|
|
2489
|
+
bucketSeed:
|
|
2490
|
+
type: string
|
|
2491
|
+
- type: object
|
|
2492
|
+
properties:
|
|
2493
|
+
type:
|
|
2494
|
+
type: string
|
|
2495
|
+
enum:
|
|
2496
|
+
- whitelist
|
|
2497
|
+
userIds:
|
|
2498
|
+
type: array
|
|
2499
|
+
items:
|
|
2500
|
+
type: string
|
|
2501
|
+
deviceIds:
|
|
2502
|
+
type: array
|
|
2503
|
+
items:
|
|
2504
|
+
type: string
|
|
2505
|
+
ips:
|
|
2506
|
+
type: array
|
|
2507
|
+
items:
|
|
2508
|
+
type: string
|
|
2509
|
+
- type: object
|
|
2510
|
+
properties:
|
|
2511
|
+
type:
|
|
2512
|
+
type: string
|
|
2513
|
+
enum:
|
|
2514
|
+
- blacklist
|
|
2515
|
+
userIds:
|
|
2516
|
+
type: array
|
|
2517
|
+
items:
|
|
2518
|
+
type: string
|
|
2519
|
+
deviceIds:
|
|
2520
|
+
type: array
|
|
2521
|
+
items:
|
|
2522
|
+
type: string
|
|
2523
|
+
ips:
|
|
2524
|
+
type: array
|
|
2525
|
+
items:
|
|
2526
|
+
type: string
|
|
2527
|
+
- type: object
|
|
2528
|
+
properties:
|
|
2529
|
+
type:
|
|
2530
|
+
type: string
|
|
2531
|
+
enum:
|
|
2532
|
+
- feature
|
|
2533
|
+
conditions:
|
|
2534
|
+
type: array
|
|
2535
|
+
items:
|
|
2536
|
+
type: object
|
|
2537
|
+
properties:
|
|
2538
|
+
field:
|
|
2539
|
+
type: string
|
|
2540
|
+
operator:
|
|
2541
|
+
type: string
|
|
2542
|
+
enum:
|
|
2543
|
+
- eq
|
|
2544
|
+
- ne
|
|
2545
|
+
- in
|
|
2546
|
+
- not_in
|
|
2547
|
+
- regex
|
|
2548
|
+
- contains
|
|
2549
|
+
- starts_with
|
|
2550
|
+
- ends_with
|
|
2551
|
+
value:
|
|
2552
|
+
$ref: '#/components/schemas/ConditionValue'
|
|
2553
|
+
logic:
|
|
2554
|
+
type: string
|
|
2555
|
+
enum:
|
|
2556
|
+
- and
|
|
2557
|
+
- or
|
|
2558
|
+
- type: object
|
|
2559
|
+
properties:
|
|
2560
|
+
type:
|
|
2561
|
+
type: string
|
|
2562
|
+
enum:
|
|
2563
|
+
- time_window
|
|
2564
|
+
startAt:
|
|
2565
|
+
type: string
|
|
2566
|
+
format: date-time
|
|
2567
|
+
endAt:
|
|
2568
|
+
type: string
|
|
2569
|
+
format: date-time
|
|
2570
|
+
timezone:
|
|
2571
|
+
type: string
|
|
2572
|
+
- type: object
|
|
2573
|
+
properties:
|
|
2574
|
+
type:
|
|
2575
|
+
type: string
|
|
2576
|
+
enum:
|
|
2577
|
+
- ab_test
|
|
2578
|
+
experimentId:
|
|
2579
|
+
type: string
|
|
2580
|
+
variantId:
|
|
2581
|
+
type: string
|
|
2582
|
+
variants:
|
|
2583
|
+
type: array
|
|
2584
|
+
items:
|
|
2585
|
+
type: object
|
|
2586
|
+
properties:
|
|
2587
|
+
id:
|
|
2588
|
+
type: string
|
|
2589
|
+
name:
|
|
2590
|
+
type: string
|
|
2591
|
+
weight:
|
|
2592
|
+
type: number
|
|
2593
|
+
pageVersionId:
|
|
2594
|
+
type: string
|
|
2595
|
+
- type: object
|
|
2596
|
+
properties:
|
|
2597
|
+
type:
|
|
2598
|
+
type: string
|
|
2599
|
+
enum:
|
|
2600
|
+
- canary
|
|
2601
|
+
stages:
|
|
2602
|
+
type: array
|
|
2603
|
+
items:
|
|
2604
|
+
type: object
|
|
2605
|
+
properties:
|
|
2606
|
+
name:
|
|
2607
|
+
type: string
|
|
2608
|
+
percentage:
|
|
2609
|
+
type: integer
|
|
2610
|
+
durationSeconds:
|
|
2611
|
+
type: integer
|
|
2612
|
+
requireApproval:
|
|
2613
|
+
type: boolean
|
|
2614
|
+
currentStageIndex:
|
|
2615
|
+
type: integer
|
|
2616
|
+
autoAdvance:
|
|
2617
|
+
type: object
|
|
2618
|
+
properties:
|
|
2619
|
+
enabled:
|
|
2620
|
+
type: boolean
|
|
2621
|
+
stageDurationSeconds:
|
|
2622
|
+
type: integer
|
|
2623
|
+
healthCheck:
|
|
2624
|
+
type: object
|
|
2625
|
+
properties:
|
|
2626
|
+
errorRateThreshold:
|
|
2627
|
+
type: number
|
|
2628
|
+
latencyThresholdMs:
|
|
2629
|
+
type: integer
|
|
2630
|
+
windowSeconds:
|
|
2631
|
+
type: integer
|
|
2632
|
+
persist:
|
|
2633
|
+
type: boolean
|
|
2634
|
+
description: 是否保存为持久化配置
|
|
2635
|
+
persistName:
|
|
2636
|
+
type: string
|
|
2637
|
+
description: 持久化时的策略名称
|
|
2638
|
+
persistPriority:
|
|
2639
|
+
type: integer
|
|
2640
|
+
description: 持久化时的优先级
|
|
2641
|
+
cdn:
|
|
2642
|
+
type: object
|
|
2643
|
+
description: CDN 配置(PublishCdnConfig)
|
|
2644
|
+
properties:
|
|
2645
|
+
refreshCache:
|
|
2646
|
+
type: boolean
|
|
2647
|
+
description: 是否刷新缓存
|
|
2648
|
+
warmupUrls:
|
|
2649
|
+
type: array
|
|
2650
|
+
items:
|
|
2651
|
+
type: string
|
|
2652
|
+
format: uri
|
|
2653
|
+
description: 预热 URL 列表
|
|
2654
|
+
priority:
|
|
2655
|
+
type: string
|
|
2656
|
+
enum:
|
|
2657
|
+
- high
|
|
2658
|
+
- normal
|
|
2659
|
+
- low
|
|
2660
|
+
description: 刷新优先级
|
|
2661
|
+
notification:
|
|
2662
|
+
type: object
|
|
2663
|
+
description: 发布通知配置(PublishNotificationConfig)
|
|
2664
|
+
properties:
|
|
2665
|
+
enabled:
|
|
2666
|
+
type: boolean
|
|
2667
|
+
description: 是否发送通知
|
|
2668
|
+
channels:
|
|
2669
|
+
type: array
|
|
2670
|
+
items:
|
|
2671
|
+
type: string
|
|
2672
|
+
enum:
|
|
2673
|
+
- email
|
|
2674
|
+
- webhook
|
|
2675
|
+
- slack
|
|
2676
|
+
- dingtalk
|
|
2677
|
+
description: 通知渠道
|
|
2678
|
+
recipients:
|
|
2679
|
+
type: array
|
|
2680
|
+
items:
|
|
2681
|
+
type: string
|
|
2682
|
+
description: 通知接收者
|
|
2683
|
+
webhookUrl:
|
|
2684
|
+
type: string
|
|
2685
|
+
format: uri
|
|
2686
|
+
description: Webhook URL
|
|
2687
|
+
skipValidation:
|
|
2688
|
+
type: boolean
|
|
2689
|
+
description: 是否跳过校验(仅开发环境有效)
|
|
2690
|
+
immediate:
|
|
2691
|
+
type: boolean
|
|
2692
|
+
description: 是否立即生效(false 时进入待发布状态)
|
|
2693
|
+
scheduledAt:
|
|
2694
|
+
type: string
|
|
2695
|
+
format: date-time
|
|
2696
|
+
description: 定时发布时间(immediate 为 false 时有效)
|
|
2697
|
+
versionUid:
|
|
2698
|
+
type: string
|
|
2699
|
+
maxLength: 32
|
|
2700
|
+
description: 指定发布的版本 UID(不传则使用当前页面最新内容,UniqueId)
|
|
3615
2701
|
PublishResponse:
|
|
3616
2702
|
type: object
|
|
3617
|
-
required:
|
|
3618
|
-
|
|
2703
|
+
required:
|
|
2704
|
+
- data
|
|
2705
|
+
properties:
|
|
2706
|
+
data:
|
|
2707
|
+
$ref: '#/components/schemas/VersionInfo'
|
|
3619
2708
|
RollbackRequest:
|
|
3620
2709
|
type: object
|
|
3621
|
-
required:
|
|
3622
|
-
|
|
2710
|
+
required:
|
|
2711
|
+
- targetVersion
|
|
2712
|
+
properties:
|
|
2713
|
+
targetVersion:
|
|
2714
|
+
type: string
|
|
2715
|
+
description: 目标版本 ID 或版本号
|
|
2716
|
+
reason:
|
|
2717
|
+
type: string
|
|
2718
|
+
maxLength: 1024
|
|
2719
|
+
description: 回滚原因
|
|
3623
2720
|
PreviewTokenInfo:
|
|
3624
2721
|
type: object
|
|
3625
|
-
required:
|
|
3626
|
-
|
|
2722
|
+
required:
|
|
2723
|
+
- token
|
|
2724
|
+
- pageId
|
|
2725
|
+
- expiresAt
|
|
2726
|
+
properties:
|
|
2727
|
+
token:
|
|
2728
|
+
type: string
|
|
2729
|
+
description: 预览 Token
|
|
2730
|
+
pageId:
|
|
2731
|
+
type: string
|
|
2732
|
+
description: 页面 ID
|
|
2733
|
+
draftVersion:
|
|
2734
|
+
type: string
|
|
2735
|
+
description: 草稿版本标识
|
|
2736
|
+
previewUrl:
|
|
2737
|
+
type: string
|
|
2738
|
+
format: uri
|
|
2739
|
+
description: 预览 URL
|
|
2740
|
+
deviceType:
|
|
2741
|
+
type: string
|
|
2742
|
+
enum:
|
|
2743
|
+
- mobile
|
|
2744
|
+
- tablet
|
|
2745
|
+
- desktop
|
|
2746
|
+
description: 预览设备类型
|
|
2747
|
+
context:
|
|
2748
|
+
type: object
|
|
2749
|
+
additionalProperties: true
|
|
2750
|
+
description: 预览上下文
|
|
2751
|
+
createdAt:
|
|
2752
|
+
type: string
|
|
2753
|
+
format: date-time
|
|
2754
|
+
description: 创建时间
|
|
2755
|
+
expiresAt:
|
|
2756
|
+
type: string
|
|
2757
|
+
format: date-time
|
|
2758
|
+
description: 过期时间
|
|
2759
|
+
createdBy:
|
|
2760
|
+
type: string
|
|
2761
|
+
description: 创建者 ID
|
|
3627
2762
|
ComponentInfo:
|
|
3628
2763
|
type: object
|
|
3629
|
-
required:
|
|
3630
|
-
|
|
2764
|
+
required:
|
|
2765
|
+
- id
|
|
2766
|
+
- name
|
|
2767
|
+
- category
|
|
2768
|
+
- status
|
|
2769
|
+
properties:
|
|
2770
|
+
id:
|
|
2771
|
+
type: string
|
|
2772
|
+
description: 组件 ID
|
|
2773
|
+
name:
|
|
2774
|
+
type: string
|
|
2775
|
+
description: 组件名称
|
|
2776
|
+
displayName:
|
|
2777
|
+
type: string
|
|
2778
|
+
description: 显示名称
|
|
2779
|
+
description:
|
|
2780
|
+
type: string
|
|
2781
|
+
description: 组件描述
|
|
2782
|
+
category:
|
|
2783
|
+
type: string
|
|
2784
|
+
description: 组件分类
|
|
2785
|
+
status:
|
|
2786
|
+
type: string
|
|
2787
|
+
enum:
|
|
2788
|
+
- active
|
|
2789
|
+
- deprecated
|
|
2790
|
+
- disabled
|
|
2791
|
+
description: 组件状态
|
|
2792
|
+
latestVersion:
|
|
2793
|
+
type: string
|
|
2794
|
+
description: 最新版本号
|
|
2795
|
+
icon:
|
|
2796
|
+
type: string
|
|
2797
|
+
description: 图标 URL
|
|
3631
2798
|
ComponentListResponse:
|
|
3632
2799
|
type: object
|
|
3633
|
-
required:
|
|
3634
|
-
|
|
2800
|
+
required:
|
|
2801
|
+
- data
|
|
2802
|
+
- meta
|
|
2803
|
+
properties:
|
|
2804
|
+
data:
|
|
2805
|
+
type: array
|
|
2806
|
+
items:
|
|
2807
|
+
$ref: '#/components/schemas/ComponentInfo'
|
|
2808
|
+
meta:
|
|
2809
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
3635
2810
|
ComponentVersionInfo:
|
|
3636
2811
|
type: object
|
|
3637
|
-
required:
|
|
3638
|
-
|
|
2812
|
+
required:
|
|
2813
|
+
- id
|
|
2814
|
+
- version
|
|
2815
|
+
- status
|
|
2816
|
+
- createdAt
|
|
2817
|
+
properties:
|
|
2818
|
+
id:
|
|
2819
|
+
type: string
|
|
2820
|
+
description: 版本 ID
|
|
2821
|
+
version:
|
|
2822
|
+
type: string
|
|
2823
|
+
pattern: ^\d+\.\d+\.\d+$
|
|
2824
|
+
description: 语义化版本号
|
|
2825
|
+
status:
|
|
2826
|
+
type: string
|
|
2827
|
+
enum:
|
|
2828
|
+
- active
|
|
2829
|
+
- deprecated
|
|
2830
|
+
- disabled
|
|
2831
|
+
description: 版本状态
|
|
2832
|
+
changelog:
|
|
2833
|
+
type: string
|
|
2834
|
+
description: 变更日志
|
|
2835
|
+
integrity:
|
|
2836
|
+
type: string
|
|
2837
|
+
description: 完整性哈希
|
|
2838
|
+
createdAt:
|
|
2839
|
+
type: string
|
|
2840
|
+
format: date-time
|
|
2841
|
+
description: 创建时间
|
|
3639
2842
|
ComponentVersionListResponse:
|
|
3640
2843
|
type: object
|
|
3641
|
-
required:
|
|
3642
|
-
|
|
2844
|
+
required:
|
|
2845
|
+
- data
|
|
2846
|
+
- meta
|
|
2847
|
+
properties:
|
|
2848
|
+
data:
|
|
2849
|
+
type: array
|
|
2850
|
+
items:
|
|
2851
|
+
$ref: '#/components/schemas/ComponentVersionInfo'
|
|
2852
|
+
meta:
|
|
2853
|
+
$ref: '#/components/schemas/PaginationMeta'
|
|
3643
2854
|
UpdateComponentStatusRequest:
|
|
3644
2855
|
type: object
|
|
3645
|
-
required:
|
|
3646
|
-
|
|
2856
|
+
required:
|
|
2857
|
+
- status
|
|
2858
|
+
properties:
|
|
2859
|
+
status:
|
|
2860
|
+
type: string
|
|
2861
|
+
enum:
|
|
2862
|
+
- active
|
|
2863
|
+
- deprecated
|
|
2864
|
+
- disabled
|
|
2865
|
+
description: 新状态
|
|
2866
|
+
reason:
|
|
2867
|
+
type: string
|
|
2868
|
+
maxLength: 1024
|
|
2869
|
+
description: 状态变更原因
|
|
3647
2870
|
ComponentVersionResponse:
|
|
3648
2871
|
type: object
|
|
3649
|
-
required:
|
|
3650
|
-
|
|
2872
|
+
required:
|
|
2873
|
+
- data
|
|
2874
|
+
properties:
|
|
2875
|
+
data:
|
|
2876
|
+
$ref: '#/components/schemas/ComponentVersionInfo'
|
|
2877
|
+
RolloutConfig:
|
|
2878
|
+
type: object
|
|
2879
|
+
properties:
|
|
2880
|
+
percentage:
|
|
2881
|
+
type: integer
|
|
2882
|
+
minimum: 0
|
|
2883
|
+
maximum: 100
|
|
2884
|
+
default: 100
|
|
2885
|
+
description: 灰度发布百分比
|
|
2886
|
+
targetGroups:
|
|
2887
|
+
type: array
|
|
2888
|
+
items:
|
|
2889
|
+
type: string
|
|
2890
|
+
description: 目标用户组
|
|
3651
2891
|
UpdateRolloutRequest:
|
|
3652
2892
|
type: object
|
|
3653
|
-
properties:
|
|
2893
|
+
properties:
|
|
2894
|
+
percentage:
|
|
2895
|
+
type: integer
|
|
2896
|
+
minimum: 0
|
|
2897
|
+
maximum: 100
|
|
2898
|
+
description: 灰度发布百分比
|
|
2899
|
+
targetGroups:
|
|
2900
|
+
type: array
|
|
2901
|
+
items:
|
|
2902
|
+
type: string
|
|
2903
|
+
description: 目标用户组
|
|
2904
|
+
enabled:
|
|
2905
|
+
type: boolean
|
|
2906
|
+
description: 是否启用
|
|
3654
2907
|
AddRolloutStrategyRequest:
|
|
3655
2908
|
type: object
|
|
3656
|
-
required:
|
|
3657
|
-
|
|
2909
|
+
required:
|
|
2910
|
+
- name
|
|
2911
|
+
- type
|
|
2912
|
+
- config
|
|
2913
|
+
properties:
|
|
2914
|
+
name:
|
|
2915
|
+
type: string
|
|
2916
|
+
minLength: 1
|
|
2917
|
+
maxLength: 255
|
|
2918
|
+
description: 策略名称
|
|
2919
|
+
type:
|
|
2920
|
+
type: string
|
|
2921
|
+
enum:
|
|
2922
|
+
- percentage
|
|
2923
|
+
- userGroup
|
|
2924
|
+
- feature
|
|
2925
|
+
- gradual
|
|
2926
|
+
description: 策略类型
|
|
2927
|
+
config:
|
|
2928
|
+
type: object
|
|
2929
|
+
additionalProperties: true
|
|
2930
|
+
description: 策略配置
|
|
2931
|
+
priority:
|
|
2932
|
+
type: integer
|
|
2933
|
+
minimum: 0
|
|
2934
|
+
description: 优先级
|
|
2935
|
+
enabled:
|
|
2936
|
+
type: boolean
|
|
2937
|
+
default: true
|
|
2938
|
+
description: 是否启用
|
|
3658
2939
|
RolloutStrategy:
|
|
3659
2940
|
type: object
|
|
3660
|
-
required:
|
|
3661
|
-
|
|
2941
|
+
required:
|
|
2942
|
+
- id
|
|
2943
|
+
- name
|
|
2944
|
+
- type
|
|
2945
|
+
- config
|
|
2946
|
+
properties:
|
|
2947
|
+
id:
|
|
2948
|
+
type: string
|
|
2949
|
+
description: 策略 ID
|
|
2950
|
+
name:
|
|
2951
|
+
type: string
|
|
2952
|
+
description: 策略名称
|
|
2953
|
+
type:
|
|
2954
|
+
type: string
|
|
2955
|
+
enum:
|
|
2956
|
+
- percentage
|
|
2957
|
+
- userGroup
|
|
2958
|
+
- feature
|
|
2959
|
+
- gradual
|
|
2960
|
+
description: 策略类型
|
|
2961
|
+
config:
|
|
2962
|
+
type: object
|
|
2963
|
+
additionalProperties: true
|
|
2964
|
+
description: 策略配置
|
|
2965
|
+
priority:
|
|
2966
|
+
type: integer
|
|
2967
|
+
minimum: 0
|
|
2968
|
+
description: 优先级
|
|
2969
|
+
enabled:
|
|
2970
|
+
type: boolean
|
|
2971
|
+
description: 是否启用
|
|
2972
|
+
createdAt:
|
|
2973
|
+
type: string
|
|
2974
|
+
format: date-time
|
|
2975
|
+
description: 创建时间
|
|
2976
|
+
updatedAt:
|
|
2977
|
+
type: string
|
|
2978
|
+
format: date-time
|
|
2979
|
+
description: 更新时间
|
|
3662
2980
|
UpdateRolloutStrategyRequest:
|
|
3663
2981
|
type: object
|
|
3664
|
-
properties:
|
|
2982
|
+
properties:
|
|
2983
|
+
name:
|
|
2984
|
+
type: string
|
|
2985
|
+
minLength: 1
|
|
2986
|
+
maxLength: 255
|
|
2987
|
+
description: 策略名称
|
|
2988
|
+
config:
|
|
2989
|
+
type: object
|
|
2990
|
+
additionalProperties: true
|
|
2991
|
+
description: 策略配置
|
|
2992
|
+
priority:
|
|
2993
|
+
type: integer
|
|
2994
|
+
minimum: 0
|
|
2995
|
+
description: 优先级
|
|
2996
|
+
enabled:
|
|
2997
|
+
type: boolean
|
|
2998
|
+
description: 是否启用
|
|
3665
2999
|
ActionDefinitionInfo:
|
|
3666
3000
|
type: object
|
|
3667
|
-
required:
|
|
3668
|
-
|
|
3001
|
+
required:
|
|
3002
|
+
- id
|
|
3003
|
+
- name
|
|
3004
|
+
- actionType
|
|
3005
|
+
- status
|
|
3006
|
+
- createdAt
|
|
3007
|
+
properties:
|
|
3008
|
+
id:
|
|
3009
|
+
type: string
|
|
3010
|
+
description: 定义 ID
|
|
3011
|
+
name:
|
|
3012
|
+
type: string
|
|
3013
|
+
description: 动作名称
|
|
3014
|
+
displayName:
|
|
3015
|
+
type: string
|
|
3016
|
+
description: 显示名称
|
|
3017
|
+
actionType:
|
|
3018
|
+
type: string
|
|
3019
|
+
enum:
|
|
3020
|
+
- claim
|
|
3021
|
+
- signin
|
|
3022
|
+
- lottery
|
|
3023
|
+
- reserve
|
|
3024
|
+
- bind
|
|
3025
|
+
- task_complete
|
|
3026
|
+
- vote
|
|
3027
|
+
- share
|
|
3028
|
+
- form_submit
|
|
3029
|
+
- custom
|
|
3030
|
+
description: 动作类型
|
|
3031
|
+
description:
|
|
3032
|
+
type: string
|
|
3033
|
+
description: 描述
|
|
3034
|
+
status:
|
|
3035
|
+
type: string
|
|
3036
|
+
enum:
|
|
3037
|
+
- draft
|
|
3038
|
+
- stable
|
|
3039
|
+
- deprecated
|
|
3040
|
+
- blocked
|
|
3041
|
+
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
3042
|
+
latestVersion:
|
|
3043
|
+
type: string
|
|
3044
|
+
description: 最新版本
|
|
3045
|
+
createdAt:
|
|
3046
|
+
type: string
|
|
3047
|
+
format: date-time
|
|
3048
|
+
description: 创建时间
|
|
3049
|
+
updatedAt:
|
|
3050
|
+
type: string
|
|
3051
|
+
format: date-time
|
|
3052
|
+
description: 更新时间
|
|
3669
3053
|
CreateActionDefinitionRequest:
|
|
3670
3054
|
type: object
|
|
3671
|
-
required:
|
|
3672
|
-
|
|
3055
|
+
required:
|
|
3056
|
+
- name
|
|
3057
|
+
- actionType
|
|
3058
|
+
properties:
|
|
3059
|
+
name:
|
|
3060
|
+
type: string
|
|
3061
|
+
minLength: 1
|
|
3062
|
+
maxLength: 255
|
|
3063
|
+
description: 动作名称
|
|
3064
|
+
displayName:
|
|
3065
|
+
type: string
|
|
3066
|
+
maxLength: 255
|
|
3067
|
+
description: 显示名称
|
|
3068
|
+
actionType:
|
|
3069
|
+
type: string
|
|
3070
|
+
enum:
|
|
3071
|
+
- claim
|
|
3072
|
+
- signin
|
|
3073
|
+
- lottery
|
|
3074
|
+
- reserve
|
|
3075
|
+
- bind
|
|
3076
|
+
- task_complete
|
|
3077
|
+
- vote
|
|
3078
|
+
- share
|
|
3079
|
+
- form_submit
|
|
3080
|
+
- custom
|
|
3081
|
+
description: 动作类型
|
|
3082
|
+
description:
|
|
3083
|
+
type: string
|
|
3084
|
+
maxLength: 1024
|
|
3085
|
+
description: 描述
|
|
3086
|
+
spec:
|
|
3087
|
+
type: object
|
|
3088
|
+
description: 动作规范定义
|
|
3673
3089
|
DefinitionVersionInfo:
|
|
3674
3090
|
type: object
|
|
3675
|
-
required:
|
|
3676
|
-
|
|
3091
|
+
required:
|
|
3092
|
+
- id
|
|
3093
|
+
- version
|
|
3094
|
+
- status
|
|
3095
|
+
- createdAt
|
|
3096
|
+
properties:
|
|
3097
|
+
id:
|
|
3098
|
+
type: string
|
|
3099
|
+
description: 版本 ID
|
|
3100
|
+
version:
|
|
3101
|
+
type: string
|
|
3102
|
+
pattern: ^\d+\.\d+\.\d+$
|
|
3103
|
+
description: 语义化版本号
|
|
3104
|
+
status:
|
|
3105
|
+
type: string
|
|
3106
|
+
enum:
|
|
3107
|
+
- draft
|
|
3108
|
+
- stable
|
|
3109
|
+
- deprecated
|
|
3110
|
+
- blocked
|
|
3111
|
+
description: 版本状态(状态机:draft → stable → deprecated → blocked)
|
|
3112
|
+
changelog:
|
|
3113
|
+
type: string
|
|
3114
|
+
description: 变更日志
|
|
3115
|
+
integrity:
|
|
3116
|
+
type: string
|
|
3117
|
+
description: 完整性哈希
|
|
3118
|
+
createdAt:
|
|
3119
|
+
type: string
|
|
3120
|
+
format: date-time
|
|
3121
|
+
description: 创建时间
|
|
3122
|
+
createdBy:
|
|
3123
|
+
type: string
|
|
3124
|
+
description: 创建者 ID
|
|
3677
3125
|
ActionDefinitionDetail:
|
|
3678
3126
|
type: object
|
|
3679
|
-
required:
|
|
3680
|
-
|
|
3127
|
+
required:
|
|
3128
|
+
- id
|
|
3129
|
+
- name
|
|
3130
|
+
- actionType
|
|
3131
|
+
- status
|
|
3132
|
+
- spec
|
|
3133
|
+
- createdAt
|
|
3134
|
+
properties:
|
|
3135
|
+
id:
|
|
3136
|
+
type: string
|
|
3137
|
+
description: 定义 ID
|
|
3138
|
+
name:
|
|
3139
|
+
type: string
|
|
3140
|
+
description: 动作名称
|
|
3141
|
+
displayName:
|
|
3142
|
+
type: string
|
|
3143
|
+
description: 显示名称
|
|
3144
|
+
actionType:
|
|
3145
|
+
type: string
|
|
3146
|
+
enum:
|
|
3147
|
+
- claim
|
|
3148
|
+
- signin
|
|
3149
|
+
- lottery
|
|
3150
|
+
- reserve
|
|
3151
|
+
- bind
|
|
3152
|
+
- task_complete
|
|
3153
|
+
- vote
|
|
3154
|
+
- share
|
|
3155
|
+
- form_submit
|
|
3156
|
+
- custom
|
|
3157
|
+
description: 动作类型
|
|
3158
|
+
description:
|
|
3159
|
+
type: string
|
|
3160
|
+
description: 描述
|
|
3161
|
+
status:
|
|
3162
|
+
type: string
|
|
3163
|
+
enum:
|
|
3164
|
+
- draft
|
|
3165
|
+
- stable
|
|
3166
|
+
- deprecated
|
|
3167
|
+
- blocked
|
|
3168
|
+
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
3169
|
+
spec:
|
|
3170
|
+
type: object
|
|
3171
|
+
description: 动作规范定义
|
|
3172
|
+
versions:
|
|
3173
|
+
type: array
|
|
3174
|
+
items:
|
|
3175
|
+
$ref: '#/components/schemas/DefinitionVersionInfo'
|
|
3176
|
+
description: 版本列表
|
|
3177
|
+
createdAt:
|
|
3178
|
+
type: string
|
|
3179
|
+
format: date-time
|
|
3180
|
+
description: 创建时间
|
|
3181
|
+
updatedAt:
|
|
3182
|
+
type: string
|
|
3183
|
+
format: date-time
|
|
3184
|
+
description: 更新时间
|
|
3681
3185
|
UpdateActionDefinitionRequest:
|
|
3682
3186
|
type: object
|
|
3683
|
-
properties:
|
|
3187
|
+
properties:
|
|
3188
|
+
displayName:
|
|
3189
|
+
type: string
|
|
3190
|
+
maxLength: 255
|
|
3191
|
+
description: 显示名称
|
|
3192
|
+
description:
|
|
3193
|
+
type: string
|
|
3194
|
+
maxLength: 1024
|
|
3195
|
+
description: 描述
|
|
3196
|
+
spec:
|
|
3197
|
+
type: object
|
|
3198
|
+
description: 动作规范定义
|
|
3199
|
+
status:
|
|
3200
|
+
type: string
|
|
3201
|
+
enum:
|
|
3202
|
+
- draft
|
|
3203
|
+
- stable
|
|
3204
|
+
- deprecated
|
|
3205
|
+
- blocked
|
|
3206
|
+
description: 状态
|
|
3684
3207
|
PublishDefinitionVersionRequest:
|
|
3685
3208
|
type: object
|
|
3686
|
-
properties:
|
|
3209
|
+
properties:
|
|
3210
|
+
changelog:
|
|
3211
|
+
type: string
|
|
3212
|
+
maxLength: 2048
|
|
3213
|
+
description: 变更日志
|
|
3214
|
+
versionBump:
|
|
3215
|
+
type: string
|
|
3216
|
+
enum:
|
|
3217
|
+
- major
|
|
3218
|
+
- minor
|
|
3219
|
+
- patch
|
|
3220
|
+
default: patch
|
|
3221
|
+
description: 版本号升级类型
|
|
3687
3222
|
DataQueryDefinitionInfo:
|
|
3688
3223
|
type: object
|
|
3689
|
-
required:
|
|
3690
|
-
|
|
3224
|
+
required:
|
|
3225
|
+
- id
|
|
3226
|
+
- name
|
|
3227
|
+
- sourceType
|
|
3228
|
+
- status
|
|
3229
|
+
- createdAt
|
|
3230
|
+
properties:
|
|
3231
|
+
id:
|
|
3232
|
+
type: string
|
|
3233
|
+
description: 定义 ID
|
|
3234
|
+
name:
|
|
3235
|
+
type: string
|
|
3236
|
+
description: 查询名称
|
|
3237
|
+
displayName:
|
|
3238
|
+
type: string
|
|
3239
|
+
description: 显示名称
|
|
3240
|
+
sourceType:
|
|
3241
|
+
type: string
|
|
3242
|
+
enum:
|
|
3243
|
+
- http
|
|
3244
|
+
- graphql
|
|
3245
|
+
- database
|
|
3246
|
+
- internal
|
|
3247
|
+
- aggregation
|
|
3248
|
+
description: 数据源类型
|
|
3249
|
+
description:
|
|
3250
|
+
type: string
|
|
3251
|
+
description: 描述
|
|
3252
|
+
status:
|
|
3253
|
+
type: string
|
|
3254
|
+
enum:
|
|
3255
|
+
- draft
|
|
3256
|
+
- stable
|
|
3257
|
+
- deprecated
|
|
3258
|
+
- blocked
|
|
3259
|
+
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
3260
|
+
latestVersion:
|
|
3261
|
+
type: string
|
|
3262
|
+
description: 最新版本
|
|
3263
|
+
createdAt:
|
|
3264
|
+
type: string
|
|
3265
|
+
format: date-time
|
|
3266
|
+
description: 创建时间
|
|
3267
|
+
updatedAt:
|
|
3268
|
+
type: string
|
|
3269
|
+
format: date-time
|
|
3270
|
+
description: 更新时间
|
|
3691
3271
|
CreateDataQueryDefinitionRequest:
|
|
3692
3272
|
type: object
|
|
3693
|
-
required:
|
|
3694
|
-
|
|
3273
|
+
required:
|
|
3274
|
+
- name
|
|
3275
|
+
- sourceType
|
|
3276
|
+
properties:
|
|
3277
|
+
name:
|
|
3278
|
+
type: string
|
|
3279
|
+
minLength: 1
|
|
3280
|
+
maxLength: 255
|
|
3281
|
+
description: 查询名称
|
|
3282
|
+
displayName:
|
|
3283
|
+
type: string
|
|
3284
|
+
maxLength: 255
|
|
3285
|
+
description: 显示名称
|
|
3286
|
+
sourceType:
|
|
3287
|
+
type: string
|
|
3288
|
+
enum:
|
|
3289
|
+
- http
|
|
3290
|
+
- graphql
|
|
3291
|
+
- database
|
|
3292
|
+
- internal
|
|
3293
|
+
- aggregation
|
|
3294
|
+
description: 数据源类型
|
|
3295
|
+
description:
|
|
3296
|
+
type: string
|
|
3297
|
+
maxLength: 1024
|
|
3298
|
+
description: 描述
|
|
3299
|
+
spec:
|
|
3300
|
+
type: object
|
|
3301
|
+
description: 查询规范定义
|
|
3695
3302
|
DataQueryDefinitionDetail:
|
|
3696
3303
|
type: object
|
|
3697
|
-
required:
|
|
3698
|
-
|
|
3304
|
+
required:
|
|
3305
|
+
- id
|
|
3306
|
+
- name
|
|
3307
|
+
- sourceType
|
|
3308
|
+
- status
|
|
3309
|
+
- spec
|
|
3310
|
+
- createdAt
|
|
3311
|
+
properties:
|
|
3312
|
+
id:
|
|
3313
|
+
type: string
|
|
3314
|
+
description: 定义 ID
|
|
3315
|
+
name:
|
|
3316
|
+
type: string
|
|
3317
|
+
description: 查询名称
|
|
3318
|
+
displayName:
|
|
3319
|
+
type: string
|
|
3320
|
+
description: 显示名称
|
|
3321
|
+
sourceType:
|
|
3322
|
+
type: string
|
|
3323
|
+
enum:
|
|
3324
|
+
- http
|
|
3325
|
+
- graphql
|
|
3326
|
+
- database
|
|
3327
|
+
- internal
|
|
3328
|
+
- aggregation
|
|
3329
|
+
description: 数据源类型
|
|
3330
|
+
description:
|
|
3331
|
+
type: string
|
|
3332
|
+
description: 描述
|
|
3333
|
+
status:
|
|
3334
|
+
type: string
|
|
3335
|
+
enum:
|
|
3336
|
+
- draft
|
|
3337
|
+
- stable
|
|
3338
|
+
- deprecated
|
|
3339
|
+
- blocked
|
|
3340
|
+
description: 状态(状态机:draft → stable → deprecated → blocked)
|
|
3341
|
+
spec:
|
|
3342
|
+
type: object
|
|
3343
|
+
description: 查询规范定义
|
|
3344
|
+
versions:
|
|
3345
|
+
type: array
|
|
3346
|
+
items:
|
|
3347
|
+
$ref: '#/components/schemas/DefinitionVersionInfo'
|
|
3348
|
+
description: 版本列表
|
|
3349
|
+
createdAt:
|
|
3350
|
+
type: string
|
|
3351
|
+
format: date-time
|
|
3352
|
+
description: 创建时间
|
|
3353
|
+
updatedAt:
|
|
3354
|
+
type: string
|
|
3355
|
+
format: date-time
|
|
3356
|
+
description: 更新时间
|
|
3699
3357
|
UpdateDataQueryDefinitionRequest:
|
|
3700
3358
|
type: object
|
|
3701
|
-
properties:
|
|
3359
|
+
properties:
|
|
3360
|
+
displayName:
|
|
3361
|
+
type: string
|
|
3362
|
+
maxLength: 255
|
|
3363
|
+
description: 显示名称
|
|
3364
|
+
description:
|
|
3365
|
+
type: string
|
|
3366
|
+
maxLength: 1024
|
|
3367
|
+
description: 描述
|
|
3368
|
+
spec:
|
|
3369
|
+
type: object
|
|
3370
|
+
description: 查询规范定义
|
|
3371
|
+
status:
|
|
3372
|
+
type: string
|
|
3373
|
+
enum:
|
|
3374
|
+
- draft
|
|
3375
|
+
- stable
|
|
3376
|
+
- deprecated
|
|
3377
|
+
- blocked
|
|
3378
|
+
description: 状态
|
|
3702
3379
|
ActivityInfo:
|
|
3703
3380
|
type: object
|
|
3704
|
-
required:
|
|
3705
|
-
|
|
3381
|
+
required:
|
|
3382
|
+
- id
|
|
3383
|
+
- appId
|
|
3384
|
+
- name
|
|
3385
|
+
- type
|
|
3386
|
+
- status
|
|
3387
|
+
- createdAt
|
|
3388
|
+
description: 活动信息(Activity,根据 types/src/activity/index.ts)
|
|
3389
|
+
properties:
|
|
3390
|
+
id:
|
|
3391
|
+
type: string
|
|
3392
|
+
description: 活动 ID(UniqueId)
|
|
3393
|
+
appId:
|
|
3394
|
+
type: string
|
|
3395
|
+
description: 应用 ID(UniqueId)
|
|
3396
|
+
name:
|
|
3397
|
+
type: string
|
|
3398
|
+
description: 活动名称
|
|
3399
|
+
description:
|
|
3400
|
+
type: string
|
|
3401
|
+
description: 活动描述
|
|
3402
|
+
type:
|
|
3403
|
+
type: string
|
|
3404
|
+
enum:
|
|
3405
|
+
- claim
|
|
3406
|
+
- signin
|
|
3407
|
+
- lottery
|
|
3408
|
+
- reserve
|
|
3409
|
+
- task
|
|
3410
|
+
- vote
|
|
3411
|
+
- share
|
|
3412
|
+
- bind
|
|
3413
|
+
- custom
|
|
3414
|
+
description: 活动类型(ActivityType)
|
|
3415
|
+
status:
|
|
3416
|
+
type: string
|
|
3417
|
+
enum:
|
|
3418
|
+
- draft
|
|
3419
|
+
- scheduled
|
|
3420
|
+
- active
|
|
3421
|
+
- paused
|
|
3422
|
+
- ended
|
|
3423
|
+
- archived
|
|
3424
|
+
description: 活动状态(ActivityStatus)
|
|
3425
|
+
createdAt:
|
|
3426
|
+
type: string
|
|
3427
|
+
format: date-time
|
|
3428
|
+
description: 创建时间(ISODateTime)
|
|
3429
|
+
updatedAt:
|
|
3430
|
+
type: string
|
|
3431
|
+
format: date-time
|
|
3432
|
+
description: 更新时间(ISODateTime)
|
|
3433
|
+
createdBy:
|
|
3434
|
+
type: string
|
|
3435
|
+
description: 创建者
|
|
3436
|
+
updatedBy:
|
|
3437
|
+
type: string
|
|
3438
|
+
description: 更新者
|
|
3706
3439
|
CreateActivityRequest:
|
|
3707
3440
|
type: object
|
|
3708
|
-
required:
|
|
3709
|
-
|
|
3441
|
+
required:
|
|
3442
|
+
- name
|
|
3443
|
+
- type
|
|
3444
|
+
- rule
|
|
3445
|
+
description: 创建活动请求(根据 types/src/activity/index.ts)
|
|
3446
|
+
properties:
|
|
3447
|
+
name:
|
|
3448
|
+
type: string
|
|
3449
|
+
minLength: 1
|
|
3450
|
+
maxLength: 255
|
|
3451
|
+
description: 活动名称
|
|
3452
|
+
type:
|
|
3453
|
+
type: string
|
|
3454
|
+
enum:
|
|
3455
|
+
- claim
|
|
3456
|
+
- signin
|
|
3457
|
+
- lottery
|
|
3458
|
+
- reserve
|
|
3459
|
+
- task
|
|
3460
|
+
- vote
|
|
3461
|
+
- share
|
|
3462
|
+
- bind
|
|
3463
|
+
- custom
|
|
3464
|
+
description: 活动类型(ActivityType)
|
|
3465
|
+
description:
|
|
3466
|
+
type: string
|
|
3467
|
+
maxLength: 1024
|
|
3468
|
+
description: 活动描述
|
|
3469
|
+
rule:
|
|
3470
|
+
type: object
|
|
3471
|
+
description: 活动规则(ActivityRule,根据 type 不同而不同)
|
|
3472
|
+
additionalProperties: true
|
|
3473
|
+
properties:
|
|
3474
|
+
startAt:
|
|
3475
|
+
type: string
|
|
3476
|
+
format: date-time
|
|
3477
|
+
description: 开始时间(ISODateTime)
|
|
3478
|
+
endAt:
|
|
3479
|
+
type: string
|
|
3480
|
+
format: date-time
|
|
3481
|
+
description: 结束时间(ISODateTime)
|
|
3482
|
+
timezone:
|
|
3483
|
+
type: string
|
|
3484
|
+
description: 时区
|
|
3485
|
+
requireAuth:
|
|
3486
|
+
type: boolean
|
|
3487
|
+
description: 是否要求登录
|
|
3488
|
+
participationLimit:
|
|
3489
|
+
type: object
|
|
3490
|
+
description: 参与次数限制(ParticipationLimit)
|
|
3491
|
+
properties:
|
|
3492
|
+
perUser:
|
|
3493
|
+
type: integer
|
|
3494
|
+
perUserPerDay:
|
|
3495
|
+
type: integer
|
|
3496
|
+
perUserPerWeek:
|
|
3497
|
+
type: integer
|
|
3498
|
+
global:
|
|
3499
|
+
type: integer
|
|
3500
|
+
globalPerDay:
|
|
3501
|
+
type: integer
|
|
3502
|
+
preconditions:
|
|
3503
|
+
type: array
|
|
3504
|
+
items:
|
|
3505
|
+
type: object
|
|
3506
|
+
properties:
|
|
3507
|
+
type:
|
|
3508
|
+
type: string
|
|
3509
|
+
enum:
|
|
3510
|
+
- user_level
|
|
3511
|
+
- membership
|
|
3512
|
+
- whitelist
|
|
3513
|
+
- prerequisite_activity
|
|
3514
|
+
- custom
|
|
3515
|
+
config:
|
|
3516
|
+
type: object
|
|
3517
|
+
additionalProperties: true
|
|
3518
|
+
errorMessage:
|
|
3519
|
+
type: string
|
|
3520
|
+
description: 前置条件(ActivityPrecondition[])
|
|
3710
3521
|
ActivityDetail:
|
|
3711
3522
|
type: object
|
|
3712
|
-
required:
|
|
3713
|
-
|
|
3523
|
+
required:
|
|
3524
|
+
- id
|
|
3525
|
+
- appId
|
|
3526
|
+
- name
|
|
3527
|
+
- type
|
|
3528
|
+
- rule
|
|
3529
|
+
- status
|
|
3530
|
+
- createdAt
|
|
3531
|
+
description: 活动详情(Activity,根据 types/src/activity/index.ts)
|
|
3532
|
+
properties:
|
|
3533
|
+
id:
|
|
3534
|
+
type: string
|
|
3535
|
+
description: 活动 ID(UniqueId)
|
|
3536
|
+
appId:
|
|
3537
|
+
type: string
|
|
3538
|
+
description: 应用 ID(UniqueId)
|
|
3539
|
+
name:
|
|
3540
|
+
type: string
|
|
3541
|
+
description: 活动名称
|
|
3542
|
+
description:
|
|
3543
|
+
type: string
|
|
3544
|
+
description: 活动描述
|
|
3545
|
+
type:
|
|
3546
|
+
type: string
|
|
3547
|
+
enum:
|
|
3548
|
+
- claim
|
|
3549
|
+
- signin
|
|
3550
|
+
- lottery
|
|
3551
|
+
- reserve
|
|
3552
|
+
- task
|
|
3553
|
+
- vote
|
|
3554
|
+
- share
|
|
3555
|
+
- bind
|
|
3556
|
+
- custom
|
|
3557
|
+
description: 活动类型(ActivityType)
|
|
3558
|
+
rule:
|
|
3559
|
+
type: object
|
|
3560
|
+
description: 活动规则(ActivityRule,联合类型:ClaimActivityRule | SigninActivityRule | LotteryActivityRule)
|
|
3561
|
+
additionalProperties: true
|
|
3562
|
+
status:
|
|
3563
|
+
type: string
|
|
3564
|
+
enum:
|
|
3565
|
+
- draft
|
|
3566
|
+
- scheduled
|
|
3567
|
+
- active
|
|
3568
|
+
- paused
|
|
3569
|
+
- ended
|
|
3570
|
+
- archived
|
|
3571
|
+
description: 活动状态(ActivityStatus)
|
|
3572
|
+
createdAt:
|
|
3573
|
+
type: string
|
|
3574
|
+
format: date-time
|
|
3575
|
+
description: 创建时间(ISODateTime)
|
|
3576
|
+
updatedAt:
|
|
3577
|
+
type: string
|
|
3578
|
+
format: date-time
|
|
3579
|
+
description: 更新时间(ISODateTime)
|
|
3580
|
+
createdBy:
|
|
3581
|
+
type: string
|
|
3582
|
+
description: 创建者
|
|
3583
|
+
updatedBy:
|
|
3584
|
+
type: string
|
|
3585
|
+
description: 更新者
|
|
3586
|
+
extensions:
|
|
3587
|
+
type: object
|
|
3588
|
+
additionalProperties: true
|
|
3589
|
+
description: 扩展数据(Record<string, unknown>)
|
|
3714
3590
|
UpdateActivityRequest:
|
|
3715
3591
|
type: object
|
|
3716
|
-
properties:
|
|
3592
|
+
properties:
|
|
3593
|
+
name:
|
|
3594
|
+
type: string
|
|
3595
|
+
minLength: 1
|
|
3596
|
+
maxLength: 255
|
|
3597
|
+
description: 活动名称
|
|
3598
|
+
description:
|
|
3599
|
+
type: string
|
|
3600
|
+
maxLength: 1024
|
|
3601
|
+
description: 活动描述
|
|
3602
|
+
config:
|
|
3603
|
+
type: object
|
|
3604
|
+
additionalProperties: true
|
|
3605
|
+
description: 活动配置
|
|
3606
|
+
rules:
|
|
3607
|
+
type: object
|
|
3608
|
+
additionalProperties: true
|
|
3609
|
+
description: 活动规则
|
|
3610
|
+
startTime:
|
|
3611
|
+
type: string
|
|
3612
|
+
format: date-time
|
|
3613
|
+
description: 开始时间
|
|
3614
|
+
endTime:
|
|
3615
|
+
type: string
|
|
3616
|
+
format: date-time
|
|
3617
|
+
description: 结束时间
|
|
3717
3618
|
ActivityStats:
|
|
3718
3619
|
type: object
|
|
3719
|
-
properties:
|
|
3620
|
+
properties:
|
|
3621
|
+
totalParticipants:
|
|
3622
|
+
type: integer
|
|
3623
|
+
description: 总参与人数
|
|
3624
|
+
todayParticipants:
|
|
3625
|
+
type: integer
|
|
3626
|
+
description: 今日参与人数
|
|
3627
|
+
totalRewards:
|
|
3628
|
+
type: integer
|
|
3629
|
+
description: 总发放奖励数
|
|
3630
|
+
todayRewards:
|
|
3631
|
+
type: integer
|
|
3632
|
+
description: 今日发放奖励数
|
|
3633
|
+
conversionRate:
|
|
3634
|
+
type: number
|
|
3635
|
+
format: float
|
|
3636
|
+
description: 转化率
|
|
3720
3637
|
AuditLogEntry:
|
|
3721
3638
|
type: object
|
|
3722
|
-
required:
|
|
3723
|
-
|
|
3639
|
+
required:
|
|
3640
|
+
- id
|
|
3641
|
+
- action
|
|
3642
|
+
- resource
|
|
3643
|
+
- timestamp
|
|
3644
|
+
properties:
|
|
3645
|
+
id:
|
|
3646
|
+
type: string
|
|
3647
|
+
description: 日志 ID
|
|
3648
|
+
action:
|
|
3649
|
+
type: string
|
|
3650
|
+
description: 操作类型
|
|
3651
|
+
resource:
|
|
3652
|
+
type: string
|
|
3653
|
+
description: 资源类型
|
|
3654
|
+
resourceId:
|
|
3655
|
+
type: string
|
|
3656
|
+
description: 资源 ID
|
|
3657
|
+
userId:
|
|
3658
|
+
type: string
|
|
3659
|
+
description: 操作用户 ID
|
|
3660
|
+
userName:
|
|
3661
|
+
type: string
|
|
3662
|
+
description: 操作用户名
|
|
3663
|
+
timestamp:
|
|
3664
|
+
type: string
|
|
3665
|
+
format: date-time
|
|
3666
|
+
description: 操作时间
|
|
3667
|
+
status:
|
|
3668
|
+
type: string
|
|
3669
|
+
enum:
|
|
3670
|
+
- success
|
|
3671
|
+
- failed
|
|
3672
|
+
description: 操作状态
|
|
3724
3673
|
AuditLogDetail:
|
|
3725
3674
|
type: object
|
|
3726
|
-
required:
|
|
3727
|
-
|
|
3675
|
+
required:
|
|
3676
|
+
- id
|
|
3677
|
+
- action
|
|
3678
|
+
- resource
|
|
3679
|
+
- timestamp
|
|
3680
|
+
properties:
|
|
3681
|
+
id:
|
|
3682
|
+
type: string
|
|
3683
|
+
description: 日志 ID
|
|
3684
|
+
action:
|
|
3685
|
+
type: string
|
|
3686
|
+
description: 操作类型
|
|
3687
|
+
resource:
|
|
3688
|
+
type: string
|
|
3689
|
+
description: 资源类型
|
|
3690
|
+
resourceId:
|
|
3691
|
+
type: string
|
|
3692
|
+
description: 资源 ID
|
|
3693
|
+
userId:
|
|
3694
|
+
type: string
|
|
3695
|
+
description: 操作用户 ID
|
|
3696
|
+
userName:
|
|
3697
|
+
type: string
|
|
3698
|
+
description: 操作用户名
|
|
3699
|
+
timestamp:
|
|
3700
|
+
type: string
|
|
3701
|
+
format: date-time
|
|
3702
|
+
description: 操作时间
|
|
3703
|
+
status:
|
|
3704
|
+
type: string
|
|
3705
|
+
enum:
|
|
3706
|
+
- success
|
|
3707
|
+
- failed
|
|
3708
|
+
description: 操作状态
|
|
3709
|
+
changes:
|
|
3710
|
+
type: object
|
|
3711
|
+
properties:
|
|
3712
|
+
before:
|
|
3713
|
+
type: object
|
|
3714
|
+
additionalProperties: true
|
|
3715
|
+
description: 变更前数据
|
|
3716
|
+
after:
|
|
3717
|
+
type: object
|
|
3718
|
+
additionalProperties: true
|
|
3719
|
+
description: 变更后数据
|
|
3720
|
+
metadata:
|
|
3721
|
+
type: object
|
|
3722
|
+
additionalProperties: true
|
|
3723
|
+
description: 元数据
|
|
3724
|
+
ipAddress:
|
|
3725
|
+
type: string
|
|
3726
|
+
description: IP 地址
|
|
3727
|
+
userAgent:
|
|
3728
|
+
type: string
|
|
3729
|
+
description: User Agent
|
|
3728
3730
|
AuditStats:
|
|
3729
3731
|
type: object
|
|
3730
|
-
properties:
|
|
3732
|
+
properties:
|
|
3733
|
+
totalLogs:
|
|
3734
|
+
type: integer
|
|
3735
|
+
description: 总日志数
|
|
3736
|
+
todayLogs:
|
|
3737
|
+
type: integer
|
|
3738
|
+
description: 今日日志数
|
|
3739
|
+
actionBreakdown:
|
|
3740
|
+
type: object
|
|
3741
|
+
additionalProperties:
|
|
3742
|
+
type: integer
|
|
3743
|
+
description: 按操作类型统计
|
|
3744
|
+
resourceBreakdown:
|
|
3745
|
+
type: object
|
|
3746
|
+
additionalProperties:
|
|
3747
|
+
type: integer
|
|
3748
|
+
description: 按资源类型统计
|
|
3731
3749
|
KillSwitchStatusResponse:
|
|
3732
3750
|
type: object
|
|
3733
|
-
required:
|
|
3734
|
-
|
|
3751
|
+
required:
|
|
3752
|
+
- data
|
|
3753
|
+
properties:
|
|
3754
|
+
data:
|
|
3755
|
+
type: object
|
|
3756
|
+
required:
|
|
3757
|
+
- enabled
|
|
3758
|
+
properties:
|
|
3759
|
+
enabled:
|
|
3760
|
+
type: boolean
|
|
3761
|
+
description: 是否启用全局 Kill Switch
|
|
3762
|
+
enabledAt:
|
|
3763
|
+
type: string
|
|
3764
|
+
format: date-time
|
|
3765
|
+
description: 启用时间
|
|
3766
|
+
enabledBy:
|
|
3767
|
+
type: string
|
|
3768
|
+
description: 启用者 ID
|
|
3769
|
+
reason:
|
|
3770
|
+
type: string
|
|
3771
|
+
description: 启用原因
|
|
3772
|
+
affectedPages:
|
|
3773
|
+
type: integer
|
|
3774
|
+
description: 受影响的页面数量
|
|
3735
3775
|
SetKillSwitchRequest:
|
|
3736
3776
|
type: object
|
|
3737
|
-
required:
|
|
3738
|
-
|
|
3777
|
+
required:
|
|
3778
|
+
- enabled
|
|
3779
|
+
properties:
|
|
3780
|
+
enabled:
|
|
3781
|
+
type: boolean
|
|
3782
|
+
description: 是否启用 Kill Switch
|
|
3783
|
+
reason:
|
|
3784
|
+
type: string
|
|
3785
|
+
maxLength: 1024
|
|
3786
|
+
description: 原因
|
|
3787
|
+
fallbackUrl:
|
|
3788
|
+
type: string
|
|
3789
|
+
format: uri
|
|
3790
|
+
description: 降级跳转 URL(仅页面级别)
|
|
3739
3791
|
PageKillSwitchStatusResponse:
|
|
3740
3792
|
type: object
|
|
3741
|
-
required:
|
|
3742
|
-
|
|
3793
|
+
required:
|
|
3794
|
+
- data
|
|
3795
|
+
properties:
|
|
3796
|
+
data:
|
|
3797
|
+
type: object
|
|
3798
|
+
required:
|
|
3799
|
+
- pageId
|
|
3800
|
+
- enabled
|
|
3801
|
+
properties:
|
|
3802
|
+
pageId:
|
|
3803
|
+
type: string
|
|
3804
|
+
description: 页面 ID
|
|
3805
|
+
enabled:
|
|
3806
|
+
type: boolean
|
|
3807
|
+
description: 是否启用 Kill Switch
|
|
3808
|
+
enabledAt:
|
|
3809
|
+
type: string
|
|
3810
|
+
format: date-time
|
|
3811
|
+
description: 启用时间
|
|
3812
|
+
enabledBy:
|
|
3813
|
+
type: string
|
|
3814
|
+
description: 启用者 ID
|
|
3815
|
+
reason:
|
|
3816
|
+
type: string
|
|
3817
|
+
description: 启用原因
|
|
3818
|
+
fallbackUrl:
|
|
3819
|
+
type: string
|
|
3820
|
+
format: uri
|
|
3821
|
+
description: 降级跳转 URL
|
|
3743
3822
|
HealthResponse:
|
|
3744
3823
|
type: object
|
|
3745
|
-
required:
|
|
3746
|
-
|
|
3824
|
+
required:
|
|
3825
|
+
- status
|
|
3826
|
+
- version
|
|
3827
|
+
properties:
|
|
3828
|
+
status:
|
|
3829
|
+
type: string
|
|
3830
|
+
enum:
|
|
3831
|
+
- healthy
|
|
3832
|
+
- degraded
|
|
3833
|
+
- unhealthy
|
|
3834
|
+
description: 服务状态
|
|
3835
|
+
version:
|
|
3836
|
+
type: string
|
|
3837
|
+
description: 服务版本
|
|
3838
|
+
uptime:
|
|
3839
|
+
type: integer
|
|
3840
|
+
description: 运行时间(秒)
|
|
3841
|
+
timestamp:
|
|
3842
|
+
type: string
|
|
3843
|
+
format: date-time
|
|
3844
|
+
description: 检查时间
|
|
3845
|
+
dependencies:
|
|
3846
|
+
type: object
|
|
3847
|
+
additionalProperties:
|
|
3848
|
+
type: object
|
|
3849
|
+
properties:
|
|
3850
|
+
status:
|
|
3851
|
+
type: string
|
|
3852
|
+
enum:
|
|
3853
|
+
- healthy
|
|
3854
|
+
- degraded
|
|
3855
|
+
- unhealthy
|
|
3856
|
+
latency:
|
|
3857
|
+
type: integer
|
|
3858
|
+
description: 延迟(毫秒)
|
|
3859
|
+
message:
|
|
3860
|
+
type: string
|
|
3861
|
+
description: 依赖服务状态
|
|
3862
|
+
ErrorDetail:
|
|
3863
|
+
type: object
|
|
3864
|
+
required:
|
|
3865
|
+
- message
|
|
3866
|
+
description: 错误详情(ApiErrorDetail,与 types/src/common/api.ts 保持一致)
|
|
3867
|
+
properties:
|
|
3868
|
+
field:
|
|
3869
|
+
type: string
|
|
3870
|
+
description: 字段路径(可选)
|
|
3871
|
+
message:
|
|
3872
|
+
type: string
|
|
3873
|
+
description: 错误消息(必填)
|
|
3874
|
+
code:
|
|
3875
|
+
type: string
|
|
3876
|
+
description: 错误码(可选)
|
|
3877
|
+
ComponentMeta:
|
|
3878
|
+
type: object
|
|
3879
|
+
description: |
|
|
3880
|
+
组件元数据(ComponentMeta)。完整定义与校验见 packages/schemas/schemas/component-meta.json 与 types/src/component/meta.ts。
|
|
3881
|
+
additionalProperties: true
|
|
3882
|
+
ErrorDetailList:
|
|
3883
|
+
type: array
|
|
3884
|
+
description: 验证错误时的 data(ApiErrorDetail[])
|
|
3885
|
+
items:
|
|
3886
|
+
$ref: '#/components/schemas/ErrorDetail'
|
|
3887
|
+
ErrorResponseData:
|
|
3888
|
+
type: object
|
|
3889
|
+
additionalProperties: true
|
|
3890
|
+
description: 错误响应数据(用于非验证错误场景,对应 unknown 类型)
|
|
3891
|
+
ErrorResponseDataObject:
|
|
3892
|
+
type: object
|
|
3893
|
+
description: 错误响应 data 的非数组分支(任意结构)
|
|
3894
|
+
properties:
|
|
3895
|
+
_:
|
|
3896
|
+
type: string
|
|
3897
|
+
description: 占位属性,确保生成器产出命名类型
|
|
3898
|
+
additionalProperties: true
|
|
3899
|
+
LockInfo:
|
|
3900
|
+
type: object
|
|
3901
|
+
properties:
|
|
3902
|
+
lockedBy:
|
|
3903
|
+
type: string
|
|
3904
|
+
description: 锁定者 ID
|
|
3905
|
+
lockedAt:
|
|
3906
|
+
type: string
|
|
3907
|
+
format: date-time
|
|
3908
|
+
description: 锁定时间
|
|
3909
|
+
expiresAt:
|
|
3910
|
+
type: string
|
|
3911
|
+
format: date-time
|
|
3912
|
+
description: 锁定过期时间
|
|
3747
3913
|
responses:
|
|
3748
3914
|
Unauthorized:
|
|
3749
3915
|
description: 未授权
|
|
3750
|
-
content:
|
|
3916
|
+
content:
|
|
3917
|
+
application/json:
|
|
3918
|
+
schema:
|
|
3919
|
+
$ref: '#/components/schemas/ErrorResponse'
|
|
3920
|
+
example:
|
|
3921
|
+
success: false
|
|
3922
|
+
code: AUTH_TOKEN_MISSING
|
|
3923
|
+
message: 请先登录
|
|
3924
|
+
timestamp: 1702300000000
|
|
3925
|
+
path: /api/admin/pages
|
|
3926
|
+
requestId: uuid-string
|
|
3751
3927
|
InternalError:
|
|
3752
3928
|
description: 服务器内部错误
|
|
3753
|
-
content:
|
|
3929
|
+
content:
|
|
3930
|
+
application/json:
|
|
3931
|
+
schema:
|
|
3932
|
+
$ref: '#/components/schemas/ErrorResponse'
|
|
3933
|
+
example:
|
|
3934
|
+
success: false
|
|
3935
|
+
code: SYSTEM_INTERNAL_ERROR
|
|
3936
|
+
message: 服务器内部错误,请稍后重试
|
|
3937
|
+
timestamp: 1702300000000
|
|
3938
|
+
path: /api/admin/pages
|
|
3939
|
+
requestId: uuid-string
|
|
3940
|
+
traceId: 00-4bf92f3577b34da6a3ce929d0e0e4736-00f067aa0ba902b7-01
|
|
3754
3941
|
BadRequest:
|
|
3755
3942
|
description: 请求参数错误
|
|
3756
|
-
content:
|
|
3943
|
+
content:
|
|
3944
|
+
application/json:
|
|
3945
|
+
schema:
|
|
3946
|
+
$ref: '#/components/schemas/ErrorResponse'
|
|
3947
|
+
example:
|
|
3948
|
+
success: false
|
|
3949
|
+
code: VALIDATION_INVALID_PARAMS
|
|
3950
|
+
message: 请求参数无效
|
|
3951
|
+
data:
|
|
3952
|
+
- field: title
|
|
3953
|
+
message: 标题不能为空
|
|
3954
|
+
code: REQUIRED
|
|
3955
|
+
timestamp: 1702300000000
|
|
3956
|
+
path: /api/admin/pages
|
|
3957
|
+
requestId: uuid-string
|
|
3757
3958
|
NotFound:
|
|
3758
3959
|
description: 资源不存在
|
|
3759
|
-
content:
|
|
3960
|
+
content:
|
|
3961
|
+
application/json:
|
|
3962
|
+
schema:
|
|
3963
|
+
$ref: '#/components/schemas/ErrorResponse'
|
|
3964
|
+
example:
|
|
3965
|
+
success: false
|
|
3966
|
+
code: RESOURCE_NOT_FOUND
|
|
3967
|
+
message: 资源不存在
|
|
3968
|
+
timestamp: 1702300000000
|
|
3969
|
+
path: /api/admin/pages/123
|
|
3970
|
+
requestId: uuid-string
|
|
3760
3971
|
Conflict:
|
|
3761
3972
|
description: 资源冲突
|
|
3762
|
-
content:
|
|
3973
|
+
content:
|
|
3974
|
+
application/json:
|
|
3975
|
+
schema:
|
|
3976
|
+
$ref: '#/components/schemas/ErrorResponse'
|
|
3977
|
+
example:
|
|
3978
|
+
success: false
|
|
3979
|
+
code: CONFLICT
|
|
3980
|
+
message: 资源已被其他用户修改,请刷新后重试
|
|
3981
|
+
timestamp: 1702300000000
|
|
3982
|
+
path: /api/admin/pages/123
|
|
3983
|
+
requestId: uuid-string
|
|
3763
3984
|
Forbidden:
|
|
3764
3985
|
description: 权限不足
|
|
3765
|
-
content:
|
|
3986
|
+
content:
|
|
3987
|
+
application/json:
|
|
3988
|
+
schema:
|
|
3989
|
+
$ref: '#/components/schemas/ErrorResponse'
|
|
3990
|
+
example:
|
|
3991
|
+
success: false
|
|
3992
|
+
code: PERMISSION_DENIED
|
|
3993
|
+
message: 您没有权限执行此操作
|
|
3994
|
+
timestamp: 1702300000000
|
|
3995
|
+
path: /api/admin/pages
|
|
3996
|
+
requestId: uuid-string
|
|
3766
3997
|
parameters:
|
|
3767
3998
|
PageParam:
|
|
3768
3999
|
name: page
|
|
3769
4000
|
in: query
|
|
3770
|
-
schema:
|
|
4001
|
+
schema:
|
|
4002
|
+
type: integer
|
|
4003
|
+
minimum: 1
|
|
4004
|
+
default: 1
|
|
3771
4005
|
description: 页码
|
|
3772
4006
|
LimitParam:
|
|
3773
4007
|
name: limit
|
|
3774
4008
|
in: query
|
|
3775
|
-
schema:
|
|
4009
|
+
schema:
|
|
4010
|
+
type: integer
|
|
4011
|
+
minimum: 1
|
|
4012
|
+
maximum: 100
|
|
4013
|
+
default: 20
|
|
3776
4014
|
description: 每页数量
|
|
3777
4015
|
PageIdPath:
|
|
3778
4016
|
name: pageId
|
|
3779
4017
|
in: path
|
|
3780
4018
|
required: true
|
|
3781
|
-
schema:
|
|
4019
|
+
schema:
|
|
4020
|
+
type: string
|
|
4021
|
+
minLength: 1
|
|
4022
|
+
maxLength: 128
|
|
3782
4023
|
description: 页面 ID
|
|
3783
4024
|
VersionIdPath:
|
|
3784
4025
|
name: versionId
|
|
3785
4026
|
in: path
|
|
3786
4027
|
required: true
|
|
3787
|
-
schema:
|
|
4028
|
+
schema:
|
|
4029
|
+
type: string
|
|
3788
4030
|
description: 版本 ID
|
|
3789
4031
|
ComponentIdPath:
|
|
3790
4032
|
name: componentId
|
|
3791
4033
|
in: path
|
|
3792
4034
|
required: true
|
|
3793
|
-
schema:
|
|
4035
|
+
schema:
|
|
4036
|
+
type: string
|
|
3794
4037
|
description: 组件 ID
|
|
3795
4038
|
securitySchemes:
|
|
3796
4039
|
BearerAuth:
|