@hyper-fetch/cli 7.5.2 → 8.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (85) hide show
  1. package/.eslintrc.cjs +18 -0
  2. package/__tests__/codegen/openapi/schemas/v2/petstore-expanded.json +210 -0
  3. package/__tests__/codegen/openapi/schemas/v3/broken-schema.json +3604 -0
  4. package/__tests__/codegen/openapi/schemas/v3/petstore-expanded.json +638 -0
  5. package/__tests__/codegen/openapi/v3/generator.spec.ts +367 -0
  6. package/__tests__/codegen/openapi/v3/operations.spec.ts +52 -0
  7. package/__tests__/codegen/openapi/v3/utils.spec.ts +28 -0
  8. package/__tests__/commands/generate/generate.spec.ts +106 -0
  9. package/__tests__/commands/init/.gitkeep +0 -0
  10. package/__tests__/tsconfig.json +22 -0
  11. package/__tests__/vitest.setup.ts +10 -0
  12. package/dist/cli/index.d.ts +3 -0
  13. package/dist/cli/index.d.ts.map +1 -0
  14. package/dist/cli.js +12969 -0
  15. package/dist/cli.js.map +1 -0
  16. package/dist/codegen/index.d.ts +2 -0
  17. package/dist/codegen/index.d.ts.map +1 -0
  18. package/dist/codegen/openapi/generator.d.ts +61 -0
  19. package/dist/codegen/openapi/generator.d.ts.map +1 -0
  20. package/dist/codegen/openapi/http-methods.enum.d.ts +11 -0
  21. package/dist/codegen/openapi/http-methods.enum.d.ts.map +1 -0
  22. package/dist/codegen/openapi/index.d.ts +4 -0
  23. package/dist/codegen/openapi/index.d.ts.map +1 -0
  24. package/dist/codegen/openapi/openapi.types.d.ts +11 -0
  25. package/dist/codegen/openapi/openapi.types.d.ts.map +1 -0
  26. package/dist/codegen/openapi/operations.d.ts +6 -0
  27. package/dist/codegen/openapi/operations.d.ts.map +1 -0
  28. package/dist/codegen/openapi/utils.d.ts +7 -0
  29. package/dist/codegen/openapi/utils.d.ts.map +1 -0
  30. package/dist/commands/add.d.ts +10 -0
  31. package/dist/commands/add.d.ts.map +1 -0
  32. package/dist/commands/generate.d.ts +14 -0
  33. package/dist/commands/generate.d.ts.map +1 -0
  34. package/dist/commands/init.d.ts +3 -0
  35. package/dist/commands/init.d.ts.map +1 -0
  36. package/dist/config/auto-init.d.ts +6 -0
  37. package/dist/config/auto-init.d.ts.map +1 -0
  38. package/dist/config/get-config.d.ts +4 -0
  39. package/dist/config/get-config.d.ts.map +1 -0
  40. package/dist/config/get-ts-alias.d.ts +2 -0
  41. package/dist/config/get-ts-alias.d.ts.map +1 -0
  42. package/dist/config/schema.d.ts +21 -0
  43. package/dist/config/schema.d.ts.map +1 -0
  44. package/dist/generator-f5QJtrBW.js +194000 -0
  45. package/dist/generator-f5QJtrBW.js.map +1 -0
  46. package/dist/index.d.ts +2 -103
  47. package/dist/index.d.ts.map +1 -0
  48. package/dist/index.js +3 -3091
  49. package/dist/preflights/preflight-add.d.ts +27 -0
  50. package/dist/preflights/preflight-add.d.ts.map +1 -0
  51. package/dist/preflights/preflight-generate.d.ts +8 -0
  52. package/dist/preflights/preflight-generate.d.ts.map +1 -0
  53. package/dist/utils/errors.d.ts +14 -0
  54. package/dist/utils/errors.d.ts.map +1 -0
  55. package/dist/utils/handle-error.d.ts +2 -0
  56. package/dist/utils/handle-error.d.ts.map +1 -0
  57. package/dist/utils/highlighter.d.ts +7 -0
  58. package/dist/utils/highlighter.d.ts.map +1 -0
  59. package/dist/utils/logger.d.ts +8 -0
  60. package/dist/utils/logger.d.ts.map +1 -0
  61. package/dist/utils/resolve-import.d.ts +3 -0
  62. package/dist/utils/resolve-import.d.ts.map +1 -0
  63. package/dist/utils/show-help.d.ts +3 -0
  64. package/dist/utils/show-help.d.ts.map +1 -0
  65. package/dist/utils/spinner.d.ts +5 -0
  66. package/dist/utils/spinner.d.ts.map +1 -0
  67. package/dist/utils/zod-to-table.d.ts +6 -0
  68. package/dist/utils/zod-to-table.d.ts.map +1 -0
  69. package/package.json +5 -8
  70. package/project.json +4 -0
  71. package/src/codegen/openapi/generator.ts +4 -3
  72. package/src/codegen/openapi/openapi.types.ts +2 -2
  73. package/src/codegen/openapi/operations.ts +1 -1
  74. package/src/codegen/openapi/utils.ts +1 -1
  75. package/src/commands/add.ts +2 -2
  76. package/src/commands/init.ts +4 -3
  77. package/src/config/auto-init.ts +54 -0
  78. package/src/config/get-config.ts +5 -14
  79. package/src/preflights/preflight-add.ts +2 -2
  80. package/src/preflights/preflight-generate.ts +3 -3
  81. package/src/utils/show-help.ts +1 -1
  82. package/tsconfig.json +1 -1
  83. package/vite.config.ts +45 -0
  84. package/.eslintrc.json +0 -11
  85. package/dist/index.js.map +0 -7
