NodeJS and WSDL

42 views
Skip to first unread message

Naminder Singh

unread,
Feb 15, 2018, 10:33:17 PM2/15/18
to nodejs
Hi,

I have a local copy of wsdl file, I want to read and execute SOAP calls from it, how can this be achieved?

Please help on this.

Thanks.

Mikkel Wilson

unread,
Feb 16, 2018, 3:52:32 PM2/16/18
to nodejs
Are you familiar with how to use NPM? There are already great libraries for making this work and, fortunately, it's pretty well documented. One option is strong-soap ( https://github.com/strongloop/strong-soap ), but you can search for others.

$ npm install strong-soap --save

// somefile.js
var soap = require('strong-soap');
var wsdlOptions = {};

soap.createClient(__dirname + '/wsdl/default_namespace.wsdl', wsdlOptions, function (err, client) {
  // your code
  console.log(client.describe());
});

HTH,
Mikkel
Reply all
Reply to author
Forward
0 new messages