harness-drone/common/token.go

17 lines
345 B
Go
Raw Normal View History

package common
2015-04-13 05:32:32 +00:00
const (
TokenUser = "u"
TokenSess = "s"
)
type Token struct {
2015-04-13 05:32:32 +00:00
Kind string `json:"-"`
Login string `json:"-"`
2015-04-13 05:32:32 +00:00
Label string `json:"label"`
Repos []string `json:"repos,omitempty"`
Scopes []string `json:"scopes,omitempty"`
Expiry int64 `json:"expiry,omitempty"`
2015-04-13 05:32:32 +00:00
Issued int64 `json:"issued_at,omitempty"`
}