Failed Sending Notification with "error": "Cannot read property 'slice' of undefined, line:27, col:13"


Suddenly we start seeing an error is the logs of type Failed Sending Notification and we checked log details it was due to Cannot read property 'slice' of undefined, line:27, col:13.

I still don’t know the source of that error. I’ve checked our DB Connections → Custom which is enabled, but there is no use of .slice over there. So where is the error coming from? or how could we know exactly the source of that?


Hi @feras.allaou,

Welcome to the Auth0 Community!

Can you post the entirety of the error (omitting sensitive data)?

Hey @dan.woda

Here is the whole error log

  "date": "2022-03-18T22:04:16.238Z",
  "type": "fn",
  "description": "",
  "connection": "xxxx-xxxx-identity-store",
  "connection_id": "",
  "client_id": "xxxx",
  "details": {
    "email_type": "verify_email",
    "to": "",
    "error": "Cannot read property 'slice' of undefined, line:27, col:13"
  "log_id": "90020220318220421419459052756769622269433241827033481282",
  "_id": "90020220318220421419459052756769622269433241827033481282",

Hey @dan.woda

Managed to find the source of the issue which was coming from Email Verification Template. I wish the error messages where more descriptive. Also, the weird thing is that when we call the resend API /api/v2/jobs/verification-email it works without showing any issue, just the automated verification email that is being sent by Auth0 after creating a new User.

Thanks a lot for your assistance :pray:t2:

Great, glad you found a resolution. It looks like the log gives a direct reference to the source of the issue, the verify_email notification. What would you like to see to be more descriptive? I’d be happy to pass the feedback along.

Hey again,

Well, now it make sense actually. I mean verify_email is mentioned in the error log but didn’t first it was a bit vague like is it related to template or custom DB connection scripts or what exactly. I think mentioning the source of the issue like the Email template name, or the file that it occurred on might make it easier to debug in that case.

Thanks again for your prompt assistance :slight_smile:

1 Like

Thanks for the added context!