JSON serialization - still needs refactoring
Cleanup