SOAPpy, WSDL and objects

B

Bob.Capa

Hi,

I am trying to access a webservice which needs a login request of the
following form:

<login>
<request>
<firstname>FirstName</firstname>
<lastname>LastName</lastname>
</request>
</login>

I am trying to do this with the following code:

from SOAPpy import WSDL
server = WSDL.Proxy(m_url)
request = {'firstname': FirstName,
'lastname': LastName}
server.login(request)

But this will be sending the following:
<login>
<v1>
<firstname>FirstName</firstname>
<lastname>LastName</lastname>
</v1>
</login>

Basically, I need to know how to change the code so it generates
'request' instead of 'v1'.

Have a nice evening!
 
D

Dieter Maurer

<login>
<request>
<firstname>FirstName</firstname>
<lastname>LastName</lastname>
</request>
</login>

I am trying to do this with the following code:

from SOAPpy import WSDL
server = WSDL.Proxy(m_url)
request = {'firstname': FirstName,
'lastname': LastName}
server.login(request)

Try: "server.login({'request':request})".


Dieter
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,241
Members
46,831
Latest member
RusselWill

Latest Threads

Top