I have some sample code that looks like the following:
var soap = require('soap');
var url = "http://www.example.com?wsdl";
var soapHeader = "<AuthHeader>...</AuthHeader>";
soap.createClient(url, function(err, client){
client.addSoapHeader(soapHeader);
var args = {
'arg1': 1
}
};
client.SomeMethod(args, function(err, result){
if(err){
throw err;
}
console.log(JSON.stringify(result));
});
});
The problem is the request is failing due to either an incorrect header or arguments I'm passing. It would be much easier to debug if I could see the entirety of the request body. How is that done?