Wrong response

Posted in General by Gourav Wed Dec 14 2016 16:05:28 GMT+0000 (UTC)·2·Viewed 1,188 times

NSString *urlString = @"https://www.instamojo.com/api/1.1/payment-requests"; NSMutableDictionary *dict=[[NSMutableDictionary alloc]init]; [dict setValue:@"XXXXXXXXXXXXXX" forKey:@"X-Api-Key"]; [dict setValue:@"XXXXXXXXXXXXXX" forKey:@"X-Auth-Token"]; [dict setValue:@"False" forKey:@"allow_repeated_payments"]; [dict setValue:@"25" forKey:@"amount"]; [dict setValue:@"John" forKey:@"buyer_name"]; [dict setValue:@"FIFA" forKey:@"purpose"]; [dict setValue:@"www.google.com" forKey:@"redirect_url"]; [dict setValue:@"9914277755" forKey:@"phone"]; [dict setValue:@"True" forKey:@"send_email"]; [dict setValue:@"www.google.com" forKey:@"webhook"]; [dict setValue:@"True" forKey:@"send_sms"]; [dict setValue:@"gourav@webmobsoft.com" forKey:@"email"]; when i hit that service with attached parameters everytime it will return following response Response: { "payment_requests" = ( { "allow_repeated_payments" = 0; amount = "2000.00"; "buyer_name" = "<null>"; "created_at" = "2016-11-28T20:52:58.126122Z"; email = "<null>"; "email_status" = "<null>"; id = f38fd4d9c0a54a018b13f9c0ac4b977a; longurl = "https://www.instamojo.com/@prashant21/f38fd4d9c0a54a018b13f9c0ac4b977a"; "modified_at" = "2016-11-28T20:52:58.314658Z"; phone = "<null>"; purpose = vefv34fr; "redirect_url" = "<null>"; "send_email" = 0; "send_sms" = 0; shorturl = "https://imjo.in/FdrxSd"; "sms_status" = "<null>"; status = Pending; webhook = "<null>"; } ); success = 1; } please re check my parameters but response are always same like this let me know what i do know
Dec 15, 2016

any body tell me What is the solution of this problem.

Dec 16, 2016

All of our API endpoints expect a trailing /, hence change the URL to https://www.instamojo.com/api/1.1/payment-requests/. Without the trailing / it will result in a redirect and will convert your GET request into a POST.

Ashwini Chaudhary

Instamojo marked this as solved
Markdown is allowed