From 30472dafd553b77b561cf94430f64ab6b2393141 Mon Sep 17 00:00:00 2001 From: rishabhpoddar Date: Wed, 3 May 2023 10:59:30 +0530 Subject: [PATCH] adding dev-v0.32.0 tag to this commit to ensure building --- docs/classes/index.default.html | 2 +- docs/classes/recipe_authRecipe.default.html | 2 +- docs/classes/recipe_emailpassword.default.html | 2 +- docs/classes/recipe_passwordless.default.html | 2 +- docs/classes/recipe_recipeModule.default.html | 2 +- docs/classes/recipe_session.default.html | 2 +- docs/classes/recipe_thirdparty.Apple.html | 2 +- docs/classes/recipe_thirdparty.Bitbucket.html | 2 +- docs/classes/recipe_thirdparty.Discord.html | 2 +- docs/classes/recipe_thirdparty.Facebook.html | 2 +- docs/classes/recipe_thirdparty.Github.html | 2 +- docs/classes/recipe_thirdparty.Gitlab.html | 2 +- docs/classes/recipe_thirdparty.Google.html | 2 +- docs/classes/recipe_thirdparty.default.html | 2 +- docs/classes/recipe_thirdpartyemailpassword.default.html | 2 +- docs/classes/recipe_thirdpartypasswordless.default.html | 2 +- docs/classes/recipe_userroles.default.html | 2 +- docs/modules/index.html | 2 +- docs/modules/recipe_emailpassword.html | 4 ++-- docs/modules/recipe_passwordless.html | 4 ++-- docs/modules/recipe_session.html | 2 +- docs/modules/recipe_thirdparty.html | 4 ++-- docs/modules/recipe_thirdpartyemailpassword.html | 4 ++-- docs/modules/recipe_thirdpartypasswordless.html | 4 ++-- 24 files changed, 29 insertions(+), 29 deletions(-) diff --git a/docs/classes/index.default.html b/docs/classes/index.default.html index bdd82229b..8f5a60b3a 100644 --- a/docs/classes/index.default.html +++ b/docs/classes/index.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

SuperTokensWrapper: FC<PropsWithChildren<{ userContext?: any }>> = SuperTokensWrapper
useTranslation: (() => TranslationFunc) = useTranslation

Type declaration

    • (): TranslationFunc
    • Returns TranslationFunc

useUserContext: (() => any) = useUserContext

Type declaration

    • (): any
    • Returns any

Methods

  • changeLanguage(language: string): Promise<void>
  • init(config: SuperTokensConfig): void
  • loadTranslation(store: TranslationStore): void
  • redirectToAuth(options?: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }): Promise<void>
  • Parameters

    • Optional options: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }
      • Optional history?: any
      • Optional queryParams?: any
      • Optional redirectBack?: boolean
      • Optional show?: "signin" | "signup"

    Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

SuperTokensWrapper: FC<PropsWithChildren<{ userContext?: any }>> = SuperTokensWrapper
useTranslation: (() => TranslationFunc) = useTranslation

Type declaration

    • (): TranslationFunc
    • Returns TranslationFunc

useUserContext: (() => any) = useUserContext

Type declaration

    • (): any
    • Returns any

Methods

  • changeLanguage(language: string): Promise<void>
  • init(config: SuperTokensConfig): void
  • loadTranslation(store: TranslationStore): void
  • redirectToAuth(options?: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }): Promise<void>
  • Parameters

    • Optional options: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }
      • Optional history?: any
      • Optional queryParams?: any
      • Optional redirectBack?: boolean
      • Optional show?: "signin" | "signup"

    Returns Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_authRecipe.default.html b/docs/classes/recipe_authRecipe.default.html index 904243de2..51b505200 100644 --- a/docs/classes/recipe_authRecipe.default.html +++ b/docs/classes/recipe_authRecipe.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class default<T, Action, R, N> Abstract

Type Parameters

  • T

  • Action

  • R

  • N extends NormalisedConfig<T | GetRedirectionURLContext, Action, R | OnHandleEventContext>

Hierarchy

  • default<T | GetRedirectionURLContext, Action, R | OnHandleEventContext, N>
    • default

Index

Constructors

  • new default<T, Action, R, N>(config: NormalisedConfigWithAppInfoAndRecipeID<N>): default<T, Action, R, N>

Properties

config: NormalisedConfigWithAppInfoAndRecipeID<N>

Methods

  • doesSessionExist(input?: { userContext?: any }): Promise<boolean>
  • getAuthRecipeDefaultRedirectionURL(context: GetRedirectionURLContext): Promise<string>
  • getDefaultRedirectionURL(_: GetRedirectionURLContext | T): Promise<string>
  • getRedirectUrl(context: GetRedirectionURLContextType): Promise<string>
  • redirect(context: GetRedirectionURLContextType, history?: any, queryParams?: Record<string, string>): Promise<void>
  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class default<T, Action, R, N> Abstract

Type Parameters

  • T

  • Action

  • R

  • N extends NormalisedConfig<T | GetRedirectionURLContext, Action, R | OnHandleEventContext>

Hierarchy

  • default<T | GetRedirectionURLContext, Action, R | OnHandleEventContext, N>
    • default

Index

Constructors

  • new default<T, Action, R, N>(config: NormalisedConfigWithAppInfoAndRecipeID<N>): default<T, Action, R, N>

Properties

config: NormalisedConfigWithAppInfoAndRecipeID<N>

Methods

  • doesSessionExist(input?: { userContext?: any }): Promise<boolean>
  • getAuthRecipeDefaultRedirectionURL(context: GetRedirectionURLContext): Promise<string>
  • getDefaultRedirectionURL(_: GetRedirectionURLContext | T): Promise<string>
  • getRedirectUrl(context: GetRedirectionURLContextType): Promise<string>
  • redirect(context: GetRedirectionURLContextType, history?: any, queryParams?: Record<string, string>): Promise<void>
  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_emailpassword.default.html b/docs/classes/recipe_emailpassword.default.html index 52fa33322..af4c8c450 100644 --- a/docs/classes/recipe_emailpassword.default.html +++ b/docs/classes/recipe_emailpassword.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider

Methods

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • signIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • signUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider

Methods

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • signIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • signUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_passwordless.default.html b/docs/classes/recipe_passwordless.default.html index 239173d56..9e545f1c4 100644 --- a/docs/classes/recipe_passwordless.default.html +++ b/docs/classes/recipe_passwordless.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider

Methods

  • clearLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
  • consumeCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

  • createCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

    Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • doesPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • phoneNumber: string
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getLinkCodeFromURL(input?: { userContext?: any }): string
  • getLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
  • Type Parameters

    • CustomLoginAttemptInfoProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

  • getPreAuthSessionIdFromURL(input?: { userContext?: any }): string
  • resendCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

  • setLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
      • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider

Methods

  • clearLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
  • consumeCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

  • createCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

    Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • doesPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • phoneNumber: string
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getLinkCodeFromURL(input?: { userContext?: any }): string
  • getLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
  • Type Parameters

    • CustomLoginAttemptInfoProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

  • getPreAuthSessionIdFromURL(input?: { userContext?: any }): string
  • resendCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

  • setLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
      • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_recipeModule.default.html b/docs/classes/recipe_recipeModule.default.html index 7a4056285..7fa0f1e7c 100644 --- a/docs/classes/recipe_recipeModule.default.html +++ b/docs/classes/recipe_recipeModule.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N> Abstract

Type Parameters

  • GetRedirectionURLContextType

  • Action

  • OnHandleEventContextType

  • N extends NormalisedConfig<GetRedirectionURLContextType, Action, OnHandleEventContextType>

Hierarchy

Index

Constructors

  • new default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N>(config: NormalisedConfigWithAppInfoAndRecipeID<N>): default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N>
  • Type Parameters

    • GetRedirectionURLContextType

    • Action

    • OnHandleEventContextType

    • N extends NormalisedConfig<GetRedirectionURLContextType, Action, OnHandleEventContextType>

    Parameters

    • config: NormalisedConfigWithAppInfoAndRecipeID<N>

    Returns default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N>

Properties

config: NormalisedConfigWithAppInfoAndRecipeID<N>

Methods

  • getDefaultRedirectionURL(_: GetRedirectionURLContextType): Promise<string>
  • getRedirectUrl(context: GetRedirectionURLContextType): Promise<string>
  • redirect(context: GetRedirectionURLContextType, history?: any, queryParams?: Record<string, string>): Promise<void>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Class default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N> Abstract

Type Parameters

  • GetRedirectionURLContextType

  • Action

  • OnHandleEventContextType

  • N extends NormalisedConfig<GetRedirectionURLContextType, Action, OnHandleEventContextType>

Hierarchy

Index

Constructors

  • new default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N>(config: NormalisedConfigWithAppInfoAndRecipeID<N>): default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N>
  • Type Parameters

    • GetRedirectionURLContextType

    • Action

    • OnHandleEventContextType

    • N extends NormalisedConfig<GetRedirectionURLContextType, Action, OnHandleEventContextType>

    Parameters

    • config: NormalisedConfigWithAppInfoAndRecipeID<N>

    Returns default<GetRedirectionURLContextType, Action, OnHandleEventContextType, N>

Properties

config: NormalisedConfigWithAppInfoAndRecipeID<N>

Methods

  • getDefaultRedirectionURL(_: GetRedirectionURLContextType): Promise<string>
  • getRedirectUrl(context: GetRedirectionURLContextType): Promise<string>
  • redirect(context: GetRedirectionURLContextType, history?: any, queryParams?: Record<string, string>): Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_session.default.html b/docs/classes/recipe_session.default.html index 175223257..52d5ea200 100644 --- a/docs/classes/recipe_session.default.html +++ b/docs/classes/recipe_session.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

SessionAuth: FC<PropsWithChildren<SessionAuthProps & { userContext?: any }>> = SessionAuthWrapper
useClaimValue: (<T>(claim: SessionClaim<T>) => { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }) = useClaimValueFunc

Type declaration

    • <T>(claim: SessionClaim<T>): { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }
    • Type Parameters

      • T

      Parameters

      Returns { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }

useSessionContext: (() => SessionContextType) = useSessionContextFunc

Type declaration

Methods

  • addAxiosInterceptors(axiosInstance: any, userContext?: any): void
  • attemptRefreshingSession(): Promise<boolean>
  • doesSessionExist(input?: { userContext?: any }): Promise<boolean>
  • getAccessToken(input?: { userContext?: any }): Promise<undefined | string>
  • getAccessTokenPayloadSecurely(input?: { userContext?: any }): Promise<any>
  • getClaimValue(input: { claim: SessionClaim<unknown>; userContext?: any }): Promise<unknown>
  • getInvalidClaimsFromResponse(input: { response: Response | { data: any }; userContext: any }): Promise<ClaimValidationError[]>
  • getUserId(input?: { userContext?: any }): Promise<string>
  • init(config?: InputType): RecipeInitResult<unknown, unknown, unknown, any>
  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

SessionAuth: FC<PropsWithChildren<SessionAuthProps & { userContext?: any }>> = SessionAuthWrapper
useClaimValue: (<T>(claim: SessionClaim<T>) => { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }) = useClaimValueFunc

Type declaration

    • <T>(claim: SessionClaim<T>): { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }
    • Type Parameters

      • T

      Parameters

      Returns { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }

useSessionContext: (() => SessionContextType) = useSessionContextFunc

Type declaration

Methods

  • addAxiosInterceptors(axiosInstance: any, userContext?: any): void
  • attemptRefreshingSession(): Promise<boolean>
  • doesSessionExist(input?: { userContext?: any }): Promise<boolean>
  • getAccessToken(input?: { userContext?: any }): Promise<undefined | string>
  • getAccessTokenPayloadSecurely(input?: { userContext?: any }): Promise<any>
  • getClaimValue(input: { claim: SessionClaim<unknown>; userContext?: any }): Promise<unknown>
  • getInvalidClaimsFromResponse(input: { response: Response | { data: any }; userContext: any }): Promise<ClaimValidationError[]>
  • getUserId(input?: { userContext?: any }): Promise<string>
  • init(config?: InputType): RecipeInitResult<unknown, unknown, unknown, any>
  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Apple.html b/docs/classes/recipe_thirdparty.Apple.html index 9e839d0b9..0ac9b721b 100644 --- a/docs/classes/recipe_thirdparty.Apple.html +++ b/docs/classes/recipe_thirdparty.Apple.html @@ -1 +1 @@ -Apple | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Apple

Index

Constructors

  • new Apple(config?: BuiltInProviderConfig): Apple

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Apple

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Apple | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Apple

Index

Constructors

  • new Apple(config?: BuiltInProviderConfig): Apple

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Apple

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Bitbucket.html b/docs/classes/recipe_thirdparty.Bitbucket.html index 349e252ab..a7b2059b3 100644 --- a/docs/classes/recipe_thirdparty.Bitbucket.html +++ b/docs/classes/recipe_thirdparty.Bitbucket.html @@ -1 +1 @@ -Bitbucket | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Bitbucket

Index

Constructors

  • new Bitbucket(config?: BuiltInProviderConfig): Bitbucket

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Bitbucket

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Bitbucket | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Bitbucket

Index

Constructors

  • new Bitbucket(config?: BuiltInProviderConfig): Bitbucket

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Bitbucket

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Discord.html b/docs/classes/recipe_thirdparty.Discord.html index 208eff335..ae3e85527 100644 --- a/docs/classes/recipe_thirdparty.Discord.html +++ b/docs/classes/recipe_thirdparty.Discord.html @@ -1 +1 @@ -Discord | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Discord

Index

Constructors

  • new Discord(config?: BuiltInProviderConfig): Discord

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Discord

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Discord | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Discord

Index

Constructors

  • new Discord(config?: BuiltInProviderConfig): Discord

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Discord

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Facebook.html b/docs/classes/recipe_thirdparty.Facebook.html index 33080a3ee..58bd74d9f 100644 --- a/docs/classes/recipe_thirdparty.Facebook.html +++ b/docs/classes/recipe_thirdparty.Facebook.html @@ -1 +1 @@ -Facebook | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Facebook

Index

Constructors

  • new Facebook(config?: BuiltInProviderConfig): Facebook

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Facebook

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Facebook | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Facebook

Index

Constructors

  • new Facebook(config?: BuiltInProviderConfig): Facebook

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Facebook

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Github.html b/docs/classes/recipe_thirdparty.Github.html index 7dbcb7220..c51dcee32 100644 --- a/docs/classes/recipe_thirdparty.Github.html +++ b/docs/classes/recipe_thirdparty.Github.html @@ -1 +1 @@ -Github | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Github

Index

Constructors

  • new Github(config?: BuiltInProviderConfig): Github

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Github

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Github | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Github

Index

Constructors

  • new Github(config?: BuiltInProviderConfig): Github

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Github

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Gitlab.html b/docs/classes/recipe_thirdparty.Gitlab.html index a0016b7c6..8788edf07 100644 --- a/docs/classes/recipe_thirdparty.Gitlab.html +++ b/docs/classes/recipe_thirdparty.Gitlab.html @@ -1 +1 @@ -Gitlab | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Gitlab

Index

Constructors

  • new Gitlab(config?: BuiltInProviderConfig): Gitlab

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Gitlab

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Gitlab | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Gitlab

Index

Constructors

  • new Gitlab(config?: BuiltInProviderConfig): Gitlab

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Gitlab

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.Google.html b/docs/classes/recipe_thirdparty.Google.html index 92a1646fc..eb66041b0 100644 --- a/docs/classes/recipe_thirdparty.Google.html +++ b/docs/classes/recipe_thirdparty.Google.html @@ -1 +1 @@ -Google | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Google

Index

Constructors

  • new Google(config?: BuiltInProviderConfig): Google

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Google

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file +Google | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default
    • Google

Index

Constructors

  • new Google(config?: BuiltInProviderConfig): Google

Properties

buttonComponent?: Element
clientId?: string
getRedirectURL: (() => string)

Type declaration

    • (): string
    • Returns string

id: string
name: string
instance?: Google

Methods

  • defaultGetRedirectURL(): string
  • generateState(): string
  • getButton(): Element
  • getDefaultButton(name?: string): Element
  • getLogo(): Element
  • init(config?: BuiltInProviderConfig): default
  • reset(): void

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdparty.default.html b/docs/classes/recipe_thirdparty.default.html index 96e9913d8..b46460ce8 100644 --- a/docs/classes/recipe_thirdparty.default.html +++ b/docs/classes/recipe_thirdparty.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

Apple: typeof Apple = Apple
Bitbucket: typeof Bitbucket = Bitbucket
ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider
Discord: typeof Discord = Discord
Facebook: typeof Facebook = Facebook
Github: typeof Github = Github
Gitlab: typeof Gitlab = Gitlab
Google: typeof Google = Google

