Search
Preparing search index...
The search index is not available
supertokens-auth-react
Options
All
Public
Public/Protected
All
Inherited
Externals
Menu
supertokens-auth-react
recipe/emailpassword
default
Class default
Hierarchy
default
Index
Constructors
constructor
Properties
Components
Override
Provider
Methods
does
Email
Exist
get
Reset
Password
Token
FromURL
init
send
Password
Reset
Email
sign
In
sign
Out
sign
Up
submit
New
Password
Constructors
constructor
new default
(
)
:
default
Returns
default
Properties
Static
Components
Override
Provider
Components
Override
Provider
:
FC
<
PropsWithChildren
<
{
components
:
ComponentOverrideMap
}
>
>
= RecipeComponentsOverrideContextProvider
Methods
Static
does
Email
Exist
does
Email
Exist
(
input
:
{
email
:
string
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
)
:
Promise
<
{
doesExist
:
boolean
;
fetchResponse
:
Response
;
status
:
"OK"
}
>
Parameters
input:
{
email
:
string
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
email
:
string
Optional
options
?:
RecipeFunctionOptions
Optional
user
Context
?:
UserContext
Returns
Promise
<
{
doesExist
:
boolean
;
fetchResponse
:
Response
;
status
:
"OK"
}
>
Static
get
Reset
Password
Token
FromURL
get
Reset
Password
Token
FromURL
(
input
?:
{
userContext
?:
UserContext
}
)
:
string
Parameters
Optional
input:
{
userContext
?:
UserContext
}
Optional
user
Context
?:
UserContext
Returns
string
Static
init
init
(
config
?:
UserInput
)
:
RecipeInitResult
<
GetRedirectionURLContext
,
PreAndPostAPIHookAction
,
OnHandleEventContext
,
NormalisedConfig
>
Parameters
Optional
config:
UserInput
Returns
RecipeInitResult
<
GetRedirectionURLContext
,
PreAndPostAPIHookAction
,
OnHandleEventContext
,
NormalisedConfig
>
Static
send
Password
Reset
Email
send
Password
Reset
Email
(
input
:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
)
:
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
|
"PASSWORD_RESET_NOT_ALLOWED"
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
>
Parameters
input:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
form
Fields
:
{
id
:
string
;
value
:
string
}
[]
Optional
options
?:
RecipeFunctionOptions
Optional
user
Context
?:
UserContext
Returns
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
|
"PASSWORD_RESET_NOT_ALLOWED"
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
>
Static
sign
In
sign
In
(
input
:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
)
:
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
;
user
:
User
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
|
{
fetchResponse
:
Response
;
status
:
"WRONG_CREDENTIALS_ERROR"
}
|
{
fetchResponse
:
Response
;
reason
:
string
;
status
:
"SIGN_IN_NOT_ALLOWED"
}
>
Parameters
input:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
form
Fields
:
{
id
:
string
;
value
:
string
}
[]
Optional
options
?:
RecipeFunctionOptions
Optional
user
Context
?:
UserContext
Returns
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
;
user
:
User
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
|
{
fetchResponse
:
Response
;
status
:
"WRONG_CREDENTIALS_ERROR"
}
|
{
fetchResponse
:
Response
;
reason
:
string
;
status
:
"SIGN_IN_NOT_ALLOWED"
}
>
Static
sign
Out
sign
Out
(
input
?:
{
userContext
?:
UserContext
}
)
:
Promise
<
void
>
Parameters
Optional
input:
{
userContext
?:
UserContext
}
Optional
user
Context
?:
UserContext
Returns
Promise
<
void
>
Static
sign
Up
sign
Up
(
input
:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
)
:
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
;
user
:
User
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
|
{
fetchResponse
:
Response
;
reason
:
string
;
status
:
"SIGN_UP_NOT_ALLOWED"
}
>
Parameters
input:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
form
Fields
:
{
id
:
string
;
value
:
string
}
[]
Optional
options
?:
RecipeFunctionOptions
Optional
user
Context
?:
UserContext
Returns
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
;
user
:
User
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
|
{
fetchResponse
:
Response
;
reason
:
string
;
status
:
"SIGN_UP_NOT_ALLOWED"
}
>
Static
submit
New
Password
submit
New
Password
(
input
:
{
formFields
:
{
id
:
string
;
value
:
string
}
[]
;
options
?:
RecipeFunctionOptions
;
userContext
?:
UserContext
}
)
:
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
}
|
{
fetchResponse
:
Response
;
status
:
"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
?:
UserContext
}
form
Fields
:
{
id
:
string
;
value
:
string
}
[]
Optional
options
?:
RecipeFunctionOptions
Optional
user
Context
?:
UserContext
Returns
Promise
<
{
fetchResponse
:
Response
;
status
:
"OK"
}
|
{
fetchResponse
:
Response
;
status
:
"RESET_PASSWORD_INVALID_TOKEN_ERROR"
}
|
{
fetchResponse
:
Response
;
formFields
:
{
error
:
string
;
id
:
string
}
[]
;
status
:
"FIELD_ERROR"
}
>
Modules
date
Provider
index
recipe/auth
Recipe
recipe/emailpassword
recipe/emailverification
recipe/multifactorauth
recipe/multitenancy
recipe/passwordless
recipe/recipe
Module
recipe/session
recipe/thirdparty
recipe/totp
recipe/userroles
default
constructor
Components
Override
Provider
does
Email
Exist
get
Reset
Password
Token
FromURL
init
send
Password
Reset
Email
sign
In
sign
Out
sign
Up
submit
New
Password
Generated using
TypeDoc