Dear All,
I need to map the whole source XML in a single contained string Parameter in target structure, before sending to the third party bank URL. Please do not confuse with converting source XML payload to string field warped in XML format, I know lot of blog and discussion available for that on SCN.
As we know during the PI message mapping always the target structure will be wrapped in the XML format , however in my case the target XML structure should be contained in a single string, please the below detail for source and target.
Source structure:-
<?xml version='1.0' ?>
<PaymentInfoMessage>
<PaymentInfoRequest>
<CompanyCode>Partner01</CompanyCode>
<BankCode>BSFRSARI</BankCode>
<StartDate>2006-07-09T00:00:00</StartDate>
<EndDate>2006-07-09T00:00:00</EndDate>
<TransactionType>940</TransactionType>
</PaymentInfoRequest>
</PaymentInfoMessage>
Required Target Structure:-
Please see the below statement is from third party (bank) for target structure from their document.
“You have to build post command with parameter name strXmldata, that parameter will contain the XML request of the accounts statement.
Pseudocode:
replyXML = HTTPS_Post_B2B(”strXmldata=”+ statementReqXMLfile)
processReplyXMLinCORE-SYSTEM(replyXML)
The following is HTML file content, shows how to post that parameter with the statement XML request:
Note: In the following html examples, html used below only as a demonstration of how data can be posted to B2B Gateway (using HTML form tag), This example shows the use of HTML page which can be opened by the Internet browser, to post data, in case you have a program to post requests, you only have to post the XML (in bold), in the parameter named strXmlData.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <HEAD> </HEAD> <BODY> <FORM action=https://<environment-domain/b2b/epay method=post> <INPUT value='<?xml version="1.0" ?><PaymentInfoMessage><PaymentInfoRequest><BankCode>RIBLSARI</BankCode><CompanyCode> PARTNER0001</CompanyCode><StartDate>2004-05-29T00:00:00</StartDate><EndDate>2004-05-29T00:00:00</EndDate><TransactionType>940</TransactionType></PaymentInfoRequest></PaymentInfoMessage>' name=strXmldata> <INPUT type=submit value=Proceed> </FORM> </BODY> </HTML> |
Figure 10– Example of a Accounts Statements Post Request
You can see from the above example, the italic is the URL, and the accounts statements request xml message in bold passed in the parameter strXmldata."
please let me know if any one has faced such requirement in their implementation.
Thanks,
Farhan