Using Autosuggested Terms

When autosuggest (same as “Did You Mean”) is enabled, a search suggestion is generated. The search suggestion is presented on the UI. The user has to click on the suggestion to run the suggested search. See the example below for the query “plltion”. The autosuggested term presented on the UI is “pollution”. The user has to click on “pollution” to run the suggested search.

To get autosuggested terms in either the EDS API Search or Publication API Search response, set the autosuggest parameter to 'y' in the search request.

Example EDS API Search Requests with Autosuggest

GET http://eds-api.ebscohost.com/edsapi/rest/Search?query=plltion&autosuggest=y
<SearchRequestMessage xmlns="http://epnet.com/webservices/EbscoApi/Contracts" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
  <SearchCriteria>
     <Queries>
       <Query>
         <Term>plltion</Term>
      </Query>
     </Queries>
   <SearchMode>...</SearchMode>
   <IncludeFacets>...</IncludeFacets>
   <Sort>...</Sort>
   <AutoSuggest>y</AutoSuggest>
  </SearchCriteria>
  <RetrievalCriteria>
    <View>...</View>
    <ResultsPerPage>...</ResultsPerPage>
    <PageNumber>...</PageNumber>
    <Highlight>...</Highlight>
  </RetrievalCriteria>
</SearchRequestMessage>
{
   "SearchRequestMessage":{
      "SearchCriteria":{
         "Queries":{
            "Query":{
               "Term":"plltion"
            }
         },
         "SearchMode":"...",
         "IncludeFacets":"...",
         "Sort":"...",
         "AutoSuggest":"y"
      },
      "RetrievalCriteria":{
         "View":"...",
         "ResultsPerPage":"...",
         "PageNumber":"...",
         "Highlight":"..."
      }
   }
}

If autosuggested terms are available, the autosuggested terms will be returned below the available criteria in the search response message.

Example Response Message with Autosuggested Terms

<SearchResponseMessage xmlns="http://epnet.com/webservices/EbscoApi/Contracts"
xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
   <SearchRequest>...</SearchRequest> or <SearchRequestGet></SearchRequestGet>
      <SearchResult>
         <Statistics> ... </Statistics>
         <Data> ... </Data>
         <AvailableFacets> ... </AvailableFacets>
         <RelatedContent> ... </RelatedContent>
         <AvailableCriteria> ... </AvailableCriteria>
         <AutoSuggestedTerms>
            <AutoSuggestedTerm>pollution</AutoSuggestedTerm>
         </AutoSuggestedTerms>
      </SearchResult>
</SearchResponseMessage>
{
   "SearchRequest":{
 
   },
   "SearchResult":{
      "Statistics":{
 
      },
      "Data":{
 
      },
      "AvailableFacets":[
 
      ],
      "RelatedContent":{
 
      },
      "AvailableCriteria":{
 
      },
      "AutoSuggestedTerms":{
         "AutoSuggestedTerm":"pollution"
      }
   }
}

Example Request, Response, and Screen Usage of Autosuggested Terms