cancel
Showing results for 
Search instead for 
Did you mean: 

Using PI 7.0 to handle moving a PDF document into a SOAP Message & sending

Former Member
0 Kudos

Here is our situation. We have the business writing all invoices for a day out of SAP to disk formatted as a PDF document; meaning, if the file is FTP'd from the disk of SAP to an NT server inside our firewall it is recognised as a PDF by Windows and Adobe.

After we read the PDF, I need to add it as the payload to a SOAP message that will be sent to the web service of a partner out side our firewall. They will extract the PDF from the SOAP Message and print the invoices... stuff the envelopes ... and post them.

I have been trying to use the file adapter to "pick up" the PDF and the SOAP adapter to send... Obviously, it is not working and I need some assistance. I am new to XI, so any advice will be greatly appreciated.

Thanks,

Rich

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Thank you all for your assistance.

former_member181985
Active Contributor
0 Kudos

1.If the partner webservice supports SOAP attachments then you can send the required attachments from FileAdapter by selecting "Additional Files" check box in the File Sender channel.

Check this link: [http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm|http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm]

2.Else if this not the case i.e., you want to send PDF file stream as part of payload then you need to convert the PDF file stream to BASE64 format then map to one of the field of Webservice structure and then post using SOAP Adapter.

Remember the webservice field length should be enough to carry the BASE64 string otherwise the target application will fail to process the data or it will process data by truncating. Also there should be extra funtionality in target webservice for converting BASE64 format to binary format(PDF file).

But in general the webservices will support attachements. So you can go ahead with Case1.

Thanks,

- Gujjeti.

Former Member
0 Kudos

Rich,

What do you mean by sending the pdf in SOAP message?

1. Do you want to read the pdf file and send the content of the pdf file in the soap message? Or

2. Do you want to send the pdf file as an attachment to the receiver Webservice?

Regards

Jai

Former Member
0 Kudos

Hello Jai,

The PDF will be in the message, not an attachment.

Rich

VijayKonam
Active Contributor
0 Kudos

Use the file adapter and enable it for attachments. Specify where it has to look for the file in the channel configuration. Use SOAP adapter for calling the other side web service.

VJ

former_member181985
Active Contributor
0 Kudos

Have you checked my reply.