Last Updated: February 25, 2016
·
181
· hamza0088

Testing public Weather API soap

keys = {
"xmlns:soapenv" => "http://schemas.xmlsoap.org/soap/envelope/",
"xmlns:weat" => "http://ws.cdyne.com/WeatherWS/",
}

builder = Nokogiri::XML::Builder.new do |xml|
xml['soapenv'].Envelope(keys) do
xml['soapenv'].Header
xml['soapenv'].Body {
xml['weat'].GetCityForecastByZIP {
xml['weat'].ZIP("#{address}")
}
}

end
end