I'm having an issue mapping posts from ADN into my database.
Please keep in mind I am using MagicalRecord to automatically map the JSON to the NSManagedObjects I've setup.
The JSON can be seen here: http://web.archive.org/web/20170123035402/https://developers.app.net/reference/resources/post/, specifically the section with the entities.
My Core Data model has been setup with the following relationships:
Post <-> Entities <->> Links/Hashtags/Mentions
The relationships have been setup with the proper names so MagicalRecord should be able to map down the tree just fine. The Post object has a bunch of attributes. Its relationship to the Entities object is called "entities" and this is where it seems to fail because of the primary key (AFAIK from where it breaks in the code in MagicalRecord).
Due to the fact that Entities is basically just an object to hold the relationships to each entity type, I don't have any attributes for the Entity object. Unfortunately it doesn't seem to help setting an attribute with a random name for the Entity object.
Based on the above information, is there anything you would do differently to map the relationships and objects properly? Is it OK to have this empty Entities object that I just use for the relationships to each entity type, sort of how the ADN post has been setup with the "entities" dictionary.