用python做soap连接时要有哪些条件

用python做soap连接时要有哪些条件

1、URL
2、命名
3、XML格式??

第3点的xml串要怎么传递?
http POST阿


[Copy to clipboard] [ - ]
CODE:
#coding=utf-8
from SOAPpy import WSDL
def link_soap():
    url = 'http://www.XXX.com/Serving?wsdl'
    wsdl_f='<?xml version=\"1.0\"?><info><agent_id>wxgs</agent_id><agent_pwd>12345</agent_pwd><user_number>8613115926561</user_number><sendcontent>cjd</sendcontent><servicetype>free</servicetype><chargenumber>8613115926561</chargenumber></info>'
    #namespace = 'getYHXFServices'
    server = WSDL.Proxy(url)
    return server.getYHXFServices(wsdl_f)

请教一下,发述的这种方式和语法有问题吗