Skip to content
Esc
navigateopen⌘Jpreview
Dashboard
On this page

supertokens-web-js/recipe/totp/types

References documentation for the supertokens-web-js/recipe/totp/types package

Type Aliases

DeviceInfo

type DeviceInfo = object;

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

Properties


InputType

type InputType = AuthRecipeInputType<PreAndPostAPIHookAction> & UserInput;

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


NormalisedInputType

type NormalisedInputType = AuthRecipeNormalisedInputType<PreAndPostAPIHookAction> & object;

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

Type Declaration

Name Type Defined in
override object tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts
override.functions() (originalImplementation, builder) => RecipeInterface tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts

PostAPIHookContext

type PostAPIHookContext = RecipePostAPIHookContext<PreAndPostAPIHookAction>;

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


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


PreAPIHookContext

type PreAPIHookContext = RecipePreAPIHookContext<PreAndPostAPIHookAction>;

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


RecipeInterface

type RecipeInterface = object;

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

Properties

Property Type Defined 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
listDevices (input) => Promise<{ devices: object[]; fetchResponse: Response; status: "OK"; }> tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts
removeDevice (input) => Promise<{ didDeviceExist: boolean; fetchResponse: Response; status: "OK"; }> tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts
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
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

UserInput

type UserInput = object & RecipeModuleUserInput<PreAndPostAPIHookAction>;

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

Type Declaration

Name Type Defined in
override? object tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts
override.functions()? (originalImplementation, builder) => RecipeInterface tmp/supertokens-web-js/lib/ts/recipe/totp/types.ts

API reference

API schema and response details