-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrestClient.http
212 lines (172 loc) · 4.84 KB
/
restClient.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
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
@entryPoint = http://localhost:4100/api/v1
#* --------------------- USER
#& ---- All User
###
GET {{entryPoint}}/users
Content-Type: application/json
Authorization: Bearer
###
GET {{entryPoint}}/users/12
Content-Type: application/json
###
PUT {{entryPoint}}/users/13
Content-Type: application/json
{
"is_active": false
}
###
POST {{entryPoint}}/signup
Content-Type: application/json
{
"username": "Coucou_Heleneeeeeeeeee",
"email": "[email protected]",
"password": "N6y$Ozddzt=1aa",
"passwordConfirm": "N6y$Ozddzt=1aa"
}
###
POST {{entryPoint}}/signin
Content-Type: application/json
{
"email": "[email protected]",
"password": "N6y$Ozddzt=1aa"
}
###
GET {{entryPoint}}/signout
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZGVudGl0eSI6eyJpZCI6MTEsImVtYWlsIjoiRnJlZG8uTGl0dGxlODlAeWFob28uY29tIiwiaXNhY3RpdmUiOnRydWUsInJvbGUiOiJhZG1pbiJ9LCJpYXQiOjE2NTg1NjM3NjUsImV4cCI6MTY1ODU2NDk2NX0.2JEWpAEKCQEjEU1g-QPx-cWmvdHl1BsPCZqjhSLWpEg
# ------------------------------------------------------------------
# ------------------------------------------------------------------
###
POST {{entryPoint}}/refreshToken
Content-type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZGVudGl0eSI6eyJpZCI6MTEsImVtYWlsIjoiRnJlZG8uTGl0dGxlODlAeWFob28uY29tIiwiaXNhY3RpdmUiOnRydWUsInJvbGUiOiJhdXRob3IifSwiaWF0IjoxNjU4NTY3NzI5LCJleHAiOjE2NTg1Njc4NDl9.vciY0crBXNgEdGDdvFJ30K83LFhLPS0CP7_k4meQWGc
{
"email": "[email protected]"
}
# ------------------------------------------------------------------
# ------------------------------------------------------------------
###
PATCH {{entryPoint}}/users/14
Content-Type: application/json
{
"username": "Coucou_Heleneeeeeeeeee",
"email": "[email protected]",
"password": "N6y$Ozddzt=1aa",
"passwordConfirm": "N6y$Ozddzt=1aa",
"profile_pic_url":"https://cloudflare-ipfs.com/ipfs/Qmd3W5DuhgHirLHGVixi6V76LhCkZUz6pnFt5AJBiyvHye/avatar/940.jpg",
"linkedin_url":"https://cloudflare-ipfs.com/ipfs/Qmd3W5DuhgHirLHGVixi6V76LhCkZUz6pnFt5AJBiyvHye/avatar/745.jpg",
"id": 2
}
###
DELETE {{entryPoint}}/users/12
Content-Type: application/json
#* --------------------- ARTICLE
###
GET {{entryPoint}}/articles
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZGVudGl0eSI6eyJpZCI6MTEsImVtYWlsIjoiRnJlZG8uTGl0dGxlODlAeWFob28uY29tIiwiaXNhY3RpdmUiOnRydWUsInJvbGUiOiJhdXRob3IifSwiaWF0IjoxNjU4NTY3NzI5LCJleHAiOjE2NTg1Njc3ODl9.K-EB8WKOxiTZRYho8A6N5vgjAKhnPbLpUJdVzeH_Mnk
###
POST {{entryPoint}}/articles
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZGVudGl0eSI6eyJpZCI6MTEsImVtYWlsIjoiRnJlZG8uTGl0dGxlODlAeWFob28uY29tIiwiaXNhY3RpdmUiOnRydWUsInJvbGUiOiJhdXRob3IifSwiaWF0IjoxNjU4NTY3NzI5LCJleHAiOjE2NTg1Njc3ODl9.K-EB8WKOxiTZRYho8A6N5vgjAKhnPbLpUJdVzeH_Mnk
{
"title": "test",
"abstract": "test",
"content": "test",
"user_id":1,
"status_id":1
}
###
GET {{entryPoint}}/articles/4
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZGVudGl0eSI6eyJpZCI6MTEsImVtYWlsIjoiSGVsZW5lLkxpdHRsZTg5QHlhaG9vLmNvbSIsInJvbGUiOiJ1c2VyIn0sImlhdCI6MTY1ODU1MTA3NiwiZXhwIjoxNjU4NjM3NDc2fQ.zDRuuE6Bq3m-WJ8t-1w4NLQbtZMeHqAACuLNveyy0hU
#* --------------------- ERROR
###
GET {{entryPoint}}/errors
Content-Type: application/json
###
GET {{entryPoint}}/errors/1
Content-Type: application/json
#* --------------------- ARTICLE COMMENT
###
GET {{entryPoint}}/articles/7/comments
Content-Type: application/json
#* --------------------- ERROR COMMENT
###
GET {{entryPoint}}/errors/3/comments
Content-Type: application/json
#* --------------------- CATEGORY
###
GET {{entryPoint}}/categories
Content-Type: application/json
###
GET {{entryPoint}}/categories/1
Content-Type: application/json
// Utilisateur
{
"id": ,
"username": "",
"email": "",
"password": "",
"is_active": "",
"title": "",
"presentation": "",
"profile_pic_url": "",
"linkedin_url": "",
"github_url": "",
"instagram_url": "",
"twitter_url": "",
"portfolio_url": "",
"role_id": "",
"created_at": "",
"updated_at": "",
}
// articles
{
"id": ,
"title": ,
"abstract": ,
"content": ,
"user_id":,
"status_id":,
"created_at":,
"updated_at":,
}
// Error Tickets
{
"id": ,
"error_snippet": ,
"title": ,
"abstract": ,
"content":,
"user_id":,
"status_id":,
"error_comment_id":,
"created_at":,
"updated_at"
}
// Article Comments
{
"id": ,
"content": ,
"user_id": ,
"article_id": ,
"created_at": ,
"updated_at":,
}
// Error ticket comments
{
"id": ,
"content": ,
"user_id": ,
"article_id": ,
"error_id": ,
"created_at":,
"updated_at"
}
// category
{
"id":,
"name":,
"logo_svg":,
}