SOAPpy and WSDL and basic authentication

V

Vivek

Hi,

Can anyone provide me with sample code that will allow me to use
SOAPpy with a WSDL file using HTTP basic authentication? The only
thing I've been able to find on the net is SOAPpy.URLopener. However,
I am unclear what the relationship is between SOAPpy.URLopener and
SOAPpy.WSDL is.

Is it as straightforward as this?
from SOAPpy import WSDL
url = 'http://user:[email protected]/path/to/wsdl'
ssClient = WSDL.proxy(url)
ssClient.Test() # assuming Test is a SOAP-Action

Or do I need to use SOAPpy.URLopener like so?
from SOAPpy import WSDL
from SOAPpy import URLopener
url = 'http://user:[email protected]/path/to/wsdl'
url1 = URLopener.URLopener(username='user',passwd='pass')
ssClient = WSDL.proxy(url1.open(url))
ssClient.Test() # assumption as above

Or do I need to do something completely different?

All help is much appreicated.

Vivek
 

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

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top