Fixed createResourceFromJson to clean data. Implemented ArrayOf and ObjectAs fields correctly.