我使用
发出肥皂请求 var soap = require('soap-everywhere');
var url = 'http://ews.taxservice.am/taxsystem-fe-ws/taxpayer/loginService
soap.createClient(url, function(err, client) {
var args = {'Tin': "TestTin",
'Login': "TestLogin",
'Password':"TestPassword*"};
client.login(args, function(err, response,headers ) {
console.log(response);
});
});
我的请求看起来像
<soap:Envelope
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:tax="http://www.taxservice.am/tp3/invoice/definitions">
<soap:Header></soap:Header>
<soap:Body>
<tax:LoginRequest>
<tax:Tin>TestTin</tax:Tin>
<tax:Login>TestLogin</tax:Login>
<tax:Password>TestPassword</tax:Password>
</tax:LoginRequest>
</soap:Body>**
</soap:Envelope>
但是它没有t work
i
在调试器中执行相同的操作,并且有效
请求的区别是
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://www.taxservice.am/tp3/invoice/definitions">
<SOAP-ENV:Body>
<ns1:LoginRequest Tin="Array" Login="?" Password="?"/>
</SOAP-ENV:Body>**
</SOAP-ENV:Envelope>
身体部位
我的要求
<tax:LoginRequest>
<tax:Tin>testTin</tax:Tin>
<tax:Login>TestLogin</tax:Login>
<tax:Password>TestPassword</tax:Password>
</tax:LoginRequest>
调试器请求
<SOAP-ENV:Body>
<ns1:LoginRequest Tin="Array" Login="?" Password="?"/>
</SOAP-ENV:Body>
我认为问题在于args格式,有人可以帮我吗?