Updates one or more settings for the index. Only the fields sent in the body are changed. Pass null for a setting to reset it to its default. If the index does not exist, it is created.
An API key is a token that you provide when making API calls. Read more about how to secure your project.
Include the API key to the Authorization header, for instance:
-H 'Authorization: Bearer 6436fc5237b0d6e0d64253fbaac21d135012ecf1'If you use a SDK, ensure you instantiate the client with the API key, for instance with JS SDK:
const client = new MeiliSearch({
host: 'MEILISEARCH_URL',
apiKey: '6436fc5237b0d6e0d64253fbaac21d135012ecf1'
});Unique identifier of the index.
Holds all the settings for an index. T can either be Checked if
they represents settings whose validity is guaranteed, or Unchecked if
they need to be validated. In the later case, a call to check will
return a Settings<Checked> from a Settings<Unchecked>.
Fields displayed in the returned documents.
["id", "title", "description", "url"]Fields in which to search for matching query words sorted by order of importance.
["title", "description"]Attributes to use for faceting and filtering. See Filtering and Faceted Search.
["release_date", "genre"]Attributes to use when sorting search results.
["release_date"]List of ranking rules sorted by order of importance. The order is customizable. A list of ordered built-in ranking rules.
[
"words",
"typo",
"proximity",
"attribute",
"exactness"
]List of words ignored when present in search queries.
["the", "a", "them", "their"]List of characters not delimiting where one term begins and ends.
[" ", "\n"]List of characters delimiting where one term begins and ends.
["S"]List of strings Meilisearch should parse as a single term.
["iPhone pro"]List of associated words treated similarly. A word associated to an array of word as synonyms.
{
"he": ["she", "they", "them"],
"phone": ["iPhone", "android"]
}Search returns documents with distinct (different) values of the given field.
"sku"
Precision level when calculating the proximity ranking rule.
"byAttribute"
Typo tolerance settings for controlling how Meilisearch handles spelling mistakes in search queries. Configure minimum word lengths, disable on specific words or attributes.
Faceting settings for controlling facet behavior. Configure maximum facet values returned and sorting order for facet values.
Pagination settings for controlling the maximum number of results
that can be returned. Set maxTotalHits to limit how far users can
paginate into results.
Embedder required for performing semantic search queries.
Maximum duration of a search query.
x >= 050
Rules for associating locales (languages) with specific attributes. This enables language-specific tokenization for multilingual content, improving search quality for non-English text.
[
{
"locales": ["jpn"],
"attributePatterns": ["*_ja"]
}
]When true, enables facet search which allows users to search within
facet values. When false, only the first maxValuesPerFacet values
are returned. Defaults to true.
true
Controls prefix search behavior. indexingTime enables prefix search
by building a prefix database at indexing time. disabled turns off
prefix search for faster indexing. Defaults to indexingTime.
indexingTime, disabled Chat settings for AI-powered search. Configure the index description, document template for rendering, and search parameters used when the LLM queries this index.
Backend storage for vector embeddings. memory stores vectors in
memory for fastest performance. database stores vectors on disk to
reduce memory usage at the cost of speed.
stable, experimental Task successfully enqueued.
A summarized view of a task, returned when a task is enqueued
Unique sequential identifier of the task.
x >= 0Status of the task. Possible values are enqueued, processing,
succeeded, failed, and canceled.
enqueued, processing, succeeded, failed, canceled "processing"
Type of operation performed by the task.
documentAdditionOrUpdate, documentEdition, documentDeletion, settingsUpdate, indexCreation, indexDeletion, indexUpdate, indexSwap, taskCancelation, taskDeletion, dumpCreation, snapshotCreation, export, upgradeDatabase, indexCompaction, networkTopologyChange "documentAdditionOrUpdate"
Date and time when the task was enqueued.
Unique identifier of the targeted index. Null for global tasks.
Custom metadata attached to this task at creation. Use it to associate tasks with external systems or add application-specific information.