fix rest calls

Fix rest api calls.