-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathreq.http
109 lines (82 loc) · 2.02 KB
/
req.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
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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
###################################################################
### DOCTOR
### register | OK
POST http://localhost:8080/doctor/register
Content-Type: application/json
{
"firstName": "james",
"lastName": "adam",
"phoneNumber": "01010931887",
"nationalId": "292123132313",
"dateOfBirth": "1997-07-16",
"email": "[email protected]",
"spec": "cardiology",
"password": "xcdz"
}
### all doctors | OK
GET http://localhost:8080/doctor/all
### one | OK
GET http://localhost:8080/doctor/one/2
### get by specialization
GET http://localhost:8080/doctor/specialization/1
### edit | OK
PUT http://localhost:8080/doctor/10
Content-Type: application/json
{
"workingHoursStart": "05:00",
"workingHoursEnd": "23:00",
"bookingDuration": 1
}
### delete | OK
DELETE http://localhost:8080/doctor/3
###########################################################################
### PATIENT
### register
POST http://localhost:8080/user/register
Content-Type: application/json
{
"firstName": "james",
"lastName": "adam",
"phoneNumber": "01010931887",
"nationalId": "921332393213",
"dateOfBirth": "1997-07-16",
"email": "[email protected]",
"password": "xcdz"
}
### update | OK
PUT http://localhost:8080/user/12
Content-Type: application/json
{
"firstName": "jamesxxx",
"lastName": "bbbbb",
"phoneNumber": "01018888888888888887"
}
### delete | OK
DELETE http://localhost:8080/user/12
### login
POST http://localhost:8080/login
Content-Type: application/json
{
"email": "[email protected]",
"password": "xcdz"
}
###########################################################################
### RESERVATIONS
### patient reservations | OK
GET http://localhost:8080/book/patient/2
### doctor reservations | OK
GET http://localhost:8080/book/doctor/10
### book | OK
POST http://localhost:8080/book
Content-Type: application/json
{
"doctorId": 10,
"patientId": 2,
"day": "2023-12-25",
"start": "05:15",
"end": "05:30"
}
### slots | OK
GET http://localhost:8080/book/availble_slots/1
### delete | OK
DELETE http://localhost:8080/book/28