mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-25 11:22:16 +00:00
Fix Swagger JSON autogeneration issues. (#4845)
* Fix Swagger JSON. Remove unnecessary schema references for the forbidden and empty responses Signed-off-by: Andrew Thornton <art27@cantab.net> * Fix swagger API for CreateAccessToken * Fix admin create org swagger * Fix swagger for adminCreateRepo * More swagger fixes Set int64 format for those which are int64 Some more form fixes * Fix swagger description of GET /repos/{owner}/{repo}/pulls
This commit is contained in:
parent
9b2fcadeef
commit
43f9233914
23 changed files with 298 additions and 66 deletions
|
@ -38,11 +38,13 @@ func GetReleaseAttachment(ctx *context.APIContext) {
|
|||
// in: path
|
||||
// description: id of the release
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// - name: attachment_id
|
||||
// in: path
|
||||
// description: id of the attachment to get
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// responses:
|
||||
// "200":
|
||||
|
@ -84,6 +86,7 @@ func ListReleaseAttachments(ctx *context.APIContext) {
|
|||
// in: path
|
||||
// description: id of the release
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// responses:
|
||||
// "200":
|
||||
|
@ -129,6 +132,7 @@ func CreateReleaseAttachment(ctx *context.APIContext) {
|
|||
// in: path
|
||||
// description: id of the release
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// - name: name
|
||||
// in: query
|
||||
|
@ -233,11 +237,13 @@ func EditReleaseAttachment(ctx *context.APIContext, form api.EditAttachmentOptio
|
|||
// in: path
|
||||
// description: id of the release
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// - name: attachment_id
|
||||
// in: path
|
||||
// description: id of the attachment to edit
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// - name: body
|
||||
// in: body
|
||||
|
@ -292,11 +298,13 @@ func DeleteReleaseAttachment(ctx *context.APIContext) {
|
|||
// in: path
|
||||
// description: id of the release
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// - name: attachment_id
|
||||
// in: path
|
||||
// description: id of the attachment to delete
|
||||
// type: integer
|
||||
// format: int64
|
||||
// required: true
|
||||
// responses:
|
||||
// "204":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue