How to view the complete XML sent as request?

I have created a proxy where I'm receiving request in .json format, extracting certain data from the request and using them in a XML payload to post to the endpoint.

I would like to see how the complete XML looks like after mapping the extracted variables. Is there anyway to see the complete XML as I could see only few lines in the Trace?

<soapenv:Body xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><getServicePH xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><header:standardHeader xmlns:header="http://wsi.nat.bt.com/2005/06/StandardHeader/"><header:e2e>.....
Solved Solved
0 3 1,432
2 ACCEPTED SOLUTIONS

Not applicable

Hello @Hadlee N.A,

One of the several ways is to keep a javascript policy and do a context.setVariable("myVariable",context.getVariable("request.content"));

Hope this helps.


View solution in original post

@Hadlee N.A ,

Print to trace output using print command in javascript,

 print(context.getVariable("request.content"));

See the result in trace "Output from all transactions",

3874-screen-shot-2016-11-04-at-81927-pm.png

Hope it helps

View solution in original post

3 REPLIES 3

Not applicable

Hello @Hadlee N.A,

One of the several ways is to keep a javascript policy and do a context.setVariable("myVariable",context.getVariable("request.content"));

Hope this helps.


@Hadlee N.A ,

Print to trace output using print command in javascript,

 print(context.getVariable("request.content"));

See the result in trace "Output from all transactions",

3874-screen-shot-2016-11-04-at-81927-pm.png

Hope it helps

Thanks @Meghdeep Basu and @Anil Sagar . It helped:) I am able to see the complete request now!