这是我下面使用邮递员的请求和响应代码。我无法弄清楚为什么身份验证返回失败的响应。
Here is my request made with Postman
POST /OrderStatus/Kroll.Dealer.OrderStatus.svc/Basic HTTP/1.1
Host: api.krollcorp.com
Content-Type: text/xm
SoapAction:http://tempuri.org/IOrderStatusService/GetAllOpenOrders
ApiKey: myAPIkey
User-Agent: PostmanRuntime/7.15.2
Cache-Control: no-cache
Postman-Token: PostmanToken
Host: api.krollcorp.com
Accept-Encoding: gzip, deflate
Content-Length: 620
Connection:keep-alive
cache-control: no-cache
<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Body>
<GetAllOpenOrders xmlns="http://tempuri.org/">
<request>
<DealerAccountNumber xmlns="http://schemas.datacontract.org/2004/07/Kroll.Dealer.EBusiness">mydealeraccountnuber</DealerAccountNumber>
<Password xmlns="http://schemas.datacontract.org/2004/07/Kroll.Dealer.EBusiness"> mypassword</Password>
<UserId xmlns="http://schemas.datacontract.org/2004/07/Kroll.Dealer.EBusiness"> myuserid</UserId>
</request>
</GetAllOpenOrders>
</Body>
</Envelope>
Here is the response
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
<s:Body>
<GetAllOpenOrdersResponse xmlns="http://tempuri.org/">
<GetAllOpenOrdersResult xmlns:a="http://schemas.datacontract.org/2004/07/Kroll.Dealer.EBusiness" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<a:AuthenticationFailed>true</a:AuthenticationFailed>
<a:DealerAccountNumber i:nil="true"/>
<a:Orders/>
</GetAllOpenOrdersResult>
</GetAllOpenOrdersResponse>
</s:Body>
</s:Envelope>
我想收到一个经过验证的有效回复。