-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapi-description.json
90 lines (90 loc) · 2.21 KB
/
api-description.json
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
{
"apiVersion": "1.0.0",
"swaggerVersion": "1.2",
"basePath": "http://node.github.dev:8000/api",
"resourcePath": "/genres",
"produces": [
"application/json"
],
"apis": [
{
"path": "/genres/",
"operations": [
{
"method": "GET",
"summary": "Get all genres",
"nickname": "getAllGenres",
"parameters": []
},
{
"method": "POST",
"summary": "Add a new genre",
"nickname": "addNewGenre",
"parameters": [
{
"name": "Data",
"description": "Data of genre to be added",
"required": true,
"type": "string",
"paramType": "body"
}
]
}
]
},
{
"path": "/genres/{genre_id}",
"operations": [
{
"method": "GET",
"summary": "Get genre by ID",
"nickname": "getGenreById",
"parameters": [
{
"name": "genre_id",
"description": "ID of genre that needs to be fetched",
"required": true,
"type": "string",
"paramType": "path"
}
]
},
{
"method": "PUT",
"summary": "Update a genre",
"nickname": "updateGenre",
"parameters": [
{
"name": "genre_id",
"description": "ID of genre that needs to be updated",
"required": true,
"type": "string",
"paramType": "path"
},
{
"name": "Data",
"description": "Data of genre to be updated",
"required": true,
"type": "string",
"paramType": "body"
}
]
},
{
"method": "DELETE",
"summary": "Delete a genre",
"nickname": "deleteGenre",
"parameters": [
{
"name": "genre_id",
"description": "ID of genre that needs to be deleted",
"required": true,
"type": "string",
"paramType": "path"
}
]
}
]
}
]
}