Q: Making a post call from within sinatra Basically, I want to accept a request at certain URLs, and essentially redirect to another but include some data with the redirect - funneling several URLs into a single one with data based on the originally requested URL.
There are other ways of doing this, I realize, but to keep the URL clean I prefer to do it this way and pass info by POST, like doing a curl -F.
Any advice?

A: There are a whole mess of http clients out there for Ruby. To name a few, there are httpclient, ruby-httpclient and patron. A quick glance through them leaves me feeling like I like Patron best, due to the fact that it relies on libcurl:
hc = Patron::Session.new
hc.base_url = "http://search.twitter.com/"
hc.post("/foo/stuff", "Some data I want to post", {"Content-Type" => "text/plain"})

ruby-httpclient looks somewhat similar, but there are less examples on their page, so harder to immediately grok:
client = Net::HTTPClient.new
html = client.get 'http://www.google.com.au'

I haven't hacked around with any of them, so YMMV but those are good places to start!
UPDATE:
After looking in my Service-Oriented Design with Ruby and Rails (link to Amazon) book, they highly recommended Typhoeus for doing http requests. After glancing at it, I have to agree. Looks very solid and easy to use. Hope this helps!
