changed return value to json class type