From 985ece57551515e3b10a83c4a826bf35913a992a Mon Sep 17 00:00:00 2001 From: Rigel Kent Date: Mon, 10 May 2021 14:26:17 +0200 Subject: refactor abuses response list to totalDataList in openapi spec closes #4066 --- support/doc/api/openapi.yaml | 28 +++++++++++++++++++++------- 1 file changed, 21 insertions(+), 7 deletions(-) (limited to 'support') diff --git a/support/doc/api/openapi.yaml b/support/doc/api/openapi.yaml index a7501c9d3..bfe3c6da4 100644 --- a/support/doc/api/openapi.yaml +++ b/support/doc/api/openapi.yaml @@ -1867,6 +1867,7 @@ paths: /users/me/abuses: get: summary: List my abuses + operationId: getMyAbuses security: - OAuth2: [] tags: @@ -1882,22 +1883,29 @@ paths: in: query schema: $ref: '#/components/schemas/AbuseStateSet' + - $ref: '#/components/parameters/abusesSort' - $ref: '#/components/parameters/start' - $ref: '#/components/parameters/count' - - $ref: '#/components/parameters/abusesSort' responses: '200': description: successful operation content: application/json: schema: - type: array - items: - $ref: '#/components/schemas/Abuse' + type: object + properties: + total: + type: integer + example: 1 + data: + type: array + items: + $ref: '#/components/schemas/Abuse' /abuses: get: summary: List abuses + operationId: getAbuses security: - OAuth2: - admin @@ -1970,9 +1978,15 @@ paths: content: application/json: schema: - type: array - items: - $ref: '#/components/schemas/Abuse' + type: object + properties: + total: + type: integer + example: 1 + data: + type: array + items: + $ref: '#/components/schemas/Abuse' post: summary: Report an abuse -- cgit v1.2.3