-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapiary.apib
51 lines (33 loc) · 897 Bytes
/
apiary.apib
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
FORMAT: 1A
# Animals API
Animals API is a service to store animals.
# Group Animals
Contracts related resources of the **Animals API**
## Animals [/animals]
### List all animals [GET]
+ Response 200 (application/json)
[
"cat",
"dog",
"lion"
]
### Add a new animal [PUT]
+ Request (application/json)
+ Header
Authorization: bearer eHZ6MWV2R...o4OERSZHlPZw==
+ Body
"tiger"
+ Response 201
## Animal [/animals/{animal}]
A single animal object with all its details
+ Parameters
+ animal (required, string, `tiger`) ... String `animal` of the animal you want to retrieve.
### Retrieve an animal [GET]
+ Response 200 (application/json)
+ Body
"cat"
### Remove the animal [DELETE]
+ Request
+ Header
Authorization: bearer eHZ6MWV2R...o4OERSZHlPZw==
+ Response 204