Methods

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • Type Parameters

    • CustomStateProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns undefined | StateObject & CustomStateProperties

  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • Parameters

    • input: { thirdPartyId: string; userContext?: any }
      • thirdPartyId: string
      • Optional userContext?: any

    Returns Promise<{ status: "OK" | "ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

Apple: typeof Apple = Apple
Bitbucket: typeof Bitbucket = Bitbucket
ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider
Discord: typeof Discord = Discord
Facebook: typeof Facebook = Facebook
Github: typeof Github = Github
Gitlab: typeof Gitlab = Gitlab
Google: typeof Google = Google

Methods

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • Type Parameters

    • CustomStateProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns undefined | StateObject & CustomStateProperties

  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • Parameters

    • input: { thirdPartyId: string; userContext?: any }
      • thirdPartyId: string
      • Optional userContext?: any

    Returns Promise<{ status: "OK" | "ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdpartyemailpassword.default.html b/docs/classes/recipe_thirdpartyemailpassword.default.html index 0ea3b7a35..36faf7ba1 100644 --- a/docs/classes/recipe_thirdpartyemailpassword.default.html +++ b/docs/classes/recipe_thirdpartyemailpassword.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

Apple: typeof Apple = Apple
Bitbucket: typeof Bitbucket = Bitbucket
ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider
Discord: typeof Discord = Discord
Facebook: typeof Facebook = Facebook
Github: typeof Github = Github
Gitlab: typeof Gitlab = Gitlab
Google: typeof Google = Google

Methods

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • emailPasswordSignIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • emailPasswordSignUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

Apple: typeof Apple = Apple
Bitbucket: typeof Bitbucket = Bitbucket
ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider
Discord: typeof Discord = Discord
Facebook: typeof Facebook = Facebook
Github: typeof Github = Github
Gitlab: typeof Gitlab = Gitlab
Google: typeof Google = Google

Methods

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • emailPasswordSignIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • emailPasswordSignUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_thirdpartypasswordless.default.html b/docs/classes/recipe_thirdpartypasswordless.default.html index a7efa150a..25be97f4b 100644 --- a/docs/classes/recipe_thirdpartypasswordless.default.html +++ b/docs/classes/recipe_thirdpartypasswordless.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

Apple: typeof Apple = Apple
Bitbucket: typeof Bitbucket = Bitbucket
ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider
Discord: typeof Discord = Discord
Facebook: typeof Facebook = Facebook
Github: typeof Github = Github
Gitlab: typeof Gitlab = Gitlab
Google: typeof Google = Google

Methods

  • clearPasswordlessLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
  • consumePasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

  • createPasswordlessCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

    Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

  • doesPasswordlessUserEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • doesPasswordlessUserPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • phoneNumber: string
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • generateThirdPartyStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getPasswordlessLinkCodeFromURL(input?: { userContext?: any }): string
  • getPasswordlessLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
  • Type Parameters

    • CustomLoginAttemptInfoProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

  • getPasswordlessPreAuthSessionIdFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthCodeFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getThirdPartyAuthStateFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getThirdPartyStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • resendPasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

  • setPasswordlessLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
      • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • setThirdPartyStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetThirdPartyStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • default

Index

Constructors

Properties

Apple: typeof Apple = Apple
Bitbucket: typeof Bitbucket = Bitbucket
ComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = RecipeComponentsOverrideContextProvider
Discord: typeof Discord = Discord
Facebook: typeof Facebook = Facebook
Github: typeof Github = Github
Gitlab: typeof Gitlab = Gitlab
Google: typeof Google = Google

Methods

  • clearPasswordlessLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
  • consumePasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

  • createPasswordlessCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

    Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

  • doesPasswordlessUserEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • doesPasswordlessUserPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • phoneNumber: string
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • generateThirdPartyStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getPasswordlessLinkCodeFromURL(input?: { userContext?: any }): string
  • getPasswordlessLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
  • Type Parameters

    • CustomLoginAttemptInfoProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

  • getPasswordlessPreAuthSessionIdFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthCodeFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getThirdPartyAuthStateFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getThirdPartyStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • resendPasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

  • setPasswordlessLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
      • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • setThirdPartyStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetThirdPartyStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/classes/recipe_userroles.default.html b/docs/classes/recipe_userroles.default.html index b33a0578a..183c3d7d6 100644 --- a/docs/classes/recipe_userroles.default.html +++ b/docs/classes/recipe_userroles.default.html @@ -1 +1 @@ -default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Generated using TypeDoc

\ No newline at end of file +default | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/index.html b/docs/modules/index.html index 1e09c3a37..59ea83db8 100644 --- a/docs/modules/index.html +++ b/docs/modules/index.html @@ -1 +1 @@ -index | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Variables

SuperTokensWrapper: React.FC<PropsWithChildren<{ userContext?: any }>> = ...

Functions

  • changeLanguage(language: string): Promise<void>
  • init(config: SuperTokensConfig): void
  • loadTranslation(store: TranslationStore): void
  • redirectToAuth(options?: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }): Promise<void>
  • Parameters

    • Optional options: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }
      • Optional history?: any
      • Optional queryParams?: any
      • Optional redirectBack?: boolean
      • Optional show?: "signin" | "signup"

    Returns Promise<void>

  • useTranslation(): TranslationFunc
  • useUserContext(): any

Generated using TypeDoc

\ No newline at end of file +index | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Variables

SuperTokensWrapper: React.FC<PropsWithChildren<{ userContext?: any }>> = ...

Functions

  • changeLanguage(language: string): Promise<void>
  • init(config: SuperTokensConfig): void
  • loadTranslation(store: TranslationStore): void
  • redirectToAuth(options?: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }): Promise<void>
  • Parameters

    • Optional options: { history?: any; queryParams?: any; redirectBack?: boolean; show?: "signin" | "signup" }
      • Optional history?: any
      • Optional queryParams?: any
      • Optional redirectBack?: boolean
      • Optional show?: "signin" | "signup"

    Returns Promise<void>

  • useTranslation(): TranslationFunc
  • useUserContext(): any

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/recipe_emailpassword.html b/docs/modules/recipe_emailpassword.html index c984c3d72..f2c5bf785 100644 --- a/docs/modules/recipe_emailpassword.html +++ b/docs/modules/recipe_emailpassword.html @@ -1,4 +1,4 @@ -recipe/emailpassword | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Module recipe/emailpassword

Index

Type Aliases

GetRedirectionURLContext: AuthRecipeModuleGetRedirectionURLContext | { action: "RESET_PASSWORD" }
OnHandleEventContext: AuthRecipeModuleOnHandleEventContext | { action: "RESET_PASSWORD_EMAIL_SENT" | "PASSWORD_RESET_SUCCESSFUL"; userContext: any } | { action: "SUCCESS"; isNewUser: boolean; user: { email: string; id: string }; userContext: any }
PreAPIHookContext: { action: PreAndPostAPIHookAction; requestInit: RequestInit; url: string; userContext: any }

Type declaration

  • action: PreAndPostAPIHookAction
  • requestInit: RequestInit
  • url: string
  • userContext: any
RecipeInterface: { doesEmailExist: any; getResetPasswordTokenFromURL: any; sendPasswordResetEmail: any; signIn: any; signUp: any; submitNewPassword: any }

Type declaration

  • doesEmailExist:function
    • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
    • +recipe/emailpassword | supertokens-auth-react
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Module recipe/emailpassword

      Index

      Type Aliases

      GetRedirectionURLContext: AuthRecipeModuleGetRedirectionURLContext | { action: "RESET_PASSWORD" }
      OnHandleEventContext: AuthRecipeModuleOnHandleEventContext | { action: "RESET_PASSWORD_EMAIL_SENT" | "PASSWORD_RESET_SUCCESSFUL"; userContext: any } | { action: "SUCCESS"; isNewUser: boolean; user: { email: string; id: string }; userContext: any }
      PreAPIHookContext: { action: PreAndPostAPIHookAction; requestInit: RequestInit; url: string; userContext: any }

      Type declaration

      • action: PreAndPostAPIHookAction
      • requestInit: RequestInit
      • url: string
      • userContext: any
      RecipeInterface: { doesEmailExist: any; getResetPasswordTokenFromURL: any; sendPasswordResetEmail: any; signIn: any; signUp: any; submitNewPassword: any }

      Type declaration

      • doesEmailExist:function
        • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
        • Check if an email exists

          throws

          STGeneralError if the API exposed by the backend SDKs returns status: "GENERAL_ERROR"

          Parameters

          • input: { email: string; options?: RecipeFunctionOptions; userContext: any }
            • email: string
            • Optional options?: RecipeFunctionOptions
            • userContext: any

          Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

          {status: "OK", doesExist: boolean}

          @@ -21,4 +21,4 @@

          Submit a new password for the user

          throws

          STGeneralError if the API exposed by the backend SDKs returns status: "GENERAL_ERROR"

      Parameters

      • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext: any }
        • formFields: { id: string; value: string }[]
        • Optional options?: RecipeFunctionOptions
        • userContext: any

      Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

      {status: "OK"} if successfull

      -
