Skip to main content
References

Passwordless Types

Type Aliases

AdditionalLoginAttemptInfoProperties

type AdditionalLoginAttemptInfoProperties = object;

Defined in: recipe/passwordless/types.ts:231

When calling getLoginAttemptInfo/setLoginAttemptInfo from web-js we use generics to get access to properties in local storage that web-js does not set by default. This allows us to strongly type the response while keeping it dynamic.

In the context of auth-react this type indicates all the additional properties we need.

Properties

PropertyTypeDefined in
contactInfostringrecipe/passwordless/types.ts:232
contactMethod"EMAIL" | "PHONE"recipe/passwordless/types.ts:233
lastResendnumberrecipe/passwordless/types.ts:234
redirectToPath?stringrecipe/passwordless/types.ts:235

ComponentOverrideMap

type ComponentOverrideMap = object;

Defined in: recipe/passwordless/types.ts:445

Properties

PropertyTypeDefined in
PasswordlessContinueWithPasswordless_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:459
PasswordlessEmailForm_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:446
PasswordlessEmailOrPhoneForm_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:448
PasswordlessEPComboEmailForm_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:449
PasswordlessEPComboEmailOrPhoneForm_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:450
PasswordlessLinkClickedScreen_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:458
PasswordlessLinkSent_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:456
PasswordlessMFAFooter_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:462
PasswordlessMFAHeader_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:461
PasswordlessMFAOTPFooter_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:464
PasswordlessMFAOTPHeader_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:463
PasswordlessMFAOTPLoadingScreen_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:465
PasswordlessPhoneForm_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:447
PasswordlessUserInputCodeForm_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:454
PasswordlessUserInputCodeFormFooter_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:453
PasswordlessUserInputCodeFormHeader_Override?ComponentOverride<typeof SuperTokensWrapper>recipe/passwordless/types.ts:452

Config

type Config = UserInput & AuthRecipeModuleConfig<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>;

Defined in: recipe/passwordless/types.ts:125

GetRedirectionURLContext

type GetRedirectionURLContext = never;

Defined in: recipe/passwordless/types.ts:78

LinkClickedScreenProps

type LinkClickedScreenProps = object;

Defined in: recipe/passwordless/types.ts:283

Properties

LinkSentChildProps

type LinkSentChildProps = LinkSentThemeProps;

Defined in: recipe/passwordless/types.ts:389

LinkSentThemeProps

type LinkSentThemeProps = object;

Defined in: recipe/passwordless/types.ts:392

Properties

LoginAttemptInfo

type LoginAttemptInfo = object;

Defined in: recipe/passwordless/types.ts:214

Properties

PropertyTypeDefined in
contactInfostringrecipe/passwordless/types.ts:217
contactMethod"EMAIL" | "PHONE"recipe/passwordless/types.ts:218
deviceIdstringrecipe/passwordless/types.ts:215
flowType"USER_INPUT_CODE" | "MAGIC_LINK" | "USER_INPUT_CODE_AND_MAGIC_LINK"recipe/passwordless/types.ts:221
lastResendnumberrecipe/passwordless/types.ts:219
preAuthSessionIdstringrecipe/passwordless/types.ts:216
redirectToPath?stringrecipe/passwordless/types.ts:220

MFAAction

type MFAAction = 
| {
callingCreateCode: boolean;
canChangeEmail: boolean;
error: string | undefined;
loginAttemptInfo: LoginAttemptInfo | undefined;
showAccessDenied: boolean;
showBackButton: boolean;
type: "load";
}
| {
loginAttemptInfo: LoginAttemptInfo;
type: "startVerify";
}
| {
timestamp: number;
type: "resendCode";
}
| {
error: string | undefined;
type: "restartFlow";
}
| {
error: string | undefined;
showAccessDenied: boolean;
type: "setError";
};

Defined in: recipe/passwordless/types.ts:335

MFAChildProps

type MFAChildProps = Omit<MFAProps, "featureState" | "dispatch">;

Defined in: recipe/passwordless/types.ts:390

MFAFooterProps

type MFAFooterProps = object;

Defined in: recipe/passwordless/types.ts:413

Properties

MFAHeaderProps

type MFAHeaderProps = object;

Defined in: recipe/passwordless/types.ts:428

Properties

PropertyTypeDefined in
configNormalisedConfigrecipe/passwordless/types.ts:433
contactMethod"EMAIL" | "PHONE"recipe/passwordless/types.ts:429
onBackButtonClicked() => voidrecipe/passwordless/types.ts:431
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:432
showBackButtonbooleanrecipe/passwordless/types.ts:430