@@ -0,0 +1,3604 @@
1
+ {
2
+ "openapi": "3.0.0",
3
+ "paths": {
4
+ "/api/auth/signup": {
5
+ "post": {
6
+ "operationId": "AuthController_signup",
7
+ "parameters": [],
8
+ "requestBody": {
9
+ "required": true,
10
+ "content": {
11
+ "application/json": {
12
+ "schema": {
13
+ "$ref": "#/components/schemas/SignupDto"
14
+ }
15
+ }
16
+ }
17
+ },
18
+ "responses": {
19
+ "200": {
20
+ "description": "Tokens",
21
+ "content": {
22
+ "application/json": {
23
+ "schema": {
24
+ "$ref": "#/components/schemas/SignupSuccessDto"
25
+ }
26
+ }
27
+ }
28
+ }
29
+ },
30
+ "summary": "Sign up new user",
31
+ "tags": ["auth"]
32
+ }
33
+ },
34
+ "/api/auth/login": {
35
+ "post": {
36
+ "operationId": "AuthController_login",
37
+ "parameters": [],
38
+ "requestBody": {
39
+ "required": true,
40
+ "content": {
41
+ "application/json": {
42
+ "schema": {
43
+ "$ref": "#/components/schemas/LoginDto"
44
+ }
45
+ }
46
+ }
47
+ },
48
+ "responses": {
49
+ "200": {
50
+ "description": "The user records",
51
+ "content": {
52
+ "application/json": {
53
+ "schema": {
54
+ "$ref": "#/components/schemas/UserResponse"
55
+ }
56
+ }
57
+ }
58
+ }
59
+ },
60
+ "summary": "Login user",
61
+ "tags": ["auth"]
62
+ }
63
+ },
64
+ "/api/auth/refresh": {
65
+ "post": {
66
+ "operationId": "AuthController_refresh",
67
+ "parameters": [],
68
+ "requestBody": {
69
+ "required": true,
70
+ "content": {
71
+ "application/json": {
72
+ "schema": {
73
+ "type": "object",
74
+ "properties": {
75
+ "refreshToken": {
76
+ "type": "string"
77
+ }
78
+ }
79
+ }
80
+ }
81
+ }
82
+ },
83
+ "responses": {
84
+ "200": {
85
+ "description": "Tokens",
86
+ "content": {
87
+ "application/json": {
88
+ "schema": {
89
+ "$ref": "#/components/schemas/SignupSuccessDto"
90
+ }
91
+ }
92
+ }
93
+ }
94
+ },
95
+ "summary": "Refresh access token",
96
+ "tags": ["auth"]
97
+ }
98
+ },
99
+ "/api/auth/logout": {
100
+ "post": {
101
+ "operationId": "AuthController_logout",
102
+ "parameters": [
103
+ {
104
+ "name": "authorization",
105
+ "required": true,
106
+ "in": "header",
107
+ "schema": {
108
+ "type": "string"
109
+ }
110
+ }
111
+ ],
112
+ "requestBody": {
113
+ "required": true,
114
+ "content": {
115
+ "application/json": {
116
+ "schema": {
117
+ "type": "object",
118
+ "properties": {
119
+ "refreshToken": {
120
+ "type": "string"
121
+ }
122
+ }
123
+ }
124
+ }
125
+ }
126
+ },
127
+ "responses": {
128
+ "200": {
129
+ "description": "Message",
130
+ "content": {
131
+ "application/json": {
132
+ "schema": {
133
+ "$ref": "#/components/schemas/MessageDto"
134
+ }
135
+ }
136
+ }
137
+ }
138
+ },
139
+ "security": [
140
+ {
141
+ "bearer": []
142
+ }
143
+ ],
144
+ "summary": "Logout user",
145
+ "tags": ["auth"]
146
+ }
147
+ },
148
+ "/api/auth/password-reset/request": {
149
+ "post": {
150
+ "operationId": "AuthController_requestPasswordReset",
151
+ "parameters": [],
152
+ "requestBody": {
153
+ "required": true,
154
+ "content": {
155
+ "application/json": {
156
+ "schema": {
157
+ "$ref": "#/components/schemas/ResetPasswordDto"
158
+ }
159
+ }
160
+ }
161
+ },
162
+ "responses": {
163
+ "200": {
164
+ "description": "Message",
165
+ "content": {
166
+ "application/json": {
167
+ "schema": {
168
+ "$ref": "#/components/schemas/MessageDto"
169
+ }
170
+ }
171
+ }
172
+ }
173
+ },
174
+ "summary": "Request password reset email",
175
+ "tags": ["auth"]
176
+ }
177
+ },
178
+ "/api/auth/password-reset/confirm": {
179
+ "post": {
180
+ "operationId": "AuthController_resetPassword",
181
+ "parameters": [],
182
+ "requestBody": {
183
+ "required": true,
184
+ "content": {
185
+ "application/json": {
186
+ "schema": {
187
+ "$ref": "#/components/schemas/NewPasswordDto"
188
+ }
189
+ }
190
+ }
191
+ },
192
+ "responses": {
193
+ "200": {
194
+ "description": "Message",
195
+ "content": {
196
+ "application/json": {
197
+ "schema": {
198
+ "$ref": "#/components/schemas/MessageDto"
199
+ }
200
+ }
201
+ }
202
+ }
203
+ },
204
+ "summary": "Reset password with token",
205
+ "tags": ["auth"]
206
+ }
207
+ },
208
+ "/api/auth/2fa/enable": {
209
+ "post": {
210
+ "operationId": "AuthController_enable2FA",
211
+ "parameters": [],
212
+ "responses": {
213
+ "200": {
214
+ "description": "Message",
215
+ "content": {
216
+ "application/json": {
217
+ "schema": {
218
+ "$ref": "#/components/schemas/TwoFactorCodeDto"
219
+ }
220
+ }
221
+ }
222
+ }
223
+ },
224
+ "security": [
225
+ {
226
+ "bearer": []
227
+ }
228
+ ],
229
+ "summary": "Enable 2FA",
230
+ "tags": ["auth"]
231
+ }
232
+ },
233
+ "/api/auth/2fa/verify": {
234
+ "post": {
235
+ "operationId": "AuthController_verify2FA",
236
+ "parameters": [],
237
+ "requestBody": {
238
+ "required": true,
239
+ "content": {
240
+ "application/json": {
241
+ "schema": {
242
+ "$ref": "#/components/schemas/TwoFactorCodeDto"
243
+ }
244
+ }
245
+ }
246
+ },
247
+ "responses": {
248
+ "200": {
249
+ "description": "Message",
250
+ "content": {
251
+ "application/json": {
252
+ "schema": {
253
+ "$ref": "#/components/schemas/MessageDto"
254
+ }
255
+ }
256
+ }
257
+ }
258
+ },
259
+ "security": [
260
+ {
261
+ "bearer": []
262
+ }
263
+ ],
264
+ "summary": "Verify 2FA setup",
265
+ "tags": ["auth"]
266
+ }
267
+ },
268
+ "/api/auth/2fa/login": {
269
+ "post": {
270
+ "operationId": "AuthController_verify2FALogin",
271
+ "parameters": [],
272
+ "requestBody": {
273
+ "required": true,
274
+ "content": {
275
+ "application/json": {
276
+ "schema": {
277
+ "$ref": "#/components/schemas/TwoFactorCodeDto"
278
+ }
279
+ }
280
+ }
281
+ },
282
+ "responses": {
283
+ "200": {
284
+ "description": "Tokens",
285
+ "content": {
286
+ "application/json": {
287
+ "schema": {
288
+ "$ref": "#/components/schemas/SignupSuccessDto"
289
+ }
290
+ }
291
+ }
292
+ }
293
+ },
294
+ "summary": "Login with 2FA code",
295
+ "tags": ["auth"]
296
+ }
297
+ },
298
+ "/api/user/me": {
299
+ "get": {
300
+ "operationId": "UserController_getUser",
301
+ "parameters": [],
302
+ "responses": {
303
+ "200": {
304
+ "description": "",
305
+ "content": {
306
+ "application/json": {
307
+ "schema": {
308
+ "$ref": "#/components/schemas/UserResponseDto"
309
+ }
310
+ }
311
+ }
312
+ }
313
+ },
314
+ "security": [
315
+ {
316
+ "bearer": []
317
+ }
318
+ ],
319
+ "tags": ["user"]
320
+ },
321
+ "put": {
322
+ "operationId": "UserController_updateMe",
323
+ "parameters": [],
324
+ "requestBody": {
325
+ "required": true,
326
+ "content": {
327
+ "application/json": {
328
+ "schema": {
329
+ "$ref": "#/components/schemas/UpdateUserDto"
330
+ }
331
+ }
332
+ }
333
+ },
334
+ "responses": {
335
+ "200": {
336
+ "description": "",
337
+ "content": {
338
+ "application/json": {
339
+ "schema": {
340
+ "$ref": "#/components/schemas/UserResponseDto"
341
+ }
342
+ }
343
+ }
344
+ }
345
+ },
346
+ "security": [
347
+ {
348
+ "bearer": []
349
+ }
350
+ ],
351
+ "tags": ["user"]
352
+ }
353
+ },
354
+ "/api/user/{id}": {
355
+ "get": {
356
+ "operationId": "UserController_getUserById",
357
+ "parameters": [
358
+ {
359
+ "name": "id",
360
+ "required": true,
361
+ "in": "path",
362
+ "schema": {
363
+ "type": "string"
364
+ }
365
+ }
366
+ ],
367
+ "responses": {
368
+ "200": {
369
+ "description": "",
370
+ "content": {
371
+ "application/json": {
372
+ "schema": {
373
+ "$ref": "#/components/schemas/UserResponseDto"
374
+ }
375
+ }
376
+ }
377
+ }
378
+ },
379
+ "security": [
380
+ {
381
+ "bearer": []
382
+ }
383
+ ],
384
+ "tags": ["user"]
385
+ },
386
+ "put": {
387
+ "operationId": "UserController_updateUser",
388
+ "parameters": [
389
+ {
390
+ "name": "id",
391
+ "required": true,
392
+ "in": "path",
393
+ "schema": {
394
+ "type": "string"
395
+ }
396
+ }
397
+ ],
398
+ "requestBody": {
399
+ "required": true,
400
+ "content": {
401
+ "application/json": {
402
+ "schema": {
403
+ "$ref": "#/components/schemas/UpdateUserDto"
404
+ }
405
+ }
406
+ }
407
+ },
408
+ "responses": {
409
+ "200": {
410
+ "description": "",
411
+ "content": {
412
+ "application/json": {
413
+ "schema": {
414
+ "$ref": "#/components/schemas/UserResponseDto"
415
+ }
416
+ }
417
+ }
418
+ }
419
+ },
420
+ "security": [
421
+ {
422
+ "bearer": []
423
+ }
424
+ ],
425
+ "tags": ["user"]
426
+ },
427
+ "delete": {
428
+ "operationId": "UserController_deleteUser",
429
+ "parameters": [
430
+ {
431
+ "name": "id",
432
+ "required": true,
433
+ "in": "path",
434
+ "schema": {
435
+ "type": "string"
436
+ }
437
+ }
438
+ ],
439
+ "responses": {
440
+ "200": {
441
+ "description": ""
442
+ }
443
+ },
444
+ "security": [
445
+ {
446
+ "bearer": []
447
+ }
448
+ ],
449
+ "tags": ["user"]
450
+ }
451
+ },
452
+ "/api/organization/{organizationId}/category": {
453
+ "get": {
454
+ "operationId": "CategoryController_findAll",
455
+ "parameters": [
456
+ {
457
+ "name": "organizationId",
458
+ "required": true,
459
+ "in": "path",
460
+ "schema": {
461
+ "type": "string"
462
+ }
463
+ },
464
+ {
465
+ "name": "organizationId",
466
+ "required": true,
467
+ "in": "query",
468
+ "schema": {
469
+ "example": "123e4567-e89b-12d3-a456-426614174000",
470
+ "type": "string"
471
+ }
472
+ },
473
+ {
474
+ "name": "offset",
475
+ "required": false,
476
+ "in": "query",
477
+ "schema": {
478
+ "example": 0,
479
+ "type": "number"
480
+ }
481
+ },
482
+ {
483
+ "name": "limit",
484
+ "required": false,
485
+ "in": "query",
486
+ "schema": {
487
+ "example": 10,
488
+ "type": "number"
489
+ }
490
+ },
491
+ {
492
+ "name": "search",
493
+ "required": false,
494
+ "in": "query",
495
+ "schema": {
496
+ "example": "search",
497
+ "type": "string"
498
+ }
499
+ }
500
+ ],
501
+ "responses": {
502
+ "200": {
503
+ "description": "",
504
+ "content": {
505
+ "application/json": {
506
+ "schema": {
507
+ "$ref": "#/components/schemas/CategoryListResponse"
508
+ }
509
+ }
510
+ }
511
+ }
512
+ },
513
+ "security": [
514
+ {
515
+ "bearer": []
516
+ }
517
+ ],
518
+ "summary": "Get all categories",
519
+ "tags": ["Content category"]
520
+ },
521
+ "post": {
522
+ "operationId": "CategoryController_create",
523
+ "parameters": [
524
+ {
525
+ "name": "organizationId",
526
+ "required": true,
527
+ "in": "path",
528
+ "schema": {
529
+ "type": "string"
530
+ }
531
+ }
532
+ ],
533
+ "requestBody": {
534
+ "required": true,
535
+ "content": {
536
+ "application/json": {
537
+ "schema": {
538
+ "$ref": "#/components/schemas/CategoryCreateDto"
539
+ }
540
+ }
541
+ }
542
+ },
543
+ "responses": {
544
+ "200": {
545
+ "description": "",
546
+ "content": {
547
+ "application/json": {
548
+ "schema": {
549
+ "$ref": "#/components/schemas/CategoryResponseDto"
550
+ }
551
+ }
552
+ }
553
+ }
554
+ },
555
+ "security": [
556
+ {
557
+ "bearer": []
558
+ }
559
+ ],
560
+ "summary": "Create category",
561
+ "tags": ["Content category"]
562
+ }
563
+ },
564
+ "/api/organization/{organizationId}/category/{id}": {
565
+ "get": {
566
+ "operationId": "CategoryController_findOne",
567
+ "parameters": [
568
+ {
569
+ "name": "id",
570
+ "required": true,
571
+ "in": "path",
572
+ "schema": {
573
+ "type": "string"
574
+ }
575
+ }
576
+ ],
577
+ "responses": {
578
+ "200": {
579
+ "description": "",
580
+ "content": {
581
+ "application/json": {
582
+ "schema": {
583
+ "$ref": "#/components/schemas/CategoryResponseDto"
584
+ }
585
+ }
586
+ }
587
+ }
588
+ },
589
+ "security": [
590
+ {
591
+ "bearer": []
592
+ }
593
+ ],
594
+ "summary": "Get category by id",
595
+ "tags": ["Content category"]
596
+ },
597
+ "put": {
598
+ "operationId": "CategoryController_update",
599
+ "parameters": [
600
+ {
601
+ "name": "id",
602
+ "required": true,
603
+ "in": "path",
604
+ "schema": {
605
+ "type": "string"
606
+ }
607
+ }
608
+ ],
609
+ "requestBody": {
610
+ "required": true,
611
+ "content": {
612
+ "application/json": {
613
+ "schema": {
614
+ "$ref": "#/components/schemas/CategoryUpdateDto"
615
+ }
616
+ }
617
+ }
618
+ },
619
+ "responses": {
620
+ "200": {
621
+ "description": "",
622
+ "content": {
623
+ "application/json": {
624
+ "schema": {
625
+ "$ref": "#/components/schemas/CategoryResponseDto"
626
+ }
627
+ }
628
+ }
629
+ }
630
+ },
631
+ "security": [
632
+ {
633
+ "bearer": []
634
+ }
635
+ ],
636
+ "summary": "Update category",
637
+ "tags": ["Content category"]
638
+ },
639
+ "delete": {
640
+ "operationId": "CategoryController_delete",
641
+ "parameters": [
642
+ {
643
+ "name": "id",
644
+ "required": true,
645
+ "in": "path",
646
+ "schema": {
647
+ "type": "string"
648
+ }
649
+ }
650
+ ],
651
+ "responses": {
652
+ "200": {
653
+ "description": "",
654
+ "content": {
655
+ "application/json": {
656
+ "schema": {
657
+ "$ref": "#/components/schemas/CategoryResponseDto"
658
+ }
659
+ }
660
+ }
661
+ }
662
+ },
663
+ "security": [
664
+ {
665
+ "bearer": []
666
+ }
667
+ ],
668
+ "summary": "Delete category",
669
+ "tags": ["Content category"]
670
+ }
671
+ },
672
+ "/api/organization/{organizationId}/content": {
673
+ "get": {
674
+ "operationId": "ContentController_findAll",
675
+ "parameters": [
676
+ {
677
+ "name": "organizationId",
678
+ "required": true,
679
+ "in": "path",
680
+ "schema": {
681
+ "type": "string"
682
+ }
683
+ },
684
+ {
685
+ "name": "organizationId",
686
+ "required": true,
687
+ "in": "query",
688
+ "schema": {
689
+ "example": "123e4567-e89b-12d3-a456-426614174000",
690
+ "type": "string"
691
+ }
692
+ },
693
+ {
694
+ "name": "offset",
695
+ "required": false,
696
+ "in": "query",
697
+ "schema": {
698
+ "example": 0,
699
+ "type": "number"
700
+ }
701
+ },
702
+ {
703
+ "name": "limit",
704
+ "required": false,
705
+ "in": "query",
706
+ "schema": {
707
+ "example": 10,
708
+ "type": "number"
709
+ }
710
+ },
711
+ {
712
+ "name": "search",
713
+ "required": false,
714
+ "in": "query",
715
+ "schema": {
716
+ "example": "search",
717
+ "type": "string"
718
+ }
719
+ },
720
+ {
721
+ "name": "groupId",
722
+ "required": false,
723
+ "in": "query",
724
+ "schema": {
725
+ "example": "123e4567-e89b-12d3-a456-426614174000",
726
+ "type": "string"
727
+ }
728
+ },
729
+ {
730
+ "name": "categoryId",
731
+ "required": false,
732
+ "in": "query",
733
+ "schema": {
734
+ "example": "123e4567-e89b-12d3-a456-426614174000",
735
+ "type": "string"
736
+ }
737
+ },
738
+ {
739
+ "name": "pathId",
740
+ "required": false,
741
+ "in": "query",
742
+ "schema": {
743
+ "example": "123e4567-e89b-12d3-a456-426614174000",
744
+ "type": "string"
745
+ }
746
+ }
747
+ ],
748
+ "responses": {
749
+ "200": {
750
+ "description": "",
751
+ "content": {
752
+ "application/json": {
753
+ "schema": {
754
+ "$ref": "#/components/schemas/ContentItemListResponse"
755
+ }
756
+ }
757
+ }
758
+ }
759
+ },
760
+ "security": [
761
+ {
762
+ "bearer": []
763
+ }
764
+ ],
765
+ "summary": "Get items created by the current user(creator)",
766
+ "tags": ["Content"]
767
+ },
768
+ "post": {
769
+ "operationId": "ContentController_create",
770
+ "parameters": [
771
+ {
772
+ "name": "organizationId",
773
+ "required": true,
774
+ "in": "path",
775
+ "schema": {
776
+ "type": "string"
777
+ }
778
+ }
779
+ ],
780
+ "requestBody": {
781
+ "required": true,
782
+ "content": {
783
+ "application/json": {
784
+ "schema": {
785
+ "$ref": "#/components/schemas/ContentCreateDto"
786
+ }
787
+ }
788
+ }
789
+ },
790
+ "responses": {
791
+ "200": {
792
+ "description": "",
793
+ "content": {
794
+ "application/json": {
795
+ "schema": {
796
+ "$ref": "#/components/schemas/ContentItemResponse"
797
+ }
798
+ }
799
+ }
800
+ }
801
+ },
802
+ "security": [
803
+ {
804
+ "bearer": []
805
+ }
806
+ ],
807
+ "summary": "Create content",
808
+ "tags": ["Content"]
809
+ }
810
+ },
811
+ "/api/organization/{organizationId}/content/{id}": {
812
+ "get": {
813
+ "operationId": "ContentController_findOne",
814
+ "parameters": [
815
+ {
816
+ "name": "id",
817
+ "required": true,
818
+ "in": "path",
819
+ "schema": {
820
+ "type": "string"
821
+ }
822
+ }
823
+ ],
824
+ "responses": {
825
+ "200": {
826
+ "description": "",
827
+ "content": {
828
+ "application/json": {
829
+ "schema": {
830
+ "$ref": "#/components/schemas/ContentItemResponse"
831
+ }
832
+ }
833
+ }
834
+ }
835
+ },
836
+ "summary": "Get content by id",
837
+ "tags": ["Content"]
838
+ },
839
+ "put": {
840
+ "operationId": "ContentController_update",
841
+ "parameters": [
842
+ {
843
+ "name": "id",
844
+ "required": true,
845
+ "in": "path",
846
+ "schema": {
847
+ "type": "string"
848
+ }
849
+ }
850
+ ],
851
+ "requestBody": {
852
+ "required": true,
853
+ "content": {
854
+ "application/json": {
855
+ "schema": {
856
+ "$ref": "#/components/schemas/ContentUpdateDto"
857
+ }
858
+ }
859
+ }
860
+ },
861
+ "responses": {
862
+ "200": {
863
+ "description": "",
864
+ "content": {
865
+ "application/json": {
866
+ "schema": {
867
+ "$ref": "#/components/schemas/ContentItemResponse"
868
+ }
869
+ }
870
+ }
871
+ }
872
+ },
873
+ "security": [
874
+ {
875
+ "bearer": []
876
+ }
877
+ ],
878
+ "summary": "Update content",
879
+ "tags": ["Content"]
880
+ },
881
+ "delete": {
882
+ "operationId": "ContentController_delete",
883
+ "parameters": [
884
+ {
885
+ "name": "id",
886
+ "required": true,
887
+ "in": "path",
888
+ "schema": {
889
+ "type": "string"
890
+ }
891
+ }
892
+ ],
893
+ "responses": {
894
+ "200": {
895
+ "description": "",
896
+ "content": {
897
+ "application/json": {
898
+ "schema": {
899
+ "$ref": "#/components/schemas/ContentItemResponse"
900
+ }
901
+ }
902
+ }
903
+ }
904
+ },
905
+ "security": [
906
+ {
907
+ "bearer": []
908
+ }
909
+ ],
910
+ "summary": "Delete content",
911
+ "tags": ["Content"]
912
+ }
913
+ },
914
+ "/api/organization/{organizationId}/content/image": {
915
+ "post": {
916
+ "operationId": "ContentController_uploadImage",
917
+ "parameters": [],
918
+ "requestBody": {
919
+ "required": true,
920
+ "content": {
921
+ "multipart/form-data": {
922
+ "schema": {
923
+ "$ref": "#/components/schemas/ContentImageDto"
924
+ }
925
+ }
926
+ }
927
+ },
928
+ "responses": {
929
+ "200": {
930
+ "description": "",
931
+ "content": {
932
+ "application/json": {
933
+ "schema": {
934
+ "$ref": "#/components/schemas/ContentImageResponse"
935
+ }
936
+ }
937
+ }
938
+ }
939
+ },
940
+ "security": [
941
+ {
942
+ "bearer": []
943
+ }
944
+ ],
945
+ "summary": "Upload image for later use in content",
946
+ "tags": ["Content"]
947
+ }
948
+ },
949
+ "/api/organization/{organizationId}/content/answer": {
950
+ "post": {
951
+ "operationId": "ContentController_postAnswer",
952
+ "parameters": [],
953
+ "requestBody": {
954
+ "required": true,
955
+ "content": {
956
+ "application/json": {
957
+ "schema": {
958
+ "$ref": "#/components/schemas/ContentAnswerDto"
959
+ }
960
+ }
961
+ }
962
+ },
963
+ "responses": {
964
+ "200": {
965
+ "description": "",
966
+ "content": {
967
+ "application/json": {
968
+ "schema": {
969
+ "$ref": "#/components/schemas/ContentAnswerResponse"
970
+ }
971
+ }
972
+ }
973
+ }
974
+ },
975
+ "security": [
976
+ {
977
+ "bearer": []
978
+ }
979
+ ],
980
+ "summary": "Upload image for later use in content",
981
+ "tags": ["Content"]
982
+ }
983
+ },
984
+ "/api/organization/{organizationId}/group": {
985
+ "get": {
986
+ "operationId": "GroupController_findAll",
987
+ "parameters": [
988
+ {
989
+ "name": "organizationId",
990
+ "required": true,
991
+ "in": "path",
992
+ "schema": {
993
+ "type": "string"
994
+ }
995
+ },
996
+ {
997
+ "name": "organizationId",
998
+ "required": true,
999
+ "in": "query",
1000
+ "schema": {
1001
+ "example": "123e4567-e89b-12d3-a456-426614174000",
1002
+ "type": "string"
1003
+ }
1004
+ },
1005
+ {
1006
+ "name": "offset",
1007
+ "required": false,
1008
+ "in": "query",
1009
+ "schema": {
1010
+ "example": 0,
1011
+ "type": "number"
1012
+ }
1013
+ },
1014
+ {
1015
+ "name": "limit",
1016
+ "required": false,
1017
+ "in": "query",
1018
+ "schema": {
1019
+ "example": 10,
1020
+ "type": "number"
1021
+ }
1022
+ },
1023
+ {
1024
+ "name": "search",
1025
+ "required": false,
1026
+ "in": "query",
1027
+ "schema": {
1028
+ "example": "search",
1029
+ "type": "string"
1030
+ }
1031
+ }
1032
+ ],
1033
+ "responses": {
1034
+ "200": {
1035
+ "description": "",
1036
+ "content": {
1037
+ "application/json": {
1038
+ "schema": {
1039
+ "$ref": "#/components/schemas/GroupListResponse"
1040
+ }
1041
+ }
1042
+ }
1043
+ }
1044
+ },
1045
+ "security": [
1046
+ {
1047
+ "bearer": []
1048
+ }
1049
+ ],
1050
+ "summary": "Get groups within organization",
1051
+ "tags": ["Content/user groups"]
1052
+ },
1053
+ "post": {
1054
+ "operationId": "GroupController_create",
1055
+ "parameters": [
1056
+ {
1057
+ "name": "organizationId",
1058
+ "required": true,
1059
+ "in": "path",
1060
+ "schema": {
1061
+ "type": "string"
1062
+ }
1063
+ }
1064
+ ],
1065
+ "requestBody": {
1066
+ "required": true,
1067
+ "content": {
1068
+ "application/json": {
1069
+ "schema": {
1070
+ "$ref": "#/components/schemas/GroupCreateDto"
1071
+ }
1072
+ }
1073
+ }
1074
+ },
1075
+ "responses": {
1076
+ "200": {
1077
+ "description": "",
1078
+ "content": {
1079
+ "application/json": {
1080
+ "schema": {
1081
+ "$ref": "#/components/schemas/GroupResponseDto"
1082
+ }
1083
+ }
1084
+ }
1085
+ }
1086
+ },
1087
+ "security": [
1088
+ {
1089
+ "bearer": []
1090
+ }
1091
+ ],
1092
+ "summary": "Create group",
1093
+ "tags": ["Content/user groups"]
1094
+ }
1095
+ },
1096
+ "/api/organization/{organizationId}/group/{id}": {
1097
+ "get": {
1098
+ "operationId": "GroupController_findOne",
1099
+ "parameters": [
1100
+ {
1101
+ "name": "id",
1102
+ "required": true,
1103
+ "in": "path",
1104
+ "schema": {
1105
+ "type": "string"
1106
+ }
1107
+ }
1108
+ ],
1109
+ "responses": {
1110
+ "200": {
1111
+ "description": "",
1112
+ "content": {
1113
+ "application/json": {
1114
+ "schema": {
1115
+ "$ref": "#/components/schemas/GroupResponseDto"
1116
+ }
1117
+ }
1118
+ }
1119
+ }
1120
+ },
1121
+ "security": [
1122
+ {
1123
+ "bearer": []
1124
+ }
1125
+ ],
1126
+ "summary": "Get group by id",
1127
+ "tags": ["Content/user groups"]
1128
+ },
1129
+ "put": {
1130
+ "operationId": "GroupController_update",
1131
+ "parameters": [
1132
+ {
1133
+ "name": "id",
1134
+ "required": true,
1135
+ "in": "path",
1136
+ "schema": {
1137
+ "type": "string"
1138
+ }
1139
+ }
1140
+ ],
1141
+ "requestBody": {
1142
+ "required": true,
1143
+ "content": {
1144
+ "application/json": {
1145
+ "schema": {
1146
+ "$ref": "#/components/schemas/GroupUpdateDto"
1147
+ }
1148
+ }
1149
+ }
1150
+ },
1151
+ "responses": {
1152
+ "200": {
1153
+ "description": "",
1154
+ "content": {
1155
+ "application/json": {
1156
+ "schema": {
1157
+ "$ref": "#/components/schemas/GroupResponseDto"
1158
+ }
1159
+ }
1160
+ }
1161
+ }
1162
+ },
1163
+ "security": [
1164
+ {
1165
+ "bearer": []
1166
+ }
1167
+ ],
1168
+ "summary": "Update group",
1169
+ "tags": ["Content/user groups"]
1170
+ },
1171
+ "delete": {
1172
+ "operationId": "GroupController_delete",
1173
+ "parameters": [
1174
+ {
1175
+ "name": "id",
1176
+ "required": true,
1177
+ "in": "path",
1178
+ "schema": {
1179
+ "type": "string"
1180
+ }
1181
+ }
1182
+ ],
1183
+ "responses": {
1184
+ "200": {
1185
+ "description": "",
1186
+ "content": {
1187
+ "application/json": {
1188
+ "schema": {
1189
+ "$ref": "#/components/schemas/GroupResponseDto"
1190
+ }
1191
+ }
1192
+ }
1193
+ }
1194
+ },
1195
+ "security": [
1196
+ {
1197
+ "bearer": []
1198
+ }
1199
+ ],
1200
+ "summary": "Delete group",
1201
+ "tags": ["Content/user groups"]
1202
+ }
1203
+ },
1204
+ "/api/organization": {
1205
+ "get": {
1206
+ "operationId": "OrganizationController_getOrganizations",
1207
+ "parameters": [],
1208
+ "responses": {
1209
+ "200": {
1210
+ "description": "",
1211
+ "content": {
1212
+ "application/json": {
1213
+ "schema": {
1214
+ "$ref": "#/components/schemas/OrganizationListResponse"
1215
+ }
1216
+ }
1217
+ }
1218
+ }
1219
+ },
1220
+ "security": [
1221
+ {
1222
+ "bearer": []
1223
+ }
1224
+ ],
1225
+ "summary": "Get all users organizations",
1226
+ "tags": ["Organization"]
1227
+ },
1228
+ "post": {
1229
+ "operationId": "OrganizationController_createOrganization",
1230
+ "parameters": [],
1231
+ "requestBody": {
1232
+ "required": true,
1233
+ "content": {
1234
+ "application/json": {
1235
+ "schema": {
1236
+ "$ref": "#/components/schemas/CreateOrganizationDto"
1237
+ }
1238
+ }
1239
+ }
1240
+ },
1241
+ "responses": {
1242
+ "200": {
1243
+ "description": "",
1244
+ "content": {
1245
+ "application/json": {
1246
+ "schema": {
1247
+ "$ref": "#/components/schemas/OrganizationResponseDto"
1248
+ }
1249
+ }
1250
+ }
1251
+ }
1252
+ },
1253
+ "security": [
1254
+ {
1255
+ "bearer": []
1256
+ }
1257
+ ],
1258
+ "summary": "Create new organization",
1259
+ "tags": ["Organization"]
1260
+ }
1261
+ },
1262
+ "/api/organization/{id}": {
1263
+ "get": {
1264
+ "operationId": "OrganizationController_getOrganizationDetails",
1265
+ "parameters": [
1266
+ {
1267
+ "name": "id",
1268
+ "required": true,
1269
+ "in": "path",
1270
+ "schema": {
1271
+ "type": "string"
1272
+ }
1273
+ }
1274
+ ],
1275
+ "responses": {
1276
+ "200": {
1277
+ "description": "",
1278
+ "content": {
1279
+ "application/json": {
1280
+ "schema": {
1281
+ "$ref": "#/components/schemas/OrganizationResponseDto"
1282
+ }
1283
+ }
1284
+ }
1285
+ }
1286
+ },
1287
+ "security": [
1288
+ {
1289
+ "bearer": []
1290
+ }
1291
+ ],
1292
+ "summary": "Get organization details",
1293
+ "tags": ["Organization"]
1294
+ },
1295
+ "put": {
1296
+ "operationId": "OrganizationController_updateOrganization",
1297
+ "parameters": [
1298
+ {
1299
+ "name": "id",
1300
+ "required": true,
1301
+ "in": "path",
1302
+ "schema": {
1303
+ "type": "string"
1304
+ }
1305
+ }
1306
+ ],
1307
+ "requestBody": {
1308
+ "required": true,
1309
+ "content": {
1310
+ "application/json": {
1311
+ "schema": {
1312
+ "$ref": "#/components/schemas/UpdateOrganizationDto"
1313
+ }
1314
+ }
1315
+ }
1316
+ },
1317
+ "responses": {
1318
+ "200": {
1319
+ "description": "",
1320
+ "content": {
1321
+ "application/json": {
1322
+ "schema": {
1323
+ "$ref": "#/components/schemas/OrganizationResponseDto"
1324
+ }
1325
+ }
1326
+ }
1327
+ }
1328
+ },
1329
+ "security": [
1330
+ {
1331
+ "bearer": []
1332
+ }
1333
+ ],
1334
+ "summary": "Update organization details",
1335
+ "tags": ["Organization"]
1336
+ },
1337
+ "delete": {
1338
+ "operationId": "OrganizationController_deleteOrganization",
1339
+ "parameters": [
1340
+ {
1341
+ "name": "id",
1342
+ "required": true,
1343
+ "in": "path",
1344
+ "schema": {
1345
+ "type": "string"
1346
+ }
1347
+ }
1348
+ ],
1349
+ "responses": {
1350
+ "200": {
1351
+ "description": "",
1352
+ "content": {
1353
+ "application/json": {
1354
+ "schema": {
1355
+ "$ref": "#/components/schemas/OrganizationResponseDto"
1356
+ }
1357
+ }
1358
+ }
1359
+ }
1360
+ },
1361
+ "security": [
1362
+ {
1363
+ "bearer": []
1364
+ }
1365
+ ],
1366
+ "summary": "Delete organization",
1367
+ "tags": ["Organization"]
1368
+ }
1369
+ },
1370
+ "/api/organization/{organizationId}/path": {
1371
+ "get": {
1372
+ "operationId": "PathController_findAll",
1373
+ "parameters": [
1374
+ {
1375
+ "name": "organizationId",
1376
+ "required": true,
1377
+ "in": "path",
1378
+ "schema": {
1379
+ "type": "string"
1380
+ }
1381
+ },
1382
+ {
1383
+ "name": "organizationId",
1384
+ "required": true,
1385
+ "in": "query",
1386
+ "schema": {
1387
+ "example": "123e4567-e89b-12d3-a456-426614174000",
1388
+ "type": "string"
1389
+ }
1390
+ },
1391
+ {
1392
+ "name": "offset",
1393
+ "required": false,
1394
+ "in": "query",
1395
+ "schema": {
1396
+ "example": 0,
1397
+ "type": "number"
1398
+ }
1399
+ },
1400
+ {
1401
+ "name": "limit",
1402
+ "required": false,
1403
+ "in": "query",
1404
+ "schema": {
1405
+ "example": 10,
1406
+ "type": "number"
1407
+ }
1408
+ },
1409
+ {
1410
+ "name": "search",
1411
+ "required": false,
1412
+ "in": "query",
1413
+ "schema": {
1414
+ "example": "search",
1415
+ "type": "string"
1416
+ }
1417
+ }
1418
+ ],
1419
+ "responses": {
1420
+ "200": {
1421
+ "description": "",
1422
+ "content": {
1423
+ "application/json": {
1424
+ "schema": {
1425
+ "$ref": "#/components/schemas/PathListResponse"
1426
+ }
1427
+ }
1428
+ }
1429
+ }
1430
+ },
1431
+ "security": [
1432
+ {
1433
+ "bearer": []
1434
+ }
1435
+ ],
1436
+ "summary": "Get all content paths within organization",
1437
+ "tags": ["Content paths"]
1438
+ },
1439
+ "post": {
1440
+ "operationId": "PathController_create",
1441
+ "parameters": [
1442
+ {
1443
+ "name": "organizationId",
1444
+ "required": true,
1445
+ "in": "path",
1446
+ "schema": {
1447
+ "type": "string"
1448
+ }
1449
+ }
1450
+ ],
1451
+ "requestBody": {
1452
+ "required": true,
1453
+ "content": {
1454
+ "application/json": {
1455
+ "schema": {
1456
+ "$ref": "#/components/schemas/PathCreateDto"
1457
+ }
1458
+ }
1459
+ }
1460
+ },
1461
+ "responses": {
1462
+ "200": {
1463
+ "description": "",
1464
+ "content": {
1465
+ "application/json": {
1466
+ "schema": {
1467
+ "$ref": "#/components/schemas/PathResponseDto"
1468
+ }
1469
+ }
1470
+ }
1471
+ }
1472
+ },
1473
+ "security": [
1474
+ {
1475
+ "bearer": []
1476
+ }
1477
+ ],
1478
+ "summary": "Create path",
1479
+ "tags": ["Content paths"]
1480
+ }
1481
+ },
1482
+ "/api/organization/{organizationId}/path/{id}": {
1483
+ "get": {
1484
+ "operationId": "PathController_findOne",
1485
+ "parameters": [
1486
+ {
1487
+ "name": "id",
1488
+ "required": true,
1489
+ "in": "path",
1490
+ "schema": {
1491
+ "type": "string"
1492
+ }
1493
+ }
1494
+ ],
1495
+ "responses": {
1496
+ "200": {
1497
+ "description": "",
1498
+ "content": {
1499
+ "application/json": {
1500
+ "schema": {
1501
+ "$ref": "#/components/schemas/PathResponseDto"
1502
+ }
1503
+ }
1504
+ }
1505
+ }
1506
+ },
1507
+ "security": [
1508
+ {
1509
+ "bearer": []
1510
+ }
1511
+ ],
1512
+ "summary": "Get path by id",
1513
+ "tags": ["Content paths"]
1514
+ },
1515
+ "put": {
1516
+ "operationId": "PathController_update",
1517
+ "parameters": [
1518
+ {
1519
+ "name": "id",
1520
+ "required": true,
1521
+ "in": "path",
1522
+ "schema": {
1523
+ "type": "string"
1524
+ }
1525
+ }
1526
+ ],
1527
+ "requestBody": {
1528
+ "required": true,
1529
+ "content": {
1530
+ "application/json": {
1531
+ "schema": {
1532
+ "$ref": "#/components/schemas/PathUpdateDto"
1533
+ }
1534
+ }
1535
+ }
1536
+ },
1537
+ "responses": {
1538
+ "200": {
1539
+ "description": "",
1540
+ "content": {
1541
+ "application/json": {
1542
+ "schema": {
1543
+ "$ref": "#/components/schemas/PathResponseDto"
1544
+ }
1545
+ }
1546
+ }
1547
+ }
1548
+ },
1549
+ "security": [
1550
+ {
1551
+ "bearer": []
1552
+ }
1553
+ ],
1554
+ "summary": "Update path",
1555
+ "tags": ["Content paths"]
1556
+ },
1557
+ "delete": {
1558
+ "operationId": "PathController_delete",
1559
+ "parameters": [
1560
+ {
1561
+ "name": "id",
1562
+ "required": true,
1563
+ "in": "path",
1564
+ "schema": {
1565
+ "type": "string"
1566
+ }
1567
+ }
1568
+ ],
1569
+ "responses": {
1570
+ "200": {
1571
+ "description": "",
1572
+ "content": {
1573
+ "application/json": {
1574
+ "schema": {
1575
+ "$ref": "#/components/schemas/PathResponseDto"
1576
+ }
1577
+ }
1578
+ }
1579
+ }
1580
+ },
1581
+ "security": [
1582
+ {
1583
+ "bearer": []
1584
+ }
1585
+ ],
1586
+ "summary": "Delete path",
1587
+ "tags": ["Content paths"]
1588
+ }
1589
+ },
1590
+ "/api/organization/{organizationId}/user": {
1591
+ "get": {
1592
+ "operationId": "UserController_findAll",
1593
+ "parameters": [
1594
+ {
1595
+ "name": "organizationId",
1596
+ "required": true,
1597
+ "in": "path",
1598
+ "schema": {
1599
+ "type": "string"
1600
+ }
1601
+ },
1602
+ {
1603
+ "name": "organizationId",
1604
+ "required": true,
1605
+ "in": "query",
1606
+ "schema": {
1607
+ "example": "123e4567-e89b-12d3-a456-426614174000",
1608
+ "type": "string"
1609
+ }
1610
+ },
1611
+ {
1612
+ "name": "offset",
1613
+ "required": false,
1614
+ "in": "query",
1615
+ "schema": {
1616
+ "example": 0,
1617
+ "type": "number"
1618
+ }
1619
+ },
1620
+ {
1621
+ "name": "limit",
1622
+ "required": false,
1623
+ "in": "query",
1624
+ "schema": {
1625
+ "example": 10,
1626
+ "type": "number"
1627
+ }
1628
+ },
1629
+ {
1630
+ "name": "search",
1631
+ "required": false,
1632
+ "in": "query",
1633
+ "schema": {
1634
+ "example": "search",
1635
+ "type": "string"
1636
+ }
1637
+ },
1638
+ {
1639
+ "name": "groupId",
1640
+ "required": false,
1641
+ "in": "query",
1642
+ "schema": {
1643
+ "example": "123e4567-e89b-12d3-a456-426614174000",
1644
+ "type": "string"
1645
+ }
1646
+ }
1647
+ ],
1648
+ "responses": {
1649
+ "200": {
1650
+ "description": "Users",
1651
+ "content": {
1652
+ "application/json": {
1653
+ "schema": {
1654
+ "$ref": "#/components/schemas/UserListResponse"
1655
+ }
1656
+ }
1657
+ }
1658
+ }
1659
+ },
1660
+ "security": [
1661
+ {
1662
+ "bearer": []
1663
+ }
1664
+ ],
1665
+ "summary": "Get all users within organization",
1666
+ "tags": ["Users within organization"]
1667
+ }
1668
+ },
1669
+ "/api/organization/{organizationId}/user/invite": {
1670
+ "get": {
1671
+ "operationId": "UserController_inviteToOrganization",
1672
+ "parameters": [],
1673
+ "responses": {
1674
+ "200": {
1675
+ "description": "Tokens",
1676
+ "content": {
1677
+ "application/json": {
1678
+ "schema": {
1679
+ "$ref": "#/components/schemas/InviteResponse"
1680
+ }
1681
+ }
1682
+ }
1683
+ }
1684
+ },
1685
+ "tags": ["Users within organization"]
1686
+ }
1687
+ },
1688
+ "/api/organization/{organizationId}/user/{userId}": {
1689
+ "delete": {
1690
+ "operationId": "UserController_deleteUserFromOrganization",
1691
+ "parameters": [
1692
+ {
1693
+ "name": "userId",
1694
+ "required": true,
1695
+ "in": "path",
1696
+ "schema": {
1697
+ "type": "string"
1698
+ }
1699
+ },
1700
+ {
1701
+ "name": "organizationId",
1702
+ "required": true,
1703
+ "in": "path",
1704
+ "schema": {
1705
+ "type": "string"
1706
+ }
1707
+ }
1708
+ ],
1709
+ "responses": {
1710
+ "200": {
1711
+ "description": "",
1712
+ "content": {
1713
+ "application/json": {
1714
+ "schema": {
1715
+ "$ref": "#/components/schemas/DeleteUserResponse"
1716
+ }
1717
+ }
1718
+ }
1719
+ }
1720
+ },
1721
+ "security": [
1722
+ {
1723
+ "bearer": []
1724
+ }
1725
+ ],
1726
+ "tags": ["Users within organization"]
1727
+ }
1728
+ },
1729
+ "/api/marketplace": {
1730
+ "get": {
1731
+ "operationId": "MarketplaceController_getMarketplaceItems",
1732
+ "parameters": [
1733
+ {
1734
+ "name": "organizationId",
1735
+ "required": true,
1736
+ "in": "query",
1737
+ "schema": {
1738
+ "example": "123e4567-e89b-12d3-a456-426614174000",
1739
+ "type": "string"
1740
+ }
1741
+ },
1742
+ {
1743
+ "name": "offset",
1744
+ "required": false,
1745
+ "in": "query",
1746
+ "schema": {
1747
+ "example": 0,
1748
+ "type": "number"
1749
+ }
1750
+ },
1751
+ {
1752
+ "name": "limit",
1753
+ "required": false,
1754
+ "in": "query",
1755
+ "schema": {
1756
+ "example": 10,
1757
+ "type": "number"
1758
+ }
1759
+ },
1760
+ {
1761
+ "name": "search",
1762
+ "required": false,
1763
+ "in": "query",
1764
+ "schema": {
1765
+ "example": "search",
1766
+ "type": "string"
1767
+ }
1768
+ }
1769
+ ],
1770
+ "responses": {
1771
+ "200": {
1772
+ "description": "",
1773
+ "content": {
1774
+ "application/json": {
1775
+ "schema": {
1776
+ "$ref": "#/components/schemas/MarketplaceListResponse"
1777
+ }
1778
+ }
1779
+ }
1780
+ }
1781
+ },
1782
+ "summary": "Get marketplace items",
1783
+ "tags": ["Marketplace"]
1784
+ },
1785
+ "post": {
1786
+ "operationId": "MarketplaceController_createMarketplaceItem",
1787
+ "parameters": [],
1788
+ "requestBody": {
1789
+ "required": true,
1790
+ "content": {
1791
+ "application/json": {
1792
+ "schema": {
1793
+ "$ref": "#/components/schemas/MarketplaceItemCreateDto"
1794
+ }
1795
+ }
1796
+ }
1797
+ },
1798
+ "responses": {
1799
+ "201": {
1800
+ "description": ""
1801
+ }
1802
+ },
1803
+ "security": [
1804
+ {
1805
+ "bearer": []
1806
+ }
1807
+ ],
1808
+ "summary": "Create marketplace item",
1809
+ "tags": ["Marketplace"]
1810
+ }
1811
+ },
1812
+ "/api/marketplace/purchased": {
1813
+ "get": {
1814
+ "operationId": "MarketplaceController_getMarketplacePurchasedItems",
1815
+ "parameters": [
1816
+ {
1817
+ "name": "organizationId",
1818
+ "required": true,
1819
+ "in": "query",
1820
+ "schema": {
1821
+ "example": "123e4567-e89b-12d3-a456-426614174000",
1822
+ "type": "string"
1823
+ }
1824
+ },
1825
+ {
1826
+ "name": "offset",
1827
+ "required": false,
1828
+ "in": "query",
1829
+ "schema": {
1830
+ "example": 0,
1831
+ "type": "number"
1832
+ }
1833
+ },
1834
+ {
1835
+ "name": "limit",
1836
+ "required": false,
1837
+ "in": "query",
1838
+ "schema": {
1839
+ "example": 10,
1840
+ "type": "number"
1841
+ }
1842
+ },
1843
+ {
1844
+ "name": "search",
1845
+ "required": false,
1846
+ "in": "query",
1847
+ "schema": {
1848
+ "example": "search",
1849
+ "type": "string"
1850
+ }
1851
+ }
1852
+ ],
1853
+ "responses": {
1854
+ "200": {
1855
+ "description": "",
1856
+ "content": {
1857
+ "application/json": {
1858
+ "schema": {
1859
+ "$ref": "#/components/schemas/MarketplaceListResponse"
1860
+ }
1861
+ }
1862
+ }
1863
+ }
1864
+ },
1865
+ "summary": "Get marketplace items purchased by the current user",
1866
+ "tags": ["Marketplace"]
1867
+ }
1868
+ },
1869
+ "/api/marketplace/{id}": {
1870
+ "get": {
1871
+ "operationId": "MarketplaceController_getMarketplaceItem",
1872
+ "parameters": [
1873
+ {
1874
+ "name": "id",
1875
+ "required": true,
1876
+ "in": "path",
1877
+ "schema": {
1878
+ "type": "string"
1879
+ }
1880
+ }
1881
+ ],
1882
+ "responses": {
1883
+ "200": {
1884
+ "description": "",
1885
+ "content": {
1886
+ "application/json": {
1887
+ "schema": {
1888
+ "$ref": "#/components/schemas/MarketplaceItemResponse"
1889
+ }
1890
+ }
1891
+ }
1892
+ }
1893
+ },
1894
+ "summary": "Get marketplace item",
1895
+ "tags": ["Marketplace"]
1896
+ },
1897
+ "put": {
1898
+ "operationId": "MarketplaceController_updateMarketplaceItem",
1899
+ "parameters": [
1900
+ {
1901
+ "name": "id",
1902
+ "required": true,
1903
+ "in": "path",
1904
+ "schema": {
1905
+ "type": "string"
1906
+ }
1907
+ }
1908
+ ],
1909
+ "requestBody": {
1910
+ "required": true,
1911
+ "content": {
1912
+ "application/json": {
1913
+ "schema": {
1914
+ "$ref": "#/components/schemas/MarketplaceItemUpdateDto"
1915
+ }
1916
+ }
1917
+ }
1918
+ },
1919
+ "responses": {
1920
+ "200": {
1921
+ "description": ""
1922
+ }
1923
+ },
1924
+ "security": [
1925
+ {
1926
+ "bearer": []
1927
+ }
1928
+ ],
1929
+ "summary": "Update marketplace item",
1930
+ "tags": ["Marketplace"]
1931
+ },
1932
+ "delete": {
1933
+ "operationId": "MarketplaceController_deleteMarketplaceItem",
1934
+ "parameters": [
1935
+ {
1936
+ "name": "id",
1937
+ "required": true,
1938
+ "in": "path",
1939
+ "schema": {
1940
+ "type": "string"
1941
+ }
1942
+ }
1943
+ ],
1944
+ "responses": {
1945
+ "200": {
1946
+ "description": ""
1947
+ }
1948
+ },
1949
+ "security": [
1950
+ {
1951
+ "bearer": []
1952
+ }
1953
+ ],
1954
+ "summary": "Delete marketplace item",
1955
+ "tags": ["Marketplace"]
1956
+ }
1957
+ },
1958
+ "/api/marketplace/purchase": {
1959
+ "post": {
1960
+ "operationId": "MarketplaceController_createPurchase",
1961
+ "parameters": [],
1962
+ "requestBody": {
1963
+ "required": true,
1964
+ "content": {
1965
+ "application/json": {
1966
+ "schema": {
1967
+ "$ref": "#/components/schemas/PurchaseCreateDto"
1968
+ }
1969
+ }
1970
+ }
1971
+ },
1972
+ "responses": {
1973
+ "201": {
1974
+ "description": ""
1975
+ }
1976
+ },
1977
+ "security": [
1978
+ {
1979
+ "bearer": []
1980
+ }
1981
+ ],
1982
+ "summary": "Create purchase",
1983
+ "tags": ["Marketplace"]
1984
+ }
1985
+ },
1986
+ "/api/dashboard/stats": {
1987
+ "get": {
1988
+ "operationId": "DashboardController_getDashboardStats",
1989
+ "parameters": [],
1990
+ "responses": {
1991
+ "200": {
1992
+ "description": "",
1993
+ "content": {
1994
+ "application/json": {
1995
+ "schema": {
1996
+ "$ref": "#/components/schemas/DashboardStatsResponse"
1997
+ }
1998
+ }
1999
+ }
2000
+ }
2001
+ },
2002
+ "security": [
2003
+ {
2004
+ "bearer": []
2005
+ }
2006
+ ],
2007
+ "summary": "Get user stats",
2008
+ "tags": ["Dashboard"]
2009
+ }
2010
+ },
2011
+ "/api/dashboard/recent": {
2012
+ "get": {
2013
+ "operationId": "DashboardController_getRecentScenarios",
2014
+ "parameters": [],
2015
+ "responses": {
2016
+ "200": {
2017
+ "description": "",
2018
+ "content": {
2019
+ "application/json": {
2020
+ "schema": {
2021
+ "type": "array",
2022
+ "items": {
2023
+ "$ref": "#/components/schemas/DashboardRecentScenariosResponse"
2024
+ }
2025
+ }
2026
+ }
2027
+ }
2028
+ }
2029
+ },
2030
+ "security": [
2031
+ {
2032
+ "bearer": []
2033
+ }
2034
+ ],
2035
+ "summary": "Get recent scenarios",
2036
+ "tags": ["Dashboard"]
2037
+ }
2038
+ },
2039
+ "/api/dashboard/suggestions": {
2040
+ "get": {
2041
+ "operationId": "DashboardController_getSuggestions",
2042
+ "parameters": [],
2043
+ "responses": {
2044
+ "200": {
2045
+ "description": "",
2046
+ "content": {
2047
+ "application/json": {
2048
+ "schema": {
2049
+ "type": "array",
2050
+ "items": {
2051
+ "$ref": "#/components/schemas/DashboardSuggestionsResponse"
2052
+ }
2053
+ }
2054
+ }
2055
+ }
2056
+ }
2057
+ },
2058
+ "security": [
2059
+ {
2060
+ "bearer": []
2061
+ }
2062
+ ],
2063
+ "summary": "Get suggestions",
2064
+ "tags": ["Dashboard"]
2065
+ }
2066
+ }
2067
+ },
2068
+ "info": {
2069
+ "title": "FenceApp",
2070
+ "description": "FenceApp API",
2071
+ "version": "1.0",
2072
+ "contact": {}
2073
+ },
2074
+ "tags": [],
2075
+ "servers": [],
2076
+ "components": {
2077
+ "securitySchemes": {
2078
+ "bearer": {
2079
+ "scheme": "bearer",
2080
+ "bearerFormat": "JWT",
2081
+ "type": "http"
2082
+ }
2083
+ },
2084
+ "schemas": {
2085
+ "SignupDto": {
2086
+ "type": "object",
2087
+ "properties": {
2088
+ "email": {
2089
+ "type": "string",
2090
+ "example": "user@example.com"
2091
+ },
2092
+ "password": {
2093
+ "type": "string",
2094
+ "example": "password123"
2095
+ },
2096
+ "name": {
2097
+ "type": "string",
2098
+ "example": "John Doe"
2099
+ },
2100
+ "token": {
2101
+ "type": "string",
2102
+ "example": "token123"
2103
+ }
2104
+ },
2105
+ "required": ["email", "password", "name"]
2106
+ },
2107
+ "SignupSuccessDto": {
2108
+ "type": "object",
2109
+ "properties": {
2110
+ "accessToken": {
2111
+ "type": "string",
2112
+ "description": "accessToken"
2113
+ },
2114
+ "refreshToken": {
2115
+ "type": "string",
2116
+ "description": "refreshToken"
2117
+ }
2118
+ },
2119
+ "required": ["accessToken", "refreshToken"]
2120
+ },
2121
+ "LoginDto": {
2122
+ "type": "object",
2123
+ "properties": {
2124
+ "email": {
2125
+ "type": "string",
2126
+ "example": "user@example.com"
2127
+ },
2128
+ "password": {
2129
+ "type": "string",
2130
+ "example": "password123"
2131
+ }
2132
+ },
2133
+ "required": ["email", "password"]
2134
+ },
2135
+ "UserResponse": {
2136
+ "type": "object",
2137
+ "properties": {
2138
+ "id": {
2139
+ "type": "string",
2140
+ "description": "The user's id"
2141
+ },
2142
+ "organizationId": {
2143
+ "type": "string",
2144
+ "description": "The user's organization id"
2145
+ },
2146
+ "organization": {
2147
+ "type": "string",
2148
+ "description": "The user's organization name"
2149
+ },
2150
+ "name": {
2151
+ "type": "string",
2152
+ "description": "The user's name"
2153
+ },
2154
+ "email": {
2155
+ "type": "string",
2156
+ "description": "The user's email"
2157
+ },
2158
+ "role": {
2159
+ "type": "string",
2160
+ "description": "The user's role",
2161
+ "enum": ["ADMIN", "CREATOR", "USER"]
2162
+ },
2163
+ "createdAt": {
2164
+ "format": "date-time",
2165
+ "type": "string",
2166
+ "description": "The user's created at"
2167
+ },
2168
+ "updatedAt": {
2169
+ "format": "date-time",
2170
+ "type": "string",
2171
+ "description": "The user's updated at"
2172
+ },
2173
+ "lastLogin": {
2174
+ "format": "date-time",
2175
+ "type": "string",
2176
+ "description": "The user's last login"
2177
+ },
2178
+ "rank": {
2179
+ "type": "string",
2180
+ "description": "The user's rank"
2181
+ },
2182
+ "points": {
2183
+ "type": "number",
2184
+ "description": "The user's points"
2185
+ },
2186
+ "onboarded": {
2187
+ "type": "boolean",
2188
+ "description": "The user's onboarded status"
2189
+ }
2190
+ },
2191
+ "required": [
2192
+ "id",
2193
+ "organizationId",
2194
+ "organization",
2195
+ "name",
2196
+ "email",
2197
+ "role",
2198
+ "createdAt",
2199
+ "updatedAt",
2200
+ "lastLogin",
2201
+ "rank",
2202
+ "points",
2203
+ "onboarded"
2204
+ ]
2205
+ },
2206
+ "MessageDto": {
2207
+ "type": "object",
2208
+ "properties": {
2209
+ "message": {
2210
+ "type": "string",
2211
+ "description": "message"
2212
+ }
2213
+ },
2214
+ "required": ["message"]
2215
+ },
2216
+ "ResetPasswordDto": {
2217
+ "type": "object",
2218
+ "properties": {
2219
+ "email": {
2220
+ "type": "string",
2221
+ "example": "user@example.com"
2222
+ }
2223
+ },
2224
+ "required": ["email"]
2225
+ },
2226
+ "NewPasswordDto": {
2227
+ "type": "object",
2228
+ "properties": {
2229
+ "password": {
2230
+ "type": "string",
2231
+ "example": "newpassword123"
2232
+ },
2233
+ "token": {
2234
+ "type": "string"
2235
+ }
2236
+ },
2237
+ "required": ["password", "token"]
2238
+ },
2239
+ "TwoFactorCodeDto": {
2240
+ "type": "object",
2241
+ "properties": {
2242
+ "code": {
2243
+ "type": "string",
2244
+ "example": "123456"
2245
+ }
2246
+ },
2247
+ "required": ["code"]
2248
+ },
2249
+ "UserResponseDto": {
2250
+ "type": "object",
2251
+ "properties": {
2252
+ "id": {
2253
+ "type": "string",
2254
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2255
+ },
2256
+ "name": {
2257
+ "type": "string",
2258
+ "example": "John Doe"
2259
+ },
2260
+ "email": {
2261
+ "type": "string",
2262
+ "example": "john@example.com"
2263
+ },
2264
+ "avatarUrl": {
2265
+ "type": "string",
2266
+ "example": "https://example.com/avatar.jpg"
2267
+ },
2268
+ "createdAt": {
2269
+ "format": "date-time",
2270
+ "type": "string",
2271
+ "example": "2024-03-20T12:00:00Z"
2272
+ },
2273
+ "updatedAt": {
2274
+ "format": "date-time",
2275
+ "type": "string",
2276
+ "example": "2024-03-20T12:00:00Z"
2277
+ },
2278
+ "userOrganizations": {
2279
+ "example": [
2280
+ {
2281
+ "organizationId": "123e4567-e89b-12d3-a456-426614174000",
2282
+ "role": "ADMIN"
2283
+ }
2284
+ ],
2285
+ "type": "array",
2286
+ "items": {
2287
+ "type": "string"
2288
+ }
2289
+ }
2290
+ },
2291
+ "required": ["id", "name", "email", "avatarUrl", "createdAt", "updatedAt", "userOrganizations"]
2292
+ },
2293
+ "UpdateUserDto": {
2294
+ "type": "object",
2295
+ "properties": {
2296
+ "name": {
2297
+ "type": "string",
2298
+ "description": "The user's name"
2299
+ },
2300
+ "position": {
2301
+ "type": "string",
2302
+ "description": "The user's position"
2303
+ },
2304
+ "department": {
2305
+ "type": "string",
2306
+ "description": "The user's department"
2307
+ },
2308
+ "twoFactorEnabled": {
2309
+ "type": "boolean",
2310
+ "description": "The user's two factor enabled"
2311
+ },
2312
+ "groups": {
2313
+ "description": "User's groups",
2314
+ "type": "array",
2315
+ "items": {
2316
+ "type": "string"
2317
+ }
2318
+ }
2319
+ }
2320
+ },
2321
+ "CategoryResponseDto": {
2322
+ "type": "object",
2323
+ "properties": {
2324
+ "id": {
2325
+ "type": "string",
2326
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2327
+ },
2328
+ "name": {
2329
+ "type": "string",
2330
+ "example": "Category Name"
2331
+ },
2332
+ "description": {
2333
+ "type": "string",
2334
+ "example": "Category Description"
2335
+ },
2336
+ "createdAt": {
2337
+ "format": "date-time",
2338
+ "type": "string",
2339
+ "example": "2024-03-20T12:00:00Z"
2340
+ },
2341
+ "updatedAt": {
2342
+ "format": "date-time",
2343
+ "type": "string",
2344
+ "example": "2024-03-20T12:00:00Z"
2345
+ }
2346
+ },
2347
+ "required": ["id", "name", "description", "createdAt", "updatedAt"]
2348
+ },
2349
+ "CategoryListResponse": {
2350
+ "type": "object",
2351
+ "properties": {
2352
+ "offset": {
2353
+ "type": "number",
2354
+ "example": 0
2355
+ },
2356
+ "limit": {
2357
+ "type": "number",
2358
+ "example": 10
2359
+ },
2360
+ "total": {
2361
+ "type": "number",
2362
+ "example": 100
2363
+ },
2364
+ "data": {
2365
+ "type": "array",
2366
+ "items": {
2367
+ "$ref": "#/components/schemas/CategoryResponseDto"
2368
+ }
2369
+ }
2370
+ },
2371
+ "required": ["offset", "limit", "total", "data"]
2372
+ },
2373
+ "CategoryCreateDto": {
2374
+ "type": "object",
2375
+ "properties": {
2376
+ "name": {
2377
+ "type": "string",
2378
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2379
+ },
2380
+ "description": {
2381
+ "type": "string",
2382
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2383
+ }
2384
+ },
2385
+ "required": ["name", "description"]
2386
+ },
2387
+ "CategoryUpdateDto": {
2388
+ "type": "object",
2389
+ "properties": {
2390
+ "name": {
2391
+ "type": "string",
2392
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2393
+ },
2394
+ "description": {
2395
+ "type": "string",
2396
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2397
+ },
2398
+ "contentIds": {
2399
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2400
+ "type": "array",
2401
+ "items": {
2402
+ "type": "string"
2403
+ }
2404
+ }
2405
+ },
2406
+ "required": ["name", "description", "contentIds"]
2407
+ },
2408
+ "ContentTaskResponse": {
2409
+ "type": "object",
2410
+ "properties": {
2411
+ "id": {
2412
+ "type": "string",
2413
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2414
+ },
2415
+ "title": {
2416
+ "type": "string",
2417
+ "example": "Task 1"
2418
+ },
2419
+ "description": {
2420
+ "type": "string",
2421
+ "example": "Learn how to identify and exploit network vulnerabilities safely."
2422
+ },
2423
+ "type": {
2424
+ "type": "object",
2425
+ "example": "radio"
2426
+ }
2427
+ },
2428
+ "required": ["id", "title", "description", "type"]
2429
+ },
2430
+ "ContentGoalResponse": {
2431
+ "type": "object",
2432
+ "properties": {
2433
+ "name": {
2434
+ "type": "string",
2435
+ "example": "Goal 1"
2436
+ },
2437
+ "description": {
2438
+ "type": "string",
2439
+ "example": "Description 1"
2440
+ }
2441
+ },
2442
+ "required": ["name", "description"]
2443
+ },
2444
+ "ContentAnswer": {
2445
+ "type": "object",
2446
+ "properties": {
2447
+ "taskId": {
2448
+ "type": "string",
2449
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2450
+ },
2451
+ "answer": {
2452
+ "type": "string",
2453
+ "example": "some-choice-id"
2454
+ },
2455
+ "selectedAnswer": {
2456
+ "type": "string",
2457
+ "example": "some-choice-id"
2458
+ }
2459
+ },
2460
+ "required": ["taskId", "answer", "selectedAnswer"]
2461
+ },
2462
+ "ContentItemResponse": {
2463
+ "type": "object",
2464
+ "properties": {
2465
+ "content": {
2466
+ "$ref": "#/components/schemas/ContentItemDto"
2467
+ }
2468
+ },
2469
+ "required": ["content"]
2470
+ },
2471
+ "ContentItemListResponse": {
2472
+ "type": "object",
2473
+ "properties": {
2474
+ "offset": {
2475
+ "type": "number",
2476
+ "example": 0
2477
+ },
2478
+ "limit": {
2479
+ "type": "number",
2480
+ "example": 10
2481
+ },
2482
+ "total": {
2483
+ "type": "number",
2484
+ "example": 100
2485
+ },
2486
+ "data": {
2487
+ "type": "array",
2488
+ "items": {
2489
+ "$ref": "#/components/schemas/ContentItemResponse"
2490
+ }
2491
+ }
2492
+ },
2493
+ "required": ["offset", "limit", "total", "data"]
2494
+ },
2495
+ "ContentTaskDto": {
2496
+ "type": "object",
2497
+ "properties": {
2498
+ "id": {
2499
+ "type": "string",
2500
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2501
+ },
2502
+ "title": {
2503
+ "type": "string",
2504
+ "example": "Task 1"
2505
+ },
2506
+ "description": {
2507
+ "type": "string",
2508
+ "example": "Learn how to identify and exploit network vulnerabilities safely."
2509
+ },
2510
+ "type": {
2511
+ "type": "string",
2512
+ "example": "radio",
2513
+ "enum": ["lecture", "radio", "checkbox", "ranking", "quiz", "virtual"]
2514
+ }
2515
+ },
2516
+ "required": ["id", "title", "description", "type"]
2517
+ },
2518
+ "ContentGoalDto": {
2519
+ "type": "object",
2520
+ "properties": {
2521
+ "name": {
2522
+ "type": "string",
2523
+ "example": "Goal 1"
2524
+ },
2525
+ "description": {
2526
+ "type": "string",
2527
+ "example": "Description 1"
2528
+ }
2529
+ },
2530
+ "required": ["name", "description"]
2531
+ },
2532
+ "ContentItemDto": {
2533
+ "type": "object",
2534
+ "properties": {
2535
+ "title": {
2536
+ "type": "string",
2537
+ "example": "Network Penetration Testing"
2538
+ },
2539
+ "description": {
2540
+ "type": "string",
2541
+ "example": "Learn how to identify and exploit network vulnerabilities safely."
2542
+ },
2543
+ "image": {
2544
+ "type": "string",
2545
+ "example": "/images/cybsec.webp"
2546
+ },
2547
+ "introduction": {
2548
+ "type": "string",
2549
+ "example": "Introduction to Network Penetration Testing"
2550
+ },
2551
+ "conclusion": {
2552
+ "type": "string",
2553
+ "example": "Great job! You've learned how to identify and exploit network vulnerabilities safely."
2554
+ },
2555
+ "marketing": {
2556
+ "type": "string",
2557
+ "example": "In this course, you will learn how to identify and exploit network vulnerabilities safely."
2558
+ },
2559
+ "tasks": {
2560
+ "type": "array",
2561
+ "items": {
2562
+ "$ref": "#/components/schemas/ContentTaskDto"
2563
+ }
2564
+ },
2565
+ "goals": {
2566
+ "type": "array",
2567
+ "items": {
2568
+ "$ref": "#/components/schemas/ContentGoalDto"
2569
+ }
2570
+ },
2571
+ "categories": {
2572
+ "example": ["Category 1", "Category 2"],
2573
+ "type": "array",
2574
+ "items": {
2575
+ "type": "string"
2576
+ }
2577
+ }
2578
+ },
2579
+ "required": [
2580
+ "title",
2581
+ "description",
2582
+ "image",
2583
+ "introduction",
2584
+ "conclusion",
2585
+ "marketing",
2586
+ "tasks",
2587
+ "goals",
2588
+ "categories"
2589
+ ]
2590
+ },
2591
+ "ContentGroupDto": {
2592
+ "type": "object",
2593
+ "properties": {
2594
+ "groupId": {
2595
+ "type": "string",
2596
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2597
+ },
2598
+ "required": {
2599
+ "type": "boolean",
2600
+ "example": true
2601
+ }
2602
+ },
2603
+ "required": ["groupId", "required"]
2604
+ },
2605
+ "ContentCreateDto": {
2606
+ "type": "object",
2607
+ "properties": {
2608
+ "title": {
2609
+ "type": "string",
2610
+ "example": "Content title"
2611
+ },
2612
+ "description": {
2613
+ "type": "string",
2614
+ "example": "Content description"
2615
+ },
2616
+ "difficulty": {
2617
+ "type": "string",
2618
+ "example": "Content difficulty"
2619
+ },
2620
+ "marketing": {
2621
+ "type": "string",
2622
+ "example": "Super awesome content"
2623
+ },
2624
+ "introduction": {
2625
+ "type": "string",
2626
+ "example": "Content introduction"
2627
+ },
2628
+ "conclusion": {
2629
+ "type": "string",
2630
+ "example": "Content conclusion"
2631
+ },
2632
+ "groupRelation": {
2633
+ "type": "array",
2634
+ "items": {
2635
+ "$ref": "#/components/schemas/ContentGroupDto"
2636
+ }
2637
+ },
2638
+ "goals": {
2639
+ "type": "array",
2640
+ "items": {
2641
+ "$ref": "#/components/schemas/ContentGoalDto"
2642
+ }
2643
+ },
2644
+ "tasks": {
2645
+ "type": "array",
2646
+ "items": {
2647
+ "$ref": "#/components/schemas/"
2648
+ }
2649
+ },
2650
+ "categoryIds": {
2651
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2652
+ "type": "array",
2653
+ "items": {
2654
+ "type": "string"
2655
+ }
2656
+ },
2657
+ "pathIds": {
2658
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2659
+ "type": "array",
2660
+ "items": {
2661
+ "type": "string"
2662
+ }
2663
+ },
2664
+ "price": {
2665
+ "type": "number",
2666
+ "example": 100
2667
+ }
2668
+ },
2669
+ "required": [
2670
+ "title",
2671
+ "description",
2672
+ "difficulty",
2673
+ "marketing",
2674
+ "introduction",
2675
+ "conclusion",
2676
+ "groupRelation",
2677
+ "goals",
2678
+ "tasks",
2679
+ "categoryIds",
2680
+ "pathIds"
2681
+ ]
2682
+ },
2683
+ "ContentUpdateDto": {
2684
+ "type": "object",
2685
+ "properties": {
2686
+ "title": {
2687
+ "type": "string",
2688
+ "example": "Content title"
2689
+ },
2690
+ "description": {
2691
+ "type": "string",
2692
+ "example": "Content description"
2693
+ },
2694
+ "difficulty": {
2695
+ "type": "string",
2696
+ "example": "Content difficulty"
2697
+ },
2698
+ "marketing": {
2699
+ "type": "string",
2700
+ "example": "Super awesome content"
2701
+ },
2702
+ "introduction": {
2703
+ "type": "string",
2704
+ "example": "Content introduction"
2705
+ },
2706
+ "conclusion": {
2707
+ "type": "string",
2708
+ "example": "Content conclusion"
2709
+ },
2710
+ "groupRelation": {
2711
+ "type": "array",
2712
+ "items": {
2713
+ "$ref": "#/components/schemas/ContentGroupDto"
2714
+ }
2715
+ },
2716
+ "goals": {
2717
+ "type": "array",
2718
+ "items": {
2719
+ "$ref": "#/components/schemas/ContentGoalDto"
2720
+ }
2721
+ },
2722
+ "tasks": {
2723
+ "type": "array",
2724
+ "items": {
2725
+ "$ref": "#/components/schemas/"
2726
+ }
2727
+ },
2728
+ "categoryIds": {
2729
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2730
+ "type": "array",
2731
+ "items": {
2732
+ "type": "string"
2733
+ }
2734
+ },
2735
+ "pathIds": {
2736
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2737
+ "type": "array",
2738
+ "items": {
2739
+ "type": "string"
2740
+ }
2741
+ },
2742
+ "price": {
2743
+ "type": "number",
2744
+ "example": 100
2745
+ }
2746
+ },
2747
+ "required": [
2748
+ "title",
2749
+ "description",
2750
+ "difficulty",
2751
+ "marketing",
2752
+ "introduction",
2753
+ "conclusion",
2754
+ "groupRelation",
2755
+ "goals",
2756
+ "tasks",
2757
+ "categoryIds",
2758
+ "pathIds"
2759
+ ]
2760
+ },
2761
+ "ContentImageDto": {
2762
+ "type": "object",
2763
+ "properties": {
2764
+ "image": {
2765
+ "type": "object",
2766
+ "properties": {
2767
+ "image": {
2768
+ "type": "string",
2769
+ "format": "binary"
2770
+ }
2771
+ }
2772
+ }
2773
+ },
2774
+ "required": ["image"]
2775
+ },
2776
+ "ContentImageResponse": {
2777
+ "type": "object",
2778
+ "properties": {
2779
+ "image": {
2780
+ "type": "string",
2781
+ "example": "/images/cybsec.webp"
2782
+ }
2783
+ },
2784
+ "required": ["image"]
2785
+ },
2786
+ "ContentAnswerDto": {
2787
+ "type": "object",
2788
+ "properties": {
2789
+ "id": {
2790
+ "type": "string",
2791
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2792
+ },
2793
+ "taskId": {
2794
+ "type": "string",
2795
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2796
+ },
2797
+ "answer": {
2798
+ "type": "object",
2799
+ "example": "true"
2800
+ }
2801
+ },
2802
+ "required": ["id", "taskId", "answer"]
2803
+ },
2804
+ "ContentAnswerResponse": {
2805
+ "type": "object",
2806
+ "properties": {
2807
+ "id": {
2808
+ "type": "string",
2809
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2810
+ },
2811
+ "taskId": {
2812
+ "type": "string",
2813
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2814
+ },
2815
+ "answer": {
2816
+ "type": "object",
2817
+ "example": "true"
2818
+ }
2819
+ },
2820
+ "required": ["id", "taskId", "answer"]
2821
+ },
2822
+ "GroupContentDto": {
2823
+ "type": "object",
2824
+ "properties": {
2825
+ "contentId": {
2826
+ "type": "string",
2827
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2828
+ },
2829
+ "required": {
2830
+ "type": "boolean",
2831
+ "example": true
2832
+ }
2833
+ },
2834
+ "required": ["contentId", "required"]
2835
+ },
2836
+ "GroupResponseDto": {
2837
+ "type": "object",
2838
+ "properties": {
2839
+ "id": {
2840
+ "type": "string",
2841
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2842
+ },
2843
+ "name": {
2844
+ "type": "string",
2845
+ "example": "Group name"
2846
+ },
2847
+ "groupContent": {
2848
+ "type": "array",
2849
+ "items": {
2850
+ "$ref": "#/components/schemas/GroupContentDto"
2851
+ }
2852
+ },
2853
+ "userIds": {
2854
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2855
+ "type": "array",
2856
+ "items": {
2857
+ "type": "string"
2858
+ }
2859
+ },
2860
+ "createdAt": {
2861
+ "format": "date-time",
2862
+ "type": "string",
2863
+ "example": "2024-03-20T12:00:00Z"
2864
+ },
2865
+ "updatedAt": {
2866
+ "format": "date-time",
2867
+ "type": "string",
2868
+ "example": "2024-03-20T12:00:00Z"
2869
+ }
2870
+ },
2871
+ "required": ["id", "name", "groupContent", "userIds", "createdAt", "updatedAt"]
2872
+ },
2873
+ "GroupListResponse": {
2874
+ "type": "object",
2875
+ "properties": {
2876
+ "offset": {
2877
+ "type": "number",
2878
+ "example": 0
2879
+ },
2880
+ "limit": {
2881
+ "type": "number",
2882
+ "example": 10
2883
+ },
2884
+ "total": {
2885
+ "type": "number",
2886
+ "example": 100
2887
+ },
2888
+ "data": {
2889
+ "type": "array",
2890
+ "items": {
2891
+ "$ref": "#/components/schemas/GroupResponseDto"
2892
+ }
2893
+ }
2894
+ },
2895
+ "required": ["offset", "limit", "total", "data"]
2896
+ },
2897
+ "GroupCreateDto": {
2898
+ "type": "object",
2899
+ "properties": {
2900
+ "name": {
2901
+ "type": "string",
2902
+ "example": "Group name"
2903
+ },
2904
+ "groupContent": {
2905
+ "type": "array",
2906
+ "items": {
2907
+ "$ref": "#/components/schemas/GroupContentDto"
2908
+ }
2909
+ },
2910
+ "userIds": {
2911
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2912
+ "type": "array",
2913
+ "items": {
2914
+ "type": "string"
2915
+ }
2916
+ }
2917
+ },
2918
+ "required": ["name", "groupContent"]
2919
+ },
2920
+ "GroupUpdateDto": {
2921
+ "type": "object",
2922
+ "properties": {
2923
+ "name": {
2924
+ "type": "string",
2925
+ "example": "Group name"
2926
+ },
2927
+ "groupContent": {
2928
+ "type": "array",
2929
+ "items": {
2930
+ "$ref": "#/components/schemas/GroupContentDto"
2931
+ }
2932
+ },
2933
+ "userIds": {
2934
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
2935
+ "type": "array",
2936
+ "items": {
2937
+ "type": "string"
2938
+ }
2939
+ }
2940
+ },
2941
+ "required": ["name", "groupContent"]
2942
+ },
2943
+ "OrganizationResponseDto": {
2944
+ "type": "object",
2945
+ "properties": {
2946
+ "id": {
2947
+ "type": "string",
2948
+ "example": "123e4567-e89b-12d3-a456-426614174000"
2949
+ },
2950
+ "name": {
2951
+ "type": "string",
2952
+ "example": "Organization name"
2953
+ },
2954
+ "companyName": {
2955
+ "type": "string",
2956
+ "example": "Company name"
2957
+ },
2958
+ "vatId": {
2959
+ "type": "string",
2960
+ "example": "VAT ID"
2961
+ },
2962
+ "addressStreet": {
2963
+ "type": "string",
2964
+ "example": "Address street"
2965
+ },
2966
+ "addressFlat": {
2967
+ "type": "string",
2968
+ "example": "Address flat"
2969
+ },
2970
+ "addressCity": {
2971
+ "type": "string",
2972
+ "example": "Address city"
2973
+ },
2974
+ "addressState": {
2975
+ "type": "string",
2976
+ "example": "Address state"
2977
+ },
2978
+ "addressZip": {
2979
+ "type": "string",
2980
+ "example": "Address zip"
2981
+ },
2982
+ "addressCountry": {
2983
+ "type": "string",
2984
+ "example": "Address country"
2985
+ },
2986
+ "websiteUrl": {
2987
+ "type": "string",
2988
+ "example": "Website URL"
2989
+ },
2990
+ "size": {
2991
+ "type": "string",
2992
+ "example": "Size"
2993
+ },
2994
+ "industry": {
2995
+ "type": "string",
2996
+ "example": "Industry"
2997
+ },
2998
+ "ownerId": {
2999
+ "type": "string",
3000
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3001
+ },
3002
+ "createdAt": {
3003
+ "format": "date-time",
3004
+ "type": "string",
3005
+ "example": "2024-03-20T12:00:00Z"
3006
+ },
3007
+ "updatedAt": {
3008
+ "format": "date-time",
3009
+ "type": "string",
3010
+ "example": "2024-03-20T12:00:00Z"
3011
+ }
3012
+ },
3013
+ "required": [
3014
+ "id",
3015
+ "name",
3016
+ "companyName",
3017
+ "vatId",
3018
+ "addressStreet",
3019
+ "addressCity",
3020
+ "addressZip",
3021
+ "addressCountry",
3022
+ "websiteUrl",
3023
+ "size",
3024
+ "industry",
3025
+ "ownerId",
3026
+ "createdAt",
3027
+ "updatedAt"
3028
+ ]
3029
+ },
3030
+ "OrganizationListResponse": {
3031
+ "type": "object",
3032
+ "properties": {
3033
+ "offset": {
3034
+ "type": "number",
3035
+ "example": 0
3036
+ },
3037
+ "limit": {
3038
+ "type": "number",
3039
+ "example": 10
3040
+ },
3041
+ "total": {
3042
+ "type": "number",
3043
+ "example": 100
3044
+ },
3045
+ "data": {
3046
+ "type": "array",
3047
+ "items": {
3048
+ "$ref": "#/components/schemas/OrganizationResponseDto"
3049
+ }
3050
+ }
3051
+ },
3052
+ "required": ["offset", "limit", "total", "data"]
3053
+ },
3054
+ "CreateOrganizationDto": {
3055
+ "type": "object",
3056
+ "properties": {
3057
+ "name": {
3058
+ "type": "string",
3059
+ "example": "Organization name"
3060
+ },
3061
+ "companyName": {
3062
+ "type": "string",
3063
+ "example": "Company name"
3064
+ },
3065
+ "vatId": {
3066
+ "type": "string",
3067
+ "example": "VAT ID"
3068
+ },
3069
+ "addressStreet": {
3070
+ "type": "string",
3071
+ "example": "Address street"
3072
+ },
3073
+ "addressFlat": {
3074
+ "type": "string",
3075
+ "example": "Address flat"
3076
+ },
3077
+ "addressCity": {
3078
+ "type": "string",
3079
+ "example": "Address city"
3080
+ },
3081
+ "addressState": {
3082
+ "type": "string",
3083
+ "example": "Address state"
3084
+ },
3085
+ "addressZip": {
3086
+ "type": "string",
3087
+ "example": "Address zip"
3088
+ },
3089
+ "addressCountry": {
3090
+ "type": "string",
3091
+ "example": "Address country"
3092
+ },
3093
+ "websiteUrl": {
3094
+ "type": "string",
3095
+ "example": "Website URL"
3096
+ },
3097
+ "size": {
3098
+ "type": "string",
3099
+ "example": "Size"
3100
+ },
3101
+ "industry": {
3102
+ "type": "string",
3103
+ "example": "Industry"
3104
+ }
3105
+ },
3106
+ "required": [
3107
+ "name",
3108
+ "companyName",
3109
+ "vatId",
3110
+ "addressStreet",
3111
+ "addressCity",
3112
+ "addressState",
3113
+ "addressZip",
3114
+ "addressCountry",
3115
+ "websiteUrl",
3116
+ "size",
3117
+ "industry"
3118
+ ]
3119
+ },
3120
+ "UpdateOrganizationDto": {
3121
+ "type": "object",
3122
+ "properties": {
3123
+ "name": {
3124
+ "type": "string",
3125
+ "example": "Organization name"
3126
+ },
3127
+ "companyName": {
3128
+ "type": "string",
3129
+ "example": "Company name"
3130
+ },
3131
+ "vatId": {
3132
+ "type": "string",
3133
+ "example": "VAT ID"
3134
+ },
3135
+ "addressStreet": {
3136
+ "type": "string",
3137
+ "example": "Address street"
3138
+ },
3139
+ "addressFlat": {
3140
+ "type": "string",
3141
+ "example": "Address flat"
3142
+ },
3143
+ "addressCity": {
3144
+ "type": "string",
3145
+ "example": "Address city"
3146
+ },
3147
+ "addressState": {
3148
+ "type": "string",
3149
+ "example": "Address state"
3150
+ },
3151
+ "addressZip": {
3152
+ "type": "string",
3153
+ "example": "Address zip"
3154
+ },
3155
+ "addressCountry": {
3156
+ "type": "string",
3157
+ "example": "Address country"
3158
+ },
3159
+ "websiteUrl": {
3160
+ "type": "string",
3161
+ "example": "Website URL"
3162
+ },
3163
+ "size": {
3164
+ "type": "string",
3165
+ "example": "Size"
3166
+ },
3167
+ "industry": {
3168
+ "type": "string",
3169
+ "example": "Industry"
3170
+ }
3171
+ },
3172
+ "required": [
3173
+ "name",
3174
+ "companyName",
3175
+ "vatId",
3176
+ "addressStreet",
3177
+ "addressCity",
3178
+ "addressState",
3179
+ "addressZip",
3180
+ "addressCountry",
3181
+ "websiteUrl",
3182
+ "size",
3183
+ "industry"
3184
+ ]
3185
+ },
3186
+ "PathResponseDto": {
3187
+ "type": "object",
3188
+ "properties": {
3189
+ "id": {
3190
+ "type": "string",
3191
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3192
+ },
3193
+ "name": {
3194
+ "type": "string",
3195
+ "example": "Path name"
3196
+ },
3197
+ "description": {
3198
+ "type": "string",
3199
+ "example": "Path description"
3200
+ },
3201
+ "contentIds": {
3202
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
3203
+ "type": "array",
3204
+ "items": {
3205
+ "type": "string"
3206
+ }
3207
+ },
3208
+ "createdAt": {
3209
+ "format": "date-time",
3210
+ "type": "string",
3211
+ "example": "2024-03-20T12:00:00Z"
3212
+ },
3213
+ "updatedAt": {
3214
+ "format": "date-time",
3215
+ "type": "string",
3216
+ "example": "2024-03-20T12:00:00Z"
3217
+ }
3218
+ },
3219
+ "required": ["id", "name", "description", "contentIds", "createdAt", "updatedAt"]
3220
+ },
3221
+ "PathListResponse": {
3222
+ "type": "object",
3223
+ "properties": {
3224
+ "offset": {
3225
+ "type": "number",
3226
+ "example": 0
3227
+ },
3228
+ "limit": {
3229
+ "type": "number",
3230
+ "example": 10
3231
+ },
3232
+ "total": {
3233
+ "type": "number",
3234
+ "example": 100
3235
+ },
3236
+ "data": {
3237
+ "type": "array",
3238
+ "items": {
3239
+ "$ref": "#/components/schemas/PathResponseDto"
3240
+ }
3241
+ }
3242
+ },
3243
+ "required": ["offset", "limit", "total", "data"]
3244
+ },
3245
+ "PathCreateDto": {
3246
+ "type": "object",
3247
+ "properties": {
3248
+ "name": {
3249
+ "type": "string",
3250
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3251
+ },
3252
+ "description": {
3253
+ "type": "string",
3254
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3255
+ },
3256
+ "contentIds": {
3257
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
3258
+ "type": "array",
3259
+ "items": {
3260
+ "type": "string"
3261
+ }
3262
+ }
3263
+ },
3264
+ "required": ["name", "description"]
3265
+ },
3266
+ "PathUpdateDto": {
3267
+ "type": "object",
3268
+ "properties": {
3269
+ "name": {
3270
+ "type": "string",
3271
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3272
+ },
3273
+ "description": {
3274
+ "type": "string",
3275
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3276
+ },
3277
+ "contentIds": {
3278
+ "example": ["123e4567-e89b-12d3-a456-426614174000"],
3279
+ "type": "array",
3280
+ "items": {
3281
+ "type": "string"
3282
+ }
3283
+ }
3284
+ },
3285
+ "required": ["name", "description"]
3286
+ },
3287
+ "UserListResponse": {
3288
+ "type": "object",
3289
+ "properties": {
3290
+ "offset": {
3291
+ "type": "number",
3292
+ "example": 0
3293
+ },
3294
+ "limit": {
3295
+ "type": "number",
3296
+ "example": 10
3297
+ },
3298
+ "total": {
3299
+ "type": "number",
3300
+ "example": 100
3301
+ },
3302
+ "data": {
3303
+ "type": "array",
3304
+ "items": {
3305
+ "$ref": "#/components/schemas/UserResponseDto"
3306
+ }
3307
+ }
3308
+ },
3309
+ "required": ["offset", "limit", "total", "data"]
3310
+ },
3311
+ "InviteResponse": {
3312
+ "type": "object",
3313
+ "properties": {
3314
+ "token": {
3315
+ "type": "string",
3316
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3317
+ }
3318
+ },
3319
+ "required": ["token"]
3320
+ },
3321
+ "DeleteUserResponse": {
3322
+ "type": "object",
3323
+ "properties": {
3324
+ "message": {
3325
+ "type": "string",
3326
+ "example": "User deleted from organization"
3327
+ }
3328
+ },
3329
+ "required": ["message"]
3330
+ },
3331
+ "Goal": {
3332
+ "type": "object",
3333
+ "properties": {
3334
+ "name": {
3335
+ "type": "string",
3336
+ "example": "Goal 1"
3337
+ },
3338
+ "description": {
3339
+ "type": "string",
3340
+ "example": "Description 1"
3341
+ }
3342
+ },
3343
+ "required": ["name", "description"]
3344
+ },
3345
+ "MarketplaceItemResponse": {
3346
+ "type": "object",
3347
+ "properties": {
3348
+ "id": {
3349
+ "type": "string",
3350
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3351
+ },
3352
+ "title": {
3353
+ "type": "string",
3354
+ "example": "Network Penetration Testing"
3355
+ },
3356
+ "description": {
3357
+ "type": "string",
3358
+ "example": "Learn how to identify and exploit network vulnerabilities safely."
3359
+ },
3360
+ "marketing": {
3361
+ "type": "string",
3362
+ "example": "This course is for beginners who want to learn how to identify and exploit network vulnerabilities safely."
3363
+ },
3364
+ "image": {
3365
+ "type": "string",
3366
+ "example": "/images/cybsec.webp"
3367
+ },
3368
+ "isPurchased": {
3369
+ "type": "boolean",
3370
+ "example": false
3371
+ },
3372
+ "isCompleted": {
3373
+ "type": "boolean",
3374
+ "example": false
3375
+ },
3376
+ "progress": {
3377
+ "type": "number",
3378
+ "example": 75
3379
+ },
3380
+ "price": {
3381
+ "type": "string",
3382
+ "example": "$100.00"
3383
+ },
3384
+ "categories": {
3385
+ "example": ["Cybersecurity", "Programming"],
3386
+ "type": "array",
3387
+ "items": {
3388
+ "type": "string"
3389
+ }
3390
+ },
3391
+ "goals": {
3392
+ "example": [
3393
+ {
3394
+ "name": "Goal 1",
3395
+ "description": "Description 1"
3396
+ }
3397
+ ],
3398
+ "type": "array",
3399
+ "items": {
3400
+ "$ref": "#/components/schemas/Goal"
3401
+ }
3402
+ },
3403
+ "difficulty": {
3404
+ "type": "string",
3405
+ "example": "Beginner"
3406
+ },
3407
+ "publishedAt": {
3408
+ "type": "string",
3409
+ "example": "2021-01-01"
3410
+ },
3411
+ "organization": {
3412
+ "type": "string",
3413
+ "example": "Organization 1"
3414
+ },
3415
+ "tasksCount": {
3416
+ "type": "number",
3417
+ "example": "100"
3418
+ }
3419
+ },
3420
+ "required": [
3421
+ "id",
3422
+ "title",
3423
+ "description",
3424
+ "marketing",
3425
+ "image",
3426
+ "isPurchased",
3427
+ "isCompleted",
3428
+ "progress",
3429
+ "price",
3430
+ "categories",
3431
+ "goals",
3432
+ "difficulty",
3433
+ "publishedAt",
3434
+ "organization",
3435
+ "tasksCount"
3436
+ ]
3437
+ },
3438
+ "MarketplaceListResponse": {
3439
+ "type": "object",
3440
+ "properties": {
3441
+ "offset": {
3442
+ "type": "number",
3443
+ "example": 0
3444
+ },
3445
+ "limit": {
3446
+ "type": "number",
3447
+ "example": 10
3448
+ },
3449
+ "total": {
3450
+ "type": "number",
3451
+ "example": 100
3452
+ },
3453
+ "data": {
3454
+ "type": "array",
3455
+ "items": {
3456
+ "$ref": "#/components/schemas/MarketplaceItemResponse"
3457
+ }
3458
+ }
3459
+ },
3460
+ "required": ["offset", "limit", "total", "data"]
3461
+ },
3462
+ "MarketplaceItemCreateDto": {
3463
+ "type": "object",
3464
+ "properties": {
3465
+ "contentId": {
3466
+ "type": "string",
3467
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3468
+ },
3469
+ "price": {
3470
+ "type": "number",
3471
+ "example": 100
3472
+ }
3473
+ },
3474
+ "required": ["contentId", "price"]
3475
+ },
3476
+ "MarketplaceItemUpdateDto": {
3477
+ "type": "object",
3478
+ "properties": {
3479
+ "price": {
3480
+ "type": "number",
3481
+ "example": 100
3482
+ }
3483
+ },
3484
+ "required": ["price"]
3485
+ },
3486
+ "PurchaseCreateDto": {
3487
+ "type": "object",
3488
+ "properties": {
3489
+ "marketplaceItemId": {
3490
+ "type": "string",
3491
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3492
+ },
3493
+ "organizationId": {
3494
+ "type": "string",
3495
+ "example": "123e4567-e89b-12d3-a456-426614174000"
3496
+ }
3497
+ },
3498
+ "required": ["marketplaceItemId", "organizationId"]
3499
+ },
3500
+ "DashboardStatsResponse": {
3501
+ "type": "object",
3502
+ "properties": {
3503
+ "completed": {
3504
+ "type": "number",
3505
+ "description": "Completed scenarios"
3506
+ },
3507
+ "started": {
3508
+ "type": "number",
3509
+ "description": "Started scenarios"
3510
+ },
3511
+ "points": {
3512
+ "type": "number",
3513
+ "description": "Points"
3514
+ },
3515
+ "rank": {
3516
+ "type": "object",
3517
+ "description": "Rank"
3518
+ },
3519
+ "nextMilestone": {
3520
+ "type": "object",
3521
+ "description": "Next Milestone"
3522
+ }
3523
+ },
3524
+ "required": ["completed", "started", "points", "rank", "nextMilestone"]
3525
+ },
3526
+ "DashboardRecentScenariosResponse": {
3527
+ "type": "object",
3528
+ "properties": {
3529
+ "id": {
3530
+ "type": "string",
3531
+ "description": "ID"
3532
+ },
3533
+ "title": {
3534
+ "type": "string",
3535
+ "description": "Title"
3536
+ },
3537
+ "description": {
3538
+ "type": "string",
3539
+ "description": "Description"
3540
+ },
3541
+ "progress": {
3542
+ "type": "number",
3543
+ "description": "Progress"
3544
+ },
3545
+ "image": {
3546
+ "type": "string",
3547
+ "description": "Image"
3548
+ },
3549
+ "isCompleted": {
3550
+ "type": "boolean",
3551
+ "description": "Is completed"
3552
+ },
3553
+ "price": {
3554
+ "type": "string",
3555
+ "description": "Price"
3556
+ },
3557
+ "isPurchased": {
3558
+ "type": "boolean",
3559
+ "description": "Is purchased"
3560
+ }
3561
+ },
3562
+ "required": ["id", "title", "description", "progress", "image", "isCompleted", "price", "isPurchased"]
3563
+ },
3564
+ "DashboardSuggestionsResponse": {
3565
+ "type": "object",
3566
+ "properties": {
3567
+ "id": {
3568
+ "type": "string",
3569
+ "description": "ID"
3570
+ },
3571
+ "title": {
3572
+ "type": "string",
3573
+ "description": "Title"
3574
+ },
3575
+ "description": {
3576
+ "type": "string",
3577
+ "description": "Description"
3578
+ },
3579
+ "image": {
3580
+ "type": "string",
3581
+ "description": "Image"
3582
+ },
3583
+ "trending": {
3584
+ "type": "boolean",
3585
+ "description": "Trending"
3586
+ },
3587
+ "isCompleted": {
3588
+ "type": "boolean",
3589
+ "description": "Is completed"
3590
+ },
3591
+ "price": {
3592
+ "type": "string",
3593
+ "description": "Price"
3594
+ },
3595
+ "isPurchased": {
3596
+ "type": "boolean",
3597
+ "description": "Is purchased"
3598
+ }
3599
+ },
3600
+ "required": ["id", "title", "description", "image", "trending", "isCompleted", "price", "isPurchased"]
3601
+ }
3602
+ }
3603
+ }
3604
+ }