Search
Preparing search index...
The search index is not available
supertokens-node
Options
All
Public
Public/Protected
All
Inherited
Externals
Menu
supertokens-node
recipe/thirdpartypasswordless
default
Class default
Hierarchy
default
Index
Constructors
constructor
Properties
Apple
Bitbucket
Discord
Error
Facebook
Git
Lab
Github
Google
Google
Workspaces
init
Methods
consume
Code
create
Code
create
Magic
Link
create
New
Code
For
Device
get
User
By
Id
get
User
By
Phone
Number
get
User
By
Third
Party
Info
get
Users
By
Email
list
Codes
By
Device
Id
list
Codes
By
Email
list
Codes
By
Phone
Number
list
Codes
By
Pre
Auth
Session
Id
passwordless
Sign
In
Up
revoke
All
Codes
revoke
Code
send
Email
send
Sms
third
Party
Sign
In
Up
update
Passwordless
User
Constructors
constructor
new default
(
)
:
default
Returns
default
Properties
Static
Apple
Apple
:
(
config
:
TypeThirdPartyProviderAppleConfig
)
=>
TypeProvider
= thirdPartyProviders.Apple
Type declaration
(
config
:
TypeThirdPartyProviderAppleConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderAppleConfig
Returns
TypeProvider
Static
Bitbucket
Bitbucket
:
(
config
:
TypeThirdPartyProviderBitbucketConfig
)
=>
TypeProvider
= thirdPartyProviders.Bitbucket
Type declaration
(
config
:
TypeThirdPartyProviderBitbucketConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderBitbucketConfig
Returns
TypeProvider
Static
Discord
Discord
:
(
config
:
TypeThirdPartyProviderDiscordConfig
)
=>
TypeProvider
= thirdPartyProviders.Discord
Type declaration
(
config
:
TypeThirdPartyProviderDiscordConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderDiscordConfig
Returns
TypeProvider
Static
Error
Error
:
typeof
default
= SuperTokensError
Static
Facebook
Facebook
:
(
config
:
TypeThirdPartyProviderFacebookConfig
)
=>
TypeProvider
= thirdPartyProviders.Facebook
Type declaration
(
config
:
TypeThirdPartyProviderFacebookConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderFacebookConfig
Returns
TypeProvider
Static
Git
Lab
Git
Lab
:
(
config
:
TypeThirdPartyProviderGitLabConfig
)
=>
TypeProvider
= thirdPartyProviders.GitLab
Type declaration
(
config
:
TypeThirdPartyProviderGitLabConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderGitLabConfig
Returns
TypeProvider
Static
Github
Github
:
(
config
:
TypeThirdPartyProviderGithubConfig
)
=>
TypeProvider
= thirdPartyProviders.Github
Type declaration
(
config
:
TypeThirdPartyProviderGithubConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderGithubConfig
Returns
TypeProvider
Static
Google
Google
:
(
config
:
TypeThirdPartyProviderGoogleConfig
)
=>
TypeProvider
= thirdPartyProviders.Google
Type declaration
(
config
:
TypeThirdPartyProviderGoogleConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderGoogleConfig
Returns
TypeProvider
Static
Google
Workspaces
Google
Workspaces
:
(
config
:
TypeThirdPartyProviderGoogleWorkspacesConfig
)
=>
TypeProvider
= thirdPartyProviders.GoogleWorkspaces
Type declaration
(
config
:
TypeThirdPartyProviderGoogleWorkspacesConfig
)
:
TypeProvider
Parameters
config:
TypeThirdPartyProviderGoogleWorkspacesConfig
Returns
TypeProvider
Static
init
init
:
(
config
:
TypeInput
)
=>
RecipeListFunction
= Recipe.init
Type declaration
(
config
:
TypeInput
)
:
RecipeListFunction
Parameters
config:
TypeInput
Returns
RecipeListFunction
Methods
Static
consume
Code
consume
Code
(
input
:
{
deviceId
:
string
;
preAuthSessionId
:
string
;
userContext
?:
any
;
userInputCode
:
string
}
|
{
linkCode
:
string
;
preAuthSessionId
:
string
;
userContext
?:
any
}
)
:
Promise
<
{
createdNewUser
:
boolean
;
status
:
"OK"
;
user
:
User
}
|
{
failedCodeInputAttemptCount
:
number
;
maximumCodeInputAttempts
:
number
;
status
:
"INCORRECT_USER_INPUT_CODE_ERROR"
|
"EXPIRED_USER_INPUT_CODE_ERROR"
}
|
{
status
:
"RESTART_FLOW_ERROR"
}
>
Parameters
input:
{
deviceId
:
string
;
preAuthSessionId
:
string
;
userContext
?:
any
;
userInputCode
:
string
}
|
{
linkCode
:
string
;
preAuthSessionId
:
string
;
userContext
?:
any
}
Returns
Promise
<
{
createdNewUser
:
boolean
;
status
:
"OK"
;
user
:
User
}
|
{
failedCodeInputAttemptCount
:
number
;
maximumCodeInputAttempts
:
number
;
status
:
"INCORRECT_USER_INPUT_CODE_ERROR"
|
"EXPIRED_USER_INPUT_CODE_ERROR"
}
|
{
status
:
"RESTART_FLOW_ERROR"
}
>
Static
create
Code
create
Code
(
input
:
(
{
email
:
string
}
&
{
userContext
?:
any
;
userInputCode
?:
string
}
)
&
(
{
phoneNumber
:
string
}
&
{
userContext
?:
any
;
userInputCode
?:
string
}
)
)
:
Promise
<
{
codeId
:
string
;
codeLifetime
:
number
;
deviceId
:
string
;
linkCode
:
string
;
preAuthSessionId
:
string
;
status
:
"OK"
;
timeCreated
:
number
;
userInputCode
:
string
}
>
Parameters
input:
(
{
email
:
string
}
&
{
userContext
?:
any
;
userInputCode
?:
string
}
)
&
(
{
phoneNumber
:
string
}
&
{
userContext
?:
any
;
userInputCode
?:
string
}
)
Returns
Promise
<
{
codeId
:
string
;
codeLifetime
:
number
;
deviceId
:
string
;
linkCode
:
string
;
preAuthSessionId
:
string
;
status
:
"OK"
;
timeCreated
:
number
;
userInputCode
:
string
}
>
Static
create
Magic
Link
create
Magic
Link
(
input
:
{
email
:
string
;
userContext
?:
any
}
|
{
phoneNumber
:
string
;
userContext
?:
any
}
)
:
Promise
<
string
>
Parameters
input:
{
email
:
string
;
userContext
?:
any
}
|
{
phoneNumber
:
string
;
userContext
?:
any
}
Returns
Promise
<
string
>
Static
create
New
Code
For
Device
create
New
Code
For
Device
(
input
:
{
deviceId
:
string
;
userContext
?:
any
;
userInputCode
?:
string
}
)
:
Promise
<
{
codeId
:
string
;
codeLifetime
:
number
;
deviceId
:
string
;
linkCode
:
string
;
preAuthSessionId
:
string
;
status
:
"OK"
;
timeCreated
:
number
;
userInputCode
:
string
}
|
{
status
:
"RESTART_FLOW_ERROR"
|
"USER_INPUT_CODE_ALREADY_USED_ERROR"
}
>
Parameters
input:
{
deviceId
:
string
;
userContext
?:
any
;
userInputCode
?:
string
}
device
Id
:
string
Optional
user
Context
?:
any
Optional
user
Input
Code
?:
string
Returns
Promise
<
{
codeId
:
string
;
codeLifetime
:
number
;
deviceId
:
string
;
linkCode
:
string
;
preAuthSessionId
:
string
;
status
:
"OK"
;
timeCreated
:
number
;
userInputCode
:
string
}
|
{
status
:
"RESTART_FLOW_ERROR"
|
"USER_INPUT_CODE_ALREADY_USED_ERROR"
}
>
Static
get
User
By
Id
get
User
By
Id
(
userId
:
string
, userContext
?:
any
)
:
Promise
<
undefined
|
User
>
Parameters
userId:
string
userContext:
any
= {}
Returns
Promise
<
undefined
|
User
>
Static
get
User
By
Phone
Number
get
User
By
Phone
Number
(
input
:
{
phoneNumber
:
string
;
userContext
?:
any
}
)
:
Promise
<
undefined
|
User
>
Parameters
input:
{
phoneNumber
:
string
;
userContext
?:
any
}
phone
Number
:
string
Optional
user
Context
?:
any
Returns
Promise
<
undefined
|
User
>
Static
get
User
By
Third
Party
Info
get
User
By
Third
Party
Info
(
thirdPartyId
:
string
, thirdPartyUserId
:
string
, userContext
?:
any
)
:
Promise
<
undefined
|
User
>
Parameters
thirdPartyId:
string
thirdPartyUserId:
string
userContext:
any
= {}
Returns
Promise
<
undefined
|
User
>
Static
get
Users
By
Email
get
Users
By
Email
(
email
:
string
, userContext
?:
any
)
:
Promise
<
User
[]
>
Parameters
email:
string
userContext:
any
= {}
Returns
Promise
<
User
[]
>
Static
list
Codes
By
Device
Id
list
Codes
By
Device
Id
(
input
:
{
deviceId
:
string
;
userContext
?:
any
}
)
:
Promise
<
undefined
|
DeviceType
>
Parameters
input:
{
deviceId
:
string
;
userContext
?:
any
}
device
Id
:
string
Optional
user
Context
?:
any
Returns
Promise
<
undefined
|
DeviceType
>
Static
list
Codes
By
Email
list
Codes
By
Email
(
input
:
{
email
:
string
;
userContext
?:
any
}
)
:
Promise
<
DeviceType
[]
>
Parameters
input:
{
email
:
string
;
userContext
?:
any
}
email
:
string
Optional
user
Context
?:
any
Returns
Promise
<
DeviceType
[]
>
Static
list
Codes
By
Phone
Number
list
Codes
By
Phone
Number
(
input
:
{
phoneNumber
:
string
;
userContext
?:
any
}
)
:
Promise
<
DeviceType
[]
>
Parameters
input:
{
phoneNumber
:
string
;
userContext
?:
any
}
phone
Number
:
string
Optional
user
Context
?:
any
Returns
Promise
<
DeviceType
[]
>
Static
list
Codes
By
Pre
Auth
Session
Id
list
Codes
By
Pre
Auth
Session
Id
(
input
:
{
preAuthSessionId
:
string
;
userContext
?:
any
}
)
:
Promise
<
undefined
|
DeviceType
>
Parameters
input:
{
preAuthSessionId
:
string
;
userContext
?:
any
}
pre
Auth
Session
Id
:
string
Optional
user
Context
?:
any
Returns
Promise
<
undefined
|
DeviceType
>
Static
passwordless
Sign
In
Up
passwordless
Sign
In
Up
(
input
:
{
email
:
string
;
userContext
?:
any
}
|
{
phoneNumber
:
string
;
userContext
?:
any
}
)
:
Promise
<
{
createdNewUser
:
boolean
;
status
:
string
;
user
:
User
}
>
Parameters
input:
{
email
:
string
;
userContext
?:
any
}
|
{
phoneNumber
:
string
;
userContext
?:
any
}
Returns
Promise
<
{
createdNewUser
:
boolean
;
status
:
string
;
user
:
User
}
>
Static
revoke
All
Codes
revoke
All
Codes
(
input
:
{
email
:
string
;
userContext
?:
any
}
|
{
phoneNumber
:
string
;
userContext
?:
any
}
)
:
Promise
<
{
status
:
"OK"
}
>
Parameters
input:
{
email
:
string
;
userContext
?:
any
}
|
{
phoneNumber
:
string
;
userContext
?:
any
}
Returns
Promise
<
{
status
:
"OK"
}
>
Static
revoke
Code
revoke
Code
(
input
:
{
codeId
:
string
;
userContext
?:
any
}
)
:
Promise
<
{
status
:
"OK"
}
>
Parameters
input:
{
codeId
:
string
;
userContext
?:
any
}
code
Id
:
string
Optional
user
Context
?:
any
Returns
Promise
<
{
status
:
"OK"
}
>
Static
send
Email
send
Email
(
input
:
TypePasswordlessEmailDeliveryInput
&
{
userContext
?:
any
}
)
:
Promise
<
void
>
Parameters
input:
TypePasswordlessEmailDeliveryInput
&
{
userContext
?:
any
}
Returns
Promise
<
void
>
Static
send
Sms
send
Sms
(
input
:
TypePasswordlessSmsDeliveryInput
&
{
userContext
?:
any
}
)
:
Promise
<
void
>
Parameters
input:
TypePasswordlessSmsDeliveryInput
&
{
userContext
?:
any
}
Returns
Promise
<
void
>
Static
third
Party
Sign
In
Up
third
Party
Sign
In
Up
(
thirdPartyId
:
string
, thirdPartyUserId
:
string
, email
:
string
, userContext
?:
any
)
:
Promise
<
{
createdNewUser
:
boolean
;
status
:
"OK"
;
user
:
User
}
>
Parameters
thirdPartyId:
string
thirdPartyUserId:
string
email:
string
userContext:
any
= {}
Returns
Promise
<
{
createdNewUser
:
boolean
;
status
:
"OK"
;
user
:
User
}
>
Static
update
Passwordless
User
update
Passwordless
User
(
input
:
{
email
?:
null
|
string
;
phoneNumber
?:
null
|
string
;
userContext
?:
any
;
userId
:
string
}
)
:
Promise
<
{
status
:
"OK"
|
"EMAIL_ALREADY_EXISTS_ERROR"
|
"UNKNOWN_USER_ID_ERROR"
|
"PHONE_NUMBER_ALREADY_EXISTS_ERROR"
}
>
Parameters
input:
{
email
?:
null
|
string
;
phoneNumber
?:
null
|
string
;
userContext
?:
any
;
userId
:
string
}
Optional
email
?:
null
|
string
Optional
phone
Number
?:
null
|
string
Optional
user
Context
?:
any
user
Id
:
string
Returns
Promise
<
{
status
:
"OK"
|
"EMAIL_ALREADY_EXISTS_ERROR"
|
"UNKNOWN_USER_ID_ERROR"
|
"PHONE_NUMBER_ALREADY_EXISTS_ERROR"
}
>
Modules
framework
framework/aws
Lambda
framework/express
framework/fastify
framework/hapi
framework/koa
framework/loopback
index
ingredients/emaildelivery
ingredients/smsdelivery
recipe/dashboard
recipe/emailpassword
recipe/emailverification
recipe/jwt
recipe/openid
recipe/passwordless
recipe/session
recipe/thirdparty
recipe/thirdpartyemailpassword
recipe/thirdpartypasswordless
recipe/usermetadata
recipe/userroles
default
constructor
Apple
Bitbucket
Discord
Error
Facebook
Git
Lab
Github
Google
Google
Workspaces
init
consume
Code
create
Code
create
Magic
Link
create
New
Code
For
Device
get
User
By
Id
get
User
By
Phone
Number
get
User
By
Third
Party
Info
get
Users
By
Email
list
Codes
By
Device
Id
list
Codes
By
Email
list
Codes
By
Phone
Number
list
Codes
By
Pre
Auth
Session
Id
passwordless
Sign
In
Up
revoke
All
Codes
revoke
Code
send
Email
send
Sms
third
Party
Sign
In
Up
update
Passwordless
User
Generated using
TypeDoc