Problem statement
This article explains why some users fail to log in via a flow with the following error:
"type": "f",
"description": "management.sendEmailVerification is not a function",
Solution
The management.sendEmailVerification
method has been deprecated from our Node SDK.
- The Node package version the action is running is “auth0@4.1.0”, which is documented in the Auth0 GitHub public library.
- The
sendEmailVerification
does not exist anymore in this version. However, it does exist in the previous version “3.7.1”.
There are two possible workarounds to this error:
- Use in the action the auth0 node version of 3.7.1 that includes the
sendEmailVerification
. Add the dependency to this previous version like below:
- Add version 3.7.1 to the dependency in Auth0 This will force your ManagementClient to use the previous version:
const ManagementClient = require('auth0').ManagementClient;
- Adapt your code to the new 4.1.0 node (or latest) version. The
sendEmailVerification
was migrated tojob.verifyEmail
, see v4_MIGRATION_GUIDE.md for more information.
- The
jobs.verifyEmail
Is documented under the JobsManager class.