refactor abuses response list to totalDataList in openapi spec

closes #4066
This commit is contained in:
Rigel Kent 2021-05-10 14:26:17 +02:00
parent 40cfb36b9d
commit 985ece5755
No known key found for this signature in database
GPG Key ID: 5E53E96A494E452F
1 changed files with 21 additions and 7 deletions

View File

@ -1867,6 +1867,7 @@ paths:
/users/me/abuses: /users/me/abuses:
get: get:
summary: List my abuses summary: List my abuses
operationId: getMyAbuses
security: security:
- OAuth2: [] - OAuth2: []
tags: tags:
@ -1882,22 +1883,29 @@ paths:
in: query in: query
schema: schema:
$ref: '#/components/schemas/AbuseStateSet' $ref: '#/components/schemas/AbuseStateSet'
- $ref: '#/components/parameters/abusesSort'
- $ref: '#/components/parameters/start' - $ref: '#/components/parameters/start'
- $ref: '#/components/parameters/count' - $ref: '#/components/parameters/count'
- $ref: '#/components/parameters/abusesSort'
responses: responses:
'200': '200':
description: successful operation description: successful operation
content: content:
application/json: application/json:
schema: schema:
type: array type: object
items: properties:
$ref: '#/components/schemas/Abuse' total:
type: integer
example: 1
data:
type: array
items:
$ref: '#/components/schemas/Abuse'
/abuses: /abuses:
get: get:
summary: List abuses summary: List abuses
operationId: getAbuses
security: security:
- OAuth2: - OAuth2:
- admin - admin
@ -1970,9 +1978,15 @@ paths:
content: content:
application/json: application/json:
schema: schema:
type: array type: object
items: properties:
$ref: '#/components/schemas/Abuse' total:
type: integer
example: 1
data:
type: array
items:
$ref: '#/components/schemas/Abuse'
post: post:
summary: Report an abuse summary: Report an abuse