-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrequests.http
64 lines (49 loc) · 1.32 KB
/
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
58
59
60
61
62
63
### create new user
POST http://localhost:3000/auth/signup
Content-Type: application/json
{
"userEmail":"[email protected]",
"userPassword":"12345678Hr",
"userFName":"hema",
"userMName":"mahamed",
"userLName":"ali"
}
### validate user email
PATCH http://localhost:3000/auth/validate-email
Content-Type: application/json
{
"id":1,
"validationCode":"2317480f"
}
### log in user
POST http://localhost:3000/auth/login
Content-Type: application/json
{
"userUniversity":"0",
"userEmail":"[email protected]",
"userPassword":"23456789Hrs"
}
### reset password
PATCH http://localhost:3000/auth/reset-password
Content-Type: application/json
{
"userId":"1",
"newPassword":"23456789Hr",
"validationCode":"5b356f5b"
}
### change Email
PATCH http://localhost:3000/auth/change-email
Content-Type: application/json
Authorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjEiLCJpYXQiOjE2NDUyNTM5MTR9.hPKrdhiPJfW0AXkoQQYi38d1tAKqt5ZWd1_Mi2CXpCs
{
"userId":"1",
"newEmail":"[email protected]",
"validationCode":"6413b754"
}
### request validation email
GET http://localhost:3000/auth/send-validation
Content-Type: application/json
Authorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjEiLCJpYXQiOjE2NDUyNTM5MTR9.hPKrdhiPJfW0AXkoQQYi38d1tAKqt5ZWd1_Mi2CXpCs
{
"userId":"1"
}