This answer seems to show how to make a JSONObject.
NSString *jsonString = @"[{\"id\": \"1\", \"name\":\"Aaa\"}, {\"id\": \"2\", \"name\":\"Bbb\"}]";
NSData *jsonData = [jsonString dataUsingEncoding:NSUTF8StringEncoding];
NSError *e = nil;
NSMutableArray *json = [NSJSONSerialization JSONObjectWithData:jsonData options:NSJSONReadingMutableContainers error:&e];
NSLog(@"%@", json);
The output looks like a json object. But then I tried the following:
NSLog(@"%@", [NSJSONSerialization dataWithJSONObject:json options:NSJSONWritingPrettyPrinted error:nil ]);
What I got back was
<5b0a2020 7b0a2020 20202269 6422203a 20223122 2c0a2020 2020226e 616d6522 203a2022 41616122 0a20207d 2c0a2020 7b0a2020 20202269 6422203a 20223222 2c0a2020 2020226e 616d6522 203a2022 42626222 0a20207d 0a5d>
This seems to show that it isn't a real JSONObject. How do you make one?