How can I reference a specific attribute/row in the results returned by client.service? I'd like to return just the value of the 'OverallStatus' shown below. Here is my code snippet:
from zeep import Client
url='https://someframework.wsdl'
client = Client(wsdl=url)
results = client.service.GetSystemStatus
Here is the 'results()' type:
print(type(results()))
<class 'zeep.objects.SystemStatusResponseMsg'>
And here is what's contained in 'results()':
print(results())
{
'Result': [
'StatusCode': 'OK',
'StatusMessage': 'System Status Retrieved',
'SystemStatus': 'OK',
'Outages': None
}
]
},
'OverallStatus': 'OK'
}
I'd like to call something like:
print(results['OverallStatus'])
or
print(results['SystemStatus'])
and just see it's value of 'OK' printed on screen. I'm a bit of a Python newbie, have reviewed casting the object into dicts, lists, tuples, etc. but feel like I'm missing something and have started going into circles.