Skip to content

Instantly share code, notes, and snippets.

@ffaerber
Created September 23, 2010 12:07
Show Gist options
  • Save ffaerber/593520 to your computer and use it in GitHub Desktop.
Save ffaerber/593520 to your computer and use it in GitHub Desktop.
require 'rubygems'
require 'savon'
require 'pp'
client = Savon::Client.new "http://reto.checkit.ch/Scripts/Lotto.dll/wsdl/IgetNumbers"
puts "------print-soap_actions------"
puts client.wsdl.soap_actions
response = client.get_lotto_numbers do |soap|
soap.body = {:min => '1', :max => '49', :numbers => '6', :count => '1'}
end
puts "------Raw------"
pp response.to_hash
puts "------Pretty------"
puts response.to_hash[:get_lotto_numbers_response][:return]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment