work on rest api