-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrequests.http
More file actions
54 lines (41 loc) · 1011 Bytes
/
requests.http
File metadata and controls
54 lines (41 loc) · 1011 Bytes
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
@baseUrl = http://localhost:3000
### List all active alarms
GET {{baseUrl}}/alarms
### Create a timer by duration (minutes)
POST {{baseUrl}}/alarms
Content-Type: application/json
{
"duration": "2 minutes",
"label": "Pizza"
}
### Create a timer by duration (shorthand)
POST {{baseUrl}}/alarms
Content-Type: application/json
{
"duration": "1h30m",
"label": "Nap"
}
### Create a timer by duration (seconds — good for quick testing)
POST {{baseUrl}}/alarms
Content-Type: application/json
{
"duration": "10s",
"label": "Test"
}
### Create an alarm by exact time (12h format)
POST {{baseUrl}}/alarms
Content-Type: application/json
{
"time": "7:30pm",
"label": "Standup"
}
### Create an alarm by exact time (24h format)
POST {{baseUrl}}/alarms
Content-Type: application/json
{
"time": "19:30"
}
### Stop the currently ringing alarm
DELETE {{baseUrl}}/alarms/ringing
### Delete / stop an alarm by id (replace with real id)
DELETE {{baseUrl}}/alarms/00000000-0000-0000-0000-000000000000