adapted to client's json format