supertokens-node
Preparing search index...
recipe/multifactorauth
RecipeInterface
Type Alias RecipeInterface
type
RecipeInterface
=
{
addToRequiredSecondaryFactorsForUser
:
(
input
:
{
factorId
:
string
;
userContext
:
UserContext
;
userId
:
string
}
,
)
=>
Promise
<
void
>
;
assertAllowedToSetupFactorElseThrowInvalidClaimError
:
(
input
:
{
factorId
:
string
;
factorsSetUpForUser
:
Promise
<
string
[]
>
;
mfaRequirementsForAuth
:
Promise
<
MFARequirementList
>
;
session
:
SessionContainer
;
userContext
:
UserContext
;
}
,
)
=>
Promise
<
void
>
;
getFactorsSetupForUser
:
(
input
:
{
user
:
User
;
userContext
:
UserContext
}
,
)
=>
Promise
<
string
[]
>
;
getMFARequirementsForAuth
:
(
input
:
{
accessTokenPayload
:
JSONObject
;
completedFactors
:
MFAClaimValue
[
"c"
]
;
factorsSetUpForUser
:
Promise
<
string
[]
>
;
requiredSecondaryFactorsForTenant
:
Promise
<
string
[]
>
;
requiredSecondaryFactorsForUser
:
Promise
<
string
[]
>
;
tenantId
:
string
;
user
:
Promise
<
User
>
;
userContext
:
UserContext
;
}
,
)
=>
Promise
<
MFARequirementList
>
|
MFARequirementList
;
getRequiredSecondaryFactorsForUser
:
(
input
:
{
userContext
:
UserContext
;
userId
:
string
}
,
)
=>
Promise
<
string
[]
>
;
markFactorAsCompleteInSession
:
(
input
:
{
factorId
:
string
;
session
:
SessionContainer
;
userContext
:
UserContext
;
}
,
)
=>
Promise
<
void
>
;
removeFromRequiredSecondaryFactorsForUser
:
(
input
:
{
factorId
:
string
;
userContext
:
UserContext
;
userId
:
string
}
,
)
=>
Promise
<
void
>
;
}
Index
Properties
add
To
Required
Secondary
Factors
For
User
assert
Allowed
To
Setup
Factor
Else
Throw
Invalid
Claim
Error
get
Factors
Setup
For
User
getMFARequirements
For
Auth
get
Required
Secondary
Factors
For
User
mark
Factor
As
Complete
In
Session
remove
From
Required
Secondary
Factors
For
User
Properties
add
To
Required
Secondary
Factors
For
User
addToRequiredSecondaryFactorsForUser
:
(
input
:
{
factorId
:
string
;
userContext
:
UserContext
;
userId
:
string
}
,
)
=>
Promise
<
void
>
assert
Allowed
To
Setup
Factor
Else
Throw
Invalid
Claim
Error
assertAllowedToSetupFactorElseThrowInvalidClaimError
:
(
input
:
{
factorId
:
string
;
factorsSetUpForUser
:
Promise
<
string
[]
>
;
mfaRequirementsForAuth
:
Promise
<
MFARequirementList
>
;
session
:
SessionContainer
;
userContext
:
UserContext
;
}
,
)
=>
Promise
<
void
>
get
Factors
Setup
For
User
getFactorsSetupForUser
:
(
input
:
{
user
:
User
;
userContext
:
UserContext
}
,
)
=>
Promise
<
string
[]
>
getMFARequirements
For
Auth
getMFARequirementsForAuth
:
(
input
:
{
accessTokenPayload
:
JSONObject
;
completedFactors
:
MFAClaimValue
[
"c"
]
;
factorsSetUpForUser
:
Promise
<
string
[]
>
;
requiredSecondaryFactorsForTenant
:
Promise
<
string
[]
>
;
requiredSecondaryFactorsForUser
:
Promise
<
string
[]
>
;
tenantId
:
string
;
user
:
Promise
<
User
>
;
userContext
:
UserContext
;
}
,
)
=>
Promise
<
MFARequirementList
>
|
MFARequirementList
get
Required
Secondary
Factors
For
User
getRequiredSecondaryFactorsForUser
:
(
input
:
{
userContext
:
UserContext
;
userId
:
string
}
,
)
=>
Promise
<
string
[]
>
mark
Factor
As
Complete
In
Session
markFactorAsCompleteInSession
:
(
input
:
{
factorId
:
string
;
session
:
SessionContainer
;
userContext
:
UserContext
;
}
,
)
=>
Promise
<
void
>
remove
From
Required
Secondary
Factors
For
User
removeFromRequiredSecondaryFactorsForUser
:
(
input
:
{
factorId
:
string
;
userContext
:
UserContext
;
userId
:
string
}
,
)
=>
Promise
<
void
>
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
On This Page
Properties
add
To
Required
Secondary
Factors
For
User
assert
Allowed
To
Setup
Factor
Else
Throw
Invalid
Claim
Error
get
Factors
Setup
For
User
getMFARequirements
For
Auth
get
Required
Secondary
Factors
For
User
mark
Factor
As
Complete
In
Session
remove
From
Required
Secondary
Factors
For
User
supertokens-node
Loading...