summaryrefslogtreecommitdiffstats
path: root/templates/swagger
diff options
context:
space:
mode:
author6543 <6543@obermui.de>2021-06-17 18:04:10 +0200
committerGitHub <noreply@github.com>2021-06-17 18:04:10 +0200
commitf7cd394680f885061144d236abc3c25f30be3147 (patch)
treeb0cceab982c18db7fb48489729dc44fdff8101af /templates/swagger
parent19dedc3fa521fdb6456bad2b080bb1aaa6722b24 (diff)
downloadgitea-f7cd394680f885061144d236abc3c25f30be3147.tar.gz
gitea-f7cd394680f885061144d236abc3c25f30be3147.zip
[API] Add repoCreateTag (#16165)
* Add API CreateTag * Add Test * API: expose Tag Message
Diffstat (limited to 'templates/swagger')
-rw-r--r--templates/swagger/v1_json.tmpl72
1 files changed, 71 insertions, 1 deletions
diff --git a/templates/swagger/v1_json.tmpl b/templates/swagger/v1_json.tmpl
index 9b0d07ebfc..017dc824d7 100644
--- a/templates/swagger/v1_json.tmpl
+++ b/templates/swagger/v1_json.tmpl
@@ -9082,6 +9082,50 @@
"$ref": "#/responses/TagList"
}
}
+ },
+ "post": {
+ "produces": [
+ "application/json"
+ ],
+ "tags": [
+ "repository"
+ ],
+ "summary": "Create a new git tag in a repository",
+ "operationId": "repoCreateTag",
+ "parameters": [
+ {
+ "type": "string",
+ "description": "owner of the repo",
+ "name": "owner",
+ "in": "path",
+ "required": true
+ },
+ {
+ "type": "string",
+ "description": "name of the repo",
+ "name": "repo",
+ "in": "path",
+ "required": true
+ },
+ {
+ "name": "body",
+ "in": "body",
+ "schema": {
+ "$ref": "#/definitions/CreateTagOption"
+ }
+ }
+ ],
+ "responses": {
+ "200": {
+ "$ref": "#/responses/AnnotatedTag"
+ },
+ "404": {
+ "$ref": "#/responses/notFound"
+ },
+ "409": {
+ "$ref": "#/responses/conflict"
+ }
+ }
}
},
"/repos/{owner}/{repo}/tags/{tag}": {
@@ -13092,6 +13136,28 @@
},
"x-go-package": "code.gitea.io/gitea/modules/structs"
},
+ "CreateTagOption": {
+ "description": "CreateTagOption options when creating a tag",
+ "type": "object",
+ "required": [
+ "tag_name"
+ ],
+ "properties": {
+ "message": {
+ "type": "string",
+ "x-go-name": "Message"
+ },
+ "tag_name": {
+ "type": "string",
+ "x-go-name": "TagName"
+ },
+ "target": {
+ "type": "string",
+ "x-go-name": "Target"
+ }
+ },
+ "x-go-package": "code.gitea.io/gitea/modules/structs"
+ },
"CreateTeamOption": {
"description": "CreateTeamOption options for creating a team",
"type": "object",
@@ -16149,6 +16215,10 @@
"type": "string",
"x-go-name": "ID"
},
+ "message": {
+ "type": "string",
+ "x-go-name": "Message"
+ },
"name": {
"type": "string",
"x-go-name": "Name"
@@ -17265,7 +17335,7 @@
"parameterBodies": {
"description": "parameterBodies",
"schema": {
- "$ref": "#/definitions/PullReviewRequestOptions"
+ "$ref": "#/definitions/CreateTagOption"
}
},
"redirect": {