Friday 21 April 2017

Node httpntlm authorisation failing

I have PHP code which is used to fetch a WSDL data using soap client.

Following is the PHP Code:

$XiPay = new XiPaySoapClient( "https://domin/url.asmx","username","password");

I want to do the same in NodeJS and tried with httpntml package, as follow:

var httpntlm = require('httpntlm');
httpntlm.get({
            url:'https://domin/url.asmx',
            username: 'username,
            password: 'password'
    }, function(err, wsdl){
        console.log(err);
        console.log(wsdl);
    });

In case of NodeJS implementation I am always getting following error:

401 - Unauthorized: Access is denied due to invalid credentials

Please help me to understand whats going wrong here. Also, is there any other better package I can use other than httpntlm.

Link might be possible duplicate of this, but as there is no update in this post I am asking again.



via Dipak

No comments:

Post a Comment