public async Task <IEnumerable <Book> > SearchBooksByTitle(SearchTitleDto search) { var title = _queryHelper.Encode(search.Title); var orderBy = _queryHelper.GetOrderBy(search.OrderBy); var url = _queryHelper.GetTitleUrl(title, orderBy, search.MaxResults); var results = await _searchRunner.PerformSearch(url); return(_searchMapper.MapBooks(results)); }
public async Task <IEnumerable <Book> > SearchBooksByTitle([FromBody] SearchTitleDto search) { return(await _searchHelper.SearchBooksByTitle(search)); }