4
我有使用捲曲bash腳本:使用Ruby的Net :: HTTP捲曲任務
url="https://example.com/api.cgi"
message="<?xml version=\"1.0\" encoding=\"utf-8\"?>
<request>
<encoding>utf-8</encoding>
<format>XML</format>
<foo>bar</foo>
</request>"
curl --data "${message}" --header 'Content-Type: text/xml' "${url}" --insecure -3
如何實現相同的紅寶石的Net :: HTTP?
如果您喜歡捲曲,請使用'curb'。它比'net/http'更具彈性,但不能在jruby上運行。 – Reactormonk 2012-03-13 10:32:47