ASIHTTPRequest - PostData but GET Method
- by RyanJM
Is there a way to see what request ASIHTTPRequest is making?
My code is:
ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL:url];
[request appendPostData:[data dataUsingEncoding:NSUTF8StringEncoding]];
[request setRequestMethod:@"GET"];
[request addRequestHeader:@"Content-Type" value:@"application/json"];
And I'm trying to duplicate:
curl -X GET "http://www.myurl.com/_api/my/url" -H "Content-Type: application/json" -d {"api_key":"my_special_api_key_123"}
The curl works fine, but I can't get the ASIHTTPRequest to work properly.
Any ideas?