1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-12 05:27:20 +00:00

Update token creation API swagger documentation (#34288) (#34296)

Backport #34288 by @lunny

Fix #34231

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
This commit is contained in:
Giteabot
2025-04-28 10:34:46 +08:00
committed by GitHub
parent 4e5aca62ee
commit 4f6d09fb68
2 changed files with 15 additions and 2 deletions

View File

@ -23,9 +23,11 @@ type AccessToken struct {
type AccessTokenList []*AccessToken
// CreateAccessTokenOption options when create access token
// swagger:model CreateAccessTokenOption
type CreateAccessTokenOption struct {
// required: true
Name string `json:"name" binding:"Required"`
Name string `json:"name" binding:"Required"`
// example: ["all", "read:activitypub","read:issue", "write:misc", "read:notification", "read:organization", "read:package", "read:repository", "read:user"]
Scopes []string `json:"scopes"`
}