Help related to Inbound action

aditya174
Tera Guru

Hi I need help to create an inbound action for this mail :

 

 

 

Dear Customer,
 
I am writing to request the renewal of my insurance policy, This is my Policy Number: PLNO12345 and has a Coverage Amount: 50,000, The Expiration Date: 2023-09-27, and the Scheme Name: Comprehensive Coverage.

If you have any questions, please feel free to contact us.

 

 

and I want to extract the Policy number, coverage amount, expiration date, and scheme name and populate it in the ticket.

 

Please help

1 REPLY 1

Uncle Rob
Kilo Patron

Is there any chance you can get the source email to be reformatted.  By default inbound actions create an object you can use in its script called "email".  It extracts name value pairs as properties for the email object.

 

So if an email has....
Policy_Number:  1234
Expiration:  12/12/2024
Scheme_Name: Comprehensive coverage,

 

then the email object in the script will allow you to do things like 
current.expiration = email.Expiration

But they MUST be the exact same name as the field you want to populate
And they MUST be on a line by themselves.

Otherwise, you're going to need some kinda crazy regex to extract the stuff you want.