added search functionality to restfull API