Kyoo/auth/dbc/models.go
2025-04-23 19:41:42 +02:00

56 lines
1.5 KiB
Go

// Code generated by sqlc. DO NOT EDIT.
// versions:
// sqlc v1.28.0
package dbc
import (
"time"
jwt "github.com/golang-jwt/jwt/v5"
"github.com/google/uuid"
)
type Apikey struct {
Pk int32 `json:"pk"`
Id uuid.UUID `json:"id"`
Name string `json:"name"`
Token string `json:"token"`
Claims jwt.MapClaims `json:"claims"`
CreatedBy int32 `json:"createdBy"`
CreatedAt time.Time `json:"createdAt"`
LastUsed time.Time `json:"lastUsed"`
}
type OidcHandle struct {
UserPk int32 `json:"userPk"`
Provider string `json:"provider"`
Id string `json:"id"`
Username string `json:"username"`
ProfileUrl *string `json:"profileUrl"`
AccessToken *string `json:"accessToken"`
RefreshToken *string `json:"refreshToken"`
ExpireAt *time.Time `json:"expireAt"`
}
type Session struct {
Pk int32 `json:"pk"`
Id uuid.UUID `json:"id"`
Token string `json:"token"`
UserPk int32 `json:"userPk"`
CreatedDate time.Time `json:"createdDate"`
LastUsed time.Time `json:"lastUsed"`
Device *string `json:"device"`
}
type User struct {
Pk int32 `json:"pk"`
Id uuid.UUID `json:"id"`
Username string `json:"username"`
Email string `json:"email"`
Password *string `json:"password"`
Claims jwt.MapClaims `json:"claims"`
CreatedDate time.Time `json:"createdDate"`
LastSeen time.Time `json:"lastSeen"`
}