base

package
v0.0.0-...-f828163 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2024 License: AGPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Auth

func Auth(params Params)

func FindOrCreateUser

func FindOrCreateUser(ctx context.Context, db *gorm.DB, user soth.User) (*models.User, error)

Types

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

func (*Handler) Login

func (h *Handler) Login(c *fiber.Ctx) error

func (*Handler) Provider

func (h *Handler) Provider(c *fiber.Ctx) error

func (*Handler) ProviderCallback

func (h *Handler) ProviderCallback(c *fiber.Ctx) error

func (*Handler) ProviderLogout

func (h *Handler) ProviderLogout(c *fiber.Ctx) error

type Params

type Params struct {
	// contains filtered or unexported fields
}

func NewParams

func NewParams(webAuthProvider soth.Provider, mobileAuthProvider soth.Provider, applicationURL string, router fiber.Router, db *gorm.DB, emailer email.Emailer, validate *validator.Validate, providers ...soth.Provider) Params

type Service

type Service interface {
	Login(c *fiber.Ctx) error
	Provider(c *fiber.Ctx) error
	ProviderCallback(c *fiber.Ctx) error
	ProviderLogout(c *fiber.Ctx) error
}

Jump to

Keyboard shortcuts

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