Auth0 password change with actions


I found a solution for the problem, but it is for hooks (Sending password change email instead of verification email for a new user - #3 by stephanie.chamblee).
Is there one for actions?

I adjusted the hook code to the actions version but get the following error messag:

Test Results
  "message": "authClient.requestChangePasswordEmail is not a function",
  "name": "TypeError",
  "stack": "TypeError: authClient.requestChangePasswordEmail is not a function\n    at exports.onExecutePostUserRegistration (/data/io/node18-actions/eb0226ed-9d75-4aab-938f-39324a6ea7de/webtask.js:20:14)\n    at /data/io/0c8366ec199636bd5aa9715551a2d91fb6316755.js:7:907\n    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)"

Kind regards,

David Bos

I am experiencing the same issue with what should be very basic code. What are we missing???

exports.onExecutePostLogin = async (event) => {
if ( !== undefined) {
    const auth0 = require('auth0');
    const authClient = new auth0.AuthenticationClient({
      domain: event.secrets.domain,
      clientId: event.secrets.clientId

  const userAndConnection = {
      connection: 'Username-Password-Authentication'

  // Send password change email
    await authClient.requestChangePasswordEmail(userAndConnection, (err) => {

Hello there,

I am facing the exact same issue and did not find a solution to this so far. or @adminiot were you able to figure this out?

Any help would be highly appreciated!