Documentation
¶
Index ¶
- type Auth
- func (a *Auth) CreateUser(cfg config.Config, user *models.User) (primitive.ObjectID, error)
- func (a *Auth) GetEmail(email string) string
- func (a *Auth) GetTokenPair(cfg config.Config, email, password string) (*models.TokenPair, error)
- func (a *Auth) GetUserByEmail(email, password string) (*models.User, error)
- func (a *Auth) Refresh(userID primitive.ObjectID, cfg config.Config) (*models.TokenPair, error)
- type AuthInterface
- type Services
- type StorageInteface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Auth ¶
type Auth struct {
DB AuthInterface
}
func (*Auth) CreateUser ¶
func (*Auth) GetTokenPair ¶
func (*Auth) GetUserByEmail ¶
type AuthInterface ¶
type Services ¶
type Services struct {
Auth
}
func NewService ¶
func NewService(storage StorageInteface) Services
type StorageInteface ¶
type StorageInteface interface { AuthInterface }
Click to show internal directories.
Click to hide internal directories.