File tree 2 files changed +9
-16
lines changed
2 files changed +9
-16
lines changed Original file line number Diff line number Diff line change @@ -22,3 +22,10 @@ Such data would become invalid:
22
22
` ` ` json
23
23
{"$ref": "#", "unknown": 1}
24
24
` ` `
25
+
26
+ # # Combine HTTP Methods in `patternProperties`
27
+
28
+ ` ` ` yaml
29
+ patternProperties:
30
+ '^(get|put|post|delete|options|head|patch|trace)$': $ref: '#/definitions/Operation'
31
+ ` ` `
Original file line number Diff line number Diff line change @@ -556,22 +556,6 @@ definitions:
556
556
type : string
557
557
description :
558
558
type : string
559
- get :
560
- $ref : ' #/definitions/Operation'
561
- put :
562
- $ref : ' #/definitions/Operation'
563
- post :
564
- $ref : ' #/definitions/Operation'
565
- delete :
566
- $ref : ' #/definitions/Operation'
567
- options :
568
- $ref : ' #/definitions/Operation'
569
- head :
570
- $ref : ' #/definitions/Operation'
571
- patch :
572
- $ref : ' #/definitions/Operation'
573
- trace :
574
- $ref : ' #/definitions/Operation'
575
559
servers :
576
560
type : array
577
561
items :
@@ -584,6 +568,8 @@ definitions:
584
568
- $ref : ' #/definitions/Reference'
585
569
uniqueItems : true
586
570
patternProperties :
571
+ ' ^(get|put|post|delete|options|head|patch|trace)$ ' :
572
+ $ref : ' #/definitions/Operation'
587
573
' ^x- ' : {}
588
574
additionalProperties : false
589
575
You can’t perform that action at this time.
0 commit comments