cancel
Showing results for 
Search instead for 
Did you mean: 

how to pass text message as a body in mail adapter

Former Member
0 Kudos

Hi ,

I configued mail adapter and I am receiving the message as xml attachments.But I need to get message in body as text formate not an xml message.

for exaple I am getting the message like this as attachment

<?xml version="1.0" encoding="UTF-8" ?>

<ns0:MT_MAIL xmlns:ns0="http://it.com/FI/I001">

-<MAIL>

<A>

<FILE>PLEASE KEEP THE FILE</FILE>

</A>

<B>

<FILE>PLEASE KEEP FILE</FILE>

</B>

</MAIL>

</ns0:MT_MAIL>

I required message in MAIL BODY ( NO attachment) like below

A PLEASE KEEP THE FILE

B PLEASE KEEP THE FILE

LIKE THAT I NEED MY OUTPUT IN MAIL BODY ...

PLEASE GUID HOW TO PROCEED ....

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member200962
Active Contributor
0 Kudos

Use PayloadSwap bean and read the attachment...on the receiver end make use of Mail package and in the mapping concat the contents of FILE field....you may need to use a UDF for this....then stuff this into the Content field of the Mail package...in receiver channel use XIPAYLOAD....

Regards,

Abhishek.

Former Member
0 Kudos

Can U plz ellobrate it

former_member200962
Active Contributor
0 Kudos

PayloadSwap Bean to read contents of the attachment: /people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step

XIPAYLOAD is protocol to be used in the mail channel...many blogs available for how to send mail as body.

Regards,

Abhishek.