UserInput: { override?: { functions?: any }; resetPasswordUsingTokenFeature?: ResetPasswordUsingTokenUserInput; signInAndUpFeature?: SignInAndUpFeatureUserInput } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

Variables

EmailPasswordComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • signIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • signUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

Generated using TypeDoc

\ No newline at end of file +
UserInput: { override?: { functions?: any }; resetPasswordUsingTokenFeature?: ResetPasswordUsingTokenUserInput; signInAndUpFeature?: SignInAndUpFeatureUserInput } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

Variables

EmailPasswordComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • signIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • signUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/recipe_passwordless.html b/docs/modules/recipe_passwordless.html index 8b6ce3b9c..65d2141c6 100644 --- a/docs/modules/recipe_passwordless.html +++ b/docs/modules/recipe_passwordless.html @@ -1,4 +1,4 @@ -recipe/passwordless | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type Aliases

GetRedirectionURLContext: AuthRecipeModuleGetRedirectionURLContext
OnHandleEventContext: { action: "SUCCESS"; isNewUser: boolean; user: PasswordlessUser } | { action: "PASSWORDLESS_RESTART_FLOW" } | { action: "PASSWORDLESS_CODE_SENT"; isResend: boolean } | AuthRecipeModuleOnHandleEventContext
PreAPIHookContext: { action: PreAndPostAPIHookAction; requestInit: RequestInit; url: string }

Type declaration

  • action: PreAndPostAPIHookAction
  • requestInit: RequestInit
  • url: string
RecipeInterface: { clearLoginAttemptInfo: any; consumeCode: any; createCode: any; doesEmailExist: any; doesPhoneNumberExist: any; getLinkCodeFromURL: any; getLoginAttemptInfo: any; getPreAuthSessionIdFromURL: any; resendCode: any; setLoginAttemptInfo: any }

Type declaration

  • clearLoginAttemptInfo:function
    • clearLoginAttemptInfo(input: { userContext: any }): Promise<void>
    • +recipe/passwordless | supertokens-auth-react
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Index

      Type Aliases

      GetRedirectionURLContext: AuthRecipeModuleGetRedirectionURLContext
      OnHandleEventContext: { action: "SUCCESS"; isNewUser: boolean; user: PasswordlessUser } | { action: "PASSWORDLESS_RESTART_FLOW" } | { action: "PASSWORDLESS_CODE_SENT"; isResend: boolean } | AuthRecipeModuleOnHandleEventContext
      PreAPIHookContext: { action: PreAndPostAPIHookAction; requestInit: RequestInit; url: string }

      Type declaration

      • action: PreAndPostAPIHookAction
      • requestInit: RequestInit
      • url: string
      RecipeInterface: { clearLoginAttemptInfo: any; consumeCode: any; createCode: any; doesEmailExist: any; doesPhoneNumberExist: any; getLinkCodeFromURL: any; getLoginAttemptInfo: any; getPreAuthSessionIdFromURL: any; resendCode: any; setLoginAttemptInfo: any }

      Type declaration

      • clearLoginAttemptInfo:function
        • clearLoginAttemptInfo(input: { userContext: any }): Promise<void>
        • Clear any information about login attempts from storage

          Parameters

          • input: { userContext: any }
            • userContext: any

          Returns Promise<void>

      • consumeCode:function
        • consumeCode(input: { deviceId: string; options?: RecipeFunctionOptions; preAuthSessionId: string; userContext: any; userInputCode: string } | { linkCode: string; options?: RecipeFunctionOptions; preAuthSessionId: string; userContext: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
        • Log the user in using the input code or link code

          @@ -31,4 +31,4 @@

          Parameters

          • input: { deviceId: string; options?: RecipeFunctionOptions; preAuthSessionId: string; userContext: any }
            • deviceId: string
            • Optional options?: RecipeFunctionOptions
            • preAuthSessionId: string
            • userContext: any

          Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

          {status: "OK"} if succesful

      • setLoginAttemptInfo:function
        • setLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext: any }): Promise<void>
        • Set information about the current login attempt to storage

          -

          Type Parameters

          • CustomStateProperties

          Parameters

          • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext: any }
            • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
            • userContext: any

          Returns Promise<void>

      UserInput: ({ contactMethod: "EMAIL"; signInUpFeature?: SignInUpFeatureConfigInput; validateEmailAddress?: any } | { contactMethod: "PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string }; validatePhoneNumber?: any } | { contactMethod: "EMAIL_OR_PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string; guessInternationPhoneNumberFromInputPhoneNumber?: any }; validateEmailAddress?: any; validatePhoneNumber?: any }) & { linkClickedScreenFeature?: PasswordlessFeatureBaseConfig; override?: { functions?: any } } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

      Variables

      PasswordlessComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

      Functions

      • clearLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
      • consumeCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
      • Parameters

        • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

        Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

      • createCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
      • Parameters

        • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

        Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

      • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
      • Parameters

        • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
          • email: string
          • Optional options?: RecipeFunctionOptions
          • Optional userContext?: any

        Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

      • doesPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
      • Parameters

        • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • phoneNumber: string
          • Optional userContext?: any

        Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

      • getLinkCodeFromURL(input?: { userContext?: any }): string
      • getLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
      • Type Parameters

        • CustomLoginAttemptInfoProperties

        Parameters

        • Optional input: { userContext?: any }
          • Optional userContext?: any

        Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

      • getPreAuthSessionIdFromURL(input?: { userContext?: any }): string
      • resendCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
      • Parameters

        • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • Optional userContext?: any

        Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

      • setLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
      • Type Parameters

        • CustomStateProperties

        Parameters

        • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
          • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
          • Optional userContext?: any

        Returns Promise<void>

      • signOut(input?: { userContext?: any }): Promise<void>

      Legend

      • Variable
      • Function
      • Function with type parameter
      • Type alias
      • Class
      • Class with type parameter

      Settings

      Theme

      Generated using TypeDoc

      \ No newline at end of file +

      Type Parameters

      • CustomStateProperties

      Parameters

      • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext: any }
        • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
        • userContext: any

      Returns Promise<void>

UserInput: ({ contactMethod: "EMAIL"; signInUpFeature?: SignInUpFeatureConfigInput; validateEmailAddress?: any } | { contactMethod: "PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string }; validatePhoneNumber?: any } | { contactMethod: "EMAIL_OR_PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string; guessInternationPhoneNumberFromInputPhoneNumber?: any }; validateEmailAddress?: any; validatePhoneNumber?: any }) & { linkClickedScreenFeature?: PasswordlessFeatureBaseConfig; override?: { functions?: any } } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

Variables

PasswordlessComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • clearLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
  • consumeCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

  • createCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

    Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • doesPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • phoneNumber: string
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • getLinkCodeFromURL(input?: { userContext?: any }): string
  • getLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
  • Type Parameters

    • CustomLoginAttemptInfoProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

  • getPreAuthSessionIdFromURL(input?: { userContext?: any }): string
  • resendCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

  • setLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
      • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/recipe_session.html b/docs/modules/recipe_session.html index 6f129d07d..d2657377d 100644 --- a/docs/modules/recipe_session.html +++ b/docs/modules/recipe_session.html @@ -1 +1 @@ -recipe/session | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type Aliases

ClaimValidationError: { reason?: any; validatorId: string }

Type declaration

  • Optional reason?: any
  • validatorId: string
ClaimValidationResult: { isValid: true } | { isValid: false; reason?: any }
InputType: WebJSInputType & { onHandleEvent?: any }
RecipeInterface: { addAxiosInterceptors: any; addFetchInterceptorsAndReturnModifiedFetch: any; addXMLHttpRequestInterceptor: any; doesSessionExist: any; getAccessTokenPayloadSecurely: any; getGlobalClaimValidators: any; getInvalidClaimsFromResponse: any; getUserId: any; signOut: any; validateClaims: any }

