Implemented the searching functionality in the REST API