Inbound Action with invalid user

simonvolkwe
Tera Expert

Hello Community,

 

I am currently working on Inbound email actions for the creation of an incident.

 

We want to change the Inbound Action so it will create an Incident even when the Inbound action can't find a User for this email address in the system. 

I changed the script so when the User is not found via email, the Incident will still be created but with a generic "Guest User" Account.

 

My problem is, somehow there is a second check for the user outside of the Inbound Action and I am apparently unable to find it. Because i have this Error Message: " Skipping script 'Create Incident', user cannot be resolved "   and i want to know where exactly does this message come from? 

 

Greetings

Simon

 

8 REPLIES 8

Siddhesh Wani1
Tera Guru

hi @simonvolkwe ,

Try this script 

 

    var userID = gs.getUserID();
    if (userID) {
        current.opened_for = userID;
    } else {
        current.opened_for = gs.getProperty('guest.user.sysid'); // guest | Guest
    }


If this helped to answer your query, please mark it helpful & accept the solution.
Thanks
Siddhesh

Hi thank you for you answer, but not sure what I should do with the script above, I need an answer for this

Error Message: " Skipping script 'Create Incident', user cannot be resolved "   and I want to know where exactly does this message come from? 

 

Greetings

Simon

 

Common cause of this are 

 

Inactive or locked-out user: 

The sender's email address might be linked to a user account that is either inactive or locked out in ServiceNow. Inbound actions are generally not processed for such users.

Invalid email address format: 
The email address in the "From" field might contain invalid characters (e.g., underscores in the domain part), preventing ServiceNow from resolving it to a valid user.
User not found in the system: 
The email address in the "From" field might not correspond to any existing user record in ServiceNow.

Try the above script to solve your issue.

Hi thank you again,

 

Maybe I didn't describe the question well enough. I want to know where exactly in the script this error message is generated. I do NOT want to know why this error message is thrown.