13
13
name : CodeCarrot
14
14
15
15
servers :
16
- - url : https://api.<your-domain>.com/api/v1
17
- description : " "
16
+ - url : ' {protocol}://{host-with-port}/api/v1'
17
+ description : " API URL"
18
+ variables :
19
+ protocol :
20
+ enum :
21
+ - ' http'
22
+ - ' https'
23
+ default : ' http'
24
+ host-with-port :
25
+ default : ' localhost:8000'
26
+ security :
27
+ - bearerAuth : []
18
28
tags :
19
29
- name : auth
20
30
description : " Endpoints related to account authentication via email and password"
32
42
description : " Endpoints related to roles and permissions"
33
43
- name : settings
34
44
description : " Endpoints related to LogChimp settings"
35
-
36
45
paths :
37
46
/auth/login :
38
47
post :
@@ -41,13 +50,10 @@ paths:
41
50
summary : Login
42
51
description : ' Login to account using email and password.'
43
52
operationId : userSignin
44
- parameters :
45
- - $ref : ' #/components/parameters/contentTypeJson'
46
- - $ref : ' #/components/parameters/origin'
47
53
requestBody :
48
54
$ref : ' #/components/requestBodies/Login'
49
55
responses :
50
- 200 :
56
+ ' 200 ' :
51
57
description : ' '
52
58
content :
53
59
application/json :
60
66
headers :
61
67
Content-Type :
62
68
$ref : ' #/components/headers/contentTypeJson'
63
- 400 :
69
+ ' 400 ' :
64
70
description : Bad Request
65
71
content :
66
72
application/json :
90
96
headers :
91
97
Content-Type :
92
98
$ref : ' #/components/headers/contentTypeJson'
93
- 500 :
99
+ ' 500 ' :
94
100
$ref : " #/components/responses/InternalServerError"
95
101
headers :
96
102
Content-Type :
@@ -103,13 +109,10 @@ paths:
103
109
summary : Sign up
104
110
description : Create a new user account.
105
111
operationId : userSignup
106
- parameters :
107
- - $ref : ' #/components/parameters/contentTypeJson'
108
- - $ref : ' #/components/parameters/origin'
109
112
requestBody :
110
113
$ref : ' #/components/requestBodies/Login'
111
114
responses :
112
- 201 :
115
+ ' 201 ' :
113
116
description : ' '
114
117
content :
115
118
application/json :
@@ -122,7 +125,7 @@ paths:
122
125
headers :
123
126
Content-Type :
124
127
$ref : ' #/components/headers/contentTypeJson'
125
- 400 :
128
+ ' 400 ' :
126
129
description : Bad Request
127
130
content :
128
131
application/json :
@@ -150,24 +153,21 @@ paths:
150
153
headers :
151
154
Content-Type :
152
155
$ref : ' #/components/headers/contentTypeJson'
153
- 500 :
156
+ ' 500 ' :
154
157
$ref : " #/components/responses/InternalServerError"
155
158
headers :
156
159
Content-Type :
157
160
$ref : ' #/components/headers/contentTypeJson'
158
- security : [ ]
161
+ security : []
159
162
/auth/setup :
160
163
get :
161
164
tags :
162
165
- auth
163
166
summary : Site setup
164
167
description : ' Get site setup information.'
165
168
operationId : getSiteSetup
166
- parameters :
167
- - $ref : ' #/components/parameters/contentTypeJson'
168
- - $ref : ' #/components/parameters/origin'
169
169
responses :
170
- 200 :
170
+ ' 200 ' :
171
171
description : ' '
172
172
content :
173
173
application/json :
@@ -180,7 +180,7 @@ paths:
180
180
headers :
181
181
Content-Type :
182
182
$ref : ' #/components/headers/contentTypeJson'
183
- 500 :
183
+ ' 500 ' :
184
184
$ref : " #/components/responses/InternalServerError"
185
185
headers :
186
186
Content-Type :
@@ -192,9 +192,6 @@ paths:
192
192
summary : Site setup
193
193
description : ' Setup the site by creating the owner account.'
194
194
operationId : siteSetup
195
- parameters :
196
- - $ref : ' #/components/parameters/contentTypeJson'
197
- - $ref : ' #/components/parameters/origin'
198
195
requestBody :
199
196
description : ' '
200
197
content :
@@ -213,7 +210,7 @@ paths:
213
210
example : " Mike"
214
211
required : true
215
212
responses :
216
- 200 :
213
+ ' 200 ' :
217
214
description : ' '
218
215
content :
219
216
application/json :
@@ -226,7 +223,7 @@ paths:
226
223
headers :
227
224
Content-Type :
228
225
$ref : ' #/components/headers/contentTypeJson'
229
- 400 :
226
+ ' 400 ' :
230
227
description : Bad Request
231
228
content :
232
229
application/json :
@@ -254,7 +251,7 @@ paths:
254
251
headers :
255
252
Content-Type :
256
253
$ref : ' #/components/headers/contentTypeJson'
257
- 500 :
254
+ ' 500 ' :
258
255
$ref : " #/components/responses/InternalServerError"
259
256
headers :
260
257
Content-Type :
@@ -292,15 +289,8 @@ paths:
292
289
type : string
293
290
default : application/json
294
291
description : " "
295
- requestBody :
296
- description : Get all the boards
297
- content :
298
- application/json :
299
- schema :
300
- type : object
301
- required : false
302
292
responses :
303
- 200 :
293
+ ' 200 ' :
304
294
description : " "
305
295
content :
306
296
application/json :
@@ -315,12 +305,12 @@ paths:
315
305
headers :
316
306
Content-Type :
317
307
$ref : ' #/components/headers/contentTypeJson'
318
- 500 :
308
+ ' 500 ' :
319
309
$ref : " #/components/responses/InternalServerError"
320
310
headers :
321
311
Content-Type :
322
312
$ref : ' #/components/headers/contentTypeJson'
323
- security : [ ]
313
+ security : []
324
314
/auth/email/verify :
325
315
post :
326
316
tags :
@@ -330,23 +320,8 @@ paths:
330
320
Send a verification email to the user email address.
331
321
The email is only sent if have configured [SMTP mail server](https://docs.logchimp.codecarrot.net/docs/environment-variables#mail) are configured at the time of deploying LogChimp.
332
322
operationId : sendVerificationEmail
333
- parameters :
334
- - $ref : ' #/components/parameters/contentTypeJson'
335
- - $ref : ' #/components/parameters/origin'
336
- requestBody :
337
- description : ' '
338
- content :
339
- application/json :
340
- schema :
341
- type : object
342
- properties :
343
- email :
344
- type : string
345
- format : email
346
-
347
- required : true
348
323
responses :
349
- 200 :
324
+ ' 200 ' :
350
325
description : ' '
351
326
content :
352
327
application/json :
@@ -362,7 +337,7 @@ paths:
362
337
headers :
363
338
Content-Type :
364
339
$ref : ' #/components/headers/contentTypeJson'
365
- 400 :
340
+ ' 400 ' :
366
341
description : Bad Request
367
342
content :
368
343
application/json :
@@ -376,40 +351,29 @@ paths:
376
351
headers :
377
352
Content-Type :
378
353
$ref : ' #/components/headers/contentTypeJson'
379
- 500 :
354
+ ' 500 ' :
380
355
$ref : " #/components/responses/InternalServerError"
381
356
headers :
382
357
Content-Type :
383
358
$ref : ' #/components/headers/contentTypeJson'
384
- security : [ ]
385
359
components :
360
+ securitySchemes :
361
+ bearerAuth :
362
+ type : http
363
+ scheme : bearer
364
+ description : JWT Bearer token authentication
386
365
headers :
387
366
contentTypeJson :
388
367
description : ' '
389
368
schema :
390
369
type : string
391
370
example : application/json
392
- parameters :
393
- contentTypeJson :
394
- name : Content-Type
395
- in : header
396
- schema :
397
- type : string
398
- default : application/json
399
- description : ' '
400
- origin :
401
- name : origin
402
- in : header
403
- schema :
404
- type : string
405
- default : ' https://example.com'
406
- description : ' '
407
371
schemas :
408
372
UserBlockedErrorCode :
409
373
type : object
410
374
required :
411
- - message
412
- - code
375
+ - message
376
+ - code
413
377
properties :
414
378
message :
415
379
type : string
@@ -420,8 +384,8 @@ components:
420
384
InvalidUserIdErrorCode :
421
385
type : object
422
386
required :
423
- - message
424
- - code
387
+ - message
388
+ - code
425
389
properties :
426
390
message :
427
391
type : string
@@ -432,8 +396,8 @@ components:
432
396
UserNotFoundErrorCode :
433
397
type : object
434
398
required :
435
- - message
436
- - code
399
+ - message
400
+ - code
437
401
properties :
438
402
message :
439
403
type : string
@@ -444,8 +408,8 @@ components:
444
408
EmailInvalidErrorCode :
445
409
type : object
446
410
required :
447
- - message
448
- - code
411
+ - message
412
+ - code
449
413
properties :
450
414
message :
451
415
type : string
@@ -456,8 +420,8 @@ components:
456
420
EmailVerifiedErrorCode :
457
421
type : object
458
422
required :
459
- - message
460
- - code
423
+ - message
424
+ - code
461
425
properties :
462
426
message :
463
427
type : string
@@ -468,8 +432,8 @@ components:
468
432
MailConfigurationErrorCode :
469
433
type : object
470
434
required :
471
- - message
472
- - code
435
+ - message
436
+ - code
473
437
properties :
474
438
message :
475
439
type : string
@@ -483,7 +447,7 @@ components:
483
447
boardId :
484
448
type : string
485
449
format : uuid
486
- example :
450
+ example : 11c14790-b4d3-4689-942c-55548cfdd8a6
487
451
name :
488
452
type : string
489
453
example : " 🔗 Integrations"
@@ -499,7 +463,7 @@ components:
499
463
format : date-time
500
464
BoardDetail :
501
465
allOf :
502
- - $ref : " #/components/schemas/Board"
466
+ - $ref : " #/components/schemas/Board"
503
467
- type : object
504
468
properties :
505
469
post_count :
0 commit comments