From ed8607066c5a2f27101f69049c94da78b219c809 Mon Sep 17 00:00:00 2001 From: domi41 Date: Thu, 24 Sep 2020 14:04:32 +0200 Subject: [PATCH] feat: tag more paths --- openapi/components/schemas/grade.yaml | 1 + openapi/mv-openapi-root.yaml | 9 ++++++++- openapi/paths/polls.yaml | 1 + openapi/paths/polls@{poll-id}@ballots.yaml | 4 +++- openapi/paths/polls@{poll-id}@ballots@{ballot-id}.yaml | 5 +++++ openapi/paths/polls@{poll-id}@results.yaml | 2 ++ 6 files changed, 20 insertions(+), 2 deletions(-) diff --git a/openapi/components/schemas/grade.yaml b/openapi/components/schemas/grade.yaml index fe39a24..1ce2a68 100644 --- a/openapi/components/schemas/grade.yaml +++ b/openapi/components/schemas/grade.yaml @@ -5,6 +5,7 @@ properties: description: > Unique identifier of the grade in its grading. Zero (0) is the worst grade, and it goes upwards. + TBD - WIP example: 0 readOnly: true name: diff --git a/openapi/mv-openapi-root.yaml b/openapi/mv-openapi-root.yaml index 937d7e7..eb33b1f 100644 --- a/openapi/mv-openapi-root.yaml +++ b/openapi/mv-openapi-root.yaml @@ -33,17 +33,24 @@ paths: '/users/{user-id}': $ref: 'paths/users@{user-id}.yaml' tags: + - name: Poll Indexation + description: > + Paths about indexing (public) polls. - name: Poll Organization description: > - Paths about the organization of polls. + Paths about organizing a poll. - name: Poll Participation description: > Paths about participating to a poll. + - name: Poll Deliberation + description: > + Paths about deliberating using a poll. components: securitySchemes: participantAuth: type: http scheme: bearer + # organizerAuth pollAuth: type: http scheme: bearer diff --git a/openapi/paths/polls.yaml b/openapi/paths/polls.yaml index 16d213d..89650e7 100644 --- a/openapi/paths/polls.yaml +++ b/openapi/paths/polls.yaml @@ -2,6 +2,7 @@ get: operationId: get-polls summary: Gets all polls tags: + - Poll Indexation - Poll Organization - Poll Participation responses: diff --git a/openapi/paths/polls@{poll-id}@ballots.yaml b/openapi/paths/polls@{poll-id}@ballots.yaml index 4b44f14..146acfa 100644 --- a/openapi/paths/polls@{poll-id}@ballots.yaml +++ b/openapi/paths/polls@{poll-id}@ballots.yaml @@ -7,6 +7,8 @@ parameters: post: operationId: create-ballot summary: Creates a ballot + tags: + - Poll Participation requestBody: required: true content: @@ -26,7 +28,7 @@ post: properties: id: type: string - description: Id of the created ballot. + description: Identifier of the created ballot. links: get-ballot: $ref: ../components/links/get-ballot.yaml diff --git a/openapi/paths/polls@{poll-id}@ballots@{ballot-id}.yaml b/openapi/paths/polls@{poll-id}@ballots@{ballot-id}.yaml index e22948e..b4ac6ea 100644 --- a/openapi/paths/polls@{poll-id}@ballots@{ballot-id}.yaml +++ b/openapi/paths/polls@{poll-id}@ballots@{ballot-id}.yaml @@ -12,6 +12,9 @@ parameters: get: operationId: get-ballot summary: Gets a ballot by ID + tags: + - Poll Participation + - Poll Deliberation responses: '200': description: A ballot object @@ -22,6 +25,8 @@ get: delete: operationId: delete-ballot summary: Deletes a ballot + tags: + - Poll Participation responses: '200': description: OK diff --git a/openapi/paths/polls@{poll-id}@results.yaml b/openapi/paths/polls@{poll-id}@results.yaml index 108f37a..8aec8e0 100644 --- a/openapi/paths/polls@{poll-id}@results.yaml +++ b/openapi/paths/polls@{poll-id}@results.yaml @@ -7,6 +7,8 @@ parameters: get: operationId: get-poll-results summary: Gets the results of a poll + tags: + - Poll Deliberation responses: '200': description: OK