I was trying to write a hook, which gets triggered on change password event. When I try to test it, I am getting “Network error”. Is there a way I can test the url connectivity from Auth0.
My application callback to my system works fine. But for some reason, the hook does not.
module.exports = function (user, context, cb) {
console.log(‘Will make the request’);
const request = require(‘ajax-request’);
const sendgridApiKey = context.webtask.secrets.SENDGRID_API_KEY;
request({
url: ‘’,
method: ‘POST’,
headers: {‘Authorization’: 'Bearer ’ + sendgridApiKey},
data: {
query1: ‘value1’
}
}, function(err, res, body) {
console.log(“Finished execution”);
return cb(null);
});
};