1
- id : https://spec.openapis.org/oas/3.0/schema/2019-04-02
1
+ id : https://spec.openapis.org/oas/3.0/schema/2021-09-28
2
2
$schema : http://json-schema.org/draft-04/schema#
3
- description : Validation schema for OpenAPI Specification 3 .0.X.
3
+ description : The description of OpenAPI v3 .0.x documents, as defined by https://spec.openapis.org/oas/v3.0.3
4
4
type : object
5
5
required :
6
6
- openapi
@@ -20,6 +20,7 @@ properties:
20
20
$ref : ' #/definitions/Server'
21
21
security :
22
22
type : array
23
+ minItems : 1
23
24
items :
24
25
$ref : ' #/definitions/SecurityRequirement'
25
26
tags :
@@ -495,6 +496,22 @@ definitions:
495
496
type : string
496
497
description :
497
498
type : string
499
+ get :
500
+ $ref : ' #/definitions/Operation'
501
+ put :
502
+ $ref : ' #/definitions/Operation'
503
+ post :
504
+ $ref : ' #/definitions/Operation'
505
+ delete :
506
+ $ref : ' #/definitions/Operation'
507
+ options :
508
+ $ref : ' #/definitions/Operation'
509
+ head :
510
+ $ref : ' #/definitions/Operation'
511
+ patch :
512
+ $ref : ' #/definitions/Operation'
513
+ trace :
514
+ $ref : ' #/definitions/Operation'
498
515
servers :
499
516
type : array
500
517
items :
@@ -507,8 +524,6 @@ definitions:
507
524
- $ref : ' #/definitions/Reference'
508
525
uniqueItems : true
509
526
patternProperties :
510
- ' ^(get|put|post|delete|options|head|patch|trace)$ ' :
511
- $ref : ' #/definitions/Operation'
512
527
' ^x- ' : {}
513
528
additionalProperties : false
514
529
@@ -553,6 +568,7 @@ definitions:
553
568
default : false
554
569
security :
555
570
type : array
571
+ minItems : 1
556
572
items :
557
573
$ref : ' #/definitions/SecurityRequirement'
558
574
servers :
@@ -692,46 +708,51 @@ definitions:
692
708
allOf :
693
709
- $ref : ' #/definitions/ExampleXORExamples'
694
710
- $ref : ' #/definitions/SchemaXORContent'
695
- - $ref : ' #/definitions/ParameterLocation'
696
-
697
- ParameterLocation :
698
- description : Parameter location
699
711
oneOf :
700
- - description : Parameter in path
701
- required :
702
- - required
703
- properties :
704
- in :
705
- enum : [path]
706
- style :
707
- enum : [matrix, label, simple]
708
- default : simple
709
- required :
710
- enum : [true]
711
-
712
- - description : Parameter in query
713
- properties :
714
- in :
715
- enum : [query]
716
- style :
717
- enum : [form, spaceDelimited, pipeDelimited, deepObject]
718
- default : form
712
+ - $ref : ' #/definitions/PathParameter'
713
+ - $ref : ' #/definitions/QueryParameter'
714
+ - $ref : ' #/definitions/HeaderParameter'
715
+ - $ref : ' #/definitions/CookieParameter'
719
716
720
- - description : Parameter in header
721
- properties :
722
- in :
723
- enum : [header]
724
- style :
725
- enum : [simple]
726
- default : simple
717
+ PathParameter :
718
+ description : Parameter in path
719
+ required :
720
+ - required
721
+ properties :
722
+ in :
723
+ enum : [path]
724
+ style :
725
+ enum : [matrix, label, simple]
726
+ default : simple
727
+ required :
728
+ enum : [true]
727
729
728
- - description : Parameter in cookie
729
- properties :
730
- in :
731
- enum : [cookie]
732
- style :
733
- enum : [form]
734
- default : form
730
+ QueryParameter :
731
+ description : Parameter in query
732
+ properties :
733
+ in :
734
+ enum : [query]
735
+ style :
736
+ enum : [form, spaceDelimited, pipeDelimited, deepObject]
737
+ default : form
738
+
739
+ HeaderParameter :
740
+ description : Parameter in header
741
+ properties :
742
+ in :
743
+ enum : [header]
744
+ style :
745
+ enum : [simple]
746
+ default : simple
747
+
748
+ CookieParameter :
749
+ description : Parameter in cookie
750
+ properties :
751
+ in :
752
+ enum : [cookie]
753
+ style :
754
+ enum : [form]
755
+ default : form
735
756
736
757
RequestBody :
737
758
type : object
@@ -806,15 +827,17 @@ definitions:
806
827
- description : Bearer
807
828
properties :
808
829
scheme :
809
- enum : [bearer]
830
+ type : string
831
+ pattern : ^[Bb][Ee][Aa][Rr][Ee][Rr]$
810
832
811
833
- description : Non Bearer
812
834
not :
813
835
required : [bearerFormat]
814
836
properties :
815
837
scheme :
816
838
not :
817
- enum : [bearer]
839
+ type : string
840
+ pattern : ^[Bb][Ee][Aa][Rr][Ee][Rr]$
818
841
819
842
OAuth2SecurityScheme :
820
843
type : object
@@ -892,6 +915,7 @@ definitions:
892
915
type : object
893
916
required :
894
917
- tokenUrl
918
+ - scopes
895
919
properties :
896
920
tokenUrl :
897
921
type : string
@@ -911,6 +935,7 @@ definitions:
911
935
type : object
912
936
required :
913
937
- tokenUrl
938
+ - scopes
914
939
properties :
915
940
tokenUrl :
916
941
type : string
@@ -931,6 +956,7 @@ definitions:
931
956
required :
932
957
- authorizationUrl
933
958
- tokenUrl
959
+ - scopes
934
960
properties :
935
961
authorizationUrl :
936
962
type : string
@@ -987,7 +1013,9 @@ definitions:
987
1013
headers :
988
1014
type : object
989
1015
additionalProperties :
990
- $ref : ' #/definitions/Header'
1016
+ oneOf :
1017
+ - $ref : ' #/definitions/Header'
1018
+ - $ref : ' #/definitions/Reference'
991
1019
style :
992
1020
type : string
993
1021
enum :
@@ -1000,4 +1028,6 @@ definitions:
1000
1028
allowReserved :
1001
1029
type : boolean
1002
1030
default : false
1031
+ patternProperties :
1032
+ ' ^x- ' : {}
1003
1033
additionalProperties : false
0 commit comments