[SalesForce] way to print the rax soap request and response during a call out in apex

We have several call outs from salesforce to an external webservices where we consume the external application wsdl and make call outs from our visual force pages. Do you guys know how can i print the entire soap request and response in xml stream or log it for debugging? How do you guys do this now?
Buyan

Best Answer

Enable Apex Debug logs the SOAP request and responses are output to these. The Debug log Category of Callout is describes here as follows...

Includes the request-response XML that the server is sending and receiving from an external Web service. This is useful when debugging issues related to using Force.com Web services API calls.

The easiest way to capture an Apex Debug log is to have Developer Console open when you perform the operation in the UI, as described here. The more traditional route is to go to Debug Logs under the Setup menu. Both give the same results.

Related Topic