Skip to content

Instantly share code, notes, and snippets.

@catalinaturlea
Created February 19, 2016 11:50
Show Gist options
  • Select an option

  • Save catalinaturlea/6826515ef24561570308 to your computer and use it in GitHub Desktop.

Select an option

Save catalinaturlea/6826515ef24561570308 to your computer and use it in GitHub Desktop.
Make alamofire request from Objective-c
[AlamofireWrapper request:RequestMethodGET URLString:@"http://something.com" parameters:nil encoding:RequestParameterEncodingURL headers:nil success:^(NSURLRequest * _Nullable request, NSHTTPURLResponse * _Nullable response, NSDictionary * _Nullable json) {
NSLog(@"Success");
// Get the required information from the response JSON
} failure:^(NSURLRequest * _Nullable request, NSHTTPURLResponse * _Nullable response, NSError * _Nullable error) {
NSLog(@"Failure");
}];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment