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