Skip to Content
0
Jun 15, 2020 at 07:39 AM

Rest sender sync : Remove header

117 Views Last edit Jun 15, 2020 at 07:45 AM 2 rev

Dear Team,

I have a Rest to Rfc sync scenario , the requirement is to remove any headers in the response and pass on only field content to the rest application. Below is a sample response and options tried thus far

XML response from RFC

<ns0:header xmlns:ns0="http://test">

<header>

<Field1>Value 1</Field1>

<Field2>Value 2</Field2>

</header>

<header>

<Field1>Value 3</Field1>

<Field2>Value 4</Field2>

</header>

REST Message expected

{

header : {

"Field 1" :"Value 1",

"Field 2" : "Value 2"

},

{

"Field 1" :"Value 3",

"Field 2" : "Value 4"

}

}

Options Tried :

1. Checked Strip Outer element , so the one header is removed

2.Option setIgnoreElement only available in REST rcvr adapter

3.Checked Strip Operation message , throws HIERARCHY_REQUEST_ERR: An attempt was made to insert a node where it is not permitted.

Please share your thoughts on how this can be acheived