Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How is the body_text of an email message populated?

Michael Domke
Tera Guru

Aspen 07-09-2012_0024

How is the sys_email.body_text field populated? I ask because when viewing an Email record (sys_email), the Body field shows the original and complete HTML content of the email sent in. But, the body_text field shows this: "You need an HTML-capable reader to read this message.".

This is an issue because I'm trying to process the email in an inbound email action and I rely of the body_text for the content.

Does the Content Type matter? The message is being sent in with a content type of "multipart/mixed". Should it be "multipart/alternative"?

Thanks,
Michael

2 REPLIES 2

justin_drysdale
Mega Guru

You are seeing "you need an HTML -capable reader to read this message." within the body_text field on sys_email instead of what is seen in the body field (minus the html tags)? That is odd behavior.

In your instance, what is the field type for body_text? It is set to 'string' in our instance and is working as expected.

I don't think the content type would affect the field this way.


Michael Domke
Tera Guru

Apparently, this is a known issue in ServiceNow and is fixed in the Berlin release.

According to HI:
"...this is a known issue in the Aspen release that was dealt with on PRB568428 and fixed in Berlin. We recommend upgrading to Berlin to resolve this. In the mean time you can create and set a system property called "glide.email.text_plain.strip_xhtml" to true. Please note that you will need to remove that property when you upgrade to Berlin."