Skip to content

Instantly share code, notes, and snippets.

@dmichael
Created June 11, 2009 14:59
Show Gist options
  • Select an option

  • Save dmichael/127956 to your computer and use it in GitHub Desktop.

Select an option

Save dmichael/127956 to your computer and use it in GitHub Desktop.
# From the RestClient documentation
RestClient.get 'http://example.com/resource'
RestClient.get 'https://user:password@example.com/private/resource'
RestClient.post 'http://example.com/resource', :param1 => 'one', :nested => { :param2 => 'two' }
RestClient.delete 'http://example.com/resource'
# ActiveResource-Style
resource = RestClient::Resource.new 'http://example.com/resource'
resource.get
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment