<p>I'm investigating SUDS as a SOAP client for python.  I want to inspect the methods available from a specified service, and the types required by a specified method.</p>

<p>The aim is to generate a user interface, allowing users to select a method, then fill in values in a dynamically generated form.</p>

<p>I can get some information on a particular method, but am unsure how to parse it:</p>

<pre><code>client = Client(url)
method = client.sd.service.methods['MyMethod']
</code></pre>

<p>I am unable to <strong>programmaticaly</strong>  figure out what object type I need to create to be able to call the service</p>

<pre><code>obj = client.factory.create('?')

res = client.service.MyMethod(obj, soapheaders=authen)
</code></pre>

<p>Does anyone have some sample code?</p>

According to
```
suds
```
documentation
, you can inspect
```
service
```
object with
```
__str()__
```
. So the following gets a list of methods and complex types:
```
```
from suds.client import Client;

url = 'http://www.webservicex.net/WeatherForecast.asmx?WSDL'
client = Client(url)

temp = str(client);
```
```
The code above produces following result (contents of
```
temp
```
):
```
```
Suds ( https://fedorahosted.org/suds/ )  version: 0.3.4 (beta)  build: R418-20081208

Service ( WeatherForecast ) tns="http://www.webservicex.net"
   Prefixes (1)
      ns0 = "http://www.webservicex.net"
   Ports (2):
      (WeatherForecastSoap)
         Methods (2):
            GetWeatherByPlaceName(xs:string PlaceName, )
            GetWeatherByZipCode(xs:string ZipCode, )
         Types (3):
            ArrayOfWeatherData
            WeatherData
            WeatherForecasts
      (WeatherForecastSoap12)
         Methods (2):
            GetWeatherByPlaceName(xs:string PlaceName, )
            GetWeatherByZipCode(xs:string ZipCode, )
         Types (3):
            ArrayOfWeatherData
            WeatherData
            WeatherForecasts
```
```
This would be much easier to parse. Also every method is listed with their parameters along with their types. You could, probably, even use just regular expression to extract information you need.