In AFNetworking's JSONRequestOperationWithRequest:success:failure: method, what type of object is the JSON response?

730 views Asked by At

It gives you a variable called JSON of type id, but how do I manipulate this? Is it a string? Do I have to serialize it first? How exactly do I interact with it?

2

There are 2 answers

0
Rajan Balana On BEST ANSWER

It is returned in the form of dictionary, you just need to extract the value based on the key. Example :

[JSON valueForKey:@"key"];

0
Alex On

You can get more than the basics here

Fantastic course, there's very good code about json handling in the photo mania app.