Reputation: 29
I'm testing an API that uses a suds SOAP client and trying to record the server IP from which the suds response is coming. Don't really know where to start, any help appreciated...
Upvotes: 0
Views: 101
Reputation: 195
I have not used suds, but SOAP clients typically create proxy objects calling the actual remote method. These proxies are configured via WSDL definition.
Your suds client is configured by the WSDL (URI), see Basic usage section in suds repo. And the WSDL defines URI(s) to possible operations. In WSDL these are called endpoint (or port in WSDL before 2.0).
Hence you need to take a look at the endpoint associated to your call. It is provided as an option to your suds client object. Probably you can also define logging so that suds reports the URI automatically. If you specifically look into retrieving an IP instead of URI, you can call socket.gethostbyname
.
Upvotes: 1