in reply to I don't understand how to send SOAP data using LWP's user agent

Assuming that $r is a HTTP::Request, I would pass the request data in using the ->content method of HTTP::Request instead of relying on the magic of LWP::UserAgent picking up the correct file or knowing what to do with $data.

Also, have you looked at what SOAP::Lite XML would construct as a request? If you can get SOAP::Lite to construct the request for you, maybe you can compare that with the request your program constructs and find the difference?

Replies are listed 'Best First'.
Re^2: I don't understand how to send SOAP data using LWP's user agent
by ted.byers (Monk) on Sep 10, 2014 at 19:11 UTC

    Thanks

    The content function of HTTP::Request was the key. I also used the header function to set the content type as text/xml. That got it working, in the sense I now have proof that my code is sending content, and that the server is processing it.

    I did look at SOAP::Lite, but it seemed like overkill as all these guys use SOAP for is to structure the XML messages it expects to receive and those it sends in response.

    Thanks

    Ted