Shamma Negi
Kilo Sage

Hi All,

 

I have recently found that when "email_body_text" contains "From:" the inbound action will trim the text  starting with "From:"

 

Example:

 

1. You have a inbound email with below text:

 

Hi user, Yes, will do. From: IT Service Desk <xxx@service-now.com> Sent: Friday, May 21, 2021 9:19 AM To: User 1 <user1@example.com> Subject: Incident INC0207486 -- comments added [cid:image001.png@01D752E5.4BF4C5C0] Short or attachment.

 

2. Have an inbound action with next lines:
var trimmed = email.body_text.toString();
gs.log('Before = ' + trimmed + ', index = ' + trimmed.indexOf("From:"));
//trimmed = trimmed.substring(0, trimmed.indexOf("From:"));
gs.log('After = ' + trimmed);

3. Process or Reprocess the email

4. The result will be in the system logs Quebec:
2023-05-27 08:22:32 Information Before = Hi user, Yes, will do., index = -1 *** Script

2023-05-27 08:22:32 Information After =

But before Quebec you will see:

2023-05-27 08:22:32 Information Before = Hi user, Yes, will do. From: IT Service Desk <xxx@service-now.com> Sent: Friday, May 21, 2021 9:19 AM To: User 1 <User1@example.com> Subject: Incident INC0207486 -- comments added [cid:image001.png@01D752E5.4BF4C5C0] Short or attachment.<Rachel.Phillips@enstargroup.com> Subject: Incident INC0207486 -- comments added [cid:image001.png@01D752E5.4BF4C5C0] Short or attachment. index = 25

2023-05-27 08:22:32 Information After = Hi user, Yes, will do.

 

Workaround

 

1. The behavior is expected, and it is part of the development of inbound actions parser version 2.0 present in Quebec and onward.

2. As a workaround to create or set (if already exists) system property "glide.email_reply_parser.version" value to 1 and new emails will work in old way before Quebec

 

Thanks,

Shamma Negi