MFAOTPFooterProps

type MFAOTPFooterProps = object;

Defined in: recipe/passwordless/types.ts:420

Properties

MFAOTPHeaderProps

type MFAOTPHeaderProps = object;

Defined in: recipe/passwordless/types.ts:436

Properties

MFAProps

type MFAProps = object;

Defined in: recipe/passwordless/types.ts:182

Properties

PropertyTypeDefined in
configNormalisedConfigrecipe/passwordless/types.ts:184
contactMethod"EMAIL" | "PHONE"recipe/passwordless/types.ts:185
dispatchDispatch<MFAAction>recipe/passwordless/types.ts:190
featureStateobjectrecipe/passwordless/types.ts:191
featureState.canChangeEmailbooleanrecipe/passwordless/types.ts:192
featureState.errorstring | undefinedrecipe/passwordless/types.ts:197
featureState.loadedbooleanrecipe/passwordless/types.ts:194
featureState.loginAttemptInfo?LoginAttemptInforecipe/passwordless/types.ts:193
featureState.showAccessDeniedbooleanrecipe/passwordless/types.ts:196
featureState.showBackButtonbooleanrecipe/passwordless/types.ts:195
onBackButtonClicked() => voidrecipe/passwordless/types.ts:186
onFetchError(err) => voidrecipe/passwordless/types.ts:189
onSignOutClicked() => voidrecipe/passwordless/types.ts:187
onSuccess?() => voidrecipe/passwordless/types.ts:188
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:183
userContext?UserContextrecipe/passwordless/types.ts:200
validatePhoneNumber(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:199

MFAState

type MFAState = object;

Defined in: recipe/passwordless/types.ts:363

Properties

PropertyTypeDefined in
canChangeEmailbooleanrecipe/passwordless/types.ts:369
errorstring | undefinedrecipe/passwordless/types.ts:365
loadedbooleanrecipe/passwordless/types.ts:366
loginAttemptInfoLoginAttemptInfo | undefinedrecipe/passwordless/types.ts:368
showAccessDeniedbooleanrecipe/passwordless/types.ts:364
showBackButtonbooleanrecipe/passwordless/types.ts:367

NormalisedConfig

type NormalisedConfig = object & NormalisedAuthRecipeModuleConfig<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>;

Defined in: recipe/passwordless/types.ts:100

Type Declaration

NameTypeDefined in
contactMethod"PHONE" | "EMAIL" | "EMAIL_OR_PHONE"recipe/passwordless/types.ts:118
linkClickedScreenFeaturePasswordlessNormalisedBaseConfigrecipe/passwordless/types.ts:115
mfaFeaturePasswordlessNormalisedBaseConfigrecipe/passwordless/types.ts:116
overrideobjectrecipe/passwordless/types.ts:120
override.functions()(originalImplementation) => SuperTokensWrapperrecipe/passwordless/types.ts:121
signInUpFeatureobjectrecipe/passwordless/types.ts:106
signInUpFeature.defaultCountry?stringrecipe/passwordless/types.ts:108
signInUpFeature.defaultToEmailbooleanrecipe/passwordless/types.ts:110
signInUpFeature.emailOrPhoneFormStylestringrecipe/passwordless/types.ts:111
signInUpFeature.linkSentScreenStylestringrecipe/passwordless/types.ts:113
signInUpFeature.resendEmailOrSMSGapInSecondsnumberrecipe/passwordless/types.ts:107
signInUpFeature.userInputCodeFormStylestringrecipe/passwordless/types.ts:112
validateEmailAddress()(email) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:101
validatePhoneNumber()?(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:104

OnHandleEventContext

type OnHandleEventContext = 
| {
action: "SUCCESS";
createdNewSession: boolean;
isNewRecipeUser: boolean;
user: SuperTokensWrapper;
}
| {
action: "PASSWORDLESS_RESTART_FLOW";
}
| {
action: "PASSWORDLESS_CODE_SENT";
isResend: boolean;
}
| AuthRecipeModuleOnHandleEventContext;

Defined in: recipe/passwordless/types.ts:80

PasswordlessFeatureBaseConfig

type PasswordlessFeatureBaseConfig = object & FeatureBaseConfig;

Defined in: recipe/passwordless/types.ts:128

Type Declaration

NameTypeDefined in
disableDefaultUI?booleanrecipe/passwordless/types.ts:129

PasswordlessNormalisedBaseConfig

type PasswordlessNormalisedBaseConfig = object & NormalisedBaseConfig;

Defined in: recipe/passwordless/types.ts:96

Type Declaration

NameTypeDefined in
disableDefaultUI?booleanrecipe/passwordless/types.ts:97

PreAndPostAPIHookAction

type PreAndPostAPIHookAction = 
| "PASSWORDLESS_CREATE_CODE"
| "PASSWORDLESS_CONSUME_CODE"
| "PASSWORDLESS_RESEND_CODE"
| "EMAIL_EXISTS"
| "PHONE_NUMBER_EXISTS";

Defined in: recipe/passwordless/types.ts:53

PreAPIHookContext

type PreAPIHookContext = object;

Defined in: recipe/passwordless/types.ts:60

Properties

RecipeImplementation

type RecipeImplementation = WebJSRecipeInterface<typeof SuperTokensWrapper>;

Defined in: recipe/passwordless/types.ts:238

SignInUpChildProps

type SignInUpChildProps = SignInUpProps;

Defined in: recipe/passwordless/types.ts:372

SignInUpEmailFormProps

type SignInUpEmailFormProps = object;

Defined in: recipe/passwordless/types.ts:240

Properties

SignInUpEmailOrPhoneFormProps

type SignInUpEmailOrPhoneFormProps = object;

Defined in: recipe/passwordless/types.ts:261

Properties

PropertyTypeDefined in
clearError() => voidrecipe/passwordless/types.ts:262
configNormalisedConfigrecipe/passwordless/types.ts:267
errorstring | undefinedrecipe/passwordless/types.ts:265
onError(error) => voidrecipe/passwordless/types.ts:263
onFetchError(error) => voidrecipe/passwordless/types.ts:264
onSuccess?() => voidrecipe/passwordless/types.ts:268
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:266
validatePhoneNumber(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:269

SignInUpEPComboChildProps

type SignInUpEPComboChildProps = Omit<SignInUpProps, "onSuccess"> & object;

Defined in: recipe/passwordless/types.ts:373

Type Declaration

NameTypeDefined in
isPhoneNumberbooleanrecipe/passwordless/types.ts:374
navigateNavigate | undefinedrecipe/passwordless/types.ts:387
onContactInfoSubmit()(contactInfo) => Promise<FormBaseAPIResponse<unknown>>recipe/passwordless/types.ts:378
onContinueWithPasswordlessClick()(contactInfo) => Promise<void>recipe/passwordless/types.ts:380
onPasswordSubmit()(formFields) => Promise<FormBaseAPIResponse<unknown>>recipe/passwordless/types.ts:379
onSuccess()(result) => voidrecipe/passwordless/types.ts:381
setIsPhoneNumber()(isPhone) => voidrecipe/passwordless/types.ts:375
showContinueWithPasswordlessLinkbooleanrecipe/passwordless/types.ts:377
showPasswordFieldbooleanrecipe/passwordless/types.ts:376
validatePhoneNumber()(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:386

SignInUpEPComboEmailFormProps

type SignInUpEPComboEmailFormProps = object;

Defined in: recipe/passwordless/types.ts:314

Properties

PropertyTypeDefined in
clearError() => voidrecipe/passwordless/types.ts:317
configNormalisedConfigrecipe/passwordless/types.ts:331
errorstring | undefinedrecipe/passwordless/types.ts:328
navigateNavigate | undefinedrecipe/passwordless/types.ts:332
onContactInfoSubmit(contactInfo) => Promise<FormBaseAPIResponse<unknown>>recipe/passwordless/types.ts:318
onContinueWithPasswordlessClick(contactInfo) => Promise<void>recipe/passwordless/types.ts:320
onError(error) => voidrecipe/passwordless/types.ts:326
onFetchError(error) => voidrecipe/passwordless/types.ts:327
onPasswordSubmit(formFields) => Promise<FormBaseAPIResponse<unknown>>recipe/passwordless/types.ts:319
onSuccess(result) => voidrecipe/passwordless/types.ts:321
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:329
showContinueWithPasswordlessLinkbooleanrecipe/passwordless/types.ts:316
showPasswordFieldbooleanrecipe/passwordless/types.ts:315
validatePhoneNumber(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:330

SignInUpEPComboEmailOrPhoneFormProps

type SignInUpEPComboEmailOrPhoneFormProps = object;

Defined in: recipe/passwordless/types.ts:291

Properties

PropertyTypeDefined in
clearError() => voidrecipe/passwordless/types.ts:294
configNormalisedConfigrecipe/passwordless/types.ts:309
errorstring | undefinedrecipe/passwordless/types.ts:307
isPhoneNumberbooleanrecipe/passwordless/types.ts:295
navigateNavigate | undefinedrecipe/passwordless/types.ts:311
onContactInfoSubmit(contactInfo) => Promise<FormBaseAPIResponse<unknown>>recipe/passwordless/types.ts:297
onContinueWithPasswordlessClick(contactInfo) => Promise<void>recipe/passwordless/types.ts:299
onError(error) => voidrecipe/passwordless/types.ts:305
onFetchError(error) => voidrecipe/passwordless/types.ts:306
onPasswordSubmit(formFields) => Promise<FormBaseAPIResponse<unknown>>recipe/passwordless/types.ts:298
onSuccess(result) => voidrecipe/passwordless/types.ts:300
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:308
setIsPhoneNumber(isPhone) => voidrecipe/passwordless/types.ts:296
showContinueWithPasswordlessLinkbooleanrecipe/passwordless/types.ts:293
showPasswordFieldbooleanrecipe/passwordless/types.ts:292
validatePhoneNumber(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:310

SignInUpFeatureConfigInput

type SignInUpFeatureConfigInput = object;

Defined in: recipe/passwordless/types.ts:132

Properties

PropertyTypeDefined in
emailOrPhoneFormStyle?stringrecipe/passwordless/types.ts:135
linkSentScreenStyle?stringrecipe/passwordless/types.ts:137
resendEmailOrSMSGapInSeconds?numberrecipe/passwordless/types.ts:133
userInputCodeFormStyle?stringrecipe/passwordless/types.ts:136

SignInUpPhoneFormProps

type SignInUpPhoneFormProps = object;

Defined in: recipe/passwordless/types.ts:250

Properties

PropertyTypeDefined in
clearError() => voidrecipe/passwordless/types.ts:251
configNormalisedConfigrecipe/passwordless/types.ts:256
errorstring | undefinedrecipe/passwordless/types.ts:254
onError(error) => voidrecipe/passwordless/types.ts:252
onFetchError(error) => voidrecipe/passwordless/types.ts:253
onSuccess?() => voidrecipe/passwordless/types.ts:257
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:255
validatePhoneNumber(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:258

SignInUpProps

type SignInUpProps = object;

Defined in: recipe/passwordless/types.ts:202

Properties

PropertyTypeDefined in
clearError() => voidrecipe/passwordless/types.ts:210
configNormalisedConfigrecipe/passwordless/types.ts:205
errorstring | undefinedrecipe/passwordless/types.ts:209
factorIdsstring[]recipe/passwordless/types.ts:204
onError(err) => voidrecipe/passwordless/types.ts:208
onFetchError(err) => voidrecipe/passwordless/types.ts:207
onSuccess?(result) => voidrecipe/passwordless/types.ts:206
recipeImplementationRecipeImplementationrecipe/passwordless/types.ts:203
userContextUserContextrecipe/passwordless/types.ts:211
validatePhoneNumber(phoneNumber) => Promise<string | undefined> | string | undefinedrecipe/passwordless/types.ts:212

SignInUpUserInputCodeFormProps

type SignInUpUserInputCodeFormProps = object;

Defined in: recipe/passwordless/types.ts:272

Properties

UserInput

type UserInput = 
| {
contactMethod: "EMAIL";
signInUpFeature?: SignInUpFeatureConfigInput;
validateEmailAddress?: (email) => Promise<string | undefined> | string | undefined;
}
| {
contactMethod: "PHONE";
signInUpFeature?: SignInUpFeatureConfigInput & object;
validatePhoneNumber?: (phoneNumber) => Promise<string | undefined> | string | undefined;
}
| {
contactMethod: "EMAIL_OR_PHONE";
signInUpFeature?: SignInUpFeatureConfigInput & object;
validateEmailAddress?: (email) => Promise<string | undefined> | string | undefined;
validatePhoneNumber?: (phoneNumber) => Promise<string | undefined> | string | undefined;
} & object & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>;

Defined in: recipe/passwordless/types.ts:140

Type Declaration

UserInputCodeFormFooterProps

type UserInputCodeFormFooterProps = object;

Defined in: recipe/passwordless/types.ts:401

Properties

UserInputCodeFormHeaderProps

type UserInputCodeFormHeaderProps = object;

Defined in: recipe/passwordless/types.ts:407

Properties