cloudapi: validate input
Validate incoming requests with openapi3. Remove unsupported uuid format from the openapi spec. Similarly, change url to uri as uri is a supported format and url is not. Co-authored-by: Ondřej Budai <obudai@redhat.com> Signed-off-by: Ondřej Budai <ondrej@budai.cz>
This commit is contained in:
parent
f616becf39
commit
13c79294b6
83 changed files with 4942 additions and 549 deletions
2
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/components/Bar.yml
generated
vendored
Normal file
2
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/components/Bar.yml
generated
vendored
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
type: string
|
||||
example: bar
|
||||
4
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/components/Foo.yml
generated
vendored
Normal file
4
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/components/Foo.yml
generated
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
type: object
|
||||
properties:
|
||||
bar:
|
||||
$ref: ../openapi.yml#/components/schemas/Bar
|
||||
4
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/components/Foo/Foo2.yml
generated
vendored
Normal file
4
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/components/Foo/Foo2.yml
generated
vendored
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
type: object
|
||||
properties:
|
||||
foo:
|
||||
$ref: ../../openapi.yml#/components/schemas/Foo
|
||||
15
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/openapi.yml
generated
vendored
Normal file
15
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/openapi.yml
generated
vendored
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
openapi: "3.0.3"
|
||||
info:
|
||||
title: Recursive refs example
|
||||
version: "1.0"
|
||||
paths:
|
||||
/foo:
|
||||
$ref: ./paths/foo.yml
|
||||
components:
|
||||
schemas:
|
||||
Foo:
|
||||
$ref: ./components/Foo.yml
|
||||
Foo2:
|
||||
$ref: ./components/Foo/Foo2.yml
|
||||
Bar:
|
||||
$ref: ./components/Bar.yml
|
||||
11
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/paths/foo.yml
generated
vendored
Normal file
11
vendor/github.com/getkin/kin-openapi/openapi3/testdata/recursiveRef/paths/foo.yml
generated
vendored
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
get:
|
||||
responses:
|
||||
"200":
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
foo2:
|
||||
$ref: ../openapi.yml#/components/schemas/Foo2
|
||||
Loading…
Add table
Add a link
Reference in a new issue