Added json stuff in class