python soap zeep module get result
<p>I'm getting a result from a SOAP API like that:</p>

<pre><code>client = zeep.Client(wsdl=self.wsdl, transport=transport)
auth_header = lb.E("authenticate", self.login())
res  = client.service.GetHouseProfile(region_id, page_number, reporting_period_id, _soapheaders=[auth_header])
</code></pre>

<p>now I need to parse res and to get a result.</p>

<pre><code>&gt;&gt;&gt; dir(res)
['__class__', '__contains__', '__deepcopy__', '__delattr__', '__delitem__', '__dict__', '__doc__', '__eq__', '__format__', '__getattribute__', '__getitem__', '__hash__', '__init__', '__iter__', '__len__', '__module__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__setitem__', '__sizeof__', '__str__', '__subclasshook__', '__values__', '__weakref__', '_xsd_type']
&gt;&gt;&gt; type(res)
&lt;class 'zeep.objects.GetHouseProfileSFResponse'&gt;
&gt;&gt;&gt; print(res.__str__()[0:100])
{
    'data': {
        'item': [
            {
                'house_id': 6465882L,
</code></pre>

<p>How to get a certain element from res?</p>

<p>So I found the way. Looks like not a standard decision but it works:</p>

<pre><code>&gt;&gt;&gt; res.__values__.get("data").__values__.get("item")[6].__values__.keys()
[u'house_id', u'house_profile_data', u'full_address', u'stage', u'state', u'emergency_date', u'emergency_number', u'emergency_reason', u'emergency_after', u'inn', u'files_info']
</code></pre>