Documentation ¶
Index ¶
- type APIInterface
- type APIOptions
- type CreateResetPasswordLinkResponse
- type CreateResetPasswordTokenResponse
- type EmailExistsGETResponse
- type GeneratePasswordResetTokenPOSTResponse
- type NormalisedFormField
- type OverrideStruct
- type PasswordPolicyViolatedError
- type RecipeInterface
- type ResetPasswordPOSTResponse
- type ResetPasswordUsingTokenResponse
- type SendResetPasswordEmailResponse
- type SignInPOSTResponse
- type SignInResponse
- type SignUpPOSTResponse
- type SignUpResponse
- type TypeFormField
- type TypeInput
- type TypeInputFormField
- type TypeInputSignUp
- type TypeNormalisedInput
- type TypeNormalisedInputResetPasswordUsingTokenFeature
- type TypeNormalisedInputSignIn
- type TypeNormalisedInputSignUp
- type UpdateEmailOrPasswordResponse
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIInterface ¶
type APIInterface struct { EmailExistsGET *func(email string, tenantId string, options APIOptions, userContext supertokens.UserContext) (EmailExistsGETResponse, error) GeneratePasswordResetTokenPOST *func(formFields []TypeFormField, tenantId string, options APIOptions, userContext supertokens.UserContext) (GeneratePasswordResetTokenPOSTResponse, error) PasswordResetPOST *func(formFields []TypeFormField, token string, tenantId string, options APIOptions, userContext supertokens.UserContext) (ResetPasswordPOSTResponse, error) SignInPOST *func(formFields []TypeFormField, tenantId string, options APIOptions, userContext supertokens.UserContext) (SignInPOSTResponse, error) SignUpPOST *func(formFields []TypeFormField, tenantId string, options APIOptions, userContext supertokens.UserContext) (SignUpPOSTResponse, error) }
type APIOptions ¶
type APIOptions struct { RecipeImplementation RecipeInterface AppInfo supertokens.NormalisedAppinfo Config TypeNormalisedInput RecipeID string Req *http.Request Res http.ResponseWriter OtherHandler http.HandlerFunc EmailDelivery emaildelivery.Ingredient }
type CreateResetPasswordLinkResponse ¶ added in v0.13.0
type CreateResetPasswordLinkResponse struct { OK *struct { Link string } UnknownUserIdError *struct{} }
type CreateResetPasswordTokenResponse ¶
type CreateResetPasswordTokenResponse struct { OK *struct { Token string } UnknownUserIdError *struct{} }
type EmailExistsGETResponse ¶
type EmailExistsGETResponse struct { OK *struct{ Exists bool } GeneralError *supertokens.GeneralErrorResponse }
type GeneratePasswordResetTokenPOSTResponse ¶
type GeneratePasswordResetTokenPOSTResponse struct { OK *struct{} GeneralError *supertokens.GeneralErrorResponse }
type NormalisedFormField ¶
type OverrideStruct ¶
type OverrideStruct struct { Functions func(originalImplementation RecipeInterface) RecipeInterface APIs func(originalImplementation APIInterface) APIInterface }
type PasswordPolicyViolatedError ¶ added in v0.12.0
type PasswordPolicyViolatedError struct {
FailureReason string
}
type RecipeInterface ¶
type RecipeInterface struct { SignUp *func(email string, password string, tenantId string, userContext supertokens.UserContext) (SignUpResponse, error) SignIn *func(email string, password string, tenantId string, userContext supertokens.UserContext) (SignInResponse, error) GetUserByID *func(userID string, userContext supertokens.UserContext) (*User, error) GetUserByEmail *func(email string, tenantId string, userContext supertokens.UserContext) (*User, error) CreateResetPasswordToken *func(userID string, tenantId string, userContext supertokens.UserContext) (CreateResetPasswordTokenResponse, error) ResetPasswordUsingToken *func(token string, newPassword string, tenantId string, userContext supertokens.UserContext) (ResetPasswordUsingTokenResponse, error) UpdateEmailOrPassword *func(userId string, email *string, password *string, applyPasswordPolicy *bool, tenantIdForPasswordPolicy string, userContext supertokens.UserContext) (UpdateEmailOrPasswordResponse, error) }
type ResetPasswordPOSTResponse ¶ added in v0.7.0
type ResetPasswordPOSTResponse struct { OK *struct { UserId *string } ResetPasswordInvalidTokenError *struct{} GeneralError *supertokens.GeneralErrorResponse }
type ResetPasswordUsingTokenResponse ¶
type ResetPasswordUsingTokenResponse struct { OK *struct { UserId *string } ResetPasswordInvalidTokenError *struct{} }
type SendResetPasswordEmailResponse ¶ added in v0.13.0
type SendResetPasswordEmailResponse struct { OK *struct{} UnknownUserIdError *struct{} }
type SignInPOSTResponse ¶ added in v0.5.0
type SignInPOSTResponse struct { OK *struct { User User Session sessmodels.SessionContainer } WrongCredentialsError *struct{} GeneralError *supertokens.GeneralErrorResponse }
type SignInResponse ¶
type SignInResponse struct { OK *struct { User User } WrongCredentialsError *struct{} }
type SignUpPOSTResponse ¶ added in v0.5.0
type SignUpPOSTResponse struct { OK *struct { User User Session sessmodels.SessionContainer } EmailAlreadyExistsError *struct{} GeneralError *supertokens.GeneralErrorResponse }
type SignUpResponse ¶
type SignUpResponse struct { OK *struct { User User } EmailAlreadyExistsError *struct{} }
type TypeFormField ¶
type TypeInput ¶
type TypeInput struct { SignUpFeature *TypeInputSignUp Override *OverrideStruct EmailDelivery *emaildelivery.TypeInput }
type TypeInputFormField ¶
type TypeInputSignUp ¶
type TypeInputSignUp struct {
FormFields []TypeInputFormField
}
type TypeNormalisedInput ¶
type TypeNormalisedInput struct { SignUpFeature TypeNormalisedInputSignUp SignInFeature TypeNormalisedInputSignIn ResetPasswordUsingTokenFeature TypeNormalisedInputResetPasswordUsingTokenFeature Override OverrideStruct GetEmailDeliveryConfig func(recipeImpl RecipeInterface) emaildelivery.TypeInputWithService }
type TypeNormalisedInputResetPasswordUsingTokenFeature ¶
type TypeNormalisedInputResetPasswordUsingTokenFeature struct { FormFieldsForGenerateTokenForm []NormalisedFormField FormFieldsForPasswordResetForm []NormalisedFormField }
type TypeNormalisedInputSignIn ¶
type TypeNormalisedInputSignIn struct {
FormFields []NormalisedFormField
}
type TypeNormalisedInputSignUp ¶
type TypeNormalisedInputSignUp struct {
FormFields []NormalisedFormField
}
type UpdateEmailOrPasswordResponse ¶
type UpdateEmailOrPasswordResponse struct { OK *struct{} UnknownUserIdError *struct{} EmailAlreadyExistsError *struct{} PasswordPolicyViolatedError *PasswordPolicyViolatedError }
Click to show internal directories.
Click to hide internal directories.