@djvlc/openapi-admin-client 1.4.0 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +4328 -3566
- package/dist/index.d.ts +4328 -3566
- package/dist/index.js +16760 -4793
- package/dist/index.mjs +16702 -4436
- package/openapi/dist/admin-api.yaml +3168 -0
- package/openapi/src/components/parameters/_index.yaml +54 -0
- package/openapi/src/components/responses/_index.yaml +65 -0
- package/openapi/src/components/schemas/_index.yaml +1165 -0
- package/openapi/src/openapi.yaml +135 -0
- package/openapi/src/paths/activities.yaml +214 -0
- package/openapi/src/paths/audit.yaml +159 -0
- package/openapi/src/paths/components.yaml +88 -0
- package/openapi/src/paths/definitions.yaml +356 -0
- package/openapi/src/paths/drafts.yaml +71 -0
- package/openapi/src/paths/operations.yaml +99 -0
- package/openapi/src/paths/pages.yaml +126 -0
- package/openapi/src/paths/rollout.yaml +166 -0
- package/openapi/src/paths/versions.yaml +110 -0
- package/package.json +8 -7
|
@@ -0,0 +1,1165 @@
|
|
|
1
|
+
# Schema 组件索引
|
|
2
|
+
|
|
3
|
+
# ============================================================================
|
|
4
|
+
# 通用
|
|
5
|
+
# ============================================================================
|
|
6
|
+
|
|
7
|
+
PaginationMeta:
|
|
8
|
+
type: object
|
|
9
|
+
required: [page, limit, total, totalPages]
|
|
10
|
+
properties:
|
|
11
|
+
page:
|
|
12
|
+
type: integer
|
|
13
|
+
minimum: 1
|
|
14
|
+
description: 当前页码
|
|
15
|
+
limit:
|
|
16
|
+
type: integer
|
|
17
|
+
minimum: 1
|
|
18
|
+
maximum: 100
|
|
19
|
+
description: 每页数量
|
|
20
|
+
total:
|
|
21
|
+
type: integer
|
|
22
|
+
minimum: 0
|
|
23
|
+
description: 总记录数
|
|
24
|
+
totalPages:
|
|
25
|
+
type: integer
|
|
26
|
+
minimum: 0
|
|
27
|
+
description: 总页数
|
|
28
|
+
|
|
29
|
+
ErrorResponse:
|
|
30
|
+
type: object
|
|
31
|
+
required: [code, message]
|
|
32
|
+
properties:
|
|
33
|
+
code:
|
|
34
|
+
type: string
|
|
35
|
+
description: 错误码
|
|
36
|
+
message:
|
|
37
|
+
type: string
|
|
38
|
+
description: 错误消息
|
|
39
|
+
details:
|
|
40
|
+
type: array
|
|
41
|
+
items:
|
|
42
|
+
$ref: '#/ErrorDetail'
|
|
43
|
+
description: 错误详情
|
|
44
|
+
|
|
45
|
+
ErrorDetail:
|
|
46
|
+
type: object
|
|
47
|
+
properties:
|
|
48
|
+
field:
|
|
49
|
+
type: string
|
|
50
|
+
description: 字段名
|
|
51
|
+
message:
|
|
52
|
+
type: string
|
|
53
|
+
description: 字段错误信息
|
|
54
|
+
code:
|
|
55
|
+
type: string
|
|
56
|
+
description: 字段错误码
|
|
57
|
+
|
|
58
|
+
# ============================================================================
|
|
59
|
+
# 页面相关
|
|
60
|
+
# ============================================================================
|
|
61
|
+
|
|
62
|
+
PageInfo:
|
|
63
|
+
type: object
|
|
64
|
+
required: [id, title, status, createdAt, updatedAt]
|
|
65
|
+
properties:
|
|
66
|
+
id:
|
|
67
|
+
type: string
|
|
68
|
+
description: 页面 ID
|
|
69
|
+
title:
|
|
70
|
+
type: string
|
|
71
|
+
description: 页面标题
|
|
72
|
+
description:
|
|
73
|
+
type: string
|
|
74
|
+
description: 页面描述
|
|
75
|
+
status:
|
|
76
|
+
type: string
|
|
77
|
+
enum: [draft, published, archived]
|
|
78
|
+
description: 页面状态
|
|
79
|
+
tags:
|
|
80
|
+
type: array
|
|
81
|
+
items:
|
|
82
|
+
type: string
|
|
83
|
+
description: 标签
|
|
84
|
+
currentVersion:
|
|
85
|
+
type: string
|
|
86
|
+
description: 当前发布版本
|
|
87
|
+
createdAt:
|
|
88
|
+
type: string
|
|
89
|
+
format: date-time
|
|
90
|
+
description: 创建时间
|
|
91
|
+
updatedAt:
|
|
92
|
+
type: string
|
|
93
|
+
format: date-time
|
|
94
|
+
description: 更新时间
|
|
95
|
+
createdBy:
|
|
96
|
+
type: string
|
|
97
|
+
description: 创建者 ID
|
|
98
|
+
updatedBy:
|
|
99
|
+
type: string
|
|
100
|
+
description: 更新者 ID
|
|
101
|
+
|
|
102
|
+
PageListResponse:
|
|
103
|
+
type: object
|
|
104
|
+
required: [data, meta]
|
|
105
|
+
properties:
|
|
106
|
+
data:
|
|
107
|
+
type: array
|
|
108
|
+
items:
|
|
109
|
+
$ref: '#/PageInfo'
|
|
110
|
+
meta:
|
|
111
|
+
$ref: '#/PaginationMeta'
|
|
112
|
+
|
|
113
|
+
PageResponse:
|
|
114
|
+
type: object
|
|
115
|
+
required: [data]
|
|
116
|
+
properties:
|
|
117
|
+
data:
|
|
118
|
+
$ref: '#/PageInfo'
|
|
119
|
+
|
|
120
|
+
CreatePageRequest:
|
|
121
|
+
type: object
|
|
122
|
+
required: [title]
|
|
123
|
+
properties:
|
|
124
|
+
title:
|
|
125
|
+
type: string
|
|
126
|
+
minLength: 1
|
|
127
|
+
maxLength: 255
|
|
128
|
+
description: 页面标题
|
|
129
|
+
description:
|
|
130
|
+
type: string
|
|
131
|
+
maxLength: 1024
|
|
132
|
+
description: 页面描述
|
|
133
|
+
tags:
|
|
134
|
+
type: array
|
|
135
|
+
items:
|
|
136
|
+
type: string
|
|
137
|
+
description: 标签
|
|
138
|
+
templateId:
|
|
139
|
+
type: string
|
|
140
|
+
description: 模板 ID(可选,从模板创建)
|
|
141
|
+
|
|
142
|
+
UpdatePageRequest:
|
|
143
|
+
type: object
|
|
144
|
+
properties:
|
|
145
|
+
title:
|
|
146
|
+
type: string
|
|
147
|
+
minLength: 1
|
|
148
|
+
maxLength: 255
|
|
149
|
+
description: 页面标题
|
|
150
|
+
description:
|
|
151
|
+
type: string
|
|
152
|
+
maxLength: 1024
|
|
153
|
+
description: 页面描述
|
|
154
|
+
tags:
|
|
155
|
+
type: array
|
|
156
|
+
items:
|
|
157
|
+
type: string
|
|
158
|
+
description: 标签
|
|
159
|
+
|
|
160
|
+
# ============================================================================
|
|
161
|
+
# 草稿相关
|
|
162
|
+
# ============================================================================
|
|
163
|
+
|
|
164
|
+
DraftResponse:
|
|
165
|
+
type: object
|
|
166
|
+
required: [data]
|
|
167
|
+
properties:
|
|
168
|
+
data:
|
|
169
|
+
$ref: '#/DraftData'
|
|
170
|
+
|
|
171
|
+
DraftData:
|
|
172
|
+
type: object
|
|
173
|
+
required: [pageId, content, updatedAt]
|
|
174
|
+
properties:
|
|
175
|
+
pageId:
|
|
176
|
+
type: string
|
|
177
|
+
description: 页面 ID
|
|
178
|
+
content:
|
|
179
|
+
type: object
|
|
180
|
+
description: 页面 Schema 内容
|
|
181
|
+
baseVersion:
|
|
182
|
+
type: string
|
|
183
|
+
description: 基于的版本号
|
|
184
|
+
updatedAt:
|
|
185
|
+
type: string
|
|
186
|
+
format: date-time
|
|
187
|
+
description: 最后更新时间
|
|
188
|
+
updatedBy:
|
|
189
|
+
type: string
|
|
190
|
+
description: 最后更新者 ID
|
|
191
|
+
lockInfo:
|
|
192
|
+
$ref: '#/LockInfo'
|
|
193
|
+
|
|
194
|
+
LockInfo:
|
|
195
|
+
type: object
|
|
196
|
+
properties:
|
|
197
|
+
lockedBy:
|
|
198
|
+
type: string
|
|
199
|
+
description: 锁定者 ID
|
|
200
|
+
lockedAt:
|
|
201
|
+
type: string
|
|
202
|
+
format: date-time
|
|
203
|
+
description: 锁定时间
|
|
204
|
+
expiresAt:
|
|
205
|
+
type: string
|
|
206
|
+
format: date-time
|
|
207
|
+
description: 锁定过期时间
|
|
208
|
+
|
|
209
|
+
SaveDraftRequest:
|
|
210
|
+
type: object
|
|
211
|
+
required: [content]
|
|
212
|
+
properties:
|
|
213
|
+
content:
|
|
214
|
+
type: object
|
|
215
|
+
description: 页面 Schema 内容
|
|
216
|
+
baseVersion:
|
|
217
|
+
type: string
|
|
218
|
+
description: 基于的版本号(用于冲突检测)
|
|
219
|
+
force:
|
|
220
|
+
type: boolean
|
|
221
|
+
default: false
|
|
222
|
+
description: 是否强制保存(忽略冲突)
|
|
223
|
+
|
|
224
|
+
# ============================================================================
|
|
225
|
+
# 版本相关
|
|
226
|
+
# ============================================================================
|
|
227
|
+
|
|
228
|
+
VersionInfo:
|
|
229
|
+
type: object
|
|
230
|
+
required: [id, version, status, createdAt]
|
|
231
|
+
properties:
|
|
232
|
+
id:
|
|
233
|
+
type: string
|
|
234
|
+
description: 版本 ID
|
|
235
|
+
version:
|
|
236
|
+
type: string
|
|
237
|
+
pattern: '^\d+\.\d+\.\d+$'
|
|
238
|
+
description: 语义化版本号
|
|
239
|
+
status:
|
|
240
|
+
type: string
|
|
241
|
+
enum: [active, inactive, deprecated]
|
|
242
|
+
description: 版本状态
|
|
243
|
+
changelog:
|
|
244
|
+
type: string
|
|
245
|
+
description: 变更日志
|
|
246
|
+
integrity:
|
|
247
|
+
type: string
|
|
248
|
+
description: 完整性哈希
|
|
249
|
+
createdAt:
|
|
250
|
+
type: string
|
|
251
|
+
format: date-time
|
|
252
|
+
description: 创建时间
|
|
253
|
+
createdBy:
|
|
254
|
+
type: string
|
|
255
|
+
description: 创建者 ID
|
|
256
|
+
rolloutPercentage:
|
|
257
|
+
type: integer
|
|
258
|
+
minimum: 0
|
|
259
|
+
maximum: 100
|
|
260
|
+
description: 灰度发布百分比
|
|
261
|
+
|
|
262
|
+
VersionListResponse:
|
|
263
|
+
type: object
|
|
264
|
+
required: [data, meta]
|
|
265
|
+
properties:
|
|
266
|
+
data:
|
|
267
|
+
type: array
|
|
268
|
+
items:
|
|
269
|
+
$ref: '#/VersionInfo'
|
|
270
|
+
meta:
|
|
271
|
+
$ref: '#/PaginationMeta'
|
|
272
|
+
|
|
273
|
+
VersionResponse:
|
|
274
|
+
type: object
|
|
275
|
+
required: [data]
|
|
276
|
+
properties:
|
|
277
|
+
data:
|
|
278
|
+
allOf:
|
|
279
|
+
- $ref: '#/VersionInfo'
|
|
280
|
+
- type: object
|
|
281
|
+
properties:
|
|
282
|
+
content:
|
|
283
|
+
type: object
|
|
284
|
+
description: 页面 Schema 内容
|
|
285
|
+
|
|
286
|
+
PublishRequest:
|
|
287
|
+
type: object
|
|
288
|
+
properties:
|
|
289
|
+
changelog:
|
|
290
|
+
type: string
|
|
291
|
+
maxLength: 2048
|
|
292
|
+
description: 变更日志
|
|
293
|
+
versionBump:
|
|
294
|
+
type: string
|
|
295
|
+
enum: [major, minor, patch]
|
|
296
|
+
default: patch
|
|
297
|
+
description: 版本号升级类型
|
|
298
|
+
rollout:
|
|
299
|
+
$ref: '#/RolloutConfig'
|
|
300
|
+
|
|
301
|
+
RolloutConfig:
|
|
302
|
+
type: object
|
|
303
|
+
properties:
|
|
304
|
+
percentage:
|
|
305
|
+
type: integer
|
|
306
|
+
minimum: 0
|
|
307
|
+
maximum: 100
|
|
308
|
+
default: 100
|
|
309
|
+
description: 灰度发布百分比
|
|
310
|
+
targetGroups:
|
|
311
|
+
type: array
|
|
312
|
+
items:
|
|
313
|
+
type: string
|
|
314
|
+
description: 目标用户组
|
|
315
|
+
|
|
316
|
+
PublishResponse:
|
|
317
|
+
type: object
|
|
318
|
+
required: [data]
|
|
319
|
+
properties:
|
|
320
|
+
data:
|
|
321
|
+
$ref: '#/VersionInfo'
|
|
322
|
+
|
|
323
|
+
RollbackRequest:
|
|
324
|
+
type: object
|
|
325
|
+
required: [targetVersion]
|
|
326
|
+
properties:
|
|
327
|
+
targetVersion:
|
|
328
|
+
type: string
|
|
329
|
+
description: 目标版本 ID 或版本号
|
|
330
|
+
reason:
|
|
331
|
+
type: string
|
|
332
|
+
maxLength: 1024
|
|
333
|
+
description: 回滚原因
|
|
334
|
+
|
|
335
|
+
# ============================================================================
|
|
336
|
+
# 组件相关
|
|
337
|
+
# ============================================================================
|
|
338
|
+
|
|
339
|
+
ComponentInfo:
|
|
340
|
+
type: object
|
|
341
|
+
required: [id, name, category, status]
|
|
342
|
+
properties:
|
|
343
|
+
id:
|
|
344
|
+
type: string
|
|
345
|
+
description: 组件 ID
|
|
346
|
+
name:
|
|
347
|
+
type: string
|
|
348
|
+
description: 组件名称
|
|
349
|
+
displayName:
|
|
350
|
+
type: string
|
|
351
|
+
description: 显示名称
|
|
352
|
+
description:
|
|
353
|
+
type: string
|
|
354
|
+
description: 组件描述
|
|
355
|
+
category:
|
|
356
|
+
type: string
|
|
357
|
+
description: 组件分类
|
|
358
|
+
status:
|
|
359
|
+
type: string
|
|
360
|
+
enum: [active, deprecated, disabled]
|
|
361
|
+
description: 组件状态
|
|
362
|
+
latestVersion:
|
|
363
|
+
type: string
|
|
364
|
+
description: 最新版本号
|
|
365
|
+
icon:
|
|
366
|
+
type: string
|
|
367
|
+
description: 图标 URL
|
|
368
|
+
|
|
369
|
+
ComponentListResponse:
|
|
370
|
+
type: object
|
|
371
|
+
required: [data, meta]
|
|
372
|
+
properties:
|
|
373
|
+
data:
|
|
374
|
+
type: array
|
|
375
|
+
items:
|
|
376
|
+
$ref: '#/ComponentInfo'
|
|
377
|
+
meta:
|
|
378
|
+
$ref: '#/PaginationMeta'
|
|
379
|
+
|
|
380
|
+
ComponentVersionInfo:
|
|
381
|
+
type: object
|
|
382
|
+
required: [id, version, status, createdAt]
|
|
383
|
+
properties:
|
|
384
|
+
id:
|
|
385
|
+
type: string
|
|
386
|
+
description: 版本 ID
|
|
387
|
+
version:
|
|
388
|
+
type: string
|
|
389
|
+
pattern: '^\d+\.\d+\.\d+$'
|
|
390
|
+
description: 语义化版本号
|
|
391
|
+
status:
|
|
392
|
+
type: string
|
|
393
|
+
enum: [active, deprecated, disabled]
|
|
394
|
+
description: 版本状态
|
|
395
|
+
changelog:
|
|
396
|
+
type: string
|
|
397
|
+
description: 变更日志
|
|
398
|
+
integrity:
|
|
399
|
+
type: string
|
|
400
|
+
description: 完整性哈希
|
|
401
|
+
createdAt:
|
|
402
|
+
type: string
|
|
403
|
+
format: date-time
|
|
404
|
+
description: 创建时间
|
|
405
|
+
|
|
406
|
+
ComponentVersionListResponse:
|
|
407
|
+
type: object
|
|
408
|
+
required: [data, meta]
|
|
409
|
+
properties:
|
|
410
|
+
data:
|
|
411
|
+
type: array
|
|
412
|
+
items:
|
|
413
|
+
$ref: '#/ComponentVersionInfo'
|
|
414
|
+
meta:
|
|
415
|
+
$ref: '#/PaginationMeta'
|
|
416
|
+
|
|
417
|
+
ComponentVersionResponse:
|
|
418
|
+
type: object
|
|
419
|
+
required: [data]
|
|
420
|
+
properties:
|
|
421
|
+
data:
|
|
422
|
+
$ref: '#/ComponentVersionInfo'
|
|
423
|
+
|
|
424
|
+
UpdateComponentStatusRequest:
|
|
425
|
+
type: object
|
|
426
|
+
required: [status]
|
|
427
|
+
properties:
|
|
428
|
+
status:
|
|
429
|
+
type: string
|
|
430
|
+
enum: [active, deprecated, disabled]
|
|
431
|
+
description: 新状态
|
|
432
|
+
reason:
|
|
433
|
+
type: string
|
|
434
|
+
maxLength: 1024
|
|
435
|
+
description: 状态变更原因
|
|
436
|
+
|
|
437
|
+
# ============================================================================
|
|
438
|
+
# 运维相关
|
|
439
|
+
# ============================================================================
|
|
440
|
+
|
|
441
|
+
KillSwitchStatusResponse:
|
|
442
|
+
type: object
|
|
443
|
+
required: [data]
|
|
444
|
+
properties:
|
|
445
|
+
data:
|
|
446
|
+
type: object
|
|
447
|
+
required: [enabled]
|
|
448
|
+
properties:
|
|
449
|
+
enabled:
|
|
450
|
+
type: boolean
|
|
451
|
+
description: 是否启用全局 Kill Switch
|
|
452
|
+
enabledAt:
|
|
453
|
+
type: string
|
|
454
|
+
format: date-time
|
|
455
|
+
description: 启用时间
|
|
456
|
+
enabledBy:
|
|
457
|
+
type: string
|
|
458
|
+
description: 启用者 ID
|
|
459
|
+
reason:
|
|
460
|
+
type: string
|
|
461
|
+
description: 启用原因
|
|
462
|
+
affectedPages:
|
|
463
|
+
type: integer
|
|
464
|
+
description: 受影响的页面数量
|
|
465
|
+
|
|
466
|
+
PageKillSwitchStatusResponse:
|
|
467
|
+
type: object
|
|
468
|
+
required: [data]
|
|
469
|
+
properties:
|
|
470
|
+
data:
|
|
471
|
+
type: object
|
|
472
|
+
required: [pageId, enabled]
|
|
473
|
+
properties:
|
|
474
|
+
pageId:
|
|
475
|
+
type: string
|
|
476
|
+
description: 页面 ID
|
|
477
|
+
enabled:
|
|
478
|
+
type: boolean
|
|
479
|
+
description: 是否启用 Kill Switch
|
|
480
|
+
enabledAt:
|
|
481
|
+
type: string
|
|
482
|
+
format: date-time
|
|
483
|
+
description: 启用时间
|
|
484
|
+
enabledBy:
|
|
485
|
+
type: string
|
|
486
|
+
description: 启用者 ID
|
|
487
|
+
reason:
|
|
488
|
+
type: string
|
|
489
|
+
description: 启用原因
|
|
490
|
+
fallbackUrl:
|
|
491
|
+
type: string
|
|
492
|
+
format: uri
|
|
493
|
+
description: 降级跳转 URL
|
|
494
|
+
|
|
495
|
+
SetKillSwitchRequest:
|
|
496
|
+
type: object
|
|
497
|
+
required: [enabled]
|
|
498
|
+
properties:
|
|
499
|
+
enabled:
|
|
500
|
+
type: boolean
|
|
501
|
+
description: 是否启用 Kill Switch
|
|
502
|
+
reason:
|
|
503
|
+
type: string
|
|
504
|
+
maxLength: 1024
|
|
505
|
+
description: 原因
|
|
506
|
+
fallbackUrl:
|
|
507
|
+
type: string
|
|
508
|
+
format: uri
|
|
509
|
+
description: 降级跳转 URL(仅页面级别)
|
|
510
|
+
|
|
511
|
+
# ============================================================================
|
|
512
|
+
# Rollout 灰度发布相关
|
|
513
|
+
# ============================================================================
|
|
514
|
+
|
|
515
|
+
RolloutStrategy:
|
|
516
|
+
type: object
|
|
517
|
+
required: [id, name, type, config]
|
|
518
|
+
properties:
|
|
519
|
+
id:
|
|
520
|
+
type: string
|
|
521
|
+
description: 策略 ID
|
|
522
|
+
name:
|
|
523
|
+
type: string
|
|
524
|
+
description: 策略名称
|
|
525
|
+
type:
|
|
526
|
+
type: string
|
|
527
|
+
enum: [percentage, userGroup, feature, gradual]
|
|
528
|
+
description: 策略类型
|
|
529
|
+
config:
|
|
530
|
+
type: object
|
|
531
|
+
additionalProperties: true
|
|
532
|
+
description: 策略配置
|
|
533
|
+
priority:
|
|
534
|
+
type: integer
|
|
535
|
+
minimum: 0
|
|
536
|
+
description: 优先级
|
|
537
|
+
enabled:
|
|
538
|
+
type: boolean
|
|
539
|
+
description: 是否启用
|
|
540
|
+
createdAt:
|
|
541
|
+
type: string
|
|
542
|
+
format: date-time
|
|
543
|
+
description: 创建时间
|
|
544
|
+
updatedAt:
|
|
545
|
+
type: string
|
|
546
|
+
format: date-time
|
|
547
|
+
description: 更新时间
|
|
548
|
+
|
|
549
|
+
UpdateRolloutRequest:
|
|
550
|
+
type: object
|
|
551
|
+
properties:
|
|
552
|
+
percentage:
|
|
553
|
+
type: integer
|
|
554
|
+
minimum: 0
|
|
555
|
+
maximum: 100
|
|
556
|
+
description: 灰度发布百分比
|
|
557
|
+
targetGroups:
|
|
558
|
+
type: array
|
|
559
|
+
items:
|
|
560
|
+
type: string
|
|
561
|
+
description: 目标用户组
|
|
562
|
+
enabled:
|
|
563
|
+
type: boolean
|
|
564
|
+
description: 是否启用
|
|
565
|
+
|
|
566
|
+
AddRolloutStrategyRequest:
|
|
567
|
+
type: object
|
|
568
|
+
required: [name, type, config]
|
|
569
|
+
properties:
|
|
570
|
+
name:
|
|
571
|
+
type: string
|
|
572
|
+
minLength: 1
|
|
573
|
+
maxLength: 255
|
|
574
|
+
description: 策略名称
|
|
575
|
+
type:
|
|
576
|
+
type: string
|
|
577
|
+
enum: [percentage, userGroup, feature, gradual]
|
|
578
|
+
description: 策略类型
|
|
579
|
+
config:
|
|
580
|
+
type: object
|
|
581
|
+
additionalProperties: true
|
|
582
|
+
description: 策略配置
|
|
583
|
+
priority:
|
|
584
|
+
type: integer
|
|
585
|
+
minimum: 0
|
|
586
|
+
description: 优先级
|
|
587
|
+
enabled:
|
|
588
|
+
type: boolean
|
|
589
|
+
default: true
|
|
590
|
+
description: 是否启用
|
|
591
|
+
|
|
592
|
+
UpdateRolloutStrategyRequest:
|
|
593
|
+
type: object
|
|
594
|
+
properties:
|
|
595
|
+
name:
|
|
596
|
+
type: string
|
|
597
|
+
minLength: 1
|
|
598
|
+
maxLength: 255
|
|
599
|
+
description: 策略名称
|
|
600
|
+
config:
|
|
601
|
+
type: object
|
|
602
|
+
additionalProperties: true
|
|
603
|
+
description: 策略配置
|
|
604
|
+
priority:
|
|
605
|
+
type: integer
|
|
606
|
+
minimum: 0
|
|
607
|
+
description: 优先级
|
|
608
|
+
enabled:
|
|
609
|
+
type: boolean
|
|
610
|
+
description: 是否启用
|
|
611
|
+
|
|
612
|
+
# ============================================================================
|
|
613
|
+
# Action Definition 相关
|
|
614
|
+
# ============================================================================
|
|
615
|
+
|
|
616
|
+
ActionDefinitionInfo:
|
|
617
|
+
type: object
|
|
618
|
+
required: [id, name, type, status, createdAt]
|
|
619
|
+
properties:
|
|
620
|
+
id:
|
|
621
|
+
type: string
|
|
622
|
+
description: 定义 ID
|
|
623
|
+
name:
|
|
624
|
+
type: string
|
|
625
|
+
description: 动作名称
|
|
626
|
+
displayName:
|
|
627
|
+
type: string
|
|
628
|
+
description: 显示名称
|
|
629
|
+
type:
|
|
630
|
+
type: string
|
|
631
|
+
enum: [builtin, custom, http, script]
|
|
632
|
+
description: 动作类型
|
|
633
|
+
description:
|
|
634
|
+
type: string
|
|
635
|
+
description: 描述
|
|
636
|
+
status:
|
|
637
|
+
type: string
|
|
638
|
+
enum: [active, deprecated, disabled]
|
|
639
|
+
description: 状态
|
|
640
|
+
latestVersion:
|
|
641
|
+
type: string
|
|
642
|
+
description: 最新版本
|
|
643
|
+
createdAt:
|
|
644
|
+
type: string
|
|
645
|
+
format: date-time
|
|
646
|
+
description: 创建时间
|
|
647
|
+
updatedAt:
|
|
648
|
+
type: string
|
|
649
|
+
format: date-time
|
|
650
|
+
description: 更新时间
|
|
651
|
+
|
|
652
|
+
ActionDefinitionDetail:
|
|
653
|
+
type: object
|
|
654
|
+
required: [id, name, type, status, spec, createdAt]
|
|
655
|
+
properties:
|
|
656
|
+
id:
|
|
657
|
+
type: string
|
|
658
|
+
description: 定义 ID
|
|
659
|
+
name:
|
|
660
|
+
type: string
|
|
661
|
+
description: 动作名称
|
|
662
|
+
displayName:
|
|
663
|
+
type: string
|
|
664
|
+
description: 显示名称
|
|
665
|
+
type:
|
|
666
|
+
type: string
|
|
667
|
+
enum: [builtin, custom, http, script]
|
|
668
|
+
description: 动作类型
|
|
669
|
+
description:
|
|
670
|
+
type: string
|
|
671
|
+
description: 描述
|
|
672
|
+
status:
|
|
673
|
+
type: string
|
|
674
|
+
enum: [active, deprecated, disabled]
|
|
675
|
+
description: 状态
|
|
676
|
+
spec:
|
|
677
|
+
type: object
|
|
678
|
+
description: 动作规范定义
|
|
679
|
+
versions:
|
|
680
|
+
type: array
|
|
681
|
+
items:
|
|
682
|
+
$ref: '#/DefinitionVersionInfo'
|
|
683
|
+
description: 版本列表
|
|
684
|
+
createdAt:
|
|
685
|
+
type: string
|
|
686
|
+
format: date-time
|
|
687
|
+
description: 创建时间
|
|
688
|
+
updatedAt:
|
|
689
|
+
type: string
|
|
690
|
+
format: date-time
|
|
691
|
+
description: 更新时间
|
|
692
|
+
|
|
693
|
+
CreateActionDefinitionRequest:
|
|
694
|
+
type: object
|
|
695
|
+
required: [name, type]
|
|
696
|
+
properties:
|
|
697
|
+
name:
|
|
698
|
+
type: string
|
|
699
|
+
minLength: 1
|
|
700
|
+
maxLength: 255
|
|
701
|
+
description: 动作名称
|
|
702
|
+
displayName:
|
|
703
|
+
type: string
|
|
704
|
+
maxLength: 255
|
|
705
|
+
description: 显示名称
|
|
706
|
+
type:
|
|
707
|
+
type: string
|
|
708
|
+
enum: [builtin, custom, http, script]
|
|
709
|
+
description: 动作类型
|
|
710
|
+
description:
|
|
711
|
+
type: string
|
|
712
|
+
maxLength: 1024
|
|
713
|
+
description: 描述
|
|
714
|
+
spec:
|
|
715
|
+
type: object
|
|
716
|
+
description: 动作规范定义
|
|
717
|
+
|
|
718
|
+
UpdateActionDefinitionRequest:
|
|
719
|
+
type: object
|
|
720
|
+
properties:
|
|
721
|
+
displayName:
|
|
722
|
+
type: string
|
|
723
|
+
maxLength: 255
|
|
724
|
+
description: 显示名称
|
|
725
|
+
description:
|
|
726
|
+
type: string
|
|
727
|
+
maxLength: 1024
|
|
728
|
+
description: 描述
|
|
729
|
+
spec:
|
|
730
|
+
type: object
|
|
731
|
+
description: 动作规范定义
|
|
732
|
+
status:
|
|
733
|
+
type: string
|
|
734
|
+
enum: [active, deprecated, disabled]
|
|
735
|
+
description: 状态
|
|
736
|
+
|
|
737
|
+
# ============================================================================
|
|
738
|
+
# Definition Version 相关
|
|
739
|
+
# ============================================================================
|
|
740
|
+
|
|
741
|
+
DefinitionVersionInfo:
|
|
742
|
+
type: object
|
|
743
|
+
required: [id, version, status, createdAt]
|
|
744
|
+
properties:
|
|
745
|
+
id:
|
|
746
|
+
type: string
|
|
747
|
+
description: 版本 ID
|
|
748
|
+
version:
|
|
749
|
+
type: string
|
|
750
|
+
pattern: '^\d+\.\d+\.\d+$'
|
|
751
|
+
description: 语义化版本号
|
|
752
|
+
status:
|
|
753
|
+
type: string
|
|
754
|
+
enum: [active, deprecated, disabled]
|
|
755
|
+
description: 版本状态
|
|
756
|
+
changelog:
|
|
757
|
+
type: string
|
|
758
|
+
description: 变更日志
|
|
759
|
+
integrity:
|
|
760
|
+
type: string
|
|
761
|
+
description: 完整性哈希
|
|
762
|
+
createdAt:
|
|
763
|
+
type: string
|
|
764
|
+
format: date-time
|
|
765
|
+
description: 创建时间
|
|
766
|
+
createdBy:
|
|
767
|
+
type: string
|
|
768
|
+
description: 创建者 ID
|
|
769
|
+
|
|
770
|
+
PublishDefinitionVersionRequest:
|
|
771
|
+
type: object
|
|
772
|
+
properties:
|
|
773
|
+
changelog:
|
|
774
|
+
type: string
|
|
775
|
+
maxLength: 2048
|
|
776
|
+
description: 变更日志
|
|
777
|
+
versionBump:
|
|
778
|
+
type: string
|
|
779
|
+
enum: [major, minor, patch]
|
|
780
|
+
default: patch
|
|
781
|
+
description: 版本号升级类型
|
|
782
|
+
|
|
783
|
+
# ============================================================================
|
|
784
|
+
# Data Query Definition 相关
|
|
785
|
+
# ============================================================================
|
|
786
|
+
|
|
787
|
+
DataQueryDefinitionInfo:
|
|
788
|
+
type: object
|
|
789
|
+
required: [id, name, type, status, createdAt]
|
|
790
|
+
properties:
|
|
791
|
+
id:
|
|
792
|
+
type: string
|
|
793
|
+
description: 定义 ID
|
|
794
|
+
name:
|
|
795
|
+
type: string
|
|
796
|
+
description: 查询名称
|
|
797
|
+
displayName:
|
|
798
|
+
type: string
|
|
799
|
+
description: 显示名称
|
|
800
|
+
type:
|
|
801
|
+
type: string
|
|
802
|
+
enum: [http, graphql, sql, custom]
|
|
803
|
+
description: 查询类型
|
|
804
|
+
description:
|
|
805
|
+
type: string
|
|
806
|
+
description: 描述
|
|
807
|
+
status:
|
|
808
|
+
type: string
|
|
809
|
+
enum: [active, deprecated, disabled]
|
|
810
|
+
description: 状态
|
|
811
|
+
latestVersion:
|
|
812
|
+
type: string
|
|
813
|
+
description: 最新版本
|
|
814
|
+
createdAt:
|
|
815
|
+
type: string
|
|
816
|
+
format: date-time
|
|
817
|
+
description: 创建时间
|
|
818
|
+
updatedAt:
|
|
819
|
+
type: string
|
|
820
|
+
format: date-time
|
|
821
|
+
description: 更新时间
|
|
822
|
+
|
|
823
|
+
DataQueryDefinitionDetail:
|
|
824
|
+
type: object
|
|
825
|
+
required: [id, name, type, status, spec, createdAt]
|
|
826
|
+
properties:
|
|
827
|
+
id:
|
|
828
|
+
type: string
|
|
829
|
+
description: 定义 ID
|
|
830
|
+
name:
|
|
831
|
+
type: string
|
|
832
|
+
description: 查询名称
|
|
833
|
+
displayName:
|
|
834
|
+
type: string
|
|
835
|
+
description: 显示名称
|
|
836
|
+
type:
|
|
837
|
+
type: string
|
|
838
|
+
enum: [http, graphql, sql, custom]
|
|
839
|
+
description: 查询类型
|
|
840
|
+
description:
|
|
841
|
+
type: string
|
|
842
|
+
description: 描述
|
|
843
|
+
status:
|
|
844
|
+
type: string
|
|
845
|
+
enum: [active, deprecated, disabled]
|
|
846
|
+
description: 状态
|
|
847
|
+
spec:
|
|
848
|
+
type: object
|
|
849
|
+
description: 查询规范定义
|
|
850
|
+
versions:
|
|
851
|
+
type: array
|
|
852
|
+
items:
|
|
853
|
+
$ref: '#/DefinitionVersionInfo'
|
|
854
|
+
description: 版本列表
|
|
855
|
+
createdAt:
|
|
856
|
+
type: string
|
|
857
|
+
format: date-time
|
|
858
|
+
description: 创建时间
|
|
859
|
+
updatedAt:
|
|
860
|
+
type: string
|
|
861
|
+
format: date-time
|
|
862
|
+
description: 更新时间
|
|
863
|
+
|
|
864
|
+
CreateDataQueryDefinitionRequest:
|
|
865
|
+
type: object
|
|
866
|
+
required: [name, type]
|
|
867
|
+
properties:
|
|
868
|
+
name:
|
|
869
|
+
type: string
|
|
870
|
+
minLength: 1
|
|
871
|
+
maxLength: 255
|
|
872
|
+
description: 查询名称
|
|
873
|
+
displayName:
|
|
874
|
+
type: string
|
|
875
|
+
maxLength: 255
|
|
876
|
+
description: 显示名称
|
|
877
|
+
type:
|
|
878
|
+
type: string
|
|
879
|
+
enum: [http, graphql, sql, custom]
|
|
880
|
+
description: 查询类型
|
|
881
|
+
description:
|
|
882
|
+
type: string
|
|
883
|
+
maxLength: 1024
|
|
884
|
+
description: 描述
|
|
885
|
+
spec:
|
|
886
|
+
type: object
|
|
887
|
+
description: 查询规范定义
|
|
888
|
+
|
|
889
|
+
# ============================================================================
|
|
890
|
+
# Activity 营销活动相关
|
|
891
|
+
# ============================================================================
|
|
892
|
+
|
|
893
|
+
ActivityInfo:
|
|
894
|
+
type: object
|
|
895
|
+
required: [id, name, type, status, createdAt]
|
|
896
|
+
properties:
|
|
897
|
+
id:
|
|
898
|
+
type: string
|
|
899
|
+
description: 活动 ID
|
|
900
|
+
name:
|
|
901
|
+
type: string
|
|
902
|
+
description: 活动名称
|
|
903
|
+
type:
|
|
904
|
+
type: string
|
|
905
|
+
enum: [signin, lottery, redpack, coupon, custom]
|
|
906
|
+
description: 活动类型
|
|
907
|
+
status:
|
|
908
|
+
type: string
|
|
909
|
+
enum: [draft, scheduled, active, paused, ended]
|
|
910
|
+
description: 活动状态
|
|
911
|
+
startTime:
|
|
912
|
+
type: string
|
|
913
|
+
format: date-time
|
|
914
|
+
description: 开始时间
|
|
915
|
+
endTime:
|
|
916
|
+
type: string
|
|
917
|
+
format: date-time
|
|
918
|
+
description: 结束时间
|
|
919
|
+
createdAt:
|
|
920
|
+
type: string
|
|
921
|
+
format: date-time
|
|
922
|
+
description: 创建时间
|
|
923
|
+
updatedAt:
|
|
924
|
+
type: string
|
|
925
|
+
format: date-time
|
|
926
|
+
description: 更新时间
|
|
927
|
+
|
|
928
|
+
ActivityDetail:
|
|
929
|
+
type: object
|
|
930
|
+
required: [id, name, type, status, config, createdAt]
|
|
931
|
+
properties:
|
|
932
|
+
id:
|
|
933
|
+
type: string
|
|
934
|
+
description: 活动 ID
|
|
935
|
+
name:
|
|
936
|
+
type: string
|
|
937
|
+
description: 活动名称
|
|
938
|
+
type:
|
|
939
|
+
type: string
|
|
940
|
+
enum: [signin, lottery, redpack, coupon, custom]
|
|
941
|
+
description: 活动类型
|
|
942
|
+
status:
|
|
943
|
+
type: string
|
|
944
|
+
enum: [draft, scheduled, active, paused, ended]
|
|
945
|
+
description: 活动状态
|
|
946
|
+
description:
|
|
947
|
+
type: string
|
|
948
|
+
description: 活动描述
|
|
949
|
+
config:
|
|
950
|
+
type: object
|
|
951
|
+
additionalProperties: true
|
|
952
|
+
description: 活动配置
|
|
953
|
+
rules:
|
|
954
|
+
type: object
|
|
955
|
+
additionalProperties: true
|
|
956
|
+
description: 活动规则
|
|
957
|
+
startTime:
|
|
958
|
+
type: string
|
|
959
|
+
format: date-time
|
|
960
|
+
description: 开始时间
|
|
961
|
+
endTime:
|
|
962
|
+
type: string
|
|
963
|
+
format: date-time
|
|
964
|
+
description: 结束时间
|
|
965
|
+
createdAt:
|
|
966
|
+
type: string
|
|
967
|
+
format: date-time
|
|
968
|
+
description: 创建时间
|
|
969
|
+
updatedAt:
|
|
970
|
+
type: string
|
|
971
|
+
format: date-time
|
|
972
|
+
description: 更新时间
|
|
973
|
+
createdBy:
|
|
974
|
+
type: string
|
|
975
|
+
description: 创建者 ID
|
|
976
|
+
|
|
977
|
+
CreateActivityRequest:
|
|
978
|
+
type: object
|
|
979
|
+
required: [name, type]
|
|
980
|
+
properties:
|
|
981
|
+
name:
|
|
982
|
+
type: string
|
|
983
|
+
minLength: 1
|
|
984
|
+
maxLength: 255
|
|
985
|
+
description: 活动名称
|
|
986
|
+
type:
|
|
987
|
+
type: string
|
|
988
|
+
enum: [signin, lottery, redpack, coupon, custom]
|
|
989
|
+
description: 活动类型
|
|
990
|
+
description:
|
|
991
|
+
type: string
|
|
992
|
+
maxLength: 1024
|
|
993
|
+
description: 活动描述
|
|
994
|
+
config:
|
|
995
|
+
type: object
|
|
996
|
+
additionalProperties: true
|
|
997
|
+
description: 活动配置
|
|
998
|
+
rules:
|
|
999
|
+
type: object
|
|
1000
|
+
additionalProperties: true
|
|
1001
|
+
description: 活动规则
|
|
1002
|
+
startTime:
|
|
1003
|
+
type: string
|
|
1004
|
+
format: date-time
|
|
1005
|
+
description: 开始时间
|
|
1006
|
+
endTime:
|
|
1007
|
+
type: string
|
|
1008
|
+
format: date-time
|
|
1009
|
+
description: 结束时间
|
|
1010
|
+
|
|
1011
|
+
UpdateActivityRequest:
|
|
1012
|
+
type: object
|
|
1013
|
+
properties:
|
|
1014
|
+
name:
|
|
1015
|
+
type: string
|
|
1016
|
+
minLength: 1
|
|
1017
|
+
maxLength: 255
|
|
1018
|
+
description: 活动名称
|
|
1019
|
+
description:
|
|
1020
|
+
type: string
|
|
1021
|
+
maxLength: 1024
|
|
1022
|
+
description: 活动描述
|
|
1023
|
+
config:
|
|
1024
|
+
type: object
|
|
1025
|
+
additionalProperties: true
|
|
1026
|
+
description: 活动配置
|
|
1027
|
+
rules:
|
|
1028
|
+
type: object
|
|
1029
|
+
additionalProperties: true
|
|
1030
|
+
description: 活动规则
|
|
1031
|
+
startTime:
|
|
1032
|
+
type: string
|
|
1033
|
+
format: date-time
|
|
1034
|
+
description: 开始时间
|
|
1035
|
+
endTime:
|
|
1036
|
+
type: string
|
|
1037
|
+
format: date-time
|
|
1038
|
+
description: 结束时间
|
|
1039
|
+
|
|
1040
|
+
ActivityStats:
|
|
1041
|
+
type: object
|
|
1042
|
+
properties:
|
|
1043
|
+
totalParticipants:
|
|
1044
|
+
type: integer
|
|
1045
|
+
description: 总参与人数
|
|
1046
|
+
todayParticipants:
|
|
1047
|
+
type: integer
|
|
1048
|
+
description: 今日参与人数
|
|
1049
|
+
totalRewards:
|
|
1050
|
+
type: integer
|
|
1051
|
+
description: 总发放奖励数
|
|
1052
|
+
todayRewards:
|
|
1053
|
+
type: integer
|
|
1054
|
+
description: 今日发放奖励数
|
|
1055
|
+
conversionRate:
|
|
1056
|
+
type: number
|
|
1057
|
+
format: float
|
|
1058
|
+
description: 转化率
|
|
1059
|
+
|
|
1060
|
+
# ============================================================================
|
|
1061
|
+
# Audit 审计日志相关
|
|
1062
|
+
# ============================================================================
|
|
1063
|
+
|
|
1064
|
+
AuditLogEntry:
|
|
1065
|
+
type: object
|
|
1066
|
+
required: [id, action, resource, timestamp]
|
|
1067
|
+
properties:
|
|
1068
|
+
id:
|
|
1069
|
+
type: string
|
|
1070
|
+
description: 日志 ID
|
|
1071
|
+
action:
|
|
1072
|
+
type: string
|
|
1073
|
+
description: 操作类型
|
|
1074
|
+
resource:
|
|
1075
|
+
type: string
|
|
1076
|
+
description: 资源类型
|
|
1077
|
+
resourceId:
|
|
1078
|
+
type: string
|
|
1079
|
+
description: 资源 ID
|
|
1080
|
+
userId:
|
|
1081
|
+
type: string
|
|
1082
|
+
description: 操作用户 ID
|
|
1083
|
+
userName:
|
|
1084
|
+
type: string
|
|
1085
|
+
description: 操作用户名
|
|
1086
|
+
timestamp:
|
|
1087
|
+
type: string
|
|
1088
|
+
format: date-time
|
|
1089
|
+
description: 操作时间
|
|
1090
|
+
status:
|
|
1091
|
+
type: string
|
|
1092
|
+
enum: [success, failed]
|
|
1093
|
+
description: 操作状态
|
|
1094
|
+
|
|
1095
|
+
AuditLogDetail:
|
|
1096
|
+
type: object
|
|
1097
|
+
required: [id, action, resource, timestamp]
|
|
1098
|
+
properties:
|
|
1099
|
+
id:
|
|
1100
|
+
type: string
|
|
1101
|
+
description: 日志 ID
|
|
1102
|
+
action:
|
|
1103
|
+
type: string
|
|
1104
|
+
description: 操作类型
|
|
1105
|
+
resource:
|
|
1106
|
+
type: string
|
|
1107
|
+
description: 资源类型
|
|
1108
|
+
resourceId:
|
|
1109
|
+
type: string
|
|
1110
|
+
description: 资源 ID
|
|
1111
|
+
userId:
|
|
1112
|
+
type: string
|
|
1113
|
+
description: 操作用户 ID
|
|
1114
|
+
userName:
|
|
1115
|
+
type: string
|
|
1116
|
+
description: 操作用户名
|
|
1117
|
+
timestamp:
|
|
1118
|
+
type: string
|
|
1119
|
+
format: date-time
|
|
1120
|
+
description: 操作时间
|
|
1121
|
+
status:
|
|
1122
|
+
type: string
|
|
1123
|
+
enum: [success, failed]
|
|
1124
|
+
description: 操作状态
|
|
1125
|
+
changes:
|
|
1126
|
+
type: object
|
|
1127
|
+
properties:
|
|
1128
|
+
before:
|
|
1129
|
+
type: object
|
|
1130
|
+
additionalProperties: true
|
|
1131
|
+
description: 变更前数据
|
|
1132
|
+
after:
|
|
1133
|
+
type: object
|
|
1134
|
+
additionalProperties: true
|
|
1135
|
+
description: 变更后数据
|
|
1136
|
+
metadata:
|
|
1137
|
+
type: object
|
|
1138
|
+
additionalProperties: true
|
|
1139
|
+
description: 元数据
|
|
1140
|
+
ipAddress:
|
|
1141
|
+
type: string
|
|
1142
|
+
description: IP 地址
|
|
1143
|
+
userAgent:
|
|
1144
|
+
type: string
|
|
1145
|
+
description: User Agent
|
|
1146
|
+
|
|
1147
|
+
AuditStats:
|
|
1148
|
+
type: object
|
|
1149
|
+
properties:
|
|
1150
|
+
totalLogs:
|
|
1151
|
+
type: integer
|
|
1152
|
+
description: 总日志数
|
|
1153
|
+
todayLogs:
|
|
1154
|
+
type: integer
|
|
1155
|
+
description: 今日日志数
|
|
1156
|
+
actionBreakdown:
|
|
1157
|
+
type: object
|
|
1158
|
+
additionalProperties:
|
|
1159
|
+
type: integer
|
|
1160
|
+
description: 按操作类型统计
|
|
1161
|
+
resourceBreakdown:
|
|
1162
|
+
type: object
|
|
1163
|
+
additionalProperties:
|
|
1164
|
+
type: integer
|
|
1165
|
+
description: 按资源类型统计
|