diff options
author | techknowlogick <techknowlogick@gitea.io> | 2019-05-04 11:45:34 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-05-04 11:45:34 -0400 |
commit | 46373e765702a203bfcb576c9d3639314ef4965f (patch) | |
tree | a44ba4de8593a9ad7898683e0e6df80e0072ef17 /vendor/code.gitea.io/sdk/gitea/user_app.go | |
parent | 1fa96629461ac4229932b0a4526fc2f60c88ec51 (diff) | |
download | gitea-46373e765702a203bfcb576c9d3639314ef4965f.tar.gz gitea-46373e765702a203bfcb576c9d3639314ef4965f.zip |
Hash App token (#6724)
Diffstat (limited to 'vendor/code.gitea.io/sdk/gitea/user_app.go')
-rw-r--r-- | vendor/code.gitea.io/sdk/gitea/user_app.go | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/vendor/code.gitea.io/sdk/gitea/user_app.go b/vendor/code.gitea.io/sdk/gitea/user_app.go index d3bfce971b..023837f83b 100644 --- a/vendor/code.gitea.io/sdk/gitea/user_app.go +++ b/vendor/code.gitea.io/sdk/gitea/user_app.go @@ -1,4 +1,5 @@ // Copyright 2014 The Gogs Authors. All rights reserved. +// Copyright 2019 The Gitea Authors. All rights reserved. // Use of this source code is governed by a MIT-style // license that can be found in the LICENSE file. @@ -17,12 +18,14 @@ func BasicAuthEncode(user, pass string) string { return base64.StdEncoding.EncodeToString([]byte(user + ":" + pass)) } -// AccessToken represents a API access token. +// AccessToken represents an API access token. // swagger:response AccessToken type AccessToken struct { - ID int64 `json:"id"` - Name string `json:"name"` - Sha1 string `json:"sha1"` + ID int64 `json:"id"` + Name string `json:"name"` + Token string `json:"token"` + HashedToken string `json:"hashed_token"` + TokenLastEight string `json:"token_last_eight"` } // AccessTokenList represents a list of API access token. |