I\'m trying to call a SOAP service from the Dutch government land register (WSDL here) with PySimpleSoap. So far I did this to connect:
from pysimplesoap.client
Constructing xml is not the necessary (or correct) way to call a soap method. PySimpleSoap
has already provided quite an elegant and human-readable way to do this:
client = SoapClient(wsdl='http://www1.kadaster.nl/1/schemas/kik-inzage/20141101/verzoekTotInformatie-2.1.wsdl', trace=True)
client.VerzoekTotInformatie(Aanvraag={'berichtversie':4.7,
'klantReferentie':'cum murmure',
'productAanduiding': 'aeoliam venit'})
The debug log would be like this:
INFO:pysimplesoap.client:POST https://service1.kadaster.nl/kik/inzage/20141101/VerzoekTotInformatieService
DEBUG:pysimplesoap.client:SOAPAction: "VerzoekTotInformatie"
Content-length: 842
Content-type: text/xml; charset="UTF-8"
DEBUG:pysimplesoap.client:
4.7000000000
cum murmure
aeoliam venit
As you can see, the xml is automatically constructed and sent to server. However I got 401: Unauthorized
error, which you may know how to fix.