Inbound action Allow Watch list user to update incidents without an account

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-03-2024 04:44 PM - edited 06-17-2025 11:15 AM
We currently have licensing for CSM but we have not implemented it yet. So we don't account accounts for a lot of our external users. They would like to be able to use comments instead of the formatted email. Is there a way that if we add the users email to the watch list we can get the system to allow replies to update the incident? As of right now the email that come in from these users get set to received-ignore because they don't have an account.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-17-2025 03:56 PM
Ok I figured out a business rule that allows me to add the inbound email into the comments. The business rule runs on the sys_email table with the following conditions.
And then the following code in the advanced script.
(function executeRule(current, previous /*null when async*/) {
// Add your code here
var subject = current.subject.toString().split(" ");
taskNumber = subject[3];
var table = "";
if (taskNumber.startsWith("INC")){
table = "incident";
}
else if (taskNumber.startsWith("RITM")){
table = "sc_req_item";
}
if (table != ""){
var gr = new GlideRecord(table);
gr.addQuery("number", taskNumber);
gr.addActiveQuery();
gr.query();
if (gr.next()){
if (gr.watch_list.toString().indexOf(current.user) > - 1){
gr.comments = "reply from: " + current.user + "\n\n" + current.body_text.toString();
gr.update();
}
}
}
})(current, previous);
This is working however since the comments are being set as being updated by the system it is sending the notification to both the watch list user who just replied as well as the assigned to. We have the notification set to not send to the event creator so how do I get the comments to show that they were updated by the person who sent the email? I was able to set with the following code the updated by and updated on for the incident but the comments still say they were updated by the system. These lines of code are right before gr.comments =... in the above script.
gr.autoSysFields(false);
gr.sys_updated_by = current.user;
gr.sys_updated_on = gs.nowDateTime();