How do I make an inbound action ignore something

johnfeist
Mega Sage
Mega Sage

We have a couple of services that are sending their logs to our ServiceNow instance.  At one point that was necessary.  We are having issues getting them to stop sending.

I have our inbound action for new set up with a typical if this then put it there type of logic.  At the end is a catch all for everything that didn't get assigned elsewhere.  If I have the last step logic trap everything but these logs and do nothing with the logs will they just drop off into never never land or will the system still try to create an incident? 

If that doesn't work, how can I have the logic ignore the logs? (I can't just block the sender.)

Thanks for any suggestions.

:{)

Hope that helps.

:{)

Helpful and Correct tags are appreciated and help others to find information faster
1 ACCEPTED SOLUTION

Mike Patel
Tera Sage

If it's coming from specific user account or to specific email than you can create inbound action and set stop processing checkbox.

How can you identify it's another system sending logs? Do you have any standard short description or anything body?

View solution in original post

5 REPLIES 5

Hi John,

Using a business rule would be a little bit different.  You're working with the current record instead of an email object, and don't have access to the same properties presented by that object.  In the Emails table ([sys_email]), there are a couple of scenarios to consider.

  1. If the sender exists as a user on your instance, the User ID field (current.user_id) will display their record (as reference) and the User field (current.user) will contain their sys_id.
  2. If the sender does not have a user record on your instance, the User ID field (current.user_id) will be empty, and the User field (current.user) will contain the sender's email address.

So, assuming the second scenario (no user record for your service account), you could create a before Business Rule (on insert) with filter condition that User ID is empty, and then have it check in the script for your sender address within current.user:

if(current.user.indexOf('service_email@yourdomain.com) != -1){
    current.type = 'received-ignored';
}

That's how I would approach it.

 

Thanks,

-Brian