1 year ago
#346623
user18296410
Making Soap Requests to a wsdl URL using python-zeep
Im trying to make a SOAP request and running into a couple of issues and I would need your help in resolving the error
from zeep import Client
client = Client(wsdl='http://<placeholder>/<serviceholder>.svc?wsdl')
response = client.service.MethodName(secret_code,secret_key,data.__str__())
and getting the following error
**zeep.exceptions.XMLSyntaxError: The XML returned by the server does not contain a valid {http://schemas.xmlsoap.org/soap/envelope/}Envelope root element. The root element found is HTML**
I need 2 inputs,
The MethodName(secret_code,secret_key,
data.__str__()
) actually needsdata.ToString()
as that from c#. Am I even right to use this__str__
in python or should I use something else? ( Just tell me the equivalent method of ToString() in pythonPlease tell me why Im getting that zeep.exception!
It would really mean a lot as I can't even sleep or resolve this error. Im so stuck! please help
Thanks in advance
python
web-services
soap
wsdl
zeep
0 Answers
Your Answer