changed JSON object structure for better flexibility