I am struggling to get a proper mapping of Core Data relationships using RESTkit 0.20.0-pre6.
I want to map this JSON:
{ \"items\" : [ {\"id\" : 2001, \"
I got it working. The trick was to add an extra attribute 'roomId' on ItemMO for the foreign key.
Entity ItemMO (Attributes "id", "roomId", "itemAttr1", Relationship "room" to RoomMO)
Then tell RESTkit about the relation:
[itemMapping addConnectionForRelationship:@"room" connectedBy:@{@"roomId" : @"id"}];
It seems as if RESTkit cannot establish the relation without the extra foreign key attribute.