-
Notifications
You must be signed in to change notification settings - Fork 0
/
api-description.apib
57 lines (40 loc) · 1021 Bytes
/
api-description.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
52
53
54
55
56
57
FORMAT: 1A
# Todo API
## POST /v1/signup
Creating a new user
+ Request (application/json)
{
"email": "test@example.com",
"password": "password",
"userName": "test"
}
+ Response 200 (application/json; charset=UTF-8)
## POST /v1/login
Logging in as the new user
+ Request (application/json)
{
"email": "test@example.com",
"password": "password"
}
+ Response 200 (application/json; charset=UTF-8)
## POST /v1/todo
Creates a new todo
+ Request (application/json)
{
"name": "new todo",
"description": "this is a new todo"
}
+ Response 200 (application/json; charset=UTF-8)
## GET /v1/todos
Gets todos created by the user
+ Request (application/json)
+ Response 200 (application/json; charset=UTF-8)
{
"todos": [
{
"id": "aaa",
"name": "new todo",
"description": "this is a new todo"
}
]
}