i need integrate rails 2 application 3dcart api. want make request number of orders in store. this, following http://api.3dcart.com/cart.asmx?op=getordercount
i created followin xml file
<?xml version="1.0" encoding="utf-8"?> <soap:envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance" xmlns:xsd="http://www.w3.org/2001/xmlschema"> <soap:body> <getordercount xmlns="http://3dcart.com/"> <storeurl>https://echtest3d.3dcartstores.com/</storeurl> <userkey>my api key</userkey> </getordercount> </soap:body>
then posting following
http = net::http.new("api.3dcart.com") http.use_ssl = false http.post("/cart.asmx", xml_file, { 'content-type' => 'text/xml; charset=utf-8', 'content-length' => "#{xml_file.length}", 'soapaction' => 'http://3dcart.com/getordercount' })
my problem that, response although
net::http ok 200 ok readbody=true
it contains following error node:
error trying data store. technical description: remote name not resolved: 'https'
the store url shouldn't contain https
prefix, should
echtest3d.3dcartstores.com/
Comments
Post a Comment