auth/token.go

15 lines
223 B
Go
Raw Permalink Normal View History

2023-10-21 08:26:15 +00:00
package auth
import "github.com/golang-jwt/jwt/v5"
const (
RoleUnauthorized = ""
RoleUser = "user"
RoleAdmin = "admin"
2023-10-21 08:26:15 +00:00
)
type MicrofilmClaims struct {
Role string `json:"role"`
jwt.RegisteredClaims
}