I am receiving some json data in my app:
NSMutableDictionary *json = [NSJSONSerialization JSONObjectWithData:jsonResponse options:NSJSONReadingAllowFragments
It seems that your server sends "nested JSON": jsonResponse
is a JSON string (not a
dictionary). The value of that string is again JSON data representing a dictionary.
In that case you have to de-serialize the JSON twice:
NSString *jsonString = [NSJSONSerialization JSONObjectWithData:jsonResponse options:NSJSONReadingAllowFragments error:nil];
NSData *innerJson = [jsonString dataUsingEncoding:NSUTF8StringEncoding];
NSDictionary *jsonDict = [NSJSONSerialization JSONObjectWithData:innerJson options:0 error:nil];
NSString *email = jsonDict[@"email"];