Important: Depending on the version of HawkSearch and the method of integration you are using, you may need to perform indexing as per this article or Hawksearch - Elasticsearch Version- Indexing API. Please contact HawkSearch for any clarifications.
Overview
This API allows you to trigger an index rebuild job in Hawksearch dashboard.
Request: POST request with empty body to the API below:
POST /api/v9/index HTTP/1.1 Host: manage.hawksearch.com X-HawkSearch-ApiKey: USE_YOUR_API_KEY Cache-Control: no-cache {}
Response: The response is an array of string objects, every object being a series of key-value pairs. Description of the data is as follows:
No | Key | Description | Value Type |
---|---|---|---|
1 | NotificationId | The unique identifier asssigned to the index rebuild request made | Number |
2 | Title | Task name | String Example: Requested Re-Indexing (API) |
3 | Message | Response message from the server | String Example: Requested Re-Indexing (API) |
4 | NotificationType | Indicates whether this was indexing related or not | String Example: indexing |
5 | Status | The current indexing status | One of the 8 possible values: new, pending, processing, queue, success, error, duplicated, suspended |
6 | AdminId | Admin account id from which the index rebuild request was raised | Numeric |
7 | Provider | Indexing provider - this is debugging info used by HawkSearch | Alphanumeric |
8 | FacetHandler | Internal handler associated with the field | Alphanumeric |
9 | Serialized | Serialized object | Alphanumeric |
10 | ErrorMessages | Error messages associated with the rebuild job | Alphanumeric |
{ "NotificationId": 122924, "Title": "Requested Re-Indexing (API)", "Message": "Requested Re-Indexing (API)", "NotificationType": "indexing", "Status": "new", "AdminId": 113, "Provider": "Contracts.IndexNotification", "Serialized": "CgsIhuSGoufqtzkQBRIECAEQDyIuChJSZXF1ZXN0ZWQgSW5kZXhpbmcSCwiG5Iai5+q3ORAFGgsIhuSGoufqtzkQBQ==", "ErrorMessages": null }
Please review : Best Practices to rebuild index