@hubex/mcp 0.13.0 → 0.14.20261120

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.
@@ -0,0 +1,1303 @@
1
+ {
2
+ "openapi": "3.0.1",
3
+ "info": {
4
+ "title": "HubEx ONBRD API",
5
+ "description": "User onboarding service (#32241)",
6
+ "contact": {
7
+ "name": "SmartService Development Team",
8
+ "email": "fmbackend@melston.ru"
9
+ },
10
+ "version": "v1.0.0.0"
11
+ },
12
+ "servers": [
13
+ {
14
+ "url": "https://dev-api.hubex.ru/fsm/ONBRD"
15
+ }
16
+ ],
17
+ "paths": {
18
+ "/onboarding/status": {
19
+ "get": {
20
+ "tags": [
21
+ "UserOnboarding"
22
+ ],
23
+ "summary": "Получить статус онбординга текущего пользователя",
24
+ "description": "## Пример запроса:\r\n \r\nGET /onboarding/status?onboardingTypeId=1\r\n \r\n## Пример успешного ответа:\r\n```json\r\n{\r\n \"onboardingTypeID\": 1,\r\n \"onboardingState\": \"not_started\",\r\n \"isEnabled\": false,\r\n \"isSystemOnboardingEnabled\": false,\r\n \"isTenantOnboardingEnabled\": false\r\n}\r\n```\r\n \r\nПоля со значением null в ответ не попадают. Нет `progressJson` — прогресс пустой. Нет `isUserOnboardingEnabled` — личного флага нет, действует флаг тенанта.",
25
+ "parameters": [
26
+ {
27
+ "name": "onboardingTypeId",
28
+ "in": "query",
29
+ "description": "Идентификатор типа онбординга (1 — general, 2 — task, 3 — asset). По умолчанию 1",
30
+ "schema": {
31
+ "type": "integer",
32
+ "format": "int32",
33
+ "default": 1
34
+ }
35
+ },
36
+ {
37
+ "name": "X-Application-ID",
38
+ "in": "header",
39
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
40
+ "schema": {
41
+ "enum": [
42
+ 1,
43
+ 2,
44
+ 3,
45
+ 4,
46
+ 5,
47
+ 6
48
+ ],
49
+ "type": "integer",
50
+ "format": "int32",
51
+ "default": 3,
52
+ "x-enumNames": [
53
+ "EngineerMobile",
54
+ "CustomerMobile",
55
+ "MainWeb",
56
+ "AdminWeb",
57
+ "Api",
58
+ "PlateWeb"
59
+ ]
60
+ }
61
+ }
62
+ ],
63
+ "responses": {
64
+ "200": {
65
+ "description": "Статус успешно получен",
66
+ "content": {
67
+ "text/plain": {
68
+ "schema": {
69
+ "$ref": "#/components/schemas/UserOnboardingConfigDto"
70
+ }
71
+ },
72
+ "application/json": {
73
+ "schema": {
74
+ "$ref": "#/components/schemas/UserOnboardingConfigDto"
75
+ }
76
+ },
77
+ "text/json": {
78
+ "schema": {
79
+ "$ref": "#/components/schemas/UserOnboardingConfigDto"
80
+ }
81
+ }
82
+ }
83
+ },
84
+ "401": {
85
+ "description": "Пользователь тенанта не найден или недоступен",
86
+ "content": {
87
+ "text/plain": {
88
+ "schema": {
89
+ "$ref": "#/components/schemas/ErrorModel"
90
+ }
91
+ },
92
+ "application/json": {
93
+ "schema": {
94
+ "$ref": "#/components/schemas/ErrorModel"
95
+ }
96
+ },
97
+ "text/json": {
98
+ "schema": {
99
+ "$ref": "#/components/schemas/ErrorModel"
100
+ }
101
+ }
102
+ }
103
+ },
104
+ "409": {
105
+ "description": "Неверный тип онбординга",
106
+ "content": {
107
+ "text/plain": {
108
+ "schema": {
109
+ "$ref": "#/components/schemas/ErrorModel"
110
+ }
111
+ },
112
+ "application/json": {
113
+ "schema": {
114
+ "$ref": "#/components/schemas/ErrorModel"
115
+ }
116
+ },
117
+ "text/json": {
118
+ "schema": {
119
+ "$ref": "#/components/schemas/ErrorModel"
120
+ }
121
+ }
122
+ }
123
+ },
124
+ "403": {
125
+ "description": "Forbidden"
126
+ }
127
+ }
128
+ }
129
+ },
130
+ "/onboarding/flags": {
131
+ "get": {
132
+ "tags": [
133
+ "UserOnboarding"
134
+ ],
135
+ "summary": "Получить флаги включения онбординга",
136
+ "description": "## Пример запроса:\r\n \r\nGET /onboarding/flags?onboardingTypeId=1\r\n \r\n## Пример успешного ответа:\r\n```json\r\n{\r\n \"onboardingTypeID\": 1,\r\n \"userID\": 42,\r\n \"isSystemOnboardingEnabled\": false,\r\n \"isTenantOnboardingEnabled\": true,\r\n \"isEnabled\": true\r\n}\r\n```\r\n \r\nНет `isUserOnboardingEnabled` — личного флага нет, `isEnabled` считается по флагу тенанта.",
137
+ "parameters": [
138
+ {
139
+ "name": "onboardingTypeId",
140
+ "in": "query",
141
+ "description": "Идентификатор типа онбординга. По умолчанию 1",
142
+ "schema": {
143
+ "type": "integer",
144
+ "format": "int32",
145
+ "default": 1
146
+ }
147
+ },
148
+ {
149
+ "name": "X-Application-ID",
150
+ "in": "header",
151
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
152
+ "schema": {
153
+ "enum": [
154
+ 1,
155
+ 2,
156
+ 3,
157
+ 4,
158
+ 5,
159
+ 6
160
+ ],
161
+ "type": "integer",
162
+ "format": "int32",
163
+ "default": 3,
164
+ "x-enumNames": [
165
+ "EngineerMobile",
166
+ "CustomerMobile",
167
+ "MainWeb",
168
+ "AdminWeb",
169
+ "Api",
170
+ "PlateWeb"
171
+ ]
172
+ }
173
+ }
174
+ ],
175
+ "responses": {
176
+ "200": {
177
+ "description": "Флаги успешно получены",
178
+ "content": {
179
+ "text/plain": {
180
+ "schema": {
181
+ "$ref": "#/components/schemas/OnboardingConfigDto"
182
+ }
183
+ },
184
+ "application/json": {
185
+ "schema": {
186
+ "$ref": "#/components/schemas/OnboardingConfigDto"
187
+ }
188
+ },
189
+ "text/json": {
190
+ "schema": {
191
+ "$ref": "#/components/schemas/OnboardingConfigDto"
192
+ }
193
+ }
194
+ }
195
+ },
196
+ "401": {
197
+ "description": "Пользователь тенанта не найден или недоступен",
198
+ "content": {
199
+ "text/plain": {
200
+ "schema": {
201
+ "$ref": "#/components/schemas/ErrorModel"
202
+ }
203
+ },
204
+ "application/json": {
205
+ "schema": {
206
+ "$ref": "#/components/schemas/ErrorModel"
207
+ }
208
+ },
209
+ "text/json": {
210
+ "schema": {
211
+ "$ref": "#/components/schemas/ErrorModel"
212
+ }
213
+ }
214
+ }
215
+ },
216
+ "409": {
217
+ "description": "Неверный тип онбординга",
218
+ "content": {
219
+ "text/plain": {
220
+ "schema": {
221
+ "$ref": "#/components/schemas/ErrorModel"
222
+ }
223
+ },
224
+ "application/json": {
225
+ "schema": {
226
+ "$ref": "#/components/schemas/ErrorModel"
227
+ }
228
+ },
229
+ "text/json": {
230
+ "schema": {
231
+ "$ref": "#/components/schemas/ErrorModel"
232
+ }
233
+ }
234
+ }
235
+ },
236
+ "403": {
237
+ "description": "Forbidden"
238
+ }
239
+ }
240
+ }
241
+ },
242
+ "/onboarding/progress": {
243
+ "put": {
244
+ "tags": [
245
+ "UserOnboarding"
246
+ ],
247
+ "summary": "Сохранить прогресс онбординга",
248
+ "description": "## Пример запроса:\r\n \r\nPUT /onboarding/progress?onboardingTypeId=1\r\n \r\n```json\r\n{\r\n \"onboardingState\": \"in_progress\",\r\n \"progress\": {\r\n \"currentStepId\": \"welcome\",\r\n \"completedStepIds\": [],\r\n \"schemaVersion\": \"1\"\r\n }\r\n}\r\n```\r\n \r\n## Пример успешного ответа:\r\n```json\r\n{\r\n \"onboardingTypeID\": 1,\r\n \"onboardingState\": \"in_progress\",\r\n \"progressJson\": \"{\\\"currentStepId\\\":\\\"welcome\\\",\\\"completedStepIds\\\":[],\\\"schemaVersion\\\":\\\"1\\\"}\"\r\n}\r\n```",
249
+ "parameters": [
250
+ {
251
+ "name": "onboardingTypeId",
252
+ "in": "query",
253
+ "description": "Идентификатор типа онбординга. По умолчанию 1",
254
+ "schema": {
255
+ "type": "integer",
256
+ "format": "int32",
257
+ "default": 1
258
+ }
259
+ },
260
+ {
261
+ "name": "X-Application-ID",
262
+ "in": "header",
263
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
264
+ "schema": {
265
+ "enum": [
266
+ 1,
267
+ 2,
268
+ 3,
269
+ 4,
270
+ 5,
271
+ 6
272
+ ],
273
+ "type": "integer",
274
+ "format": "int32",
275
+ "default": 3,
276
+ "x-enumNames": [
277
+ "EngineerMobile",
278
+ "CustomerMobile",
279
+ "MainWeb",
280
+ "AdminWeb",
281
+ "Api",
282
+ "PlateWeb"
283
+ ]
284
+ }
285
+ }
286
+ ],
287
+ "requestBody": {
288
+ "description": "Состояние и JSON прогресса",
289
+ "content": {
290
+ "application/json-patch+json": {
291
+ "schema": {
292
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
293
+ }
294
+ },
295
+ "application/json": {
296
+ "schema": {
297
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
298
+ }
299
+ },
300
+ "text/json": {
301
+ "schema": {
302
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
303
+ }
304
+ },
305
+ "application/*+json": {
306
+ "schema": {
307
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
308
+ }
309
+ }
310
+ }
311
+ },
312
+ "responses": {
313
+ "200": {
314
+ "description": "Прогресс успешно сохранён",
315
+ "content": {
316
+ "text/plain": {
317
+ "schema": {
318
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
319
+ }
320
+ },
321
+ "application/json": {
322
+ "schema": {
323
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
324
+ }
325
+ },
326
+ "text/json": {
327
+ "schema": {
328
+ "$ref": "#/components/schemas/UserOnboardingProgressDto"
329
+ }
330
+ }
331
+ }
332
+ },
333
+ "400": {
334
+ "description": "Неверное тело запроса",
335
+ "content": {
336
+ "text/plain": {
337
+ "schema": {
338
+ "$ref": "#/components/schemas/ErrorModel"
339
+ }
340
+ },
341
+ "application/json": {
342
+ "schema": {
343
+ "$ref": "#/components/schemas/ErrorModel"
344
+ }
345
+ },
346
+ "text/json": {
347
+ "schema": {
348
+ "$ref": "#/components/schemas/ErrorModel"
349
+ }
350
+ }
351
+ }
352
+ },
353
+ "401": {
354
+ "description": "Пользователь тенанта не найден или недоступен",
355
+ "content": {
356
+ "text/plain": {
357
+ "schema": {
358
+ "$ref": "#/components/schemas/ErrorModel"
359
+ }
360
+ },
361
+ "application/json": {
362
+ "schema": {
363
+ "$ref": "#/components/schemas/ErrorModel"
364
+ }
365
+ },
366
+ "text/json": {
367
+ "schema": {
368
+ "$ref": "#/components/schemas/ErrorModel"
369
+ }
370
+ }
371
+ }
372
+ },
373
+ "409": {
374
+ "description": "Онбординг уже завершён или пропущен, либо неверные данные",
375
+ "content": {
376
+ "text/plain": {
377
+ "schema": {
378
+ "$ref": "#/components/schemas/ErrorModel"
379
+ }
380
+ },
381
+ "application/json": {
382
+ "schema": {
383
+ "$ref": "#/components/schemas/ErrorModel"
384
+ }
385
+ },
386
+ "text/json": {
387
+ "schema": {
388
+ "$ref": "#/components/schemas/ErrorModel"
389
+ }
390
+ }
391
+ }
392
+ },
393
+ "403": {
394
+ "description": "Forbidden"
395
+ }
396
+ }
397
+ }
398
+ },
399
+ "/onboarding/skip": {
400
+ "post": {
401
+ "tags": [
402
+ "UserOnboarding"
403
+ ],
404
+ "summary": "Пропустить онбординг",
405
+ "description": "## Пример запроса:\r\n \r\nPOST /onboarding/skip?onboardingTypeId=1\r\n \r\n## Пример успешного ответа:\r\n```json\r\n{\r\n \"onboardingTypeID\": 1,\r\n \"onboardingState\": \"skipped\"\r\n}\r\n```",
406
+ "parameters": [
407
+ {
408
+ "name": "onboardingTypeId",
409
+ "in": "query",
410
+ "description": "Идентификатор типа онбординга. По умолчанию 1",
411
+ "schema": {
412
+ "type": "integer",
413
+ "format": "int32",
414
+ "default": 1
415
+ }
416
+ },
417
+ {
418
+ "name": "X-Application-ID",
419
+ "in": "header",
420
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
421
+ "schema": {
422
+ "enum": [
423
+ 1,
424
+ 2,
425
+ 3,
426
+ 4,
427
+ 5,
428
+ 6
429
+ ],
430
+ "type": "integer",
431
+ "format": "int32",
432
+ "default": 3,
433
+ "x-enumNames": [
434
+ "EngineerMobile",
435
+ "CustomerMobile",
436
+ "MainWeb",
437
+ "AdminWeb",
438
+ "Api",
439
+ "PlateWeb"
440
+ ]
441
+ }
442
+ }
443
+ ],
444
+ "responses": {
445
+ "200": {
446
+ "description": "Онбординг успешно пропущен",
447
+ "content": {
448
+ "text/plain": {
449
+ "schema": {
450
+ "$ref": "#/components/schemas/UserOnboardingStateResultDto"
451
+ }
452
+ },
453
+ "application/json": {
454
+ "schema": {
455
+ "$ref": "#/components/schemas/UserOnboardingStateResultDto"
456
+ }
457
+ },
458
+ "text/json": {
459
+ "schema": {
460
+ "$ref": "#/components/schemas/UserOnboardingStateResultDto"
461
+ }
462
+ }
463
+ }
464
+ },
465
+ "401": {
466
+ "description": "Пользователь тенанта не найден или недоступен",
467
+ "content": {
468
+ "text/plain": {
469
+ "schema": {
470
+ "$ref": "#/components/schemas/ErrorModel"
471
+ }
472
+ },
473
+ "application/json": {
474
+ "schema": {
475
+ "$ref": "#/components/schemas/ErrorModel"
476
+ }
477
+ },
478
+ "text/json": {
479
+ "schema": {
480
+ "$ref": "#/components/schemas/ErrorModel"
481
+ }
482
+ }
483
+ }
484
+ },
485
+ "409": {
486
+ "description": "Онбординг уже завершён или пропущен",
487
+ "content": {
488
+ "text/plain": {
489
+ "schema": {
490
+ "$ref": "#/components/schemas/ErrorModel"
491
+ }
492
+ },
493
+ "application/json": {
494
+ "schema": {
495
+ "$ref": "#/components/schemas/ErrorModel"
496
+ }
497
+ },
498
+ "text/json": {
499
+ "schema": {
500
+ "$ref": "#/components/schemas/ErrorModel"
501
+ }
502
+ }
503
+ }
504
+ },
505
+ "403": {
506
+ "description": "Forbidden"
507
+ }
508
+ }
509
+ }
510
+ },
511
+ "/onboarding/reset": {
512
+ "post": {
513
+ "tags": [
514
+ "UserOnboarding"
515
+ ],
516
+ "summary": "Сбросить прогресс онбординга пользователя",
517
+ "description": "## Пример запроса:\r\n \r\nPOST /onboarding/reset?userId=42&onboardingTypeId=1\r\n \r\n## Пример успешного ответа:\r\n```json\r\n{\r\n \"onboardingTypeID\": 1,\r\n \"userID\": 42,\r\n \"onboardingState\": \"not_started\"\r\n}\r\n```",
518
+ "parameters": [
519
+ {
520
+ "name": "userId",
521
+ "in": "query",
522
+ "description": "Идентификатор пользователя (ADM.User), для которого выполняется сброс",
523
+ "schema": {
524
+ "type": "integer",
525
+ "format": "int32"
526
+ }
527
+ },
528
+ {
529
+ "name": "onboardingTypeId",
530
+ "in": "query",
531
+ "description": "Идентификатор типа онбординга. По умолчанию 1",
532
+ "schema": {
533
+ "type": "integer",
534
+ "format": "int32",
535
+ "default": 1
536
+ }
537
+ },
538
+ {
539
+ "name": "X-Application-ID",
540
+ "in": "header",
541
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
542
+ "schema": {
543
+ "enum": [
544
+ 1,
545
+ 2,
546
+ 3,
547
+ 4,
548
+ 5,
549
+ 6
550
+ ],
551
+ "type": "integer",
552
+ "format": "int32",
553
+ "default": 3,
554
+ "x-enumNames": [
555
+ "EngineerMobile",
556
+ "CustomerMobile",
557
+ "MainWeb",
558
+ "AdminWeb",
559
+ "Api",
560
+ "PlateWeb"
561
+ ]
562
+ }
563
+ }
564
+ ],
565
+ "responses": {
566
+ "200": {
567
+ "description": "Прогресс успешно сброшен",
568
+ "content": {
569
+ "text/plain": {
570
+ "schema": {
571
+ "$ref": "#/components/schemas/UserOnboardingResetResultDto"
572
+ }
573
+ },
574
+ "application/json": {
575
+ "schema": {
576
+ "$ref": "#/components/schemas/UserOnboardingResetResultDto"
577
+ }
578
+ },
579
+ "text/json": {
580
+ "schema": {
581
+ "$ref": "#/components/schemas/UserOnboardingResetResultDto"
582
+ }
583
+ }
584
+ }
585
+ },
586
+ "401": {
587
+ "description": "Пользователь тенанта не найден или недоступен",
588
+ "content": {
589
+ "text/plain": {
590
+ "schema": {
591
+ "$ref": "#/components/schemas/ErrorModel"
592
+ }
593
+ },
594
+ "application/json": {
595
+ "schema": {
596
+ "$ref": "#/components/schemas/ErrorModel"
597
+ }
598
+ },
599
+ "text/json": {
600
+ "schema": {
601
+ "$ref": "#/components/schemas/ErrorModel"
602
+ }
603
+ }
604
+ }
605
+ },
606
+ "403": {
607
+ "description": "Недостаточно прав или пользователь не найден",
608
+ "content": {
609
+ "text/plain": {
610
+ "schema": {
611
+ "$ref": "#/components/schemas/ErrorModel"
612
+ }
613
+ },
614
+ "application/json": {
615
+ "schema": {
616
+ "$ref": "#/components/schemas/ErrorModel"
617
+ }
618
+ },
619
+ "text/json": {
620
+ "schema": {
621
+ "$ref": "#/components/schemas/ErrorModel"
622
+ }
623
+ }
624
+ }
625
+ },
626
+ "409": {
627
+ "description": "Неверный тип онбординга",
628
+ "content": {
629
+ "text/plain": {
630
+ "schema": {
631
+ "$ref": "#/components/schemas/ErrorModel"
632
+ }
633
+ },
634
+ "application/json": {
635
+ "schema": {
636
+ "$ref": "#/components/schemas/ErrorModel"
637
+ }
638
+ },
639
+ "text/json": {
640
+ "schema": {
641
+ "$ref": "#/components/schemas/ErrorModel"
642
+ }
643
+ }
644
+ }
645
+ }
646
+ }
647
+ }
648
+ },
649
+ "/onboarding/flags/tenant": {
650
+ "put": {
651
+ "tags": [
652
+ "UserOnboarding"
653
+ ],
654
+ "summary": "Обновить флаг включения онбординга на уровне тенанта",
655
+ "description": "## Пример запроса:\r\n \r\nPUT /onboarding/flags/tenant?onboardingTypeId=1\r\n \r\n```json\r\ntrue\r\n```\r\n \r\n## Пример успешного ответа:\r\n```json\r\ntrue\r\n```",
656
+ "parameters": [
657
+ {
658
+ "name": "onboardingTypeId",
659
+ "in": "query",
660
+ "description": "Идентификатор типа онбординга. По умолчанию 1",
661
+ "schema": {
662
+ "type": "integer",
663
+ "format": "int32",
664
+ "default": 1
665
+ }
666
+ },
667
+ {
668
+ "name": "X-Application-ID",
669
+ "in": "header",
670
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
671
+ "schema": {
672
+ "enum": [
673
+ 1,
674
+ 2,
675
+ 3,
676
+ 4,
677
+ 5,
678
+ 6
679
+ ],
680
+ "type": "integer",
681
+ "format": "int32",
682
+ "default": 3,
683
+ "x-enumNames": [
684
+ "EngineerMobile",
685
+ "CustomerMobile",
686
+ "MainWeb",
687
+ "AdminWeb",
688
+ "Api",
689
+ "PlateWeb"
690
+ ]
691
+ }
692
+ }
693
+ ],
694
+ "requestBody": {
695
+ "content": {
696
+ "application/json-patch+json": {
697
+ "schema": {
698
+ "type": "boolean"
699
+ }
700
+ },
701
+ "application/json": {
702
+ "schema": {
703
+ "type": "boolean"
704
+ }
705
+ },
706
+ "text/json": {
707
+ "schema": {
708
+ "type": "boolean"
709
+ }
710
+ },
711
+ "application/*+json": {
712
+ "schema": {
713
+ "type": "boolean"
714
+ }
715
+ }
716
+ }
717
+ },
718
+ "responses": {
719
+ "200": {
720
+ "description": "Флаг успешно обновлён",
721
+ "content": {
722
+ "text/plain": {
723
+ "schema": {
724
+ "type": "boolean"
725
+ }
726
+ },
727
+ "application/json": {
728
+ "schema": {
729
+ "type": "boolean"
730
+ }
731
+ },
732
+ "text/json": {
733
+ "schema": {
734
+ "type": "boolean"
735
+ }
736
+ }
737
+ }
738
+ },
739
+ "400": {
740
+ "description": "Неверное тело запроса",
741
+ "content": {
742
+ "text/plain": {
743
+ "schema": {
744
+ "$ref": "#/components/schemas/ErrorModel"
745
+ }
746
+ },
747
+ "application/json": {
748
+ "schema": {
749
+ "$ref": "#/components/schemas/ErrorModel"
750
+ }
751
+ },
752
+ "text/json": {
753
+ "schema": {
754
+ "$ref": "#/components/schemas/ErrorModel"
755
+ }
756
+ }
757
+ }
758
+ },
759
+ "401": {
760
+ "description": "Пользователь тенанта или тенант не найден",
761
+ "content": {
762
+ "text/plain": {
763
+ "schema": {
764
+ "$ref": "#/components/schemas/ErrorModel"
765
+ }
766
+ },
767
+ "application/json": {
768
+ "schema": {
769
+ "$ref": "#/components/schemas/ErrorModel"
770
+ }
771
+ },
772
+ "text/json": {
773
+ "schema": {
774
+ "$ref": "#/components/schemas/ErrorModel"
775
+ }
776
+ }
777
+ }
778
+ },
779
+ "403": {
780
+ "description": "Недостаточно прав для изменения флага онбординга тенанта",
781
+ "content": {
782
+ "text/plain": {
783
+ "schema": {
784
+ "$ref": "#/components/schemas/ErrorModel"
785
+ }
786
+ },
787
+ "application/json": {
788
+ "schema": {
789
+ "$ref": "#/components/schemas/ErrorModel"
790
+ }
791
+ },
792
+ "text/json": {
793
+ "schema": {
794
+ "$ref": "#/components/schemas/ErrorModel"
795
+ }
796
+ }
797
+ }
798
+ },
799
+ "409": {
800
+ "description": "Неверный тип онбординга",
801
+ "content": {
802
+ "text/plain": {
803
+ "schema": {
804
+ "$ref": "#/components/schemas/ErrorModel"
805
+ }
806
+ },
807
+ "application/json": {
808
+ "schema": {
809
+ "$ref": "#/components/schemas/ErrorModel"
810
+ }
811
+ },
812
+ "text/json": {
813
+ "schema": {
814
+ "$ref": "#/components/schemas/ErrorModel"
815
+ }
816
+ }
817
+ }
818
+ }
819
+ }
820
+ }
821
+ },
822
+ "/onboarding/flags/user/{userId}": {
823
+ "put": {
824
+ "tags": [
825
+ "UserOnboarding"
826
+ ],
827
+ "summary": "Обновить override-флаг онбординга для пользователя",
828
+ "description": "## Пример запроса:\r\n \r\nPUT /onboarding/flags/user/42?onboardingTypeId=1\r\n \r\n```json\r\nfalse\r\n```\r\n \r\nТело `null` снимает override. Ответ тогда 204 без тела, дальше действует флаг тенанта.\r\n \r\n## Пример успешного ответа на `false`:\r\n```json\r\nfalse\r\n```",
829
+ "parameters": [
830
+ {
831
+ "name": "userId",
832
+ "in": "path",
833
+ "description": "Идентификатор пользователя (ADM.User)",
834
+ "required": true,
835
+ "schema": {
836
+ "type": "integer",
837
+ "format": "int32"
838
+ }
839
+ },
840
+ {
841
+ "name": "onboardingTypeId",
842
+ "in": "query",
843
+ "description": "Идентификатор типа онбординга. По умолчанию 1",
844
+ "schema": {
845
+ "type": "integer",
846
+ "format": "int32",
847
+ "default": 1
848
+ }
849
+ },
850
+ {
851
+ "name": "X-Application-ID",
852
+ "in": "header",
853
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
854
+ "schema": {
855
+ "enum": [
856
+ 1,
857
+ 2,
858
+ 3,
859
+ 4,
860
+ 5,
861
+ 6
862
+ ],
863
+ "type": "integer",
864
+ "format": "int32",
865
+ "default": 3,
866
+ "x-enumNames": [
867
+ "EngineerMobile",
868
+ "CustomerMobile",
869
+ "MainWeb",
870
+ "AdminWeb",
871
+ "Api",
872
+ "PlateWeb"
873
+ ]
874
+ }
875
+ }
876
+ ],
877
+ "requestBody": {
878
+ "content": {
879
+ "application/json-patch+json": {
880
+ "schema": {
881
+ "type": "boolean"
882
+ }
883
+ },
884
+ "application/json": {
885
+ "schema": {
886
+ "type": "boolean"
887
+ }
888
+ },
889
+ "text/json": {
890
+ "schema": {
891
+ "type": "boolean"
892
+ }
893
+ },
894
+ "application/*+json": {
895
+ "schema": {
896
+ "type": "boolean"
897
+ }
898
+ }
899
+ }
900
+ },
901
+ "responses": {
902
+ "200": {
903
+ "description": "Флаг успешно обновлён",
904
+ "content": {
905
+ "text/plain": {
906
+ "schema": {
907
+ "type": "boolean"
908
+ }
909
+ },
910
+ "application/json": {
911
+ "schema": {
912
+ "type": "boolean"
913
+ }
914
+ },
915
+ "text/json": {
916
+ "schema": {
917
+ "type": "boolean"
918
+ }
919
+ }
920
+ }
921
+ },
922
+ "204": {
923
+ "description": "Override снят, тело пустое"
924
+ },
925
+ "400": {
926
+ "description": "Неверное тело запроса",
927
+ "content": {
928
+ "text/plain": {
929
+ "schema": {
930
+ "$ref": "#/components/schemas/ErrorModel"
931
+ }
932
+ },
933
+ "application/json": {
934
+ "schema": {
935
+ "$ref": "#/components/schemas/ErrorModel"
936
+ }
937
+ },
938
+ "text/json": {
939
+ "schema": {
940
+ "$ref": "#/components/schemas/ErrorModel"
941
+ }
942
+ }
943
+ }
944
+ },
945
+ "401": {
946
+ "description": "Пользователь тенанта не найден или недоступен",
947
+ "content": {
948
+ "text/plain": {
949
+ "schema": {
950
+ "$ref": "#/components/schemas/ErrorModel"
951
+ }
952
+ },
953
+ "application/json": {
954
+ "schema": {
955
+ "$ref": "#/components/schemas/ErrorModel"
956
+ }
957
+ },
958
+ "text/json": {
959
+ "schema": {
960
+ "$ref": "#/components/schemas/ErrorModel"
961
+ }
962
+ }
963
+ }
964
+ },
965
+ "403": {
966
+ "description": "Недостаточно прав или пользователь не найден",
967
+ "content": {
968
+ "text/plain": {
969
+ "schema": {
970
+ "$ref": "#/components/schemas/ErrorModel"
971
+ }
972
+ },
973
+ "application/json": {
974
+ "schema": {
975
+ "$ref": "#/components/schemas/ErrorModel"
976
+ }
977
+ },
978
+ "text/json": {
979
+ "schema": {
980
+ "$ref": "#/components/schemas/ErrorModel"
981
+ }
982
+ }
983
+ }
984
+ },
985
+ "409": {
986
+ "description": "Неверный тип онбординга",
987
+ "content": {
988
+ "text/plain": {
989
+ "schema": {
990
+ "$ref": "#/components/schemas/ErrorModel"
991
+ }
992
+ },
993
+ "application/json": {
994
+ "schema": {
995
+ "$ref": "#/components/schemas/ErrorModel"
996
+ }
997
+ },
998
+ "text/json": {
999
+ "schema": {
1000
+ "$ref": "#/components/schemas/ErrorModel"
1001
+ }
1002
+ }
1003
+ }
1004
+ }
1005
+ }
1006
+ }
1007
+ },
1008
+ "/onboarding/flags/system": {
1009
+ "put": {
1010
+ "tags": [
1011
+ "UserOnboarding"
1012
+ ],
1013
+ "summary": "Обновить глобальный флаг принудительного включения онбординга",
1014
+ "description": "При `isEnabled: true` онбординг включается для всех тенантов и пользователей (effective = true).\r\nПри `isEnabled: false` глобальный принудительный вкл снимается; итоговый флаг считается по tenant и user override.\r\n \r\n## Пример запроса:\r\n \r\nPUT /onboarding/flags/system\r\n \r\n```json\r\ntrue\r\n```\r\n \r\n## Пример успешного ответа:\r\n```json\r\ntrue\r\n```",
1015
+ "parameters": [
1016
+ {
1017
+ "name": "X-Application-ID",
1018
+ "in": "header",
1019
+ "description": "Идентификатор приложения. EngineerMobile - 1, CustomerMobile - 2, MainWeb - 3, AdminWeb - 4, Api - 5, PlateWeb - 6",
1020
+ "schema": {
1021
+ "enum": [
1022
+ 1,
1023
+ 2,
1024
+ 3,
1025
+ 4,
1026
+ 5,
1027
+ 6
1028
+ ],
1029
+ "type": "integer",
1030
+ "format": "int32",
1031
+ "default": 3,
1032
+ "x-enumNames": [
1033
+ "EngineerMobile",
1034
+ "CustomerMobile",
1035
+ "MainWeb",
1036
+ "AdminWeb",
1037
+ "Api",
1038
+ "PlateWeb"
1039
+ ]
1040
+ }
1041
+ }
1042
+ ],
1043
+ "requestBody": {
1044
+ "content": {
1045
+ "application/json-patch+json": {
1046
+ "schema": {
1047
+ "type": "boolean"
1048
+ }
1049
+ },
1050
+ "application/json": {
1051
+ "schema": {
1052
+ "type": "boolean"
1053
+ }
1054
+ },
1055
+ "text/json": {
1056
+ "schema": {
1057
+ "type": "boolean"
1058
+ }
1059
+ },
1060
+ "application/*+json": {
1061
+ "schema": {
1062
+ "type": "boolean"
1063
+ }
1064
+ }
1065
+ }
1066
+ },
1067
+ "responses": {
1068
+ "200": {
1069
+ "description": "Флаг успешно обновлён",
1070
+ "content": {
1071
+ "text/plain": {
1072
+ "schema": {
1073
+ "type": "boolean"
1074
+ }
1075
+ },
1076
+ "application/json": {
1077
+ "schema": {
1078
+ "type": "boolean"
1079
+ }
1080
+ },
1081
+ "text/json": {
1082
+ "schema": {
1083
+ "type": "boolean"
1084
+ }
1085
+ }
1086
+ }
1087
+ },
1088
+ "400": {
1089
+ "description": "Неверное тело запроса",
1090
+ "content": {
1091
+ "text/plain": {
1092
+ "schema": {
1093
+ "$ref": "#/components/schemas/ErrorModel"
1094
+ }
1095
+ },
1096
+ "application/json": {
1097
+ "schema": {
1098
+ "$ref": "#/components/schemas/ErrorModel"
1099
+ }
1100
+ },
1101
+ "text/json": {
1102
+ "schema": {
1103
+ "$ref": "#/components/schemas/ErrorModel"
1104
+ }
1105
+ }
1106
+ }
1107
+ },
1108
+ "403": {
1109
+ "description": "Доступ запрещён (требуется cross-tenant admin)",
1110
+ "content": {
1111
+ "text/plain": {
1112
+ "schema": {
1113
+ "$ref": "#/components/schemas/ErrorModel"
1114
+ }
1115
+ },
1116
+ "application/json": {
1117
+ "schema": {
1118
+ "$ref": "#/components/schemas/ErrorModel"
1119
+ }
1120
+ },
1121
+ "text/json": {
1122
+ "schema": {
1123
+ "$ref": "#/components/schemas/ErrorModel"
1124
+ }
1125
+ }
1126
+ }
1127
+ },
1128
+ "401": {
1129
+ "description": "Unauthorized"
1130
+ }
1131
+ }
1132
+ }
1133
+ }
1134
+ },
1135
+ "components": {
1136
+ "schemas": {
1137
+ "ErrorModel": {
1138
+ "type": "object",
1139
+ "properties": {
1140
+ "traceIdentifier": {
1141
+ "type": "string",
1142
+ "nullable": true
1143
+ },
1144
+ "code": {
1145
+ "type": "string",
1146
+ "nullable": true
1147
+ },
1148
+ "message": {
1149
+ "type": "string",
1150
+ "nullable": true
1151
+ },
1152
+ "arguments": {
1153
+ "type": "object",
1154
+ "additionalProperties": {
1155
+ "type": "string",
1156
+ "nullable": true
1157
+ },
1158
+ "nullable": true
1159
+ }
1160
+ },
1161
+ "additionalProperties": false
1162
+ },
1163
+ "JToken": {
1164
+ "type": "array",
1165
+ "items": {
1166
+ "$ref": "#/components/schemas/JToken"
1167
+ }
1168
+ },
1169
+ "OnboardingConfigDto": {
1170
+ "type": "object",
1171
+ "properties": {
1172
+ "onboardingTypeID": {
1173
+ "type": "integer",
1174
+ "format": "int32"
1175
+ },
1176
+ "userID": {
1177
+ "type": "integer",
1178
+ "format": "int32",
1179
+ "nullable": true
1180
+ },
1181
+ "isSystemOnboardingEnabled": {
1182
+ "type": "boolean"
1183
+ },
1184
+ "isTenantOnboardingEnabled": {
1185
+ "type": "boolean"
1186
+ },
1187
+ "isUserOnboardingEnabled": {
1188
+ "type": "boolean",
1189
+ "nullable": true
1190
+ },
1191
+ "isEnabled": {
1192
+ "type": "boolean"
1193
+ }
1194
+ },
1195
+ "additionalProperties": false
1196
+ },
1197
+ "OnboardingStateCode": {
1198
+ "enum": [
1199
+ "NotStarted",
1200
+ "InProgress",
1201
+ "Completed",
1202
+ "Skipped"
1203
+ ],
1204
+ "type": "string"
1205
+ },
1206
+ "UserOnboardingConfigDto": {
1207
+ "type": "object",
1208
+ "properties": {
1209
+ "onboardingTypeID": {
1210
+ "type": "integer",
1211
+ "format": "int32"
1212
+ },
1213
+ "userID": {
1214
+ "type": "integer",
1215
+ "format": "int32",
1216
+ "nullable": true
1217
+ },
1218
+ "isSystemOnboardingEnabled": {
1219
+ "type": "boolean"
1220
+ },
1221
+ "isTenantOnboardingEnabled": {
1222
+ "type": "boolean"
1223
+ },
1224
+ "isUserOnboardingEnabled": {
1225
+ "type": "boolean",
1226
+ "nullable": true
1227
+ },
1228
+ "isEnabled": {
1229
+ "type": "boolean"
1230
+ },
1231
+ "onboardingState": {
1232
+ "$ref": "#/components/schemas/OnboardingStateCode"
1233
+ },
1234
+ "progressJson": {
1235
+ "type": "string",
1236
+ "nullable": true
1237
+ }
1238
+ },
1239
+ "additionalProperties": false
1240
+ },
1241
+ "UserOnboardingProgressDto": {
1242
+ "type": "object",
1243
+ "properties": {
1244
+ "onboardingTypeID": {
1245
+ "type": "integer",
1246
+ "format": "int32"
1247
+ },
1248
+ "onboardingState": {
1249
+ "$ref": "#/components/schemas/OnboardingStateCode"
1250
+ },
1251
+ "progressJson": {
1252
+ "type": "string",
1253
+ "nullable": true
1254
+ },
1255
+ "progress": {
1256
+ "$ref": "#/components/schemas/JToken"
1257
+ }
1258
+ },
1259
+ "additionalProperties": false
1260
+ },
1261
+ "UserOnboardingResetResultDto": {
1262
+ "type": "object",
1263
+ "properties": {
1264
+ "onboardingTypeID": {
1265
+ "type": "integer",
1266
+ "format": "int32"
1267
+ },
1268
+ "userID": {
1269
+ "type": "integer",
1270
+ "format": "int32"
1271
+ },
1272
+ "onboardingState": {
1273
+ "$ref": "#/components/schemas/OnboardingStateCode"
1274
+ }
1275
+ },
1276
+ "additionalProperties": false
1277
+ },
1278
+ "UserOnboardingStateResultDto": {
1279
+ "type": "object",
1280
+ "properties": {
1281
+ "onboardingTypeID": {
1282
+ "type": "integer",
1283
+ "format": "int32"
1284
+ },
1285
+ "onboardingState": {
1286
+ "$ref": "#/components/schemas/OnboardingStateCode"
1287
+ }
1288
+ },
1289
+ "additionalProperties": false
1290
+ }
1291
+ }
1292
+ },
1293
+ "tags": [
1294
+ {
1295
+ "name": "UserOnboarding",
1296
+ "description": "Контроллер пользовательского онбординга"
1297
+ },
1298
+ {
1299
+ "name": "UserOnboarding",
1300
+ "description": "Контроллер пользовательского онбординга"
1301
+ }
1302
+ ]
1303
+ }