# Python and SOAP

Python isn’t especially known for its support of soap functionality, but that’s usually not a problem as most folks needing that sort of functionality are using <span class="caps">REST</span> or <span class="caps">XML</span>-<span class="caps">RPC</span>. However, in case where you **need** <span class="caps">SOAP</span> functionality, such as using UCLA’s <span class="caps">ISIS</span> service, there are a few options.

Notably, there are

1. Optio’s [soaplib](http://trac.optio.webfactional.com/wiki/soaplib)
2. PythonWare’s [<span class="caps">SOAP</span> for Python](http://www.pythonware.com/products/soap/)
3. <span class="caps">ZSI</span>: The [Zolera Soap Infrastructure](http://pywebsvcs.sourceforge.net/zsi.html) (used to be SOAPpy)

(here’s an outdated, but interesting comparison by IBM’s developerWorks: [Python Soap](http://www.ibm.com/developerworks/library/ws-pyth5/) )

Optio’s soaplib is a great toolkit, and easy to learn. However, it doesn’t (yet) support an easy way of handling a complex <span class="caps">WSDL</span>, which means a lot of headache if you’re trying to talk a complex webservice.

<span class="caps">ZSI</span> is a more complicated tool, but handles a <span class="caps">WSDL</span> gracefully (and using wsdl2py, it will create a python class for you from a remote <span class="caps">URL</span>, and even supports <span class="caps">SSL</span>!). The biggest hurdle to using it was that, up until version 2.1 alpha 1, <span class="caps">ZSI</span> had built off of [PyXML](http://pyxml.sourceforge.net/) which was a nice little <span class="caps">XML</span> parser, but is no longer maintained and even conflicts with built in <span class="caps">XML</span> parsers in modern releases of Python. However, as of version 2.1a1, <span class="caps">ZSI</span> is now built off of minidom, which is maintained and might even be built into your version of Python (such as in OS X 10.5 Leopard).