我想用Zeep解析一个WSDL文件并退出:
有关解析wsdl的所有示例吗?
我想我应该使用zeep.wsdl和parse_service方法?
/ A
答案 0 :(得分:4)
更新
{('key1','key2'): 50, ('key3','key4'): 70, ('key1','key5'): 90.....}
答案 1 :(得分:3)
解决:
client= Client('url_to_wsdl')
for service in client.wsdl.services.values():
for port in service.ports.values():
operations = sorted(
port.binding._operations.values(),
key=operator.attrgetter('name'))
for operation in operations:
print operation.name
node = client.create_message(client.service, operation.name)
print node