Parsing email body with Inbound Email Flows

Mark Roethof
Tera Patron
Tera Patron

Hi all,

Just playing around a bit with Inbound Email Flows. To get a feeling for moving from Inbound Actions to Inbound Email Flows. Setting up an Inbound Email Flow works pretty quick, Incoming mail is processed, no worries.

Though…
What about parsing the email body? With Inbound Actions you could use something like "current.body.number", "current.body.something", to get the value on a line in your email body after for example "Number: ", "Something: ", etc..

How to achieve this with Inbound Email Flows?
I tried using for example:
fd_data.trigger.body.number;
fd_data.trigger.body_text.number;

Only this just returns null.

Any ideas? Or is it just like this does not work for Inbound Email Flows and you would need to parse the whole body_text or body?

Kind regards,
Mark

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

1 ACCEPTED SOLUTION

Mark Roethof
Tera Patron
Tera Patron

Also with Paris no proper solution for this. Or solution... stick with old school Inbound Actions.

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

View solution in original post

18 REPLIES 18

jonahpiascik, have you had a chance to figure out how to use the Parse Email Flow Action? 
 

I was actually just playing around with it.  The email I was parsing had a lot of HTML in it, and most of the name:value data was not very clean (lot's of single quotes and spaces in the names).  It did parse some of it though...just not sure how to use it in the flow.  Going to build out a simpler test email to see if it works in the more traditional sense (assigned_to=user name).

I was just thinking about this today.  How is it that inbound actions does it so well?  Do they just have more precise code that's obfuscated from view?

I got the Parse Email Flow Action to work.  Folk over at #SNDEVS helped me out.  Pretty simple once you figure out where all the nougats are...

1) Use the Parse Email Body Text Flow Action to parse the Trigger>Email Record
2) Use the Email Variables with an inline transform function, utilizing the OOB 'Get item from Name/Values' Transform from the Utilities section. (HINT" use the f(x) in the data pill to access the inline transform function).

find_real_file.png

Wait... so all the components are there already?  It was just a matter of uttering the right incantation?