Jan03
RestClient 1.1: Multipart Uploads, and a New Maintainer
I’ve given over maintenance of RestClient to Julien Kirch (archiloque). He's got a 1.1 release now in Gemcutter/Rubyforge, with some hot new features:
Continue reading »Jan03
I’ve given over maintenance of RestClient to Julien Kirch (archiloque). He's got a 1.1 release now in Gemcutter/Rubyforge, with some hot new features:
Continue reading »May28
With HTTP basic auth starting to get the cold shoulder (passwords are basically low-complexity symmetric keys, not too hot for truly secure authentication), and OAuth experiencing growing pains, what options are available today for truly secure RESTful authentication?
Continue reading »Apr07
Cyril Rohr gives us Cacheability, a caching HTTP client which cleverly mashes together RestClient and Rack::Cache. It can cache results in memory, on the filesystem, or in memcached. Grab a copy:
Continue reading »Mar24
Peter Wiliams suggests versioning REST APIs with the Accept header. I agree that putting the version in the URI (e.g. GET /api/v1/resource) is ugly - for the Heroku client I used a custom header (X-Heroku-API-Version), which seems preferrable to me because you don’t pollute your mimetypes.
Jan24
New stuff:
RestClient.get('http://example.com/pic.jpg').headers[:content_type]
resource = RestClient::Resource.new 'https://example.com', :timeout => 20
Oct14
Restclient 0.8 released with new features:
Sep22
A few more chances for you to catch me in person:
Aug19
I keep thinking I’ll run out of things to add to RestClient, but then I keep wanting more features. So here comes 0.7, with gzip/deflate support and client-side logs.
Continue reading »Aug12
I like models. They do the heavy lifting. They’re easy to spec. You can grab them at the console or from script/runner with ease.
Continue reading »Aug08
John Nunemaker created HTTParty, a library for making web requests. So the options for making web calls from Ruby are now:
Continue reading »Aug01
RestClient 0.6 includes an interactive shell contributed by Blake Mizerany. Lay down your curl
, for we now have a Ruby Way to fetch resources at the command line!
Jun26
I’ve always liked to build systems with a bunch of small apps that talk to each other through various protocols. Orion and I built TrustCommerce in this manner, and that gave it some pretty impressive fault-tolerance and scalability.
Continue reading »Jun21
gem install rest-client
for new features:
site['posts/1/comments'].get
) (more examples)May12
While we wait for web broswers to become fully REST-capable, Poster is a handy Firefox plugin for sending any type of HTTP request, including all four verbs and different content types. I usually use rest-client at a rush shell for one-offs; but if you need your browser’s cookies for a call that can’t be authenticated with http basic auth, or you just want a dialog that shows all the options visually, Poster is quite handy.
Apr16
Harry Fuecks thinks MVC might be overrated. In a world of web resources, why not combine models and controllers together? Imagine replacing ActiveRecord (or my new favorite, DataMapper) with a server-side version of ActiveResource. GET, POST, PUT, and DELETE are filled in automatically, and you can extend their functionality and add suport methods.
Continue reading »Apr05
The fourth release of rest-client includes a patch from Greg Borenstein that makes it easy to send form-urlencoded data by passing a hash instead of a string as the payload:
Continue reading »Mar16
When serving up an ActiveRecord as resource, you can use options like :only and :except to to_xml. But in most cases, you want the same fields served every time - on create, update, and get. So put the options into the class itself:
Continue reading »Mar14
REST appealed to me right from the get-go. But it’s taken me a surprisingly long time to wrap my head around all of its implications. Some of my recent projects - building the fully RESTful Heroku API, working with Mike Clark on the Nested Resources recipe for his upcoming book, and writing rest-client - have allowed me to finally get a handle on how all the pricinples of REST fit together into a unified whole.
Continue reading »Mar11
Based on Dan Kubb's suggestion, I’ve implemented an ActiveResource-style accessor for rest-client. This also supports basic auth, so now:
Continue reading »Mar09
REST is part of the Ruby Way. Which is why I’m surprised that every time I go to access a RESTful resource, I find myself writing some sort of ad-hoc rest client. Net::HTTP is too low level - you’ve got to write at least three or four fairly dense lines of code even for a relatively simple GET or PUT.
Continue reading »