public
Description: Simple HTTP Rest Library for iPhone and Cocoa projects.
Homepage: http://labratrevenge.com
Clone URL: git://github.com/Caged/httpriot.git
Click here to lend your support to: httpriot and make a donation at www.pledgie.com !
Mike Schrag (author)
Thu Oct 29 15:33:27 -0700 2009
Caged (committer)
Thu Oct 29 15:33:27 -0700 2009
name age message
file .gitattributes Sun Feb 08 21:32:05 -0800 2009 Initial import [Caged]
file .gitignore Sun Feb 08 21:32:05 -0800 2009 Initial import [Caged]
file CHANGELOG Wed Sep 30 08:36:53 -0700 2009 Update changelog [Caged]
directory Documentation/ Wed Sep 30 09:03:32 -0700 2009 fix link in documentation footer [Caged]
directory HTTPRiot.xcodeproj/ Thu Oct 29 15:28:38 -0700 2009 include 3.1.2 in automated build [Caged]
file README.md Wed Sep 02 15:51:23 -0700 2009 Move resources into dedicated directory. OCD a... [Caged]
file Rakefile Thu Oct 29 15:28:38 -0700 2009 include 3.1.2 in automated build [Caged]
directory Resources/ Wed Sep 02 15:51:23 -0700 2009 Move resources into dedicated directory. OCD a... [Caged]
directory Source/ Thu Oct 29 15:33:27 -0700 2009 allow requests to handle cookies [Mike Schrag]
README.md

HTTPRiot - Easily Consume REST Services

HTTPRiot is a simple HTTP library that works on the iPhone and Cocoa Apps. It tries to abstract as much as possible in the beginning. This means you don't spend a lot of time up front setting things up and staying on a golden path, but this also means it makes no assumptions about the data returned. It will convert JSON and XML automatically to NSDictionary or NSArray objects, allowing you to do what you want to with the data, but it's up to you to create your own models if you wish.

It offers a lot of flexibility with the data returned, but the tradeoff is that you must know what to do with the data returned because if you initiate two requests from one model both will be routed through the same delegate methods that handle responses/errors/etc.

Documentation and Samples:

Quick Examples

// GET
[model getPath:@"/foo/bar.json" withOptions:nil object:nil];

// POST
NSDictionary *opts = [NSDictionary dictionaryWithObject:[obj JSONRepresentation] forKey:@"body"];
[model postPath:@"/foo" withOptions:params object:nil];

// PUT
NSDictionary *opts = [NSDictionary dictionaryWithObject:[obj JSONRepresentation] forKey:@"body"];
[model putPath:@"/foo/1" withOptions:params object:nil];

// DELETE
[model deletePath:@"/foo/1" withOptions:nil object:nil];

Similar Projects

HTTPRiot was inspired by the httparty Ruby library. There are also numerous other HTTP libraries for Cocoa: