Defined the API for the REST interface