forked from ramosbugs/openapi-lambda-rust
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbar.yaml
More file actions
62 lines (62 loc) · 1.5 KB
/
bar.yaml
File metadata and controls
62 lines (62 loc) · 1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
# Reference targets don't need to conform to the root OpenAPI definition layout.
path:
post:
operationId: createBar
parameters:
- name: barId
in: query
required: true
schema:
type: integer
format: crate::types::BarId
- $ref: "openapi.yaml#/components/parameters/SortBy"
# Identifier should be `r#type` to avoid Rust keyword.
- name: type
in: query
description: Bar type
schema:
type: string
# Inline enum should generate a new model.
enum:
- a
- B
- "1"
- ""
- name: type-array
in: query
description: Bar array type
schema:
type: array
items:
type: string
# Inline enum should generate a new model.
enum:
- a
- B
- "1"
- ""
- name: x-bar
in: header
schema:
type: string
requestBody:
$ref: "baz.yaml#/requestBodies/CreateBar"
responses:
"200":
description: Successful operation
content:
application/json:
schema:
$ref: "openapi.yaml#/components/schemas/Foo"
"400":
description: Bad request
content:
text/plain:
schema:
type: string
"404":
description: Not found
default:
description: Default response
tags:
- bar