woodpecker/common/token.go

17 lines
348 B
Go
Raw Normal View History

package common
2015-04-13 05:32:32 +00:00
const (
TokenUser = "u"
TokenSess = "s"
)
type Token struct {
Kind string `json:"kind"`
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"`
}