Fetching the Popular Words List
Request
| HTTP Method | GET |
| Endpoint | /api/v2/popular-words |
By sending a request to Fess such as http://<Server Name>/api/v2/popular-words?seed=123, you can receive a list of popular search words in JSON format.
If web.api.popular.word=false, this API returns invalid_request (HTTP 400) (equivalent to the “unsupported operation” behavior in v1).
For the common response envelope and error model, see API Overview.
Request Parameters
The available request parameters are as follows:
Response
On success, the following response is returned in the common envelope format.
Each element of response is as follows:
| record_count | Number of popular words (integer). |
| popular_words | Array of popular words (array of strings). |
Note
In v2, popular words are returned as popular_words (an array of strings), not data as in v1.
Usage Examples
Request example using curl:
Error Response
When the Popular Words API fails, a common error envelope is returned. For details on the error model, see API Overview.