Skip to main content
References

TOTP Types

Type Aliases

DeviceInfo

type DeviceInfo = object;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:57

Properties

InputType

type InputType = AuthRecipeInputType<PreAndPostAPIHookAction> & UserInput;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:46

NormalisedInputType

type NormalisedInputType = AuthRecipeNormalisedInputType<PreAndPostAPIHookAction> & object;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:48

Type Declaration

NameTypeDefined in
overrideobjecttmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:49
override.functions()(originalImplementation, builder) => RecipeInterfacetmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:50

PostAPIHookContext

type PostAPIHookContext = RecipePostAPIHookContext<PreAndPostAPIHookAction>;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:35

PreAndPostAPIHookAction

type PreAndPostAPIHookAction = 
| "CREATE_DEVICE"
| "VERIFY_CODE"
| "VERIFY_DEVICE"
| "REMOVE_DEVICE"
| "LIST_DEVICES";

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:27

PreAPIHookContext

type PreAPIHookContext = RecipePreAPIHookContext<PreAndPostAPIHookAction>;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:34

RecipeInterface

type RecipeInterface = object;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:63

Properties

PropertyTypeDefined in
createDevice(input) => Promise< | { deviceName: string; fetchResponse: Response; qrCodeString: string; secret: string; status: "OK"; } | { fetchResponse: Response; status: "DEVICE_ALREADY_EXISTS_ERROR"; }>tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:64
listDevices(input) => Promise<{ devices: object[]; fetchResponse: Response; status: "OK"; }>tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:110
removeDevice(input) => Promise<{ didDeviceExist: boolean; fetchResponse: Response; status: "OK"; }>tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:105
verifyCode(input) => Promise< | { fetchResponse: Response; status: "OK"; } | { currentNumberOfFailedAttempts: number; fetchResponse: Response; maxNumberOfFailedAttempts: number; status: "INVALID_TOTP_ERROR"; } | { fetchResponse: Response; retryAfterMs: number; status: "LIMIT_REACHED_ERROR"; }>tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:79
verifyDevice(input) => Promise< | { fetchResponse: Response; status: "OK"; wasAlreadyVerified: boolean; } | { currentNumberOfFailedAttempts: number; fetchResponse: Response; maxNumberOfFailedAttempts: number; status: "INVALID_TOTP_ERROR"; } | { fetchResponse: Response; status: "UNKNOWN_DEVICE_ERROR"; } | { fetchResponse: Response; retryAfterMs: number; status: "LIMIT_REACHED_ERROR"; }>tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:89

UserInput

type UserInput = object & RecipeModuleUserInput<PreAndPostAPIHookAction>;

Defined in: tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:37

Type Declaration

NameTypeDefined in
override?objecttmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:38
override.functions()?(originalImplementation, builder) => RecipeInterfacetmp/supertokens-web-js/lib/ts/recipe/totp/types.ts:39