@platformatic/service 1.27.0 → 1.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/schema.json ADDED
@@ -0,0 +1,2229 @@
1
+ {
2
+ "$id": "https://platformatic.dev/schemas/v1.28.0/service",
3
+ "version": "1.28.0",
4
+ "title": "Platformatic Service",
5
+ "type": "object",
6
+ "properties": {
7
+ "server": {
8
+ "type": "object",
9
+ "properties": {
10
+ "hostname": {
11
+ "type": "string"
12
+ },
13
+ "port": {
14
+ "anyOf": [
15
+ {
16
+ "type": "integer"
17
+ },
18
+ {
19
+ "type": "string"
20
+ }
21
+ ]
22
+ },
23
+ "pluginTimeout": {
24
+ "type": "integer"
25
+ },
26
+ "healthCheck": {
27
+ "anyOf": [
28
+ {
29
+ "type": "boolean"
30
+ },
31
+ {
32
+ "type": "object",
33
+ "properties": {
34
+ "enabled": {
35
+ "type": "boolean"
36
+ },
37
+ "interval": {
38
+ "type": "integer"
39
+ }
40
+ },
41
+ "additionalProperties": true
42
+ }
43
+ ]
44
+ },
45
+ "ignoreTrailingSlash": {
46
+ "type": "boolean"
47
+ },
48
+ "ignoreDuplicateSlashes": {
49
+ "type": "boolean"
50
+ },
51
+ "connectionTimeout": {
52
+ "type": "integer"
53
+ },
54
+ "keepAliveTimeout": {
55
+ "type": "integer",
56
+ "default": 5000
57
+ },
58
+ "maxRequestsPerSocket": {
59
+ "type": "integer"
60
+ },
61
+ "forceCloseConnections": {
62
+ "anyOf": [
63
+ {
64
+ "type": "boolean"
65
+ },
66
+ {
67
+ "type": "string",
68
+ "pattern": "^idle$"
69
+ }
70
+ ]
71
+ },
72
+ "requestTimeout": {
73
+ "type": "integer"
74
+ },
75
+ "bodyLimit": {
76
+ "type": "integer"
77
+ },
78
+ "maxParamLength": {
79
+ "type": "integer"
80
+ },
81
+ "disableRequestLogging": {
82
+ "type": "boolean"
83
+ },
84
+ "exposeHeadRoutes": {
85
+ "type": "boolean"
86
+ },
87
+ "logger": {
88
+ "anyOf": [
89
+ {
90
+ "type": "boolean"
91
+ },
92
+ {
93
+ "type": "object",
94
+ "properties": {
95
+ "level": {
96
+ "type": "string"
97
+ },
98
+ "transport": {
99
+ "anyOf": [
100
+ {
101
+ "type": "object",
102
+ "properties": {
103
+ "target": {
104
+ "type": "string",
105
+ "resolveModule": true
106
+ },
107
+ "options": {
108
+ "type": "object"
109
+ }
110
+ },
111
+ "additionalProperties": false
112
+ },
113
+ {
114
+ "type": "object",
115
+ "properties": {
116
+ "targets": {
117
+ "type": "array",
118
+ "items": {
119
+ "type": "object",
120
+ "properties": {
121
+ "target": {
122
+ "type": "string",
123
+ "resolveModule": true
124
+ },
125
+ "options": {
126
+ "type": "object"
127
+ },
128
+ "level": {
129
+ "type": "string"
130
+ },
131
+ "additionalProperties": false
132
+ }
133
+ }
134
+ },
135
+ "options": {
136
+ "type": "object"
137
+ }
138
+ },
139
+ "additionalProperties": false
140
+ }
141
+ ]
142
+ },
143
+ "pipeline": {
144
+ "type": "object",
145
+ "properties": {
146
+ "target": {
147
+ "type": "string",
148
+ "resolveModule": true
149
+ },
150
+ "options": {
151
+ "type": "object"
152
+ }
153
+ },
154
+ "additionalProperties": false
155
+ }
156
+ },
157
+ "additionalProperties": true
158
+ }
159
+ ]
160
+ },
161
+ "serializerOpts": {
162
+ "type": "object",
163
+ "properties": {
164
+ "schema": {
165
+ "type": "object"
166
+ },
167
+ "ajv": {
168
+ "type": "object"
169
+ },
170
+ "rounding": {
171
+ "type": "string",
172
+ "enum": [
173
+ "floor",
174
+ "ceil",
175
+ "round",
176
+ "trunc"
177
+ ],
178
+ "default": "trunc"
179
+ },
180
+ "debugMode": {
181
+ "type": "boolean"
182
+ },
183
+ "mode": {
184
+ "type": "string",
185
+ "enum": [
186
+ "debug",
187
+ "standalone"
188
+ ]
189
+ },
190
+ "largeArraySize": {
191
+ "anyOf": [
192
+ {
193
+ "type": "integer"
194
+ },
195
+ {
196
+ "type": "string"
197
+ }
198
+ ],
199
+ "default": 20000
200
+ },
201
+ "largeArrayMechanism": {
202
+ "type": "string",
203
+ "enum": [
204
+ "default",
205
+ "json-stringify"
206
+ ],
207
+ "default": "default"
208
+ }
209
+ }
210
+ },
211
+ "caseSensitive": {
212
+ "type": "boolean"
213
+ },
214
+ "requestIdHeader": {
215
+ "anyOf": [
216
+ {
217
+ "type": "string"
218
+ },
219
+ {
220
+ "type": "boolean",
221
+ "const": false
222
+ }
223
+ ]
224
+ },
225
+ "requestIdLogLabel": {
226
+ "type": "string"
227
+ },
228
+ "jsonShorthand": {
229
+ "type": "boolean"
230
+ },
231
+ "trustProxy": {
232
+ "anyOf": [
233
+ {
234
+ "type": "boolean"
235
+ },
236
+ {
237
+ "type": "string"
238
+ },
239
+ {
240
+ "type": "array",
241
+ "items": {
242
+ "type": "string"
243
+ }
244
+ },
245
+ {
246
+ "type": "integer"
247
+ }
248
+ ]
249
+ },
250
+ "https": {
251
+ "type": "object",
252
+ "properties": {
253
+ "key": {
254
+ "anyOf": [
255
+ {
256
+ "type": "string"
257
+ },
258
+ {
259
+ "type": "object",
260
+ "properties": {
261
+ "path": {
262
+ "type": "string",
263
+ "resolvePath": true
264
+ }
265
+ },
266
+ "additionalProperties": false
267
+ },
268
+ {
269
+ "type": "array",
270
+ "items": {
271
+ "anyOf": [
272
+ {
273
+ "type": "string"
274
+ },
275
+ {
276
+ "type": "object",
277
+ "properties": {
278
+ "path": {
279
+ "type": "string",
280
+ "resolvePath": true
281
+ }
282
+ },
283
+ "additionalProperties": false
284
+ }
285
+ ]
286
+ }
287
+ }
288
+ ]
289
+ },
290
+ "cert": {
291
+ "anyOf": [
292
+ {
293
+ "type": "string"
294
+ },
295
+ {
296
+ "type": "object",
297
+ "properties": {
298
+ "path": {
299
+ "type": "string",
300
+ "resolvePath": true
301
+ }
302
+ },
303
+ "additionalProperties": false
304
+ },
305
+ {
306
+ "type": "array",
307
+ "items": {
308
+ "anyOf": [
309
+ {
310
+ "type": "string"
311
+ },
312
+ {
313
+ "type": "object",
314
+ "properties": {
315
+ "path": {
316
+ "type": "string",
317
+ "resolvePath": true
318
+ }
319
+ },
320
+ "additionalProperties": false
321
+ }
322
+ ]
323
+ }
324
+ }
325
+ ]
326
+ },
327
+ "requestCert": {
328
+ "type": "boolean"
329
+ },
330
+ "rejectUnauthorized": {
331
+ "type": "boolean"
332
+ }
333
+ },
334
+ "additionalProperties": false,
335
+ "required": [
336
+ "key",
337
+ "cert"
338
+ ]
339
+ },
340
+ "cors": {
341
+ "type": "object",
342
+ "$comment": "See https://github.com/fastify/fastify-cors",
343
+ "properties": {
344
+ "origin": {
345
+ "anyOf": [
346
+ {
347
+ "type": "boolean"
348
+ },
349
+ {
350
+ "type": "string"
351
+ },
352
+ {
353
+ "type": "array",
354
+ "items": {
355
+ "anyOf": [
356
+ {
357
+ "type": "string"
358
+ },
359
+ {
360
+ "type": "object",
361
+ "properties": {
362
+ "regexp": {
363
+ "type": "string"
364
+ }
365
+ },
366
+ "required": [
367
+ "regexp"
368
+ ]
369
+ }
370
+ ]
371
+ }
372
+ },
373
+ {
374
+ "type": "object",
375
+ "properties": {
376
+ "regexp": {
377
+ "type": "string"
378
+ }
379
+ },
380
+ "required": [
381
+ "regexp"
382
+ ]
383
+ }
384
+ ]
385
+ },
386
+ "methods": {
387
+ "type": "array",
388
+ "items": {
389
+ "type": "string"
390
+ }
391
+ },
392
+ "allowedHeaders": {
393
+ "type": "string",
394
+ "description": "Comma separated string of allowed headers."
395
+ },
396
+ "exposedHeaders": {
397
+ "anyOf": [
398
+ {
399
+ "type": "array",
400
+ "items": {
401
+ "type": "string"
402
+ }
403
+ },
404
+ {
405
+ "type": "string",
406
+ "description": "Comma separated string of exposed headers."
407
+ }
408
+ ]
409
+ },
410
+ "credentials": {
411
+ "type": "boolean"
412
+ },
413
+ "maxAge": {
414
+ "type": "integer"
415
+ },
416
+ "preflightContinue": {
417
+ "type": "boolean",
418
+ "default": false
419
+ },
420
+ "optionsSuccessStatus": {
421
+ "type": "integer",
422
+ "default": 204
423
+ },
424
+ "preflight": {
425
+ "type": "boolean",
426
+ "default": true
427
+ },
428
+ "strictPreflight": {
429
+ "type": "boolean",
430
+ "default": true
431
+ },
432
+ "hideOptionsRoute": {
433
+ "type": "boolean",
434
+ "default": true
435
+ }
436
+ },
437
+ "additionalProperties": false
438
+ }
439
+ },
440
+ "additionalProperties": false
441
+ },
442
+ "plugins": {
443
+ "type": "object",
444
+ "properties": {
445
+ "packages": {
446
+ "type": "array",
447
+ "items": {
448
+ "anyOf": [
449
+ {
450
+ "type": "string"
451
+ },
452
+ {
453
+ "type": "object",
454
+ "properties": {
455
+ "name": {
456
+ "type": "string"
457
+ },
458
+ "options": {
459
+ "type": "object",
460
+ "additionalProperties": true
461
+ }
462
+ },
463
+ "required": [
464
+ "name"
465
+ ]
466
+ }
467
+ ]
468
+ }
469
+ },
470
+ "paths": {
471
+ "type": "array",
472
+ "items": {
473
+ "anyOf": [
474
+ {
475
+ "type": "string",
476
+ "resolvePath": true
477
+ },
478
+ {
479
+ "type": "object",
480
+ "properties": {
481
+ "path": {
482
+ "type": "string",
483
+ "resolvePath": true
484
+ },
485
+ "encapsulate": {
486
+ "type": "boolean",
487
+ "default": true
488
+ },
489
+ "maxDepth": {
490
+ "type": "integer"
491
+ },
492
+ "autoHooks": {
493
+ "type": "boolean"
494
+ },
495
+ "autoHooksPattern": {
496
+ "type": "string"
497
+ },
498
+ "cascadeHooks": {
499
+ "type": "boolean"
500
+ },
501
+ "overwriteHooks": {
502
+ "type": "boolean"
503
+ },
504
+ "routeParams": {
505
+ "type": "boolean"
506
+ },
507
+ "forceESM": {
508
+ "type": "boolean"
509
+ },
510
+ "ignoreFilter": {
511
+ "type": "string"
512
+ },
513
+ "matchFilter": {
514
+ "type": "string"
515
+ },
516
+ "ignorePattern": {
517
+ "type": "string"
518
+ },
519
+ "scriptPattern": {
520
+ "type": "string"
521
+ },
522
+ "indexPattern": {
523
+ "type": "string"
524
+ },
525
+ "options": {
526
+ "type": "object",
527
+ "additionalProperties": true
528
+ }
529
+ }
530
+ }
531
+ ]
532
+ }
533
+ },
534
+ "typescript": {
535
+ "anyOf": [
536
+ {
537
+ "type": "object",
538
+ "properties": {
539
+ "enabled": {
540
+ "anyOf": [
541
+ {
542
+ "type": "boolean"
543
+ },
544
+ {
545
+ "type": "string"
546
+ }
547
+ ]
548
+ },
549
+ "tsConfig": {
550
+ "type": "string",
551
+ "resolvePath": true
552
+ },
553
+ "outDir": {
554
+ "type": "string",
555
+ "resolvePath": true
556
+ },
557
+ "flags": {
558
+ "type": "array",
559
+ "items": {
560
+ "type": "string"
561
+ }
562
+ }
563
+ }
564
+ },
565
+ {
566
+ "type": "boolean"
567
+ },
568
+ {
569
+ "type": "string"
570
+ }
571
+ ]
572
+ }
573
+ },
574
+ "additionalProperties": false,
575
+ "anyOf": [
576
+ {
577
+ "required": [
578
+ "paths"
579
+ ]
580
+ },
581
+ {
582
+ "required": [
583
+ "packages"
584
+ ]
585
+ }
586
+ ]
587
+ },
588
+ "metrics": {
589
+ "anyOf": [
590
+ {
591
+ "type": "boolean"
592
+ },
593
+ {
594
+ "type": "object",
595
+ "properties": {
596
+ "port": {
597
+ "anyOf": [
598
+ {
599
+ "type": "integer"
600
+ },
601
+ {
602
+ "type": "string"
603
+ }
604
+ ]
605
+ },
606
+ "hostname": {
607
+ "type": "string"
608
+ },
609
+ "endpoint": {
610
+ "type": "string"
611
+ },
612
+ "server": {
613
+ "type": "string",
614
+ "enum": [
615
+ "own",
616
+ "parent"
617
+ ]
618
+ },
619
+ "defaultMetrics": {
620
+ "type": "object",
621
+ "properties": {
622
+ "enabled": {
623
+ "type": "boolean"
624
+ }
625
+ },
626
+ "required": [
627
+ "enabled"
628
+ ],
629
+ "additionalProperties": false
630
+ },
631
+ "prefix": {
632
+ "type": "string"
633
+ },
634
+ "auth": {
635
+ "type": "object",
636
+ "properties": {
637
+ "username": {
638
+ "type": "string"
639
+ },
640
+ "password": {
641
+ "type": "string"
642
+ }
643
+ },
644
+ "additionalProperties": false,
645
+ "required": [
646
+ "username",
647
+ "password"
648
+ ]
649
+ }
650
+ },
651
+ "additionalProperties": false
652
+ }
653
+ ]
654
+ },
655
+ "telemetry": {
656
+ "$id": "/OpenTelemetry",
657
+ "type": "object",
658
+ "properties": {
659
+ "serviceName": {
660
+ "type": "string",
661
+ "description": "The name of the service. Defaults to the folder name if not specified."
662
+ },
663
+ "version": {
664
+ "type": "string",
665
+ "description": "The version of the service (optional)"
666
+ },
667
+ "skip": {
668
+ "type": "array",
669
+ "description": "An array of paths to skip when creating spans. Useful for health checks and other endpoints that do not need to be traced.",
670
+ "items": {
671
+ "type": "object",
672
+ "properties": {
673
+ "path": {
674
+ "type": "string",
675
+ "description": "The path to skip. Can be a string or a regex."
676
+ },
677
+ "method": {
678
+ "description": "HTTP method to skip",
679
+ "type": "string",
680
+ "enum": [
681
+ "GET",
682
+ "POST",
683
+ "PUT",
684
+ "DELETE",
685
+ "PATCH",
686
+ "HEAD",
687
+ "OPTIONS"
688
+ ]
689
+ }
690
+ }
691
+ }
692
+ },
693
+ "exporter": {
694
+ "anyOf": [
695
+ {
696
+ "type": "array",
697
+ "items": {
698
+ "type": "object",
699
+ "properties": {
700
+ "type": {
701
+ "type": "string",
702
+ "enum": [
703
+ "console",
704
+ "otlp",
705
+ "zipkin",
706
+ "memory"
707
+ ],
708
+ "default": "console"
709
+ },
710
+ "options": {
711
+ "type": "object",
712
+ "description": "Options for the exporter. These are passed directly to the exporter.",
713
+ "properties": {
714
+ "url": {
715
+ "type": "string",
716
+ "description": "The URL to send the traces to. Not used for console or memory exporters."
717
+ },
718
+ "headers": {
719
+ "type": "object",
720
+ "description": "Headers to send to the exporter. Not used for console or memory exporters."
721
+ }
722
+ }
723
+ },
724
+ "additionalProperties": false
725
+ }
726
+ }
727
+ },
728
+ {
729
+ "type": "object",
730
+ "properties": {
731
+ "type": {
732
+ "type": "string",
733
+ "enum": [
734
+ "console",
735
+ "otlp",
736
+ "zipkin",
737
+ "memory"
738
+ ],
739
+ "default": "console"
740
+ },
741
+ "options": {
742
+ "type": "object",
743
+ "description": "Options for the exporter. These are passed directly to the exporter.",
744
+ "properties": {
745
+ "url": {
746
+ "type": "string",
747
+ "description": "The URL to send the traces to. Not used for console or memory exporters."
748
+ },
749
+ "headers": {
750
+ "type": "object",
751
+ "description": "Headers to send to the exporter. Not used for console or memory exporters."
752
+ }
753
+ }
754
+ },
755
+ "additionalProperties": false
756
+ }
757
+ }
758
+ ]
759
+ }
760
+ },
761
+ "required": [
762
+ "serviceName"
763
+ ],
764
+ "additionalProperties": false
765
+ },
766
+ "watch": {
767
+ "anyOf": [
768
+ {
769
+ "type": "object",
770
+ "properties": {
771
+ "enabled": {
772
+ "default": true,
773
+ "anyOf": [
774
+ {
775
+ "type": "boolean"
776
+ },
777
+ {
778
+ "type": "string"
779
+ }
780
+ ]
781
+ },
782
+ "allow": {
783
+ "type": "array",
784
+ "items": {
785
+ "type": "string"
786
+ },
787
+ "minItems": 1,
788
+ "nullable": true,
789
+ "default": null
790
+ },
791
+ "ignore": {
792
+ "type": "array",
793
+ "items": {
794
+ "type": "string"
795
+ },
796
+ "nullable": true,
797
+ "default": null
798
+ }
799
+ },
800
+ "additionalProperties": false
801
+ },
802
+ {
803
+ "type": "boolean"
804
+ },
805
+ {
806
+ "type": "string"
807
+ }
808
+ ]
809
+ },
810
+ "$schema": {
811
+ "type": "string"
812
+ },
813
+ "service": {
814
+ "type": "object",
815
+ "properties": {
816
+ "openapi": {
817
+ "anyOf": [
818
+ {
819
+ "type": "object",
820
+ "properties": {
821
+ "info": {
822
+ "$ref": "#/$defs/info"
823
+ },
824
+ "jsonSchemaDialect": {
825
+ "type": "string",
826
+ "default": "https://spec.openapis.org/oas/3.1/dialect/base"
827
+ },
828
+ "servers": {
829
+ "type": "array",
830
+ "items": {
831
+ "$ref": "#/$defs/server"
832
+ },
833
+ "default": [
834
+ {
835
+ "url": "/"
836
+ }
837
+ ]
838
+ },
839
+ "paths": {
840
+ "$ref": "#/$defs/paths"
841
+ },
842
+ "webhooks": {
843
+ "type": "object",
844
+ "additionalProperties": {
845
+ "$ref": "#/$defs/path-item-or-reference"
846
+ }
847
+ },
848
+ "components": {
849
+ "$ref": "#/$defs/components"
850
+ },
851
+ "security": {
852
+ "type": "array",
853
+ "items": {
854
+ "$ref": "#/$defs/security-requirement"
855
+ }
856
+ },
857
+ "tags": {
858
+ "type": "array",
859
+ "items": {
860
+ "$ref": "#/$defs/tag"
861
+ }
862
+ },
863
+ "externalDocs": {
864
+ "$ref": "#/$defs/external-documentation"
865
+ },
866
+ "swaggerPrefix": {
867
+ "type": "string",
868
+ "description": "Base URL for the OpenAPI Swagger Documentation"
869
+ },
870
+ "path": {
871
+ "type": "string",
872
+ "description": "Path to an OpenAPI spec file",
873
+ "resolvePath": true
874
+ }
875
+ },
876
+ "additionalProperties": false
877
+ },
878
+ {
879
+ "type": "boolean"
880
+ }
881
+ ]
882
+ },
883
+ "graphql": {
884
+ "anyOf": [
885
+ {
886
+ "type": "object",
887
+ "properties": {
888
+ "graphiql": {
889
+ "type": "boolean"
890
+ }
891
+ },
892
+ "additionalProperties": false
893
+ },
894
+ {
895
+ "type": "boolean"
896
+ }
897
+ ]
898
+ }
899
+ },
900
+ "additionalProperties": false
901
+ },
902
+ "clients": {
903
+ "type": "array",
904
+ "items": {
905
+ "type": "object",
906
+ "properties": {
907
+ "serviceId": {
908
+ "type": "string"
909
+ },
910
+ "name": {
911
+ "type": "string"
912
+ },
913
+ "type": {
914
+ "type": "string",
915
+ "enum": [
916
+ "openapi",
917
+ "graphql"
918
+ ]
919
+ },
920
+ "path": {
921
+ "type": "string",
922
+ "resolvePath": true
923
+ },
924
+ "schema": {
925
+ "type": "string",
926
+ "resolvePath": true
927
+ },
928
+ "url": {
929
+ "type": "string"
930
+ }
931
+ },
932
+ "additionalProperties": false
933
+ }
934
+ },
935
+ "versions": {
936
+ "type": "object",
937
+ "properties": {
938
+ "dir": {
939
+ "type": "string",
940
+ "description": "The path to the directory containing the versions mappers",
941
+ "resolvePath": true,
942
+ "default": "versions"
943
+ },
944
+ "configs": {
945
+ "type": "array",
946
+ "items": {
947
+ "type": "object",
948
+ "properties": {
949
+ "version": {
950
+ "type": "string"
951
+ },
952
+ "openapi": {
953
+ "type": "object",
954
+ "properties": {
955
+ "prefix": {
956
+ "type": "string"
957
+ },
958
+ "path": {
959
+ "type": "string",
960
+ "resolvePath": true
961
+ }
962
+ },
963
+ "additionalProperties": false
964
+ },
965
+ "plugins": {
966
+ "type": "object",
967
+ "properties": {
968
+ "packages": {
969
+ "type": "array",
970
+ "items": {
971
+ "anyOf": [
972
+ {
973
+ "type": "string"
974
+ },
975
+ {
976
+ "type": "object",
977
+ "properties": {
978
+ "name": {
979
+ "type": "string"
980
+ },
981
+ "options": {
982
+ "type": "object",
983
+ "additionalProperties": true
984
+ }
985
+ },
986
+ "required": [
987
+ "name"
988
+ ]
989
+ }
990
+ ]
991
+ }
992
+ },
993
+ "paths": {
994
+ "type": "array",
995
+ "items": {
996
+ "anyOf": [
997
+ {
998
+ "type": "string",
999
+ "resolvePath": true
1000
+ },
1001
+ {
1002
+ "type": "object",
1003
+ "properties": {
1004
+ "path": {
1005
+ "type": "string",
1006
+ "resolvePath": true
1007
+ },
1008
+ "encapsulate": {
1009
+ "type": "boolean",
1010
+ "default": true
1011
+ },
1012
+ "maxDepth": {
1013
+ "type": "integer"
1014
+ },
1015
+ "autoHooks": {
1016
+ "type": "boolean"
1017
+ },
1018
+ "autoHooksPattern": {
1019
+ "type": "string"
1020
+ },
1021
+ "cascadeHooks": {
1022
+ "type": "boolean"
1023
+ },
1024
+ "overwriteHooks": {
1025
+ "type": "boolean"
1026
+ },
1027
+ "routeParams": {
1028
+ "type": "boolean"
1029
+ },
1030
+ "forceESM": {
1031
+ "type": "boolean"
1032
+ },
1033
+ "ignoreFilter": {
1034
+ "type": "string"
1035
+ },
1036
+ "matchFilter": {
1037
+ "type": "string"
1038
+ },
1039
+ "ignorePattern": {
1040
+ "type": "string"
1041
+ },
1042
+ "scriptPattern": {
1043
+ "type": "string"
1044
+ },
1045
+ "indexPattern": {
1046
+ "type": "string"
1047
+ },
1048
+ "options": {
1049
+ "type": "object",
1050
+ "additionalProperties": true
1051
+ }
1052
+ }
1053
+ }
1054
+ ]
1055
+ }
1056
+ },
1057
+ "typescript": {
1058
+ "anyOf": [
1059
+ {
1060
+ "type": "object",
1061
+ "properties": {
1062
+ "enabled": {
1063
+ "anyOf": [
1064
+ {
1065
+ "type": "boolean"
1066
+ },
1067
+ {
1068
+ "type": "string"
1069
+ }
1070
+ ]
1071
+ },
1072
+ "tsConfig": {
1073
+ "type": "string",
1074
+ "resolvePath": true
1075
+ },
1076
+ "outDir": {
1077
+ "type": "string",
1078
+ "resolvePath": true
1079
+ },
1080
+ "flags": {
1081
+ "type": "array",
1082
+ "items": {
1083
+ "type": "string"
1084
+ }
1085
+ }
1086
+ }
1087
+ },
1088
+ {
1089
+ "type": "boolean"
1090
+ },
1091
+ {
1092
+ "type": "string"
1093
+ }
1094
+ ]
1095
+ }
1096
+ },
1097
+ "additionalProperties": false,
1098
+ "anyOf": [
1099
+ {
1100
+ "required": [
1101
+ "paths"
1102
+ ]
1103
+ },
1104
+ {
1105
+ "required": [
1106
+ "packages"
1107
+ ]
1108
+ }
1109
+ ]
1110
+ }
1111
+ },
1112
+ "required": [
1113
+ "version"
1114
+ ],
1115
+ "additionalProperties": false
1116
+ }
1117
+ }
1118
+ },
1119
+ "required": [
1120
+ "dir",
1121
+ "configs"
1122
+ ],
1123
+ "additionalProperties": false
1124
+ }
1125
+ },
1126
+ "additionalProperties": false,
1127
+ "$defs": {
1128
+ "info": {
1129
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#info-object",
1130
+ "type": "object",
1131
+ "properties": {
1132
+ "title": {
1133
+ "type": "string"
1134
+ },
1135
+ "summary": {
1136
+ "type": "string"
1137
+ },
1138
+ "description": {
1139
+ "type": "string"
1140
+ },
1141
+ "termsOfService": {
1142
+ "type": "string"
1143
+ },
1144
+ "contact": {
1145
+ "$ref": "#/$defs/contact"
1146
+ },
1147
+ "license": {
1148
+ "$ref": "#/$defs/license"
1149
+ },
1150
+ "version": {
1151
+ "type": "string"
1152
+ }
1153
+ },
1154
+ "required": [
1155
+ "title",
1156
+ "version"
1157
+ ],
1158
+ "$ref": "#/$defs/specification-extensions"
1159
+ },
1160
+ "contact": {
1161
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#contact-object",
1162
+ "type": "object",
1163
+ "properties": {
1164
+ "name": {
1165
+ "type": "string"
1166
+ },
1167
+ "url": {
1168
+ "type": "string"
1169
+ },
1170
+ "email": {
1171
+ "type": "string"
1172
+ }
1173
+ },
1174
+ "$ref": "#/$defs/specification-extensions"
1175
+ },
1176
+ "license": {
1177
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#license-object",
1178
+ "type": "object",
1179
+ "properties": {
1180
+ "name": {
1181
+ "type": "string"
1182
+ },
1183
+ "identifier": {
1184
+ "type": "string"
1185
+ },
1186
+ "url": {
1187
+ "type": "string"
1188
+ }
1189
+ },
1190
+ "required": [
1191
+ "name"
1192
+ ],
1193
+ "$ref": "#/$defs/specification-extensions"
1194
+ },
1195
+ "server": {
1196
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#server-object",
1197
+ "type": "object",
1198
+ "properties": {
1199
+ "url": {
1200
+ "type": "string"
1201
+ },
1202
+ "description": {
1203
+ "type": "string"
1204
+ },
1205
+ "variables": {
1206
+ "type": "object",
1207
+ "additionalProperties": {
1208
+ "$ref": "#/$defs/server-variable"
1209
+ }
1210
+ }
1211
+ },
1212
+ "required": [
1213
+ "url"
1214
+ ],
1215
+ "$ref": "#/$defs/specification-extensions"
1216
+ },
1217
+ "server-variable": {
1218
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#server-variable-object",
1219
+ "type": "object",
1220
+ "properties": {
1221
+ "enum": {
1222
+ "type": "array",
1223
+ "items": {
1224
+ "type": "string"
1225
+ },
1226
+ "minItems": 1
1227
+ },
1228
+ "default": {
1229
+ "type": "string"
1230
+ },
1231
+ "description": {
1232
+ "type": "string"
1233
+ }
1234
+ },
1235
+ "required": [
1236
+ "default"
1237
+ ],
1238
+ "$ref": "#/$defs/specification-extensions"
1239
+ },
1240
+ "components": {
1241
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#components-object",
1242
+ "type": "object",
1243
+ "properties": {
1244
+ "schemas": {
1245
+ "type": "object"
1246
+ },
1247
+ "responses": {
1248
+ "type": "object",
1249
+ "additionalProperties": {
1250
+ "$ref": "#/$defs/response-or-reference"
1251
+ }
1252
+ },
1253
+ "parameters": {
1254
+ "type": "object",
1255
+ "additionalProperties": {
1256
+ "$ref": "#/$defs/parameter-or-reference"
1257
+ }
1258
+ },
1259
+ "examples": {
1260
+ "type": "object",
1261
+ "additionalProperties": {
1262
+ "$ref": "#/$defs/example-or-reference"
1263
+ }
1264
+ },
1265
+ "requestBodies": {
1266
+ "type": "object",
1267
+ "additionalProperties": {
1268
+ "$ref": "#/$defs/request-body-or-reference"
1269
+ }
1270
+ },
1271
+ "headers": {
1272
+ "type": "object",
1273
+ "additionalProperties": {
1274
+ "$ref": "#/$defs/header-or-reference"
1275
+ }
1276
+ },
1277
+ "securitySchemes": {
1278
+ "type": "object",
1279
+ "additionalProperties": {
1280
+ "$ref": "#/$defs/security-scheme-or-reference"
1281
+ }
1282
+ },
1283
+ "links": {
1284
+ "type": "object",
1285
+ "additionalProperties": {
1286
+ "$ref": "#/$defs/link-or-reference"
1287
+ }
1288
+ },
1289
+ "callbacks": {
1290
+ "type": "object",
1291
+ "additionalProperties": {
1292
+ "$ref": "#/$defs/callbacks-or-reference"
1293
+ }
1294
+ },
1295
+ "pathItems": {
1296
+ "type": "object",
1297
+ "additionalProperties": {
1298
+ "$ref": "#/$defs/path-item-or-reference"
1299
+ }
1300
+ }
1301
+ },
1302
+ "$ref": "#/$defs/specification-extensions"
1303
+ },
1304
+ "paths": {
1305
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#paths-object",
1306
+ "type": "object",
1307
+ "patternProperties": {
1308
+ "^/": {
1309
+ "$ref": "#/$defs/path-item"
1310
+ }
1311
+ },
1312
+ "$ref": "#/$defs/specification-extensions"
1313
+ },
1314
+ "path-item": {
1315
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#path-item-object",
1316
+ "type": "object",
1317
+ "properties": {
1318
+ "summary": {
1319
+ "type": "string"
1320
+ },
1321
+ "description": {
1322
+ "type": "string"
1323
+ },
1324
+ "servers": {
1325
+ "type": "array",
1326
+ "items": {
1327
+ "$ref": "#/$defs/server"
1328
+ }
1329
+ },
1330
+ "parameters": {
1331
+ "type": "array",
1332
+ "items": {
1333
+ "$ref": "#/$defs/parameter-or-reference"
1334
+ }
1335
+ },
1336
+ "get": {
1337
+ "$ref": "#/$defs/operation"
1338
+ },
1339
+ "put": {
1340
+ "$ref": "#/$defs/operation"
1341
+ },
1342
+ "post": {
1343
+ "$ref": "#/$defs/operation"
1344
+ },
1345
+ "delete": {
1346
+ "$ref": "#/$defs/operation"
1347
+ },
1348
+ "options": {
1349
+ "$ref": "#/$defs/operation"
1350
+ },
1351
+ "head": {
1352
+ "$ref": "#/$defs/operation"
1353
+ },
1354
+ "patch": {
1355
+ "$ref": "#/$defs/operation"
1356
+ },
1357
+ "trace": {
1358
+ "$ref": "#/$defs/operation"
1359
+ }
1360
+ },
1361
+ "$ref": "#/$defs/specification-extensions"
1362
+ },
1363
+ "path-item-or-reference": {
1364
+ "if": {
1365
+ "type": "object",
1366
+ "required": [
1367
+ "$ref"
1368
+ ]
1369
+ },
1370
+ "then": {
1371
+ "$ref": "#/$defs/reference"
1372
+ },
1373
+ "else": {
1374
+ "$ref": "#/$defs/path-item"
1375
+ }
1376
+ },
1377
+ "operation": {
1378
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#operation-object",
1379
+ "type": "object",
1380
+ "properties": {
1381
+ "tags": {
1382
+ "type": "array",
1383
+ "items": {
1384
+ "type": "string"
1385
+ }
1386
+ },
1387
+ "summary": {
1388
+ "type": "string"
1389
+ },
1390
+ "description": {
1391
+ "type": "string"
1392
+ },
1393
+ "externalDocs": {
1394
+ "$ref": "#/$defs/external-documentation"
1395
+ },
1396
+ "operationId": {
1397
+ "type": "string"
1398
+ },
1399
+ "parameters": {
1400
+ "type": "array",
1401
+ "items": {
1402
+ "$ref": "#/$defs/parameter-or-reference"
1403
+ }
1404
+ },
1405
+ "requestBody": {
1406
+ "$ref": "#/$defs/request-body-or-reference"
1407
+ },
1408
+ "responses": {
1409
+ "$ref": "#/$defs/responses"
1410
+ },
1411
+ "callbacks": {
1412
+ "type": "object",
1413
+ "additionalProperties": {
1414
+ "$ref": "#/$defs/callbacks-or-reference"
1415
+ }
1416
+ },
1417
+ "security": {
1418
+ "type": "array",
1419
+ "items": {
1420
+ "$ref": "#/$defs/security-requirement"
1421
+ }
1422
+ },
1423
+ "servers": {
1424
+ "type": "array",
1425
+ "items": {
1426
+ "$ref": "#/$defs/server"
1427
+ }
1428
+ }
1429
+ },
1430
+ "$ref": "#/$defs/specification-extensions"
1431
+ },
1432
+ "external-documentation": {
1433
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#external-documentation-object",
1434
+ "type": "object",
1435
+ "properties": {
1436
+ "description": {
1437
+ "type": "string"
1438
+ },
1439
+ "url": {
1440
+ "type": "string"
1441
+ }
1442
+ },
1443
+ "required": [
1444
+ "url"
1445
+ ],
1446
+ "$ref": "#/$defs/specification-extensions"
1447
+ },
1448
+ "parameter": {
1449
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#parameter-object",
1450
+ "type": "object",
1451
+ "properties": {
1452
+ "name": {
1453
+ "type": "string"
1454
+ },
1455
+ "in": {
1456
+ "enum": [
1457
+ "query",
1458
+ "header",
1459
+ "path",
1460
+ "cookie"
1461
+ ]
1462
+ },
1463
+ "description": {
1464
+ "type": "string"
1465
+ },
1466
+ "required": {
1467
+ "default": false,
1468
+ "type": "boolean"
1469
+ },
1470
+ "content": {
1471
+ "type": "object",
1472
+ "$ref": "#/$defs/content",
1473
+ "minProperties": 1,
1474
+ "maxProperties": 1
1475
+ }
1476
+ },
1477
+ "required": [
1478
+ "name",
1479
+ "in"
1480
+ ],
1481
+ "oneOf": [
1482
+ {
1483
+ "required": [
1484
+ "schema"
1485
+ ]
1486
+ },
1487
+ {
1488
+ "required": [
1489
+ "content"
1490
+ ]
1491
+ }
1492
+ ],
1493
+ "if": {
1494
+ "type": "object",
1495
+ "properties": {
1496
+ "in": {
1497
+ "const": "query"
1498
+ }
1499
+ },
1500
+ "required": [
1501
+ "in"
1502
+ ]
1503
+ },
1504
+ "then": {
1505
+ "type": "object",
1506
+ "properties": {
1507
+ "allowEmptyValue": {
1508
+ "default": false,
1509
+ "type": "boolean"
1510
+ }
1511
+ }
1512
+ },
1513
+ "$ref": "#/$defs/specification-extensions"
1514
+ },
1515
+ "parameter-or-reference": {
1516
+ "if": {
1517
+ "type": "object",
1518
+ "required": [
1519
+ "$ref"
1520
+ ]
1521
+ },
1522
+ "then": {
1523
+ "$ref": "#/$defs/reference"
1524
+ },
1525
+ "else": {
1526
+ "$ref": "#/$defs/parameter"
1527
+ }
1528
+ },
1529
+ "request-body": {
1530
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#request-body-object",
1531
+ "type": "object",
1532
+ "properties": {
1533
+ "description": {
1534
+ "type": "string"
1535
+ },
1536
+ "content": {
1537
+ "$ref": "#/$defs/content"
1538
+ },
1539
+ "required": {
1540
+ "default": false,
1541
+ "type": "boolean"
1542
+ }
1543
+ },
1544
+ "required": [
1545
+ "content"
1546
+ ],
1547
+ "$ref": "#/$defs/specification-extensions"
1548
+ },
1549
+ "request-body-or-reference": {
1550
+ "if": {
1551
+ "type": "object",
1552
+ "required": [
1553
+ "$ref"
1554
+ ]
1555
+ },
1556
+ "then": {
1557
+ "$ref": "#/$defs/reference"
1558
+ },
1559
+ "else": {
1560
+ "$ref": "#/$defs/request-body"
1561
+ }
1562
+ },
1563
+ "content": {
1564
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#fixed-fields-10",
1565
+ "type": "object",
1566
+ "additionalProperties": {
1567
+ "$ref": "#/$defs/media-type"
1568
+ }
1569
+ },
1570
+ "media-type": {
1571
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#media-type-object",
1572
+ "type": "object",
1573
+ "properties": {
1574
+ "encoding": {
1575
+ "type": "object",
1576
+ "additionalProperties": {
1577
+ "$ref": "#/$defs/encoding"
1578
+ }
1579
+ }
1580
+ },
1581
+ "allOf": [
1582
+ {
1583
+ "$ref": "#/$defs/specification-extensions"
1584
+ },
1585
+ {
1586
+ "$ref": "#/$defs/examples"
1587
+ }
1588
+ ]
1589
+ },
1590
+ "encoding": {
1591
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#encoding-object",
1592
+ "type": "object",
1593
+ "properties": {
1594
+ "contentType": {
1595
+ "type": "string"
1596
+ },
1597
+ "headers": {
1598
+ "type": "object",
1599
+ "additionalProperties": {
1600
+ "$ref": "#/$defs/header-or-reference"
1601
+ }
1602
+ },
1603
+ "style": {
1604
+ "default": "form",
1605
+ "enum": [
1606
+ "form",
1607
+ "spaceDelimited",
1608
+ "pipeDelimited",
1609
+ "deepObject"
1610
+ ]
1611
+ },
1612
+ "explode": {
1613
+ "type": "boolean"
1614
+ },
1615
+ "allowReserved": {
1616
+ "default": false,
1617
+ "type": "boolean"
1618
+ }
1619
+ },
1620
+ "allOf": [
1621
+ {
1622
+ "$ref": "#/$defs/specification-extensions"
1623
+ },
1624
+ {
1625
+ "$ref": "#/$defs/encoding/$defs/explode-default"
1626
+ }
1627
+ ],
1628
+ "$defs": {
1629
+ "explode-default": {
1630
+ "if": {
1631
+ "type": "object",
1632
+ "properties": {
1633
+ "style": {
1634
+ "const": "form"
1635
+ }
1636
+ },
1637
+ "required": [
1638
+ "style"
1639
+ ]
1640
+ },
1641
+ "then": {
1642
+ "type": "object",
1643
+ "properties": {
1644
+ "explode": {
1645
+ "default": true
1646
+ }
1647
+ }
1648
+ },
1649
+ "else": {
1650
+ "type": "object",
1651
+ "properties": {
1652
+ "explode": {
1653
+ "default": false
1654
+ }
1655
+ }
1656
+ }
1657
+ }
1658
+ }
1659
+ },
1660
+ "responses": {
1661
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#responses-object",
1662
+ "type": "object",
1663
+ "additionalProperties": {
1664
+ "$ref": "#/$defs/response-or-reference"
1665
+ },
1666
+ "minProperties": 1,
1667
+ "$ref": "#/$defs/specification-extensions"
1668
+ },
1669
+ "response": {
1670
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#response-object",
1671
+ "type": "object",
1672
+ "properties": {
1673
+ "description": {
1674
+ "type": "string"
1675
+ },
1676
+ "headers": {
1677
+ "type": "object",
1678
+ "additionalProperties": {
1679
+ "$ref": "#/$defs/header-or-reference"
1680
+ }
1681
+ },
1682
+ "content": {
1683
+ "$ref": "#/$defs/content"
1684
+ },
1685
+ "links": {
1686
+ "type": "object",
1687
+ "additionalProperties": {
1688
+ "$ref": "#/$defs/link-or-reference"
1689
+ }
1690
+ }
1691
+ },
1692
+ "required": [
1693
+ "description"
1694
+ ],
1695
+ "$ref": "#/$defs/specification-extensions"
1696
+ },
1697
+ "response-or-reference": {
1698
+ "if": {
1699
+ "type": "object",
1700
+ "required": [
1701
+ "$ref"
1702
+ ]
1703
+ },
1704
+ "then": {
1705
+ "$ref": "#/$defs/reference"
1706
+ },
1707
+ "else": {
1708
+ "$ref": "#/$defs/response"
1709
+ }
1710
+ },
1711
+ "callbacks": {
1712
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#callback-object",
1713
+ "type": "object",
1714
+ "$ref": "#/$defs/specification-extensions",
1715
+ "additionalProperties": {
1716
+ "$ref": "#/$defs/path-item-or-reference"
1717
+ }
1718
+ },
1719
+ "callbacks-or-reference": {
1720
+ "if": {
1721
+ "type": "object",
1722
+ "required": [
1723
+ "$ref"
1724
+ ]
1725
+ },
1726
+ "then": {
1727
+ "$ref": "#/$defs/reference"
1728
+ },
1729
+ "else": {
1730
+ "$ref": "#/$defs/callbacks"
1731
+ }
1732
+ },
1733
+ "example": {
1734
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#example-object",
1735
+ "type": "object",
1736
+ "properties": {
1737
+ "summary": {
1738
+ "type": "string"
1739
+ },
1740
+ "description": {
1741
+ "type": "string"
1742
+ },
1743
+ "value": true,
1744
+ "externalValue": {
1745
+ "type": "string"
1746
+ }
1747
+ },
1748
+ "not": {
1749
+ "required": [
1750
+ "value",
1751
+ "externalValue"
1752
+ ]
1753
+ },
1754
+ "$ref": "#/$defs/specification-extensions"
1755
+ },
1756
+ "example-or-reference": {
1757
+ "if": {
1758
+ "type": "object",
1759
+ "required": [
1760
+ "$ref"
1761
+ ]
1762
+ },
1763
+ "then": {
1764
+ "$ref": "#/$defs/reference"
1765
+ },
1766
+ "else": {
1767
+ "$ref": "#/$defs/example"
1768
+ }
1769
+ },
1770
+ "link": {
1771
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#link-object",
1772
+ "type": "object",
1773
+ "properties": {
1774
+ "operationRef": {
1775
+ "type": "string"
1776
+ },
1777
+ "operationId": {
1778
+ "type": "string"
1779
+ },
1780
+ "parameters": {
1781
+ "$ref": "#/$defs/map-of-strings"
1782
+ },
1783
+ "requestBody": true,
1784
+ "description": {
1785
+ "type": "string"
1786
+ },
1787
+ "body": {
1788
+ "$ref": "#/$defs/server"
1789
+ }
1790
+ },
1791
+ "oneOf": [
1792
+ {
1793
+ "required": [
1794
+ "operationRef"
1795
+ ]
1796
+ },
1797
+ {
1798
+ "required": [
1799
+ "operationId"
1800
+ ]
1801
+ }
1802
+ ],
1803
+ "$ref": "#/$defs/specification-extensions"
1804
+ },
1805
+ "link-or-reference": {
1806
+ "if": {
1807
+ "type": "object",
1808
+ "required": [
1809
+ "$ref"
1810
+ ]
1811
+ },
1812
+ "then": {
1813
+ "$ref": "#/$defs/reference"
1814
+ },
1815
+ "else": {
1816
+ "$ref": "#/$defs/link"
1817
+ }
1818
+ },
1819
+ "header": {
1820
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#header-object",
1821
+ "type": "object",
1822
+ "properties": {
1823
+ "description": {
1824
+ "type": "string"
1825
+ },
1826
+ "required": {
1827
+ "default": false,
1828
+ "type": "boolean"
1829
+ },
1830
+ "content": {
1831
+ "type": "object",
1832
+ "$ref": "#/$defs/content",
1833
+ "minProperties": 1,
1834
+ "maxProperties": 1
1835
+ }
1836
+ },
1837
+ "oneOf": [
1838
+ {
1839
+ "required": [
1840
+ "schema"
1841
+ ]
1842
+ },
1843
+ {
1844
+ "required": [
1845
+ "content"
1846
+ ]
1847
+ }
1848
+ ],
1849
+ "$ref": "#/$defs/specification-extensions"
1850
+ },
1851
+ "header-or-reference": {
1852
+ "if": {
1853
+ "type": "object",
1854
+ "required": [
1855
+ "$ref"
1856
+ ]
1857
+ },
1858
+ "then": {
1859
+ "$ref": "#/$defs/reference"
1860
+ },
1861
+ "else": {
1862
+ "$ref": "#/$defs/header"
1863
+ }
1864
+ },
1865
+ "tag": {
1866
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#tag-object",
1867
+ "type": "object",
1868
+ "properties": {
1869
+ "name": {
1870
+ "type": "string"
1871
+ },
1872
+ "description": {
1873
+ "type": "string"
1874
+ },
1875
+ "externalDocs": {
1876
+ "$ref": "#/$defs/external-documentation"
1877
+ }
1878
+ },
1879
+ "required": [
1880
+ "name"
1881
+ ],
1882
+ "$ref": "#/$defs/specification-extensions"
1883
+ },
1884
+ "reference": {
1885
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#reference-object",
1886
+ "type": "object",
1887
+ "properties": {
1888
+ "$ref": {
1889
+ "type": "string"
1890
+ },
1891
+ "summary": {
1892
+ "type": "string"
1893
+ },
1894
+ "description": {
1895
+ "type": "string"
1896
+ }
1897
+ }
1898
+ },
1899
+ "schema": {
1900
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#schema-object",
1901
+ "type": [
1902
+ "object",
1903
+ "boolean"
1904
+ ]
1905
+ },
1906
+ "security-scheme": {
1907
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#security-scheme-object",
1908
+ "type": "object",
1909
+ "properties": {
1910
+ "type": {
1911
+ "enum": [
1912
+ "apiKey",
1913
+ "http",
1914
+ "mutualTLS",
1915
+ "oauth2",
1916
+ "openIdConnect"
1917
+ ]
1918
+ },
1919
+ "description": {
1920
+ "type": "string"
1921
+ }
1922
+ },
1923
+ "required": [
1924
+ "type"
1925
+ ],
1926
+ "allOf": [
1927
+ {
1928
+ "$ref": "#/$defs/specification-extensions"
1929
+ },
1930
+ {
1931
+ "$ref": "#/$defs/security-scheme/$defs/type-apikey"
1932
+ },
1933
+ {
1934
+ "$ref": "#/$defs/security-scheme/$defs/type-http"
1935
+ },
1936
+ {
1937
+ "$ref": "#/$defs/security-scheme/$defs/type-http-bearer"
1938
+ },
1939
+ {
1940
+ "$ref": "#/$defs/security-scheme/$defs/type-oauth2"
1941
+ },
1942
+ {
1943
+ "$ref": "#/$defs/security-scheme/$defs/type-oidc"
1944
+ }
1945
+ ],
1946
+ "$defs": {
1947
+ "type-apikey": {
1948
+ "if": {
1949
+ "type": "object",
1950
+ "properties": {
1951
+ "type": {
1952
+ "const": "apiKey"
1953
+ }
1954
+ },
1955
+ "required": [
1956
+ "type"
1957
+ ]
1958
+ },
1959
+ "then": {
1960
+ "type": "object",
1961
+ "properties": {
1962
+ "name": {
1963
+ "type": "string"
1964
+ },
1965
+ "in": {
1966
+ "enum": [
1967
+ "query",
1968
+ "header",
1969
+ "cookie"
1970
+ ]
1971
+ }
1972
+ },
1973
+ "required": [
1974
+ "name",
1975
+ "in"
1976
+ ]
1977
+ }
1978
+ },
1979
+ "type-http": {
1980
+ "if": {
1981
+ "type": "object",
1982
+ "properties": {
1983
+ "type": {
1984
+ "const": "http"
1985
+ }
1986
+ },
1987
+ "required": [
1988
+ "type"
1989
+ ]
1990
+ },
1991
+ "then": {
1992
+ "type": "object",
1993
+ "properties": {
1994
+ "scheme": {
1995
+ "type": "string"
1996
+ }
1997
+ },
1998
+ "required": [
1999
+ "scheme"
2000
+ ]
2001
+ }
2002
+ },
2003
+ "type-http-bearer": {
2004
+ "if": {
2005
+ "type": "object",
2006
+ "properties": {
2007
+ "type": {
2008
+ "const": "http"
2009
+ },
2010
+ "scheme": {
2011
+ "type": "string",
2012
+ "pattern": "^[Bb][Ee][Aa][Rr][Ee][Rr]$"
2013
+ }
2014
+ },
2015
+ "required": [
2016
+ "type",
2017
+ "scheme"
2018
+ ]
2019
+ },
2020
+ "then": {
2021
+ "type": "object",
2022
+ "properties": {
2023
+ "bearerFormat": {
2024
+ "type": "string"
2025
+ }
2026
+ }
2027
+ }
2028
+ },
2029
+ "type-oauth2": {
2030
+ "if": {
2031
+ "type": "object",
2032
+ "properties": {
2033
+ "type": {
2034
+ "const": "oauth2"
2035
+ }
2036
+ },
2037
+ "required": [
2038
+ "type"
2039
+ ]
2040
+ },
2041
+ "then": {
2042
+ "type": "object",
2043
+ "properties": {
2044
+ "flows": {
2045
+ "$ref": "#/$defs/oauth-flows"
2046
+ }
2047
+ },
2048
+ "required": [
2049
+ "flows"
2050
+ ]
2051
+ }
2052
+ },
2053
+ "type-oidc": {
2054
+ "if": {
2055
+ "type": "object",
2056
+ "properties": {
2057
+ "type": {
2058
+ "const": "openIdConnect"
2059
+ }
2060
+ },
2061
+ "required": [
2062
+ "type"
2063
+ ]
2064
+ },
2065
+ "then": {
2066
+ "type": "object",
2067
+ "properties": {
2068
+ "openIdConnectUrl": {
2069
+ "type": "string"
2070
+ }
2071
+ },
2072
+ "required": [
2073
+ "openIdConnectUrl"
2074
+ ]
2075
+ }
2076
+ }
2077
+ }
2078
+ },
2079
+ "security-scheme-or-reference": {
2080
+ "if": {
2081
+ "type": "object",
2082
+ "required": [
2083
+ "$ref"
2084
+ ]
2085
+ },
2086
+ "then": {
2087
+ "$ref": "#/$defs/reference"
2088
+ },
2089
+ "else": {
2090
+ "$ref": "#/$defs/security-scheme"
2091
+ }
2092
+ },
2093
+ "oauth-flows": {
2094
+ "type": "object",
2095
+ "properties": {
2096
+ "implicit": {
2097
+ "$ref": "#/$defs/oauth-flows/$defs/implicit"
2098
+ },
2099
+ "password": {
2100
+ "$ref": "#/$defs/oauth-flows/$defs/password"
2101
+ },
2102
+ "clientCredentials": {
2103
+ "$ref": "#/$defs/oauth-flows/$defs/client-credentials"
2104
+ },
2105
+ "authorizationCode": {
2106
+ "$ref": "#/$defs/oauth-flows/$defs/authorization-code"
2107
+ }
2108
+ },
2109
+ "$ref": "#/$defs/specification-extensions",
2110
+ "$defs": {
2111
+ "implicit": {
2112
+ "type": "object",
2113
+ "properties": {
2114
+ "authorizationUrl": {
2115
+ "type": "string"
2116
+ },
2117
+ "refreshUrl": {
2118
+ "type": "string"
2119
+ },
2120
+ "scopes": {
2121
+ "$ref": "#/$defs/map-of-strings"
2122
+ }
2123
+ },
2124
+ "required": [
2125
+ "authorizationUrl",
2126
+ "scopes"
2127
+ ],
2128
+ "$ref": "#/$defs/specification-extensions"
2129
+ },
2130
+ "password": {
2131
+ "type": "object",
2132
+ "properties": {
2133
+ "tokenUrl": {
2134
+ "type": "string"
2135
+ },
2136
+ "refreshUrl": {
2137
+ "type": "string"
2138
+ },
2139
+ "scopes": {
2140
+ "$ref": "#/$defs/map-of-strings"
2141
+ }
2142
+ },
2143
+ "required": [
2144
+ "tokenUrl",
2145
+ "scopes"
2146
+ ],
2147
+ "$ref": "#/$defs/specification-extensions"
2148
+ },
2149
+ "client-credentials": {
2150
+ "type": "object",
2151
+ "properties": {
2152
+ "tokenUrl": {
2153
+ "type": "string"
2154
+ },
2155
+ "refreshUrl": {
2156
+ "type": "string"
2157
+ },
2158
+ "scopes": {
2159
+ "$ref": "#/$defs/map-of-strings"
2160
+ }
2161
+ },
2162
+ "required": [
2163
+ "tokenUrl",
2164
+ "scopes"
2165
+ ],
2166
+ "$ref": "#/$defs/specification-extensions"
2167
+ },
2168
+ "authorization-code": {
2169
+ "type": "object",
2170
+ "properties": {
2171
+ "authorizationUrl": {
2172
+ "type": "string"
2173
+ },
2174
+ "tokenUrl": {
2175
+ "type": "string"
2176
+ },
2177
+ "refreshUrl": {
2178
+ "type": "string"
2179
+ },
2180
+ "scopes": {
2181
+ "$ref": "#/$defs/map-of-strings"
2182
+ }
2183
+ },
2184
+ "required": [
2185
+ "authorizationUrl",
2186
+ "tokenUrl",
2187
+ "scopes"
2188
+ ],
2189
+ "$ref": "#/$defs/specification-extensions"
2190
+ }
2191
+ }
2192
+ },
2193
+ "security-requirement": {
2194
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#security-requirement-object",
2195
+ "type": "object",
2196
+ "additionalProperties": {
2197
+ "type": "array",
2198
+ "items": {
2199
+ "type": "string"
2200
+ }
2201
+ }
2202
+ },
2203
+ "specification-extensions": {
2204
+ "$comment": "https://spec.openapis.org/oas/v3.1.0#specification-extensions",
2205
+ "type": "object",
2206
+ "patternProperties": {
2207
+ "^x-": true
2208
+ }
2209
+ },
2210
+ "examples": {
2211
+ "type": "object",
2212
+ "properties": {
2213
+ "example": true,
2214
+ "examples": {
2215
+ "type": "object",
2216
+ "additionalProperties": {
2217
+ "$ref": "#/$defs/example-or-reference"
2218
+ }
2219
+ }
2220
+ }
2221
+ },
2222
+ "map-of-strings": {
2223
+ "type": "object",
2224
+ "additionalProperties": {
2225
+ "type": "string"
2226
+ }
2227
+ }
2228
+ }
2229
+ }