SOAP Request using Java
I have been trying to send a request through soapui and I always keep getting the following error message:
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<fa开发者_StackOverflow社区ultstring>Failed to process SOAP request. SOAP body not in UTF-16.</faultstring>
<detail>
<wsdl_ops:error>
Failed to process SOAP request. SOAP body not in UTF-16.
</wsdl_ops:error>
</detail>
</soap:Fault>
</soap:Body>
Has anyone run into the same issue before?
UPDATE:
I changed the encoding to UTF-16 and it worked for me. Now, when I send the request I get the following error instead:
REQUEST:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsdl="http://www.broadsign.com/wsdl_ops">
<soapenv:Header/>
<soapenv:Body>
<ns1:request not_modified_since="1970-01-01T00:00:00" token="0" requestid="1" version="4" name="category_mgr_list">
<category domain_id="1719213" />
</ns1:request>
</soapenv:Body>
</soapenv:Envelope>
RESPONSE:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsdl_ops="http://www.broadsign.com/wsdl_ops">
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<faultstring>Invalid request.</faultstring>
<detail>
<wsdl_ops:error>Invalid request.</wsdl_ops:error>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>
What am I missing? :(
Sounds like the service is expecting the request to be encoded as UTF-16. Validate your request and try setting the encoding in the request properties. Failing that, edit your question with the raw inputs and outputs.
精彩评论