RESTifying the endpoints on the mock server