Move the rest calls into the client