Auth0 Home Blog Docs

Error 500 pre-registration hook

error
pre-user-registratio

#1

hi I m trying to use aws-sdk module in pre-registration hook

but I got this error:

{
“message”: “Unable to compile the extensibility code as javascript”,
“statusCode”: 500,
“error_description”: “Unable to compile the extensibility code as javascript”,
“stack”: “SyntaxError: Unable to compile the extensibility code as javascript\n at Object.exports.runInThisContext (vm.js:53:16)\n at WebtaskModule.compileWebtask (/data/sandbox/lib/module.js:91:32)\n at Object.defaultJavascriptCompiler [as nodejsCompiler] (/data/sandbox/lib/compiler.js:124:30)\n at extensibilityPointCompiler (/data/sandbox/node_modules/auth0-ext-compilers/lib/compilers/compilerFactory.js:24:17)\n at /data/sandbox/lib/compiler.js:236:17\n at /data/sandbox/node_modules/async/dist/async.js:3866:24\n at replenish (/data/sandbox/node_modules/async/dist/async.js:998:17)\n at iterateeCallback (/data/sandbox/node_modules/async/dist/async.js:983:17)\n at /data/sandbox/node_modules/async/dist/async.js:958:16\n at /data/sandbox/node_modules/async/dist/async.js:3871:13”
}


#2

The error would seem to point to some kind of issue with the hook’s code as the most likely source of the issue, however, you did not include the relevant code and any steps to create the hook which could allow for additional troubleshooting.


#3