Skip to content

Instantly share code, notes, and snippets.

@LeoNogueira
Created March 23, 2011 19:03
Show Gist options
  • Save LeoNogueira/883729 to your computer and use it in GitHub Desktop.
Save LeoNogueira/883729 to your computer and use it in GitHub Desktop.
# testing the webservice with soapUI works fine using :
# <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:tem="http://tempuri.org/">
# <soapenv:Header/>
# <soapenv:Body>
# <tem:GetAllUsers/>
# </soapenv:Body>
# </soapenv:Envelope>
require 'rubygems'
require 'savon'
client = Savon::Client.new do
wsdl.document = "http://201.6.158.145:9600/ActiveItService.svc?wsdl"
end
response = client.request :tem, :get_all_users do
soap.namespaces["xmlns:tem"] = "http://tempuri.org/"
soap.namespaces["xmlns:soapenv"] = "http://schemas.xmlsoap.org/soap/envelope/"
soap.namespaces["xmlns:xsd"] = nil
soap.namespaces["xmlns:xsi"] = nil
soap.namespaces["xmlns:env"] = nil
soap.env_namespace = "soapenv"
soap.body = "<tem:GetAllUsers/>"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment