1 Commits
Author SHA1 Message Date
gnome627andClaude Opus 5.5 801eee915a fix(swagger): починил рендер в Gitea (openapi-swagger)
- js-yaml 5 (парсер Gitea) падает на deficient indentation: закрывающие }
  flow-маппингов example стояли на уровне ключа-родителя
- /survey/index: коды 400-500 были вложены в 200, у 200 не было description
- /goal/*: responses ссылался $ref'ом целиком на components/responses;
  GoalIndexResponse содержал карту кодов вместо Response, а схема
  GoalActionResponse лежала в components/responses — перенёс в schemas

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 18:43:47 +06:00
+122 -34
View File
@@ -5686,6 +5686,7 @@ paths:
responses: responses:
200: 200:
description: Список опросов
content: content:
application/json: application/json:
schema: schema:
@@ -6021,7 +6022,16 @@ paths:
- $ref: '#/components/parameters/noDraft' - $ref: '#/components/parameters/noDraft'
- $ref: '#/components/parameters/goalParentId' - $ref: '#/components/parameters/goalParentId'
responses: responses:
$ref: '#/components/responses/GoalActionResponse' 200:
$ref: '#/components/responses/GoalIndexResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/supervise: /goal/supervise:
get: get:
@@ -6041,7 +6051,16 @@ paths:
- $ref: '#/components/parameters/noDraft' - $ref: '#/components/parameters/noDraft'
- $ref: '#/components/parameters/goalParentId' - $ref: '#/components/parameters/goalParentId'
responses: responses:
$ref: '#/components/responses/GoalActionResponse' 200:
$ref: '#/components/responses/GoalIndexResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/archive: /goal/archive:
get: get:
@@ -6060,7 +6079,16 @@ paths:
- $ref: '#/components/parameters/goalParentId' - $ref: '#/components/parameters/goalParentId'
- $ref: '#/components/parameters/goalIntervalTypeId' - $ref: '#/components/parameters/goalIntervalTypeId'
responses: responses:
$ref: '#/components/responses/GoalActionResponse' 200:
$ref: '#/components/responses/GoalIndexResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/view: /goal/view:
get: get:
@@ -6162,7 +6190,16 @@ paths:
items: items:
$ref: '#/components/schemas/GoalItem' $ref: '#/components/schemas/GoalItem'
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/approve: /goal/approve:
post: post:
@@ -6183,7 +6220,16 @@ paths:
items: items:
$ref: '#/components/schemas/GoalItem' $ref: '#/components/schemas/GoalItem'
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/reject: /goal/reject:
post: post:
@@ -6204,7 +6250,16 @@ paths:
items: items:
$ref: '#/components/schemas/GoalItem' $ref: '#/components/schemas/GoalItem'
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/finish: /goal/finish:
post: post:
@@ -6225,7 +6280,16 @@ paths:
items: items:
$ref: '#/components/schemas/GoalItem' $ref: '#/components/schemas/GoalItem'
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/remove: /goal/remove:
post: post:
@@ -6246,7 +6310,16 @@ paths:
type: string type: string
format: uuid format: uuid
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/bind: /goal/bind:
post: post:
@@ -6276,7 +6349,16 @@ paths:
format: uuid format: uuid
description: Цели которые необходимо привязать description: Цели которые необходимо привязать
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal/unbind: /goal/unbind:
post: post:
@@ -6298,7 +6380,16 @@ paths:
type: string type: string
format: uuid format: uuid
responses: responses:
200:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/responses/GoalActionResponse'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
/goal-report/users: /goal-report/users:
post: post:
@@ -6448,7 +6539,7 @@ paths:
content: content:
application/json: application/json:
schema: schema:
$ref: '#/components/responses/GoalActionResponse' $ref: '#/components/schemas/GoalActionResponse'
422: 422:
description: Bad Request description: Bad Request
403: 403:
@@ -13830,6 +13921,28 @@ components:
_meta: _meta:
$ref: '#/components/schemas/_meta' $ref: '#/components/schemas/_meta'
GoalActionResponse:
description: Goal object
type: object
properties:
success:
type: boolean
deleted:
type: array
items:
$ref: '#/components/schemas/GoalItem'
description: Цели которые были удалены
updated:
type: array
items:
$ref: '#/components/schemas/GoalItem'
description: Цели которые были обновлены
skipped:
type: array
items:
$ref: '#/components/schemas/GoalItem'
description: Цели которые не были обработаны
parameters: parameters:
boardDateTypeParam: boardDateTypeParam:
in: query in: query
@@ -13965,7 +14078,6 @@ components:
responses: responses:
GoalIndexResponse: GoalIndexResponse:
200:
description: Список целей description: Список целей
content: content:
application/json: application/json:
@@ -13982,36 +14094,12 @@ components:
$ref: '#/components/schemas/_links' $ref: '#/components/schemas/_links'
_meta: _meta:
$ref: '#/components/schemas/_meta' $ref: '#/components/schemas/_meta'
400:
description: Bad Request.
403:
description: Unauthorized.
404:
description: Not found.
500:
description: Server Error.
GoalActionResponse: GoalActionResponse:
description: Goal object description: Результат действия над целями
type: object content:
properties: application/json:
success: schema:
type: boolean $ref: '#/components/schemas/GoalActionResponse'
deleted:
type: array
items:
$ref: '#/components/schemas/GoalItem'
description: Цели которые были удалены
updated:
type: array
items:
$ref: '#/components/schemas/GoalItem'
description: Цели которые были обновлены
skipped:
type: array
items:
$ref: '#/components/schemas/GoalItem'
description: Цели которые не были обработаны
security: security:
- SessionAuth: [ ] - SessionAuth: [ ]