create escalate incident from survey response

Ravivarman Saee
Tera Contributor

currently we are sending a satisfaction survey through a mail to the caller (user) when his incident is resolved. When the user selects dissatisfied, a respond (inbound) email will be sent to servicenow(our instance). i want that response email sent to another particular group email id as well. how to do ?

 

12 REPLIES 12

Harish KM
Kilo Patron
Kilo Patron

Hi @Ravivarman Saee you need to create a after update BR on this table asmt_assessment_instance

 

sample script below

var metric;
var answer;
var getStrValue;
var surveyResponse = new GlideRecord('asmt_assessment_instance_question');
surveyResponse.addQuery('instance', current.sys_id);
surveyResponse.query();
while (surveyResponse.next()) {
metric = surveyResponse.getDisplayValue('metric'); // get Question Name
answer = surveyResponse.value; // get response value
getStrValue = surveyResponse.getValue('string_value');

// check your survey question
if (metric == 'your survey question') {
if (answer == "dissatisfied") {
// create incident here
}
}
}

Regards
Harish

HI @Harish KM ,


Thanks for the suggestion. Actually i misinterpreted the question. When the user selects dissatisfied, a feedback mail will be sent to servicenow. i want that response email sent to another particular group email id and create an escalation email as well.

Hi @Ravivarman Saee how does this happen?

a feedback mail will be sent to servicenow. --> is it through inbound email action?

Regards
Harish

yes an inbound email is recieved. i need to add another email id to that inbound email. That is sufficient