NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Problem with NUSOAP WSDL response message


Joined: 15 Dec 2017
Posts: 1
Reply with quote
Hello.
I need to make a Web Service Server to comunicate with a application. I use PHP and discover de NUSOAP to help me to do want I need.
I create a method with the name «NewInitialDocForLocalApp» and the class NUSOAP generate a WSDL Request and Response with a message «NewInitialDocForLocalAppRequest» and «NewInitialDocForLocalAppResponse».

The application that receive my response has a validation (in Data Power) that need it «NewInitialDocForLocalAppInput» and «NewInitialDocForLocalAppOutput» instead. So it blocks my response because don't has the structure they want.


I register my method with this code:
----------------------------------------------
$server->register(
'NewInitialDocForLocalApp', // method name
array(
'idApp' => 'xsd:string',
'idProcApp' => 'xsd:string',
'nIF' => 'xsd:string',
'codServico' => 'xsd:string',
'idDocFileNet' => 'xsd:string',
'tipoDocFileNet' => 'xsd:string',
'idTipoDoc' => 'xsd:string',
'dataRegisto' => 'xsd:string',
'dataDocumento' => 'xsd:string',
'idProcessoGPS' => 'xsd:string',
'classNacional' => 'xsd:string',
'nomeContribuinte' => 'xsd:string',
'nIFApresentante' => 'xsd:string',
'nomeApresentante' => 'xsd:string',
'nIFEntExterna' => 'xsd:string',
'nomeEntExterna' => 'xsd:string',
'assunto' => 'xsd:string',
'referencia' => 'xsd:string',
'codServOrigem' => 'xsd:string',
'observacoes' => 'xsd:string'
), // input
array(
'codResultado' => 'xsd:string',
'codDetalheResultado' => 'xsd:string',
'descResultado' => 'xsd:string',
'idProcApp' => 'xsd:string',
'idFuncionario' => 'xsd:string'
), // output
$namespace, // namespace
$namespace.'#NewInitialDocForLocalApp',
'rpc', // style
'literal', // 'encoded', // use
'' // documentation
);
----------------------------------------------

and XML WSDL response is (That is block it):
----------------------------------------------
<SOAP-ENV:Body>
<ns1:NewInitialDocForLocalAppResponse xmlns:ns1="http://sugar101.ritta.local/COMUM/ws/">
<codResultado>0</codResultado>
<codDetalheResultado>0 - Associado</codDetalheResultado>
<descResultado/>
<idProcApp>104-2017-D</idProcApp>
<idFuncionario/>
</ns1:NewInitialDocForLocalAppResponse>
</SOAP-ENV:Body>
----------------------------------------------

Correct response will be:
----------------------------------------------
<SOAP-ENV:Body>
<ns1:NewInitialDocForLocalAppOutput xmlns:ns1="http://sugar101.ritta.local/COMUM/ws/">
<codResultado>0</codResultado>
<codDetalheResultado>0 - Associado</codDetalheResultado>
<descResultado/>
<idProcApp>104-2017-D</idProcApp>
<idFuncionario/>
</ns1:NewInitialDocForLocalAppOutput>
</SOAP-ENV:Body>
----------------------------------------------

How I could solve this problem with NUSOAP class?

Thanks for your help.
View user's profileFind all posts by FPaisSend private message
Problem with NUSOAP WSDL response message
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic