Add validation on Constitution routes

This commit is contained in:
2021-04-10 23:45:16 +02:00
parent 0c8bcbd634
commit 6a5e00bb4d
7 changed files with 120 additions and 17 deletions

View File

@@ -851,6 +851,12 @@ paths:
type: array
items:
$ref: '#/components/schemas/ConstitutionListingResponse'
400:
description: BadReqest
content:
application/json:
schema:
$ref: '#/components/schemas/400'
post:
security:
- JWTAuth: [ ]
@@ -875,7 +881,11 @@ paths:
401:
$ref: '#/components/responses/401'
400:
$ref: '#/components/responses/400'
description: BadReqest
content:
application/json:
schema:
$ref: '#/components/schemas/400'
/constitutions/{constitution}:
parameters:
- $ref: '#/components/parameters/constitution'
@@ -2019,6 +2029,8 @@ components:
$ref: '#/components/schemas/UUID'
title:
type: string
minLength: 10
maxLength: 80
example:
Constitution for the liberty
titles:
@@ -2034,6 +2046,8 @@ components:
$ref: '#/components/schemas/UUID'
name:
type: string
minLength: 10
maxLength: 80
example:
The liberties
articles: