Run multiple search queries in a single API request.
Each query can target a different index, so you can search across several indexes at once and get one combined response.
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'
});Request body for federated multi-search across multiple indexes. This allows you to execute multiple search queries in a single request and optionally combine their results into a unified response. Use this for cross-index search scenarios or to reduce network round-trips.
An array of search queries to execute. Each query can target a
different index and have its own parameters. When federation is
null, results are returned separately for each query. When
federation is set, results are merged.
Configuration for combining results from multiple queries into a
single response. When set, results are merged and ranked together.
When null, each query's results are returned separately in an
array.
Federated multi-search.
Response from a federated multi-search query
Number of results on each page
x >= 0Current search results page
x >= 0Exhaustive total number of search result pages
x >= 0Exhaustive total number of matches
x >= 0Combined search results from all queries
Total processing time in milliseconds
x >= 0Merged facet statistics across all indexes
Facets grouped by index
Unique identifier for the request
Metadata for each query
Errors from remote servers
x >= 0