Hi,
I'm trying to use a method of a SAP Web Service using NuSoap library. I'm using the same code I wrote in other applications with Axis Web Services, but it doesn't work with SAP WS (J2EE WS).
It seems that Nusoap don't generate a correct XML. Doing tests with 'soapUI' the web service works and I can do requests. With 'soapUI' the XML sended is:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ass="http://argos.gencat.intranet/xi/assistencial">
<soapenv:Header/>
<soapenv:Body>
<ass:MT_INT059_ZASICSWSFM001v1>
<CENTRE>GT</CENTRE>
<APELLIDO1>SERRA</APELLIDO1>
<IT_DATOSPAC_O/>
<IT_RETURN/>
</ass:MT_INT059_ZASICSWSFM001v1>
</soapenv:Body>
</soapenv:Envelope>
And the request works. But with phpNusoap the XML generated is:
<?xml version="1.0" encoding="ISO-8859-1"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns5083="http://tempuri.org">
<SOAP-ENV:Body>
<MT_INT059_ZASICSWSFM001v1 xmlns="">
<CENTRE xmlns="">GT</CENTRE>
<APELLIDO1 xmlns="">SERRA</APELLIDO1>
</MT_INT059_ZASICSWSFM001v1>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
And returns this server error:
Array
(
[faultcode] => SOAP:Server
[faultstring] => Server Error
[detail] => Array
(
[SystemError] => Array
(
[context] => XIAdapter
[code.] => ADAPTER.JAVA_EXCEPTION
[text] =>
com.sap.aii.af.ra.ms.api.DeliveryException: XIServer:NO_RECEIVER_CASE_BE:
at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:455)
at com.sap.aii.af.ra.ms.impl.core.queue.consumer.CallConsumer.onMessage(CallConsumer.java:134)
at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:917)
at com.sap.aii.af.ra.ms.runtime.MSWorkWrapper.run(MSWorkWrapper.java:56)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
at java.security.AccessController.doPrivileged(AccessController.java:215)
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
)
)
)
The PHP code used is:
$client = new nusoap_client('http://zeus/sap/MI_INT059_enviaConsultaWS001v1_os.wsdl', 'wsdl');
$client->setCredentials("ws_trueta","test");
$param = array('CENTRE' => 'GT', 'APELLIDO1' => 'SERRA');
$result = $client->call('MI_INT059_enviaConsultaWS001v1_os', array($param));
Maybe someone can help me? 🙁