I have designing an alarm and according to that alarm I need to post on api what the user set as alarm, later api will handle the procedure and notif me if the alarm time is come. So basically, I searched all day long and come with those:
Here what I came so far with tons of efforts! Please help me for further..
NSMutableDictionary *alarmDic = [[NSMutableDictionary alloc] initWithCapacity:4];
NSLog(#"token: %#", self.token);
[alarmDic setObject:[NSNumber numberWithInteger:42] forKey:#"Token"];
NSLog(#"kur id: %lu", alarm.kurID);
[alarmDic setObject:[NSNumber numberWithInteger:alarm.kurID] forKey:#"CurrencyId"];
NSLog(#"not val: %f", alarm.kurAlis);
[alarmDic setObject:[NSNumber numberWithFloat:alarm.kurAlis] forKey:#"NotificationValue"];
NSLog(#"%ld", (long)alarm.kurTur);
[alarmDic setObject:[NSNumber numberWithInteger:alarm.kurTur] forKey:#"Type"];
NSData* jsonData = [NSJSONSerialization dataWithJSONObject:alarmDic
options:NSJSONWritingPrettyPrinted
error:nil];
NSLog(#"%#", [[NSString alloc] initWithData:jsonData
encoding:NSUTF8StringEncoding]);
NSString *dataLength = [NSString stringWithFormat:#"%lu", (unsigned long)[jsonData length]];
NSMutableURLRequest *request = [[NSMutableURLRequest alloc] init];
[request setURL:[NSURL URLWithString:#"http://api-dvzalt.azurewebsites.net/api/Notification/PostNotification"]];
[request setHTTPMethod:#"POST"];
[request setValue:dataLength forHTTPHeaderField:#"Content-Length"];
[request setHTTPBody:jsonData];
NSURLConnection *conn = [[NSURLConnection alloc] initWithRequest:request delegate:self];
if(conn) {
NSLog(#"Connection Successful");
} else {
NSLog(#"Connection could not be made");
}
In the log windows,
requestReply: Connection Successful
However, nothing happening on the api, telling this as always.
The requested resource does not support http method 'GET'.
Here is the confusion I have. It says connection succesful but on API, still the same. What should I do in this case? I might skip something but I can't figure out what I skip. I've done with the whole steps I suppose.
Note: API is working great, it is about my code most probably.
Thanks !
So I'm curious if you don't have a field name for the JSON data in your web handler? Something like "jsonData"? Right now you're stuffing the JSON data in your body, but there's no identifying field name for the handler to pull it out.
I'm thinking something like:
NSString jsonString = [[NSString alloc] initWithData:jsonData encoding:NSUTF8StringEncoding];
NSString requestString = [NSString stringWithFormat:#"jsonData=%#", jsonString];
Then encode requestString and use it in your body.
Related
I am trying to add ability to my app to post a new article to a wordpress blog. I know that Wordpress has the XMLRPC, but I am having issues in implementing the wp.newPost as there is little documentation outside of Ruby PHP or JAVA.
Here is what I have in my app:
-(IBAction)postNews {
NSURL *xmlrpcURL = [NSURL URLWithString:#"https://myurl.wordpress.com/xmlrpc.php"];
NSString *username = #"email#yahoo.com";
NSString *password = #"password";
NSString *title = #"Test";
NSString *content = #"This is a test of posting to the news section from the app.";
NSString *myRequestString = [NSString stringWithFormat:#"username=%#&password=%#&content=%#", username, password, title];
// Create Data from request
NSData *myRequestData = [NSData dataWithBytes: [myRequestString UTF8String] length: [myRequestString length]];
NSMutableURLRequest *request = [[NSMutableURLRequest alloc] initWithURL: xmlrpcURL];
// set Request Type
[request setHTTPMethod: #"POST"];
// Set content-type
[request setValue:#"application/x-www-form-urlencoded" forHTTPHeaderField:#"content-type"];
// Set Request Body
[request setHTTPBody: myRequestData];
// Now send a request and get Response
NSData *returnData = [NSURLConnection sendSynchronousRequest: request returningResponse: nil error: nil];
// Log Response
NSString *response = [[NSString alloc] initWithBytes:[returnData bytes] length:[returnData length] encoding:NSUTF8StringEncoding];
NSLog(#"%#",response);
}
I constantly get the response:
<?xml version="1.0" encoding="UTF-8"?>
<methodResponse>
<fault>
<value>
<struct>
<member>
<name>faultCode</name>
<value><int>-32700</int></value>
</member>
<member>
<name>faultString</name>
<value><string>parse error. not well formed</string></value>
</member>
</struct>
</value>
</fault>
</methodResponse>
What am I doing wrong with this?
Ok, for those trying to do this, documentation for Obj-C is fairly difficult to find, but here is what I did. I first imported the XMLRPC Starter Kit from here. Next, in my app I defined the server username and password as it suggests, and in my action I used both an NSDictionary and NSArray for the post to go through. Again, this is for a simple text post to a wordpress blog.
NSString *server = kWordpressBaseURL;
XMLRPCRequest *reqFRC = [[XMLRPCRequest alloc] initWithHost:[NSURL URLWithString:server]];
NSDictionary* filter = #{
#"post_type": #"post",
#"post_status": #"publish",
#"post_title": #"Test Title",
#"post_content": #"Test Content",
};
NSArray *postParams = #[ #0, kWordpressUserName, kWordpressPassword, filter, #[#"post_title"]]; [reqFRC setMethod:#"wp.newPost" withObjects:postParams];
//The result for this method is a string so we know to send it into a NSString when making the call.
NSString *result = [self executeXMLRPCRequest:reqFRC];
[reqFRC release]; //Release the request
//Basic error checking
if( ![result isKindOfClass:[NSString class]] ) //error occured.
NSLog(#"demo.sayHello Response: %#", result);
Obviously, you can have text fields that you pull from for your blog post content, but this worked great!
U can add new posts using xmlrpc as given code
XMLRPCRequest *req = [[XMLRPCRequest alloc] initWithURL:[NSURL URLWithString:#"your url name"]];
NSArray *yourparameter = #[#0,#"your user id",#"your password"];
[request setMethod:#"wp.newPost" withParameters:yourparameter];
XMLRPCResponse *saveRessponse = [XMLRPCConnection sendSynchronousXMLRPCRequest:req error:nil];
NSLog(#"The Response is%#",[saveRessponse object]);
You can add new post using xml-rpc as
XMLRPCRequest *reqFRC = [[XMLRPCRequest alloc] initWithURL:[NSURL URLWithString:#"your url name"]];
// Set your url here.
NSArray *params = #[#0,#"your user id",#"your password"];
// Add your url parameters here.
[request setMethod:#"wp.newPost" withParameters:params]; // To add new post.
XMLRPCResponse *nodeSaveRessponse = [XMLRPCConnection sendSynchronousXMLRPCRequest:request error:nil];
NSLog(#"server response :%#",[nodeSaveRessponse object]);
I have the following code to get data from server;
-(void)loginForFaceBook
{
GTMOAuth2ViewControllerTouch *viewController;
viewController = [[GTMOAuth2ViewControllerTouch alloc]
initWithScope:#"https://www.googleapis.com/auth/plus.me"
clientID:#"27615...6qdi60qjmachs.apps.googleusercontent.com"
clientSecret:#"Fs8A...u2PH"
keychainItemName:#"OAuth2 Sample:
Google+"
delegate:self
finishedSelector:#selector(viewController:finishedWithAuth:error:)];
[[self navigationController] pushViewController:viewController
animated:YES];
}
- (void)viewController:(GTMOAuth2ViewControllerTouch *)viewController
finishedWithAuth:(GTMOAuth2Authentication *)auth
error:(NSError *)error {
if (error != nil) {
// Authentication failed (perhaps the user denied access, or closed the
// window before granting access)
NSLog(#"Authentication error: %#", error);
NSData *responseData = [[error userInfo] objectForKey:#"data"]; //
kGTMHTTPFetcherStatusDataKey
if ([responseData length] > 0) {
// show the body of the server's authentication failure response
// NSString *str = [[NSString alloc] initWithData:responseData
// encoding:NSUTF8StringEncoding];
// NSLog(#"%#", str);
}
// self.auth = nil;
} else {
// NSString *authCode = [NSString alloc]in;
NSMutableURLRequest * request;
request = [[NSMutableURLRequest alloc] initWithURL:[NSURL
URLWithString:#"http://api.kliqmobile.com/v1/tokens"]
cachePolicy:NSURLRequestReloadIgnoringCacheData
timeoutInterval:60] ;
NSLog(#"%#",auth);
NSLog(#"ho gya success %# :::: %# :::: %#", auth.accessToken,
auth.refreshToken, auth.code);
NSMutableURLRequest * response;
NSError * error;
request.URL = [NSURL URLWithString:#"http://api.kliqmobile.com/v1/tokens"];
NSString *post = [NSString stringWithFormat:#"
{\"token\":\"%#\",\"secret\":\"%#\",\"service\":\"%#\",\"handle\":\"%#\"}",
auth.accessToken,auth.code,#"google",nil];
NSData *postData = [post dataUsingEncoding:NSASCIIStringEncoding
allowLossyConversion:YES];
NSString *postLength = [NSString stringWithFormat:#"%d",[postData length]];
[request setValue:postLength forHTTPHeaderField:#"Content-Length"];
[request setValue:#"application/x-www-form-urlencoded"
forHTTPHeaderField:#"Content-Type"];
[request setHTTPMethod:#"POST"];
[request setHTTPBody:postData];
error = nil;
response = nil;
NSURLConnection *connection = [NSURLConnection connectionWithRequest:request
delegate:self];
[connection start];
}
I have implemented the NSURLConnection delegtes method and data is printing well like this
- (void)connection:(NSURLConnection*)connection didReceiveData:(NSData*)data
{
NSMutableURLRequest * response;
NSError * error;
NSLog(#"Did Receive Data %#", [[NSString alloc]initWithData:data
encoding:NSUTF8StringEncoding]);
NSMutableURLRequest * requestContacts;
requestContacts = [[NSMutableURLRequest alloc] initWithURL:[NSURL
URLWithString:#"http://api.kliqmobile.com/v1/contacts"]
cachePolicy:NSURLRequestReloadIgnoringCacheData
timeoutInterval:60] ;
[requestContacts setHTTPMethod:#"GET"];
[requestContacts setAllHTTPHeaderFields:headers];
error = nil;
response = nil;
NSData* data1 = [NSURLConnection sendSynchronousRequest:requestContacts
returningResponse:&response error:&error];
NSLog(#"WE GET THE REQUIRED TOKAN DATA %# :: %# :: %#", [[NSString alloc]
initWithData:data1 encoding: NSASCIIStringEncoding], error ,response);
}
but after that my app get crashed and it is giving following error;
[NSHTTPURLResponse release]: message sent to deallocated instance 0xcb51070.
please suggest me how to do this.
A couple of thoughts:
What is the intent of your didReceiveData method? There are a bunch of issues here:
You really shouldn't be doing a synchronous network request in the middle of a NSURLConnectionDataDelegate method.
You shouldn't be doing synchronous requests at all, but rather do them asynchronously.
What is the connection between receiving data and your creation of this new request? You're not using the data in the request, so why do it here?
The typical pattern is:
The didReceiveResponse should instantiate a NSMutableData object in some class property.
The only function of didReceiveData should be to append the received data to the NSMutableData. Note, this method may be called multiple times before all the data is received.
In connectionDidFinishLoading, you should initiate any next steps that you take upon successful completion of the request. If you wanted to do start another asynchronous network request when the initial request is done, do that here.
In didFailWithError, you obviously handle any failure of the connection.
When you call connectionWithRequest, you should not use the start method. Only use start when you use initWithRequest:delegate:startImmediately: with NO for the startImmediately parameter. Otherwise the connection starts automatically for you and you're only starting it a second time.
Unrelated to your original question, but your creation of post string cannot be right. You're missing a parameter value. Even better, rather than creating JSON manually, use NSDictionary and then use NSJSONSerialization to make the NSData object containing the JSON from this dictionary. That's much safer:
NSDictionary *params = #{#"token" : auth.accessToken,
#"secret" : auth.code,
#"service" : #"google",
#"handle" : #""};
NSError *error;
NSData *postData = [NSJSONSerialization dataWithJSONObject:params options:0 error:&error];
Clearly, supply whatever you need for the handle value.
A tangential process-related observation, but I'm wondering if you're taking advantage of everything Xcode offers. For example, your declaration of response as a NSMutableURLRequest but then using that as a parameter to sendSynchronousRequest should have generated a compiler warning. The same thing is true with your stringWithFormat for your post string (my third point). That should have generated a warning, too.
Neither of these are immediately relevant, but I wonder if you are failing to heed any other compile-time warnings. These warnings are your best friend when writing robust code and I would recommend resolving all of them. To go a step further, you should also run the project through the static analyzer ("Analyze" on "Product" menu, or shift+command+B), and resolve anything it points out, too.
I am working with an application where I have to request a url and I get the response accordingly
I am using ASIHTTPRequest to request the URL
here is my request
-(void)getTips {
if ([CommonFunctions networkConnected]) {
ShowNetworkActivityIndicator();
NSString *strPhp = #"staticpage.php";
NSString *strQuery = [[NSString alloc] initWithString:[NSString stringWithFormat:#"%#%#?static_id=3",GMS_URL,strPhp]];
ASIHTTPRequest *request = [[ASIHTTPRequest alloc] initWithURL:[NSURL URLWithString:strQuery]];
NSLog(#"tips url %#",request.url);
request.delegate = self;
[request setRequestMethod:#"GET"];
[request startAsynchronous];
}
}
These are my delegate methods
-(void)request:(ASIHTTPRequest *)request didReceiveData:(NSData *)data {
// NSString *responseStr = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding];
// NSLog(#"responseStr %#",responseStr);
SBJsonParser *json = [[SBJsonParser alloc]init];
NSLog(#"json data %#",[json objectWithData:data]);
NSMutableArray *marrData = [[json objectWithData:data] valueForKey:#"responseData"];
if([[marrData valueForKey:#"result"] isEqualToString:#"failed"]){
[CommonFunctions showAlertMessage:[marrData valueForKey:#"error"]];
}
HideNetworkActivityIndicator();
}
Here I get null data no matter whether I pass request methods GET or POST
When I check the same url in browser I get the response and a valid json from online json viewer
What are the possible reason that I am getting null data in the application
Use requestFinished: delegate.. Please try this.
-(void)requestFinished:(ASIHTTPRequest *)request
{
NSLog(#"response %#", [request responseString]);
}
I'm trying to get an access token for a youtube app for iOS. Here's the relevant code I have been using from my viewDidLoad method:
mAuth = [[GTMOAuth2Authentication alloc]init];
[mAuth setClientID:#"<MY CLIENT ID>"];
[mAuth setClientSecret:#"<MY CLIENT SECRET>"];
[mAuth setRedirectURI:#"urn:ietf:wg:oauth:2.0:oob"];
[mAuth setScope:#"https://gdata.youtube.com"];
[self.web loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:[NSString stringWithFormat:#"https://accounts.google.com/o/oauth2/auth?client_id=%#&redirect_uri=%#&scope=%#&response_type=code&access_type=offline", mAuth.clientID, mAuth.redirectURI, mAuth.scope]]]];
After this is called, the user has to grant access to their account, then I retrieve the auth code from the resulting page in the following code:
NSString *string = [self.web stringByEvaluatingJavaScriptFromString:#"document.title"];
if([string rangeOfString:#"Success"].location != NSNotFound){
NSLog(#"This is the code page");
NSString *importantCode = [[string componentsSeparatedByString:#"="] objectAtIndex:1];
NSLog(#"%#", importantCode);
if([self.defaults objectForKey:#"super important code"] == nil){
[self.defaults setObject:importantCode forKey:#"super important code"];
[self.defaults synchronize];
NSString *post = [NSString stringWithFormat:#"code=%#&client_id=%#&client_secret=%#&redirect_uri=%#&grant_type=code", [self.defaults objectForKey:#"super important code"], mAuth.clientID, mAuth.clientSecret, mAuth.redirectURI];
NSData *postData = [post dataUsingEncoding:NSASCIIStringEncoding];
NSString *postLength = [NSString stringWithFormat:#"%d", [postData length]];
NSMutableURLRequest *request = [[NSMutableURLRequest alloc]init];
[request setURL:[NSURL URLWithString:[NSString stringWithFormat:#"https://accounts.google.com/o/oauth2/token"]]];
[request setHTTPMethod:#"POST"]; [request setValue:postLength forHTTPHeaderField:#"Content-Length"];
[request setValue:#"application/x-www-form-urlencoded" forHTTPHeaderField:#"Content-Type"];
[request setHTTPBody:postData];
[self.web loadRequest:request];
}
[timer invalidate];
}
After that, I should be given the access token in response to my POST request, but instead I get a page that simply says:
{
"error" : "invalid_request"
}
Does anyone (see where I went wrong)/(know how to retrieve the access token)?
I’d be interested in knowing what the HTTP status code is... I suspect ”invalid_request” means 400, which almost always means there’s some irritating stupid little error in the way you composed your authent URI. I don’t know enough iOS/ObcJ to tell if you’ve properly URLescaped any funny characters in any of the parameter values, but it’s worth checking. Or a typo in one of the values, or an extra newline creeping in or something?
It was as simple as this, I had set the grant_type parameter to 'code' when it should have been 'authorisation_code' if you are reading this and you are using the youtube api, don't make the same mistake. If you're reading this and you're sending a POST request in general, this error "invalid_request" means that either you skipped one of the parameters you should have added, or you added it incorrectly.
I am uploading Image to server. Length Of NSData will depend On the size of image. if image is too big, NSData length will be 6798791 (length will vary). if image is small Request is getting Uploaded to server. if request it too big (Contains very big image) request is not getting uploaded. Below is request format of an image.
<vaayoo:message xmlns:vaayoo="http://www.vaayoo.com<vaayoo:ostype>iphone</vaayoo:ostype><vaayoo:osversion>8</vaayoo:osversion><vaayoo:deviceid>354043043430851</vaayoo:deviceid><vaayoo:sku>lite</vaayoo:sku><vaayoo:xmlversion>1.0</vaayoo:xmlversion></vaayoo:header><vaayoo:vaayoodata xmlns:vaayoo="http://www.vaayoo.com/version2/yooml" datatype="content" mobiletid="8DD7A158-FC05-4588-B4D6-39D93F10E504" formname="frm_reportupload" streamid="A58BFEAF-E566-4ddc-842D-F8C5976FC300"><vaayoo:event type="control_click" name="btn_submit"><vaayoo:action type="form.asyncsubmit" url="http://content.vaayoo.com/AppsPlatForm/PhotoReportCreatorService/PhotoReportCreator.svc/PhotoreportResponse" asyncurl="http://content.vaayoo.com/AppsPlatForm/ConentUploadService/1_1/MyuploadService.svc/UploadData"/></vaayoo:event><vaayoo:data type="formdata" collection="true"><vaayoo:input name="img_0" type="image" filename="01262013035548648.jpg" currentchunk="18" totalchunk="18">VJpLnKnCzUkRBniTapLDOck81q6dqysPLl4ANZEod5Pl+Zc/d6Gq5Em4hsAdRg0+dyak0ZxpN+82aV8xYmQNu5wAelZkmZXGRUjySOFAycDmlJwMtx3qZS0aGmr7DPsciAYI2rz70qTMhBDfNnkelWbV9zHcd2Rj61ObEDeeFXGaty90qVrWRSfBwQmO/NIY2Bxn5e5JqRsKCTyW45oIGBu5B5qE2277hBaFV+WxI2D2xTHmXeSnJHU1OwjkU7idoHbrWfOCqZTjPercJNXbLi5XsSR3BdnLA7j0PtRNHuUOuA5NRRMwIQ4HHJqx8rbQDnHGa54q7bDkk9UyrE5D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plzEFBy2eSaSWYgBwgaNjjk4qs0w8zPCqR0HIpe7G9zT4viLJnSKE4bLdaybskl5Eycnt1NMuLvDEDBX9aghuiW/uHtVW05kTb2istEOluPPUZG3jvUFq4ILFvkHy4p7fv3JJyajZBCCzD5OpA9ajnjJq25cocsk+x//Z</vaayoo:input><vaayoo:input name="txt_rpt_name" type="text" textmode="multiline">anil dairy</vaayoo:input></vaayoo:data></vaayoo:vaayoodata></vaayoo:message>
Below is the method which is writing the data to server.
-(BOOL)write:(NSData *)data toURI:(NSString *)URI
{
BOOL retVal = NO;
NSString* requestDataLengthString = [[NSString alloc] initWithFormat:#"%d", [data length]];
NSLog(#"Data length is %#",requestDataLengthString);
NSLog(#"Urlis %#",URI);
NSRange range = [URI rangeOfString:#"http"];//Is http?
if(range.location != NSNotFound)
{
//Yes, http
NSMutableURLRequest *httpRequest = [[NSMutableURLRequest alloc] initWithURL: [NSURL URLWithString:URI]];
[httpRequest setHTTPMethod:#"POST"];
[httpRequest setHTTPBody:data];
[httpRequest setValue:#"application/xml" forHTTPHeaderField:#"Content-Type"];
[httpRequest setValue:requestDataLengthString forHTTPHeaderField:#"Content-Length"];
NSURLConnection *theConnection=[[NSURLConnection alloc] initWithRequest:httpRequest delegate:self];
[theConnection release];
[httpRequest release];
if (theConnection)
{
receivedData=[[NSMutableData data] retain];
retVal = YES;
}
else
{
NSError *error = [NSError alloc];
NSLog(#"Connection failed! Error - %# %#",
[error localizedDescription],
[[error userInfo] objectForKey:NSURLErrorFailingURLStringErrorKey]);
[error release];
retVal = NO;
}
}
return retVal;
}
What am i doing wrong in Write method ? it works fine for small images, but doesn't work for bigger images, not even getting any kind of exception if i try to upload big images. How to troubleshoot this problem. Help me out plz.. Thanks in advance..
Have you tried using the asynchronous upload with NSURLConnection delegates? Probably the error might show up there. What language are you using for the webservice? It could be the setting on your webserver that makes it fail to upload big image. Try to see the maximum request length that is set on your server. If it's smaller than the image size, then it would fail.
Use NSTimeoutInterval and try its working:
NSMutableURLRequest *request1 = [NSMutableURLRequest requestWithURL:[NSURL URLWithString:urlString] cachePolicy:NSURLRequestUseProtocolCachePolicy timeoutInterval:1000.0];
Instead of using:
[httpRequest setHTTPBody:data];
Use:
NSInputStream *stream = [[NSInputStream alloc] initWithFileAtPath:filePath];
request setHTTPBodyStream:stream];
Apple has an example of this.