Type declaration

  • addAxiosInterceptors:function
    • addAxiosInterceptors(input: { axiosInstance: any; userContext: any }): void
    • Parameters

      • input: { axiosInstance: any; userContext: any }
        • axiosInstance: any
        • userContext: any

      Returns void

  • addFetchInterceptorsAndReturnModifiedFetch:function
    • addFetchInterceptorsAndReturnModifiedFetch(input: { originalFetch: any; userContext: any }): ((input: URL | RequestInfo, init?: RequestInit) => Promise<Response>)
    • Parameters

      • input: { originalFetch: any; userContext: any }
        • originalFetch: any
        • userContext: any

      Returns ((input: URL | RequestInfo, init?: RequestInit) => Promise<Response>)

        • (input: URL | RequestInfo, init?: RequestInit): Promise<Response>
        • Parameters

          • input: URL | RequestInfo
          • Optional init: RequestInit

          Returns Promise<Response>

  • addXMLHttpRequestInterceptor:function
    • addXMLHttpRequestInterceptor(input: { userContext: any }): void
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns void

  • doesSessionExist:function
    • doesSessionExist(input: { userContext: any }): Promise<boolean>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<boolean>

  • getAccessTokenPayloadSecurely:function
    • getAccessTokenPayloadSecurely(input: { userContext: any }): Promise<any>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<any>

  • getGlobalClaimValidators:function
  • getInvalidClaimsFromResponse:function
    • getInvalidClaimsFromResponse(input: { response: { data: any } | Response; userContext: any }): Promise<ClaimValidationError[]>
    • Parameters

      • input: { response: { data: any } | Response; userContext: any }
        • response: { data: any } | Response
        • userContext: any

      Returns Promise<ClaimValidationError[]>

  • getUserId:function
    • getUserId(input: { userContext: any }): Promise<string>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<string>

  • signOut:function
    • signOut(input: { userContext: any }): Promise<void>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<void>

  • validateClaims:function
SessionClaim<ValueType>: { getLastFetchedTime: any; getValueFromPayload: any; refresh: any }

Type Parameters

  • ValueType

Type declaration

  • getLastFetchedTime:function
    • getLastFetchedTime(payload: any, _userContext?: any): undefined | number
    • Parameters

      • payload: any
      • Optional _userContext: any

      Returns undefined | number

  • getValueFromPayload:function
    • getValueFromPayload(payload: any, _userContext?: any): undefined | ValueType
    • Parameters

      • payload: any
      • Optional _userContext: any

      Returns undefined | ValueType

  • refresh:function
    • refresh(userContext: any): Promise<void>
    • Parameters

      • userContext: any

      Returns Promise<void>

SessionContextType: LoadedSessionContext | { loading: true }

Variables

SessionAuth: FC<PropsWithChildren<SessionAuthProps & { userContext?: any }>> = SessionAPIWrapper.SessionAuth
SessionContext: Context<{ invalidClaims: ClaimValidationError[]; loading: false } & SessionContextUpdate & { isDefault?: boolean } & { loading: true } & { isDefault?: boolean }> = ...

Functions

  • addAxiosInterceptors(axiosInstance: any, userContext?: any): void
  • attemptRefreshingSession(): Promise<boolean>
  • doesSessionExist(input?: { userContext?: any }): Promise<boolean>
  • getAccessToken(input?: { userContext?: any }): Promise<undefined | string>
  • getAccessTokenPayloadSecurely(input?: { userContext?: any }): Promise<any>
  • getClaimValue(input: { claim: SessionClaim<unknown>; userContext?: any }): Promise<unknown>
  • getInvalidClaimsFromResponse(input: { response: Response | { data: any }; userContext: any }): Promise<ClaimValidationError[]>
  • getUserId(input?: { userContext?: any }): Promise<string>
  • init(config?: InputType): RecipeInitResult<unknown, unknown, unknown, any>
  • signOut(input?: { userContext?: any }): Promise<void>
  • useClaimValue<T>(claim: SessionClaim<T>): { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }

Generated using TypeDoc

\ No newline at end of file +recipe/session | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type Aliases

ClaimValidationError: { reason?: any; validatorId: string }

Type declaration

  • Optional reason?: any
  • validatorId: string
ClaimValidationResult: { isValid: true } | { isValid: false; reason?: any }
InputType: WebJSInputType & { onHandleEvent?: any }
RecipeInterface: { addAxiosInterceptors: any; addFetchInterceptorsAndReturnModifiedFetch: any; addXMLHttpRequestInterceptor: any; doesSessionExist: any; getAccessTokenPayloadSecurely: any; getGlobalClaimValidators: any; getInvalidClaimsFromResponse: any; getUserId: any; signOut: any; validateClaims: any }

Type declaration

  • addAxiosInterceptors:function
    • addAxiosInterceptors(input: { axiosInstance: any; userContext: any }): void
    • Parameters

      • input: { axiosInstance: any; userContext: any }
        • axiosInstance: any
        • userContext: any

      Returns void

  • addFetchInterceptorsAndReturnModifiedFetch:function
    • addFetchInterceptorsAndReturnModifiedFetch(input: { originalFetch: any; userContext: any }): ((input: URL | RequestInfo, init?: RequestInit) => Promise<Response>)
    • Parameters

      • input: { originalFetch: any; userContext: any }
        • originalFetch: any
        • userContext: any

      Returns ((input: URL | RequestInfo, init?: RequestInit) => Promise<Response>)

        • (input: URL | RequestInfo, init?: RequestInit): Promise<Response>
        • Parameters

          • input: URL | RequestInfo
          • Optional init: RequestInit

          Returns Promise<Response>

  • addXMLHttpRequestInterceptor:function
    • addXMLHttpRequestInterceptor(input: { userContext: any }): void
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns void

  • doesSessionExist:function
    • doesSessionExist(input: { userContext: any }): Promise<boolean>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<boolean>

  • getAccessTokenPayloadSecurely:function
    • getAccessTokenPayloadSecurely(input: { userContext: any }): Promise<any>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<any>

  • getGlobalClaimValidators:function
  • getInvalidClaimsFromResponse:function
    • getInvalidClaimsFromResponse(input: { response: { data: any } | Response; userContext: any }): Promise<ClaimValidationError[]>
    • Parameters

      • input: { response: { data: any } | Response; userContext: any }
        • response: { data: any } | Response
        • userContext: any

      Returns Promise<ClaimValidationError[]>

  • getUserId:function
    • getUserId(input: { userContext: any }): Promise<string>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<string>

  • signOut:function
    • signOut(input: { userContext: any }): Promise<void>
    • Parameters

      • input: { userContext: any }
        • userContext: any

      Returns Promise<void>

  • validateClaims:function
SessionClaim<ValueType>: { getLastFetchedTime: any; getValueFromPayload: any; refresh: any }

Type Parameters

  • ValueType

Type declaration

  • getLastFetchedTime:function
    • getLastFetchedTime(payload: any, _userContext?: any): undefined | number
    • Parameters

      • payload: any
      • Optional _userContext: any

      Returns undefined | number

  • getValueFromPayload:function
    • getValueFromPayload(payload: any, _userContext?: any): undefined | ValueType
    • Parameters

      • payload: any
      • Optional _userContext: any

      Returns undefined | ValueType

  • refresh:function
    • refresh(userContext: any): Promise<void>
    • Parameters

      • userContext: any

      Returns Promise<void>

SessionContextType: LoadedSessionContext | { loading: true }

Variables

SessionAuth: FC<PropsWithChildren<SessionAuthProps & { userContext?: any }>> = SessionAPIWrapper.SessionAuth
SessionContext: Context<{ invalidClaims: ClaimValidationError[]; loading: false } & SessionContextUpdate & { isDefault?: boolean } & { loading: true } & { isDefault?: boolean }> = ...

Functions

  • addAxiosInterceptors(axiosInstance: any, userContext?: any): void
  • attemptRefreshingSession(): Promise<boolean>
  • doesSessionExist(input?: { userContext?: any }): Promise<boolean>
  • getAccessToken(input?: { userContext?: any }): Promise<undefined | string>
  • getAccessTokenPayloadSecurely(input?: { userContext?: any }): Promise<any>
  • getClaimValue(input: { claim: SessionClaim<unknown>; userContext?: any }): Promise<unknown>
  • getInvalidClaimsFromResponse(input: { response: Response | { data: any }; userContext: any }): Promise<ClaimValidationError[]>
  • getUserId(input?: { userContext?: any }): Promise<string>
  • init(config?: InputType): RecipeInitResult<unknown, unknown, unknown, any>
  • signOut(input?: { userContext?: any }): Promise<void>
  • useClaimValue<T>(claim: SessionClaim<T>): { loading: true } | { doesSessionExist: boolean; loading: false; value: undefined | T }

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/recipe_thirdparty.html b/docs/modules/recipe_thirdparty.html index 2e4e5e0c2..540e35d35 100644 --- a/docs/modules/recipe_thirdparty.html +++ b/docs/modules/recipe_thirdparty.html @@ -1,4 +1,4 @@ -recipe/thirdparty | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type Aliases

GetRedirectionURLContext: AuthRecipeModuleGetRedirectionURLContext
OnHandleEventContext: AuthRecipeModuleOnHandleEventContext | { action: "SUCCESS"; isNewUser: boolean; user: { email: string; id: string }; userContext: any }
PreAPIHookContext: { action: PreAndPostAPIHookAction; requestInit: RequestInit; url: string; userContext: any }

Type declaration

  • action: PreAndPostAPIHookAction
  • requestInit: RequestInit
  • url: string
  • userContext: any
RecipeInterface: { generateStateToSendToOAuthProvider: any; getAuthCodeFromURL: any; getAuthErrorFromURL: any; getAuthStateFromURL: any; getAuthorisationURLFromBackend: any; getAuthorisationURLWithQueryParamsAndSetState: any; getStateAndOtherInfoFromStorage: any; setStateAndOtherInfoToStorage: any; signInAndUp: any; verifyAndGetStateOrThrowError: any }

Type declaration

  • generateStateToSendToOAuthProvider:function
    • generateStateToSendToOAuthProvider(input: { userContext: any }): string
    • +recipe/thirdparty | supertokens-auth-react
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Index

      Type Aliases

      GetRedirectionURLContext: AuthRecipeModuleGetRedirectionURLContext
      OnHandleEventContext: AuthRecipeModuleOnHandleEventContext | { action: "SUCCESS"; isNewUser: boolean; user: { email: string; id: string }; userContext: any }
      PreAPIHookContext: { action: PreAndPostAPIHookAction; requestInit: RequestInit; url: string; userContext: any }

      Type declaration

      • action: PreAndPostAPIHookAction
      • requestInit: RequestInit
      • url: string
      • userContext: any
      RecipeInterface: { generateStateToSendToOAuthProvider: any; getAuthCodeFromURL: any; getAuthErrorFromURL: any; getAuthStateFromURL: any; getAuthorisationURLFromBackend: any; getAuthorisationURLWithQueryParamsAndSetState: any; getStateAndOtherInfoFromStorage: any; setStateAndOtherInfoToStorage: any; signInAndUp: any; verifyAndGetStateOrThrowError: any }

      Type declaration

      • generateStateToSendToOAuthProvider:function
        • generateStateToSendToOAuthProvider(input: { userContext: any }): string
        • Generate a new state that will be sent to the third party provider

          Parameters

          • input: { userContext: any }
            • userContext: any

          Returns string

          string

      • getAuthCodeFromURL:function
        • getAuthCodeFromURL(input: { userContext: any }): string
        • @@ -29,4 +29,4 @@

          Parameters

          • input: { options?: RecipeFunctionOptions; userContext: any }
            • Optional options?: RecipeFunctionOptions
            • userContext: any

          Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

          {status: OK, user, createdNewUser: boolean} if succesful

      • verifyAndGetStateOrThrowError:function
        • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: string | undefined; stateObjectFromStorage: StateObject & CustomStateProperties | undefined; userContext: any }): Promise<StateObject & CustomStateProperties>
        • Verify that the state recieved from the third party provider matches the one in storage

          -

          Type Parameters

          • CustomStateProperties

          Parameters

          • input: { stateFromAuthProvider: string | undefined; stateObjectFromStorage: StateObject & CustomStateProperties | undefined; userContext: any }
            • stateFromAuthProvider: string | undefined
            • stateObjectFromStorage: StateObject & CustomStateProperties | undefined
            • userContext: any

          Returns Promise<StateObject & CustomStateProperties>

      User: { email: string; id: string; thirdParty: { id: string; userId: string }; timeJoined: number }

      Type declaration

      • email: string
      • id: string
      • thirdParty: { id: string; userId: string }
        • id: string
        • userId: string
      • timeJoined: number
      UserInput: { oAuthCallbackScreen?: FeatureBaseConfig; override?: { functions?: any }; signInAndUpFeature?: SignInAndUpFeatureUserInput } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

      Variables

      ThirdpartyComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

      Functions

      • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
      • getAuthCodeFromURL(input?: { userContext?: any }): string
      • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
      • getAuthStateFromURL(input?: { userContext?: any }): string
      • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
      • Parameters

        • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • providerId: string
          • Optional userContext?: any

        Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

      • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
      • Parameters

        • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
          • authorisationURL: string
          • Optional options?: RecipeFunctionOptions
          • Optional providerClientId?: string
          • providerId: string
          • Optional userContext?: any

        Returns Promise<string>

      • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
      • Type Parameters

        • CustomStateProperties

        Parameters

        • Optional input: { userContext?: any }
          • Optional userContext?: any

        Returns undefined | StateObject & CustomStateProperties

      • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
      • Parameters

        • input: { thirdPartyId: string; userContext?: any }
          • thirdPartyId: string
          • Optional userContext?: any

        Returns Promise<{ status: "OK" | "ERROR" }>

      • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
      • Type Parameters

        • CustomStateProperties

        Parameters

        • input: { state: StateObject & CustomStateProperties; userContext?: any }
          • state: StateObject & CustomStateProperties
          • Optional userContext?: any

        Returns Promise<void>

      • signInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
      • Parameters

        • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • Optional userContext?: any

        Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

      • signOut(input?: { userContext?: any }): Promise<void>
      • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
      • Type Parameters

        • CustomStateProperties

        Parameters

        • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
          • stateFromAuthProvider: undefined | string
          • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
          • Optional userContext?: any

        Returns Promise<StateObject & CustomStateProperties>

      Legend

      • Variable
      • Function
      • Function with type parameter
      • Type alias
      • Class
      • Class with type parameter

      Settings

      Theme

      Generated using TypeDoc

      \ No newline at end of file +

      Type Parameters

      • CustomStateProperties

      Parameters

      • input: { stateFromAuthProvider: string | undefined; stateObjectFromStorage: StateObject & CustomStateProperties | undefined; userContext: any }
        • stateFromAuthProvider: string | undefined
        • stateObjectFromStorage: StateObject & CustomStateProperties | undefined
        • userContext: any

      Returns Promise<StateObject & CustomStateProperties>

User: { email: string; id: string; thirdParty: { id: string; userId: string }; timeJoined: number }

Type declaration

  • email: string
  • id: string
  • thirdParty: { id: string; userId: string }
    • id: string
    • userId: string
  • timeJoined: number
UserInput: { oAuthCallbackScreen?: FeatureBaseConfig; override?: { functions?: any }; signInAndUpFeature?: SignInAndUpFeatureUserInput } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

Variables

ThirdpartyComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • Type Parameters

    • CustomStateProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns undefined | StateObject & CustomStateProperties

  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • Parameters

    • input: { thirdPartyId: string; userContext?: any }
      • thirdPartyId: string
      • Optional userContext?: any

    Returns Promise<{ status: "OK" | "ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • signOut(input?: { userContext?: any }): Promise<void>
  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/recipe_thirdpartyemailpassword.html b/docs/modules/recipe_thirdpartyemailpassword.html index d8cc4dcfa..4607875b9 100644 --- a/docs/modules/recipe_thirdpartyemailpassword.html +++ b/docs/modules/recipe_thirdpartyemailpassword.html @@ -1,4 +1,4 @@ -recipe/thirdpartyemailpassword | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Module recipe/thirdpartyemailpassword

Index

References

Re-exports Apple
Re-exports Bitbucket
Re-exports Discord
Re-exports Facebook
Re-exports Github
Re-exports Gitlab
Re-exports Google
Renames and re-exports User

Type Aliases

RecipeInterface: { doesEmailExist: any; emailPasswordSignIn: any; emailPasswordSignUp: any; generateStateToSendToOAuthProvider: any; getAuthCodeFromURL: any; getAuthErrorFromURL: any; getAuthStateFromURL: any; getAuthorisationURLFromBackend: any; getAuthorisationURLWithQueryParamsAndSetState: any; getResetPasswordTokenFromURL: any; getStateAndOtherInfoFromStorage: any; sendPasswordResetEmail: any; setStateAndOtherInfoToStorage: any; submitNewPassword: any; thirdPartySignInAndUp: any; verifyAndGetStateOrThrowError: any }

Type declaration

UserInput: { disableEmailPassword?: boolean; oAuthCallbackScreen?: FeatureBaseConfig; override?: { functions?: any }; resetPasswordUsingTokenFeature?: ResetPasswordUsingTokenUserInput; signInAndUpFeature?: SignInAndUpFeatureUserInput } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>
UserType: { email: string; id: string; timeJoined: number }

Type declaration

  • email: string
  • id: string
  • timeJoined: number

Variables

ThirdpartyEmailPasswordComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • emailPasswordSignIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • emailPasswordSignUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file +

Type Parameters

Parameters

Returns Promise<StateObject & CustomStateProperties>

UserInput: { disableEmailPassword?: boolean; oAuthCallbackScreen?: FeatureBaseConfig; override?: { functions?: any }; resetPasswordUsingTokenFeature?: ResetPasswordUsingTokenUserInput; signInAndUpFeature?: SignInAndUpFeatureUserInput } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>
UserType: { email: string; id: string; timeJoined: number }

Type declaration

  • email: string
  • id: string
  • timeJoined: number

Variables

ThirdpartyEmailPasswordComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • doesEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • emailPasswordSignIn(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" } | { fetchResponse: Response; status: "WRONG_CREDENTIALS_ERROR" }>

  • emailPasswordSignUp(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; user: UserType } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • generateStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthCodeFromURL(input?: { userContext?: any }): string
  • getAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getAuthStateFromURL(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getResetPasswordTokenFromURL(input?: { userContext?: any }): string
  • getStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • sendPasswordResetEmail(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • setStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • submitNewPassword(input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>
  • Parameters

    • input: { formFields: { id: string; value: string }[]; options?: RecipeFunctionOptions; userContext?: any }
      • formFields: { id: string; value: string }[]
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESET_PASSWORD_INVALID_TOKEN_ERROR" } | { fetchResponse: Response; formFields: { error: string; id: string }[]; status: "FIELD_ERROR" }>

  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file diff --git a/docs/modules/recipe_thirdpartypasswordless.html b/docs/modules/recipe_thirdpartypasswordless.html index ef3f63aba..c3575fe8d 100644 --- a/docs/modules/recipe_thirdpartypasswordless.html +++ b/docs/modules/recipe_thirdpartypasswordless.html @@ -1,4 +1,4 @@ -recipe/thirdpartypasswordless | supertokens-auth-react
Options
All
  • Public
  • Public/Protected
  • All
Menu

Module recipe/thirdpartypasswordless

Index

References

Re-exports Apple
Re-exports Bitbucket
Re-exports Discord
Re-exports Facebook
Re-exports Github
Re-exports Gitlab
Re-exports Google

Type Aliases

RecipeInterface: { clearPasswordlessLoginAttemptInfo: any; consumePasswordlessCode: any; createPasswordlessCode: any; doesPasswordlessUserEmailExist: any; doesPasswordlessUserPhoneNumberExist: any; generateThirdPartyStateToSendToOAuthProvider: any; getAuthorisationURLFromBackend: any; getPasswordlessLinkCodeFromURL: any; getPasswordlessLoginAttemptInfo: any; getPasswordlessPreAuthSessionIdFromURL: any; getThirdPartyAuthCodeFromURL: any; getThirdPartyAuthErrorFromURL: any; getThirdPartyAuthStateFromURL: any; getThirdPartyAuthorisationURLWithQueryParamsAndSetState: any; getThirdPartyStateAndOtherInfoFromStorage: any; resendPasswordlessCode: any; setPasswordlessLoginAttemptInfo: any; setThirdPartyStateAndOtherInfoToStorage: any; thirdPartySignInAndUp: any; verifyAndGetThirdPartyStateOrThrowError: any }

Type declaration

  • clearPasswordlessLoginAttemptInfo:function
    • clearPasswordlessLoginAttemptInfo(input: { userContext: any }): Promise<void>
    • +recipe/thirdpartypasswordless | supertokens-auth-react
      Options
      All
      • Public
      • Public/Protected
      • All
      Menu

      Module recipe/thirdpartypasswordless

      Index

      References

      Re-exports Apple
      Re-exports Bitbucket
      Re-exports Discord
      Re-exports Facebook
      Re-exports Github
      Re-exports Gitlab
      Re-exports Google

      Type Aliases

      RecipeInterface: { clearPasswordlessLoginAttemptInfo: any; consumePasswordlessCode: any; createPasswordlessCode: any; doesPasswordlessUserEmailExist: any; doesPasswordlessUserPhoneNumberExist: any; generateThirdPartyStateToSendToOAuthProvider: any; getAuthorisationURLFromBackend: any; getPasswordlessLinkCodeFromURL: any; getPasswordlessLoginAttemptInfo: any; getPasswordlessPreAuthSessionIdFromURL: any; getThirdPartyAuthCodeFromURL: any; getThirdPartyAuthErrorFromURL: any; getThirdPartyAuthStateFromURL: any; getThirdPartyAuthorisationURLWithQueryParamsAndSetState: any; getThirdPartyStateAndOtherInfoFromStorage: any; resendPasswordlessCode: any; setPasswordlessLoginAttemptInfo: any; setThirdPartyStateAndOtherInfoToStorage: any; thirdPartySignInAndUp: any; verifyAndGetThirdPartyStateOrThrowError: any }

      Type declaration

      • clearPasswordlessLoginAttemptInfo:function
        • clearPasswordlessLoginAttemptInfo(input: { userContext: any }): Promise<void>
        • Clear any information about login attempts from storage

          Parameters

          • input: { userContext: any }
            • userContext: any

          Returns Promise<void>

      • consumePasswordlessCode:function
        • consumePasswordlessCode(input: { deviceId: string; options?: RecipeFunctionOptions; preAuthSessionId: string; userContext: any; userInputCode: string } | { linkCode: string; options?: RecipeFunctionOptions; preAuthSessionId: string; userContext: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
        • Log the user in using the input code or link code

          @@ -62,4 +62,4 @@

          Parameters

          • input: { options?: RecipeFunctionOptions; userContext: any }
            • Optional options?: RecipeFunctionOptions
            • userContext: any

          Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

          {status: OK, user, createdNewUser: boolean} if succesful

      • verifyAndGetThirdPartyStateOrThrowError:function
        • verifyAndGetThirdPartyStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: string | undefined; stateObjectFromStorage: StateObject & CustomStateProperties | undefined; userContext: any }): Promise<StateObject & CustomStateProperties>
        • Verify that the state recieved from the third party provider matches the one in storage

          -

          Type Parameters

          • CustomStateProperties

          Parameters

          • input: { stateFromAuthProvider: string | undefined; stateObjectFromStorage: StateObject & CustomStateProperties | undefined; userContext: any }
            • stateFromAuthProvider: string | undefined
            • stateObjectFromStorage: StateObject & CustomStateProperties | undefined
            • userContext: any

          Returns Promise<StateObject & CustomStateProperties>

      UserInput: ({ contactMethod: "EMAIL"; signInUpFeature?: SignInUpFeatureConfigInput; validateEmailAddress?: any } | { contactMethod: "PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string }; validatePhoneNumber?: any } | { contactMethod: "EMAIL_OR_PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string; guessInternationPhoneNumberFromInputPhoneNumber?: any }; validateEmailAddress?: any; validatePhoneNumber?: any }) & { disablePasswordless?: boolean; linkClickedScreenFeature?: PasswordlessFeatureBaseConfig; oAuthCallbackScreen?: FeatureBaseConfig; override?: { functions?: any } } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

      Variables

      ThirdpartyPasswordlessComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

      Functions

      • clearPasswordlessLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
      • consumePasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
      • Parameters

        • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

        Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

      • createPasswordlessCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
      • Parameters

        • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

        Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

      • doesPasswordlessUserEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
      • Parameters

        • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
          • email: string
          • Optional options?: RecipeFunctionOptions
          • Optional userContext?: any

        Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

      • doesPasswordlessUserPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
      • Parameters

        • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • phoneNumber: string
          • Optional userContext?: any

        Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

      • generateThirdPartyStateToSendToOAuthProvider(input?: { userContext?: any }): string
      • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
      • Parameters

        • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • providerId: string
          • Optional userContext?: any

        Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

      • getPasswordlessLinkCodeFromURL(input?: { userContext?: any }): string
      • getPasswordlessLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
      • Type Parameters

        • CustomLoginAttemptInfoProperties

        Parameters

        • Optional input: { userContext?: any }
          • Optional userContext?: any

        Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

      • getPasswordlessPreAuthSessionIdFromURL(input?: { userContext?: any }): string
      • getThirdPartyAuthCodeFromURL(input?: { userContext?: any }): string
      • getThirdPartyAuthErrorFromURL(input?: { userContext?: any }): undefined | string
      • getThirdPartyAuthStateFromURL(input?: { userContext?: any }): string
      • getThirdPartyAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
      • Parameters

        • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
          • authorisationURL: string
          • Optional options?: RecipeFunctionOptions
          • Optional providerClientId?: string
          • providerId: string
          • Optional userContext?: any

        Returns Promise<string>

      • getThirdPartyStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
      • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
      • resendPasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
      • Parameters

        • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • Optional userContext?: any

        Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

      • setPasswordlessLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
      • Type Parameters

        • CustomStateProperties

        Parameters

        • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
          • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
          • Optional userContext?: any

        Returns Promise<void>

      • setThirdPartyStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
      • Type Parameters

        • CustomStateProperties

        Parameters

        • input: { state: StateObject & CustomStateProperties; userContext?: any }
          • state: StateObject & CustomStateProperties
          • Optional userContext?: any

        Returns Promise<void>

      • signOut(input?: { userContext?: any }): Promise<void>
      • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
      • Parameters

        • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
          • Optional options?: RecipeFunctionOptions
          • Optional userContext?: any

        Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

      • verifyAndGetThirdPartyStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
      • Type Parameters

        • CustomStateProperties

        Parameters

        • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
          • stateFromAuthProvider: undefined | string
          • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
          • Optional userContext?: any

        Returns Promise<StateObject & CustomStateProperties>

      Legend

      • Variable
      • Function
      • Function with type parameter
      • Type alias
      • Class
      • Class with type parameter

      Settings

      Theme

      Generated using TypeDoc

      \ No newline at end of file +

      Type Parameters

      • CustomStateProperties

      Parameters

      • input: { stateFromAuthProvider: string | undefined; stateObjectFromStorage: StateObject & CustomStateProperties | undefined; userContext: any }
        • stateFromAuthProvider: string | undefined
        • stateObjectFromStorage: StateObject & CustomStateProperties | undefined
        • userContext: any

      Returns Promise<StateObject & CustomStateProperties>

UserInput: ({ contactMethod: "EMAIL"; signInUpFeature?: SignInUpFeatureConfigInput; validateEmailAddress?: any } | { contactMethod: "PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string }; validatePhoneNumber?: any } | { contactMethod: "EMAIL_OR_PHONE"; signInUpFeature?: SignInUpFeatureConfigInput & { defaultCountry?: string; guessInternationPhoneNumberFromInputPhoneNumber?: any }; validateEmailAddress?: any; validatePhoneNumber?: any }) & { disablePasswordless?: boolean; linkClickedScreenFeature?: PasswordlessFeatureBaseConfig; oAuthCallbackScreen?: FeatureBaseConfig; override?: { functions?: any } } & AuthRecipeModuleUserInput<GetRedirectionURLContext, PreAndPostAPIHookAction, OnHandleEventContext>

Variables

ThirdpartyPasswordlessComponentsOverrideProvider: FC<PropsWithChildren<{ components: ComponentOverrideMap }>> = Wrapper.ComponentsOverrideProvider

Functions

  • clearPasswordlessLoginAttemptInfo(input?: { userContext?: any }): Promise<void>
  • consumePasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any; userInputCode: string } | { options?: RecipeFunctionOptions; userContext?: any }

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: PasswordlessUser } | { failedCodeInputAttemptCount: number; fetchResponse: Response; maximumCodeInputAttempts: number; status: "INCORRECT_USER_INPUT_CODE_ERROR" | "EXPIRED_USER_INPUT_CODE_ERROR" } | { fetchResponse: Response; status: "RESTART_FLOW_ERROR" }>

  • createPasswordlessCode(input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any } | { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }

    Returns Promise<{ deviceId: string; fetchResponse: Response; flowType: PasswordlessFlowType; preAuthSessionId: string; status: "OK" }>

  • doesPasswordlessUserEmailExist(input: { email: string; options?: RecipeFunctionOptions; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { email: string; options?: RecipeFunctionOptions; userContext?: any }
      • email: string
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • doesPasswordlessUserPhoneNumberExist(input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }): Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; phoneNumber: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • phoneNumber: string
      • Optional userContext?: any

    Returns Promise<{ doesExist: boolean; fetchResponse: Response; status: "OK" }>

  • generateThirdPartyStateToSendToOAuthProvider(input?: { userContext?: any }): string
  • getAuthorisationURLFromBackend(input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK"; url: string }>
  • Parameters

    • input: { options?: RecipeFunctionOptions; providerId: string; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • providerId: string
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK"; url: string }>

  • getPasswordlessLinkCodeFromURL(input?: { userContext?: any }): string
  • getPasswordlessLoginAttemptInfo<CustomLoginAttemptInfoProperties>(input?: { userContext?: any }): Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>
  • Type Parameters

    • CustomLoginAttemptInfoProperties

    Parameters

    • Optional input: { userContext?: any }
      • Optional userContext?: any

    Returns Promise<undefined | { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomLoginAttemptInfoProperties>

  • getPasswordlessPreAuthSessionIdFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthCodeFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthErrorFromURL(input?: { userContext?: any }): undefined | string
  • getThirdPartyAuthStateFromURL(input?: { userContext?: any }): string
  • getThirdPartyAuthorisationURLWithQueryParamsAndSetState(input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }): Promise<string>
  • Parameters

    • input: { authorisationURL: string; options?: RecipeFunctionOptions; providerClientId?: string; providerId: string; userContext?: any }
      • authorisationURL: string
      • Optional options?: RecipeFunctionOptions
      • Optional providerClientId?: string
      • providerId: string
      • Optional userContext?: any

    Returns Promise<string>

  • getThirdPartyStateAndOtherInfoFromStorage<CustomStateProperties>(input?: { userContext?: any }): undefined | StateObject & CustomStateProperties
  • redirectToThirdPartyLogin(input: { thirdPartyId: string; userContext?: any }): Promise<{ status: "OK" | "ERROR" }>
  • resendPasswordlessCode(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ fetchResponse: Response; status: "OK" | "RESTART_FLOW_ERROR" }>

  • setPasswordlessLoginAttemptInfo<CustomStateProperties>(input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties; userContext?: any }
      • attemptInfo: { deviceId: string; flowType: PasswordlessFlowType; preAuthSessionId: string } & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • setThirdPartyStateAndOtherInfoToStorage<CustomStateProperties>(input: { state: StateObject & CustomStateProperties; userContext?: any }): Promise<void>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { state: StateObject & CustomStateProperties; userContext?: any }
      • state: StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<void>

  • signOut(input?: { userContext?: any }): Promise<void>
  • thirdPartySignInAndUp(input?: { options?: RecipeFunctionOptions; userContext?: any }): Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>
  • Parameters

    • Optional input: { options?: RecipeFunctionOptions; userContext?: any }
      • Optional options?: RecipeFunctionOptions
      • Optional userContext?: any

    Returns Promise<{ createdNewUser: boolean; fetchResponse: Response; status: "OK"; user: User } | { fetchResponse: Response; status: "NO_EMAIL_GIVEN_BY_PROVIDER" }>

  • verifyAndGetThirdPartyStateOrThrowError<CustomStateProperties>(input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }): Promise<StateObject & CustomStateProperties>
  • Type Parameters

    • CustomStateProperties

    Parameters

    • input: { stateFromAuthProvider: undefined | string; stateObjectFromStorage: undefined | StateObject & CustomStateProperties; userContext?: any }
      • stateFromAuthProvider: undefined | string
      • stateObjectFromStorage: undefined | StateObject & CustomStateProperties
      • Optional userContext?: any

    Returns Promise<StateObject & CustomStateProperties>

Generated using TypeDoc

\ No newline at end of file