# Posting xml without using curl

**URL:** <https://www.ruby-forum.com/t/posting-xml-without-using-curl/123479>\
**Category:** Rails\
**Created:** [December 18, 2007, 4:28am UTC](https://www.ruby-forum.com/t/posting-xml-without-using-curl/123479 "2007-12-18T04:28:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ericgoodwin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/c68b51/32.png) [@ericgoodwin](https://www.ruby-forum.com/u/ericgoodwin)\
**Post date:** [December 18, 2007, 4:28am UTC](https://www.ruby-forum.com/t/posting-xml-without-using-curl/123479/1 "2007-12-18T04:28:48Z")

</div>

How can you post XML data without using curl. I know it probably has  
something to do with Net::HTTP, but Im sure you have to do something a  
bit different.

The reason I cant use curl is because there seems to be a limit to how  
large a commandline command can be and when posting very large xml  
strings, it seems to throw errors.

---

<div class="post-metadata">

**Author:** ![ericgoodwin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/c68b51/32.png) [@ericgoodwin](https://www.ruby-forum.com/u/ericgoodwin)\
**Post date:** [December 18, 2007, 4:46am UTC](https://www.ruby-forum.com/t/posting-xml-without-using-curl/123479/2 "2007-12-18T04:46:06Z")

</div>

On 12/17/07, Aryk G. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> How can you post XML data without using curl. I know it probably has  
> something to do with Net::HTTP, but Im sure you have to do something a  
> bit different.
> 
> The reason I cant use curl is because there seems to be a limit to how  
> large a commandline command can be and when posting very large xml  
> strings, it seems to throw errors.

net/http:  
[http://ruby-doc.org/stdlib/libdoc/net/http/rdoc/index.html](http://ruby-doc.org/stdlib/libdoc/net/http/rdoc/index.html)

curb: # ruby bindings for curl  
[http://curl.haxx.se/libcurl/ruby/](http://curl.haxx.se/libcurl/ruby/)

–  
Rick O.  
[http://lighthouseapp.com](http://lighthouseapp.com)  
[http://weblog.techno-weenie.net](http://weblog.techno-weenie.net)  
[http://mephistoblog.com](http://mephistoblog.com)
