Auto-Suggest API


The SearchStax Studio’s Auto-Suggest URL is available on the Search API tab. This endpoint provides suggestions to search users.

The Autosuggest Endpoint for your App is available within your App Settings page as shown below:

As your users enter characters, you can call this endpoint to get suggestions for search queries.

Example: As a user starts typing si, you can call:

https://ss123456-cvrfzabx-us-east-1-aws.searchstax.com/solr/ss123456-CORPSITE-suggester-1/emsuggest?q=si&language=en

to get all suggestions for “si” as shown below:

{
  "responseHeader": {
    "zkConnected": true,
    "status": 0,
    "QTime": 0,
    "params": {
      "q": "si",
      "language": "en",
      "suggest.minPrefixChars": "2",
      "echoParams": "all",
      "suggest.count": "6",
      "suggest": "true",
      "suggest.dictionary": "suggester1",
      "wt": "json"
    }
  },
  "suggest": {
    "suggester1": {
      "si": {
        "numFound": 2,
        "suggestions": [
          {
            "term": "<b>si</b>tecore",
            "weight": 100,
            "payload": ""
          },
          {
            "term": "<b>si</b>te search",
            "weight": 100,
            "payload": ""
          }
        ]
      }
    }
  }
}

You can see all suggestions, along with their weights under suggest.<suggestername>.<enteredCharacters>

Questions?

Do not hesitate to contact the SearchStax Support Desk.