add rest api for farm register and list