Better json params parsing