Documentation
¶
Index ¶
- Variables
- func AddSocialAccountEndpoint(svc Service) endpoint.Endpoint
- func EventEndpoint(svc Service) endpoint.Endpoint
- func OTPVerifyEndpoint(svc Service) endpoint.Endpoint
- func RegisterEndpoint(svc Service) endpoint.Endpoint
- func RegisterPasskeyEndpoint(svc Service) endpoint.Endpoint
- func SignInEndpoint(svc Service) endpoint.Endpoint
- func UserEndpoint(svc Service) endpoint.Endpoint
- type AddSocialAccountRequest
- type EndpointSet
- type EventHandler
- type OTPVerifyRequest
- type RegisterRequest
- type Service
- type ServiceMiddleware
- type SignInRequest
- type SignInResponse
- type Token
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func EventEndpoint ¶
func OTPVerifyEndpoint ¶
func RegisterEndpoint ¶
func RegisterPasskeyEndpoint ¶
func SignInEndpoint ¶
func UserEndpoint ¶ added in v1.0.1
Types ¶
type AddSocialAccountRequest ¶
type AddSocialAccountRequest struct { Credential string Provider user.SocialProvider Username string }
type EndpointSet ¶
type EventHandler ¶
type EventHandler interface { UserRegisteredHandler(e *user.UserRegisteredEvent) error UserActivatedHandler(e *user.UserActivatedEvent) error UserSocialAccountAddedHandler(e *user.UserSocialAccountAddedEvent) error }
type OTPVerifyRequest ¶
type RegisterRequest ¶
type Service ¶
type Service interface { Register(username string, name string, email string) (*user.User, error) OTPVerify(otp string, username string) (*user.User, error) SignIn(credential string, provider user.SocialProvider) (*user.User, error) AddSocialAccount(credential string, provider user.SocialProvider, username string) (*user.User, error) RegisterPasskey(username string) (*protocol.CredentialCreation, error) User(username string) (*user.User, error) Handler() (EventHandler, error) }
func NewService ¶
type ServiceMiddleware ¶
func LoggingMiddleware ¶
func LoggingMiddleware(log *zap.Logger) ServiceMiddleware
type SignInRequest ¶
type SignInRequest struct { Credential string Provider user.SocialProvider }
type SignInResponse ¶
Click to show internal directories.
Click to hide internal directories.