-
-
Save matzew/ede419300262af93140a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSURL* serverURL = [NSURL URLWithString:@"http://server/"]; | |
AGPipeline* pipeline = [AGPipeline pipelineWithBaseURL:serverURL]; | |
id<AGPipe> companies = [pipeline pipe:^(id<AGPipeConfig> config) { | |
[config setName:@"companies"]; | |
}]; | |
// READ comments for ID:1 | |
[companies read:1 resource:@"teams/1/slackers" success:^(id responseObject) { | |
// LOG the JSON response, returned from the server: | |
NSLog(@"READ RESPONSE\n%@", [responseObject description]); | |
} failure:^(NSError *error) { | |
// when an error occurs... at least log it to the console.. | |
NSLog(@"Read: An error occured! \n%@", error); | |
}]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment