2
client.call(:schedule_email_message, xml: '<soapelem />') # actually a GET request, with payload. Why not a POST request?

savon gem version: 2.11.1

Magne
  • 16,401
  • 10
  • 68
  • 88

1 Answers1

2

How do you know it's a GET?

If you look into lib/savon/operation.rb line 94 (my version 2.3.0) then you'll see that there is a reference to HTTPI.post. Savon uses the HTTPI gem as interface to whatever httpclient gem is installed on your machine. I'm not sure that has changed since 2.11.1.

https://github.com/savonrb/savon/blob/version2/lib/savon/operation.rb

Steffen Roller
  • 3,464
  • 25
  • 43
  • Thanks, yeah I noticed that myself. I'm not entirely sure, I will debug some more. Does Savon on a call first perform a GET to get the WSDL and then a POST if the method specified (`:schedule_email_message` here), is a POST operation? – Magne Feb 28 '17 at 18:10
  • I **guess** it GETs the WSDL first. I prefer not to use a WSDL because I think it's too chatty. – Steffen Roller Feb 28 '17 at 18:44