tables

package
v0.0.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 1, 2022 License: BSD-2-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApplicationTable

type ApplicationTable struct {
	ID              int          `db:"id,omitempty"    fiql:"id,db:id"`
	ClientID        string       `db:"client_id"       fiql:"client_id,db:client_id"`
	ClientSecret    *string      `db:"client_secret"                                             json:"-"`
	Name            string       `db:"name"            fiql:"name,db:name"`
	ApplicationType int          `db:"type"            fiql:"type,db:type"`
	Confidentiality string       `db:"confidentiality" fiql:"confidentiality,db:confidentiality"`
	Properties      MapStructure `db:"properties"`
	RetiredOn       *time.Time   `db:"retired_on"      fiql:"retired_on,db:retired_on"`
	CreatedAt       time.Time    `db:"created_at"      fiql:"created_at,db:created_at"`
	UpdatedAt       *time.Time   `db:"updated_at"      fiql:"updated_at,db:updated_at"`
}

ApplicationTable represents the applications table

type AuditLogTable

type AuditLogTable struct {
	ID        int       `db:"id"`
	EventType string    `db:"event_type"`
	Event     string    `db:"event"`
	CreatedAt time.Time `db:"created_at"`
}

AuditLogTable represents the audit_log table

type AuthorizationTable

type AuthorizationTable struct {
	ID            uuid.UUID    `db:"id,omitempty"`
	ApplicationID int          `db:"application_id"`
	UserID        uuid.UUID    `db:"user_id"`
	Properties    MapStructure `db:"properties"`
	RevokedAt     *time.Time   `db:"revoked_at"`
	CreatedAt     time.Time    `db:"created_at"`
	UpdatedAt     *time.Time   `db:"updated_at"`
}

AuthorizationTable represents the authorizations table

type MapStructure

type MapStructure map[string]interface{}

MapStructure is a map-like structure that may be stored in a persistent store

func (MapStructure) Scan

func (m MapStructure) Scan(src interface{}) error

Scan allows to scan a map structure

func (MapStructure) Value

func (m MapStructure) Value() (driver.Value, error)

Value returns the map structures value

type RoleTable

type RoleTable struct {
	ID        int       `db:"id,omitempty" fiql:"id,db:id"`
	Name      string    `db:"name"         fiql:"name,db:name"`
	CreatedAt time.Time `db:"created_at"   fiql:"created_at,db:created_at"`
}

RoleTable represents the roles table

type TokenTable

type TokenTable struct {
	ID              int          `db:"id,omitempty"`
	ApplicationID   int          `db:"application_id"`
	AuthorizationID uuid.UUID    `db:"authorization_id"`
	UserID          uuid.UUID    `db:"user_id"`
	TokenType       string       `db:"token_type"`
	Token           string       `db:"token"`
	Properties      MapStructure `db:"properties"`
	RedeemedAt      *time.Time   `db:"redeemed_at"`
	RevokedAt       *time.Time   `db:"revoked_at"`
	ExpiresAt       time.Time    `db:"expires_at"`
	CreatedAt       time.Time    `db:"created_at"`
	UpdatedAt       *time.Time   `db:"updated_at"`
}

TokenTable represents the tokens table

type UserInviteApplicationsTable

type UserInviteApplicationsTable struct {
	ApplicationID int    `db:"application_id"`
	UserInviteID  int    `db:"user_invite_id"`
	Scopes        string `db:"scopes"`
}

UserInviteApplicationsTable represents the table

type UserInviteRolesTable

type UserInviteRolesTable struct {
	RoleID       int `db:"role_id"`
	UserInviteID int `db:"user_invite_id"`
}

UserInviteRolesTable represents the table

type UserInviteTable

type UserInviteTable struct {
	ID         int        `db:"id"          fiql:"id,db:id"`
	Email      *string    `db:"email"                                         email:"type,db:email"`
	Code       string     `db:"code"        fiql:"code,db:code"`
	SentAt     *time.Time `db:"sent_at"     fiql:"sent_at,db:sent_at"`
	ConsumedAt *time.Time `db:"consumed_at" fiql:"consumed_at,db:consumed_at"`
	ExpiresAt  time.Time  `db:"expires_at"  fiql:"expires_at,db:expires_at"`
	CreatedAt  time.Time  `db:"created_at"  fiql:"created_at,db:created_at"`
}

UserInviteTable represents the table

type UserRoleTable

type UserRoleTable struct {
	RoleID int       `db:"role_id"`
	UserID uuid.UUID `db:"user_id"`
}

UserRoleTable represents the table

type UserTable

type UserTable struct {
	ID                   uuid.UUID  `db:"id,omitempty"                     fiql:"id,db:id"`
	Email                string     `db:"email"                            fiql:"email,db:email"`
	EmailConfirmed       *time.Time `db:"email_confirmed"`
	Phone                *string    `db:"phone"                            fiql:"phone,db:phone"`
	PhoneConfirmed       *time.Time `db:"phone_confirmed"`
	Mfa                  bool       `db:"mfa"`
	MfaSecret            *string    `db:"mfa_secret"                                                                             json:"-"`
	MfaRecoveryKey       *string    `db:"mfa_recovery_key"                                                                       json:"-"`
	PendingOTP           bool       `db:"pending_otp"`
	LockoutTill          *time.Time `db:"lockout_till"                     fiql:"lockout_till,db:lockout_till"`
	BannedOn             *time.Time `db:"banned_on"                        fiql:"banned_on,db:banned_on"`
	Password             string     `db:"password"                                                                               json:"-"`
	CurrentFailureCount  int        `db:"current_failure_count"`
	RecoveryToken        *string    `db:"recovery_token"                                                                         json:"-"`
	RecoveryTokenCreated *time.Time `db:"recovery_token_created,omitempty"`
	ConfirmToken         *string    `db:"confirm_token"                    fiql:"confirm_token,db:confirm_token"`
	ConfirmTokenCreated  *time.Time `db:"confirm_token_created,omitempty"  fiql:"confirm_token_created,db:confirm_token_created"`
	CreatedAt            time.Time  `db:"created_at"                       fiql:"created_at,db:created_at"`
	UpdatedAt            *time.Time `db:"updated_at,omitempty"             fiql:"updated_at,db:updated_at"`
}

UserTable represents the users table

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL