API Guide

Table Of Contents
}
doc = Nokogiri::XML(response)
doc.xpath('//ManagedDevice').each do |device|
url = ASM::API::URI('/FirmwareRepository/compliance')
begin
response = ASM::API::sign {
RestClient.post url, device.to_xml, :content_type => :xml
}
doc2 = Nokogiri::XML(response)
serviceTag = doc2.at_xpath('//serviceTag').content
compliance = doc2.at_xpath('//compliance').content
print "Device %s firmware is %s\n" % [serviceTag,compliance]
rescue RestClient::Exception => e
print "Got exception with status: %d\n" % e.response.code
print "%s\n" % e.response
end
end
25