Indexes and documents
Index settings
Configure search behavior for an index. Changes to settings are processed asynchronously and may trigger a re-index of your documents.
Not every engine applies every setting
Get settings
/v1/indexes/:uid/settingsGet all settings for an index.
- Auth
- admin key only
- Returns
- 200
{
"searchableAttributes": ["*"],
"filterableAttributes": [],
"sortableAttributes": [],
"rankingRules": [
"words", "typo", "proximity",
"attribute", "sort", "exactness"
],
"synonyms": {},
"stopWords": [],
"displayedAttributes": ["*"],
"distinctAttribute": null,
"typoTolerance": {
"enabled": true,
"minWordSizeForTypos": {
"oneTypo": 5,
"twoTypos": 9
}
},
"faceting": {
"maxValuesPerFacet": 100
},
"pagination": {
"maxTotalHits": 1000
}
}Update settings
/v1/indexes/:uid/settingsUpdate settings for an index. Only include the settings you want to change.
- Auth
- admin key only
- Returns
- 202
{
"filterableAttributes": [
"category",
"price"
],
"sortableAttributes": [
"price",
"createdAt"
],
"searchableAttributes": [
"title",
"description"
]
}{
"taskUid": 5,
"indexUid": "products",
"status": "enqueued"
}Available settings
On a Visor index, searchableAttributes, filterableAttributes, sortableAttributes, displayedAttributes, rankingRules (built-in and custom rules, whose attribute must be sortable), synonyms, stopWords, typoTolerance, pagination and faceting (maxValuesPerFacet, with facet values most frequent first) apply to the live index. Visor refuses distinctAttribute, embedders, proximityPrecision, searchCutoffMs and the token settings with 400 feature_not_supported, so a setting never looks applied when it is not. Sending null for one of them is accepted and changes nothing.
Settings per engine
Sending back the settings you read never fails. See Engine compatibility.