-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapi.yaml
More file actions
103 lines (103 loc) · 2.64 KB
/
api.yaml
File metadata and controls
103 lines (103 loc) · 2.64 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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
"/store/inventory":
get:
tags:
- store
summary: Returns pet inventories by status
description: Returns a map of status codes to quantities
operationId: getInventory
responses:
200:
description: successful operation
content:
application/json:
schema:
type: object
additionalProperties:
type: integer
format: int32
security:
- api_key: []
"/store/order":
post:
tags:
- store
summary: Place an order for a pet
description: ''
operationId: placeOrder
responses:
200:
$ref: "#/components/responses/Order"
400:
$ref: "../../components/responses.yaml#/400"
requestBody:
$ref: "#/components/requestBodies/Order"
"/store/order/{orderId}":
get:
tags:
- store
summary: Find purchase order by ID
description: For valid response try integer IDs with value >= 1 and <= 10. Other
values will generated exceptions
operationId: getOrderById
parameters:
- name: orderId
in: path
description: ID of pet that needs to be fetched
required: true
schema:
type: integer
format: int64
minimum: 1
maximum: 10
responses:
200:
$ref: "#/components/responses/Order"
400:
$ref: "../../components/responses.yaml#/400"
404:
$ref: "../../components/responses.yaml#/404"
delete:
tags:
- store
summary: Delete purchase order by ID
description: For valid response try integer IDs with positive integer value.
Negative or non-integer values will generate API errors
operationId: deleteOrder
parameters:
- name: orderId
in: path
description: ID of the order that needs to be deleted
required: true
schema:
type: integer
format: int64
minimum: 1
responses:
400:
$ref: "../../components/responses.yaml#/400"
404:
$ref: "../../components/responses.yaml#/404"
components:
requestBodies:
Order:
content:
application/json:
schema:
$ref: "#/components/schemas/StoreOrder"
description: order placed for purchasing the pet
required: true
schemas:
Order:
$ref: "/models/order.yaml#/Order"
StoreOrder:
$ref: "/models/order.yaml#/StoreOrder"
responses:
Order:
description: successful operation
content:
application/xml:
schema:
$ref: "#/components/schemas/Order"
application/json:
schema:
$ref: "#/components/schemas/Order"