auto create incident from email sent to instance and assign

Lydon
Mega Expert

Hello 

 

 

I am in the process of developing a requirement and I did help!

I want to create an incident when a user(s) sends email to the team, for the instance name(LEGA)  to auto-create an incident ticket based on that email and automatically assigned to the incident team 

 

Thank you

1 REPLY 1

Mallidi Suma
Tera Guru

Hi @Lydon ,

 

In Application Navigator go with Inbound Action and search for "create Incident". In that create an incident in Actions you can write the code for inserting an incident ticket along with the static assignment group.

 

Screenshot 2023-06-06 at 2.11.18 AM.png

 

current.assignment_group = "sys_id of your assignment group";

current.insert();

Screenshot 2023-06-06 at 2.11.35 AM.png

 

the above process will only work if the assignment group is static and the email is sent to one of our ServiceNow SMTP email addresses.

 

If they are adding the ServiceNow Assignment group to which the incident got assigned mail address in the CC you can get that in the Actions script of the above Inbound email action by using a syntax.

 

email.copied //This will give the mail address added in the CC

email.to // this will give the To mail address

email.from //this will give the from the mail address

 

Please mark my answer as helpful and accept it as a solution, if it helps you!!