-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrequests.http
57 lines (40 loc) · 922 Bytes
/
requests.http
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
### Nuke Database
POST http://localhost:3000/debug/nuke
### Get packs
GET http://localhost:3000/packs
### Get packs with offset
GET http://localhost:3000/packs?offset=1
### Get packs with limit
GET http://localhost:3000/packs?limit=1
### Get packs by categories
GET http://localhost:3000/packs?categories[]=party
### Create a pack
POST http://localhost:3000/packs
Content-Type: application/json
{
"name": "Jon's Awesome Pack",
"categories": ["fun", "awesome", "party"],
"questions": [
"q1",
"q2",
"q3"
],
"public": false
}
### Delete a pack
DELETE http://localhost:3000/packs/1
### Edit a pack
PUT http://localhost:3000/packs/1
Content-Type: application/json
{
"name": "Gary's Awesome Pack",
"categories": ["awesome", "party", "random"],
"questions": [
"q1",
"q2",
"q4"
],
"public": true
}
### Get all categories
GET http://localhost:3000/categories