Add toJSON method to entities
Update version