algoliasearch 5.59.0 → 5.61.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/dist/algoliasearch.umd.js +13 -13
- package/dist/browser.d.ts +1 -1
- package/dist/browser.js.map +1 -1
- package/dist/browser.min.js +4 -4
- package/dist/browser.min.js.map +1 -1
- package/dist/fetch.d.ts +1 -1
- package/dist/fetch.js.map +1 -1
- package/dist/lite/browser.d.ts +76 -59
- package/dist/lite/builds/browser.js +1 -1
- package/dist/lite/builds/browser.js.map +1 -1
- package/dist/lite/builds/browser.min.js +4 -4
- package/dist/lite/builds/browser.min.js.map +1 -1
- package/dist/lite/builds/browser.umd.js +5 -5
- package/dist/lite/builds/node.cjs +1 -1
- package/dist/lite/builds/node.cjs.map +1 -1
- package/dist/lite/builds/node.js +1 -1
- package/dist/lite/builds/node.js.map +1 -1
- package/dist/lite/node.d.cts +76 -59
- package/dist/lite/node.d.ts +76 -59
- package/dist/lite/src/liteClient.cjs +1 -1
- package/dist/lite/src/liteClient.cjs.map +1 -1
- package/dist/lite/src/liteClient.js +1 -1
- package/dist/lite/src/liteClient.js.map +1 -1
- package/dist/node.cjs.map +1 -1
- package/dist/node.d.cts +1 -1
- package/dist/node.d.ts +1 -1
- package/dist/node.js.map +1 -1
- package/dist/worker.d.ts +1 -1
- package/dist/worker.js.map +1 -1
- package/package.json +21 -21
package/dist/lite/node.d.cts
CHANGED
|
@@ -54,7 +54,7 @@ type TagFilters = Array<TagFilters> | string;
|
|
|
54
54
|
|
|
55
55
|
type BaseRecommendSearchParams = {
|
|
56
56
|
/**
|
|
57
|
-
* Keywords to be used instead of the search query to conduct a more broader search Using the `similarQuery` parameter changes other settings - `queryType` is set to `prefixNone`. - `removeStopWords` is set to true. - `words` is set as the first ranking criterion. - All remaining words are treated as `optionalWords
|
|
57
|
+
* Keywords to be used instead of the search query to conduct a more broader search. Using the `similarQuery` parameter changes other settings - `queryType` is set to `prefixNone`. - `removeStopWords` is set to true. - `words` is set as the first ranking criterion. - All remaining words are treated as `optionalWords`. Since the `similarQuery` is supposed to do a broad search, they usually return many results. Combine it with `filters` to narrow down the list of results.
|
|
58
58
|
*/
|
|
59
59
|
similarQuery?: string | undefined;
|
|
60
60
|
/**
|
|
@@ -65,7 +65,7 @@ type BaseRecommendSearchParams = {
|
|
|
65
65
|
numericFilters?: NumericFilters | undefined;
|
|
66
66
|
tagFilters?: TagFilters | undefined;
|
|
67
67
|
/**
|
|
68
|
-
* Whether to sum all filter scores If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#
|
|
68
|
+
* Whether to sum all filter scores. If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulate-scores-with-sumorfiltersscores).
|
|
69
69
|
*/
|
|
70
70
|
sumOrFiltersScores?: boolean | undefined;
|
|
71
71
|
/**
|
|
@@ -73,11 +73,11 @@ type BaseRecommendSearchParams = {
|
|
|
73
73
|
*/
|
|
74
74
|
restrictSearchableAttributes?: Array<string> | undefined;
|
|
75
75
|
/**
|
|
76
|
-
* Facets for which to retrieve facet values that match the search criteria and the number of matching facet values To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
|
|
76
|
+
* Facets for which to retrieve facet values that match the search criteria and the number of matching facet values. To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
|
|
77
77
|
*/
|
|
78
78
|
facets?: Array<string> | undefined;
|
|
79
79
|
/**
|
|
80
|
-
* Whether faceting should be applied after deduplication with `distinct
|
|
80
|
+
* Whether faceting should be applied after deduplication with `distinct`. This leads to accurate facet counts when using faceting in combination with `distinct`. It\'s usually better to use `afterDistinct` modifiers in the `attributesForFaceting` setting, as `facetingAfterDistinct` only computes correct facet counts if all records have the same facet values for the `attributeForDistinct`.
|
|
81
81
|
*/
|
|
82
82
|
facetingAfterDistinct?: boolean | undefined;
|
|
83
83
|
/**
|
|
@@ -100,15 +100,15 @@ type BaseRecommendSearchParams = {
|
|
|
100
100
|
*/
|
|
101
101
|
insidePolygon?: Array<Array<number>> | undefined;
|
|
102
102
|
/**
|
|
103
|
-
* ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches) - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
|
|
103
|
+
* ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches). - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
|
|
104
104
|
*/
|
|
105
105
|
naturalLanguages?: Array<SupportedLanguage> | undefined;
|
|
106
106
|
/**
|
|
107
|
-
* Assigns a rule context to the search query [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#
|
|
107
|
+
* Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#assign-context) are strings that you can use to trigger matching rules.
|
|
108
108
|
*/
|
|
109
109
|
ruleContexts?: Array<string> | undefined;
|
|
110
110
|
/**
|
|
111
|
-
* Impact that Personalization should have on this search The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
|
|
111
|
+
* Impact that Personalization should have on this search. The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
|
|
112
112
|
*/
|
|
113
113
|
personalizationImpact?: number | undefined;
|
|
114
114
|
/**
|
|
@@ -124,7 +124,7 @@ type BaseRecommendSearchParams = {
|
|
|
124
124
|
*/
|
|
125
125
|
synonyms?: boolean | undefined;
|
|
126
126
|
/**
|
|
127
|
-
* Whether to include a `queryID` attribute in the response The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/doc/guides/sending-events/getting-started).
|
|
127
|
+
* Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/doc/guides/sending-events/getting-started).
|
|
128
128
|
*/
|
|
129
129
|
clickAnalytics?: boolean | undefined;
|
|
130
130
|
/**
|
|
@@ -179,7 +179,7 @@ type BaseIndexSettings = {
|
|
|
179
179
|
*/
|
|
180
180
|
indexLanguages?: Array<SupportedLanguage> | undefined;
|
|
181
181
|
/**
|
|
182
|
-
* Searchable attributes for which you want to turn off [prefix matching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#
|
|
182
|
+
* Searchable attributes for which you want to turn off [prefix matching](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/override-search-engine-defaults/#adjust-prefix-search). Attribute names are case-sensitive.
|
|
183
183
|
*/
|
|
184
184
|
disablePrefixOnAttributes?: Array<string> | undefined;
|
|
185
185
|
/**
|
|
@@ -233,7 +233,7 @@ type AdvancedSyntaxFeatures = 'exactPhrase' | 'excludeWords';
|
|
|
233
233
|
type AlternativesAsExact = 'ignorePlurals' | 'singleWordSynonym' | 'multiWordsSynonym' | 'ignoreConjugations';
|
|
234
234
|
|
|
235
235
|
/**
|
|
236
|
-
* Determines how many records of a group are included in the search results. Records with the same value for the `attributeForDistinct` attribute are considered a group. The `distinct` setting controls how many members of the group are returned. This is useful for [deduplication and grouping](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#
|
|
236
|
+
* Determines how many records of a group are included in the search results. Records with the same value for the `attributeForDistinct` attribute are considered a group. The `distinct` setting controls how many members of the group are returned. This is useful for [deduplication and grouping](https://www.algolia.com/doc/guides/managing-results/refine-results/grouping/#deduplicate-results-with-distinct). The `distinct` setting is ignored if `attributeForDistinct` is not set.
|
|
237
237
|
*/
|
|
238
238
|
type Distinct = boolean | number;
|
|
239
239
|
|
|
@@ -250,7 +250,7 @@ type BooleanString = 'true' | 'false';
|
|
|
250
250
|
type IgnorePlurals = Array<SupportedLanguage> | BooleanString | boolean;
|
|
251
251
|
|
|
252
252
|
/**
|
|
253
|
-
* Words that should be considered optional when found in the query. By default, records must match all words in the search query to be included in the search results. Adding optional words can increase the number of search results by running an additional search query that doesn\'t include the optional words. For example, if the search query is \"action video\" and \"video\" is optional, the search engine runs two queries: one for \"action video\" and one for \"action\". Records that match all words are ranked higher. For a search query with 4 or more words **and** all its words are optional, the number of matched words required for a record to be included in the search results increases for every 1,000 records: - If `optionalWords` has fewer than 10 words, the required number of matched words increases by 1: results 1 to 1,000 require 1 matched word; results 1,001 to 2,000 need 2 matched words. - If `optionalWords` has 10 or more words, the required number of matched words increases by the number of optional words divided by 5 (rounded down). Example: with 18 optional words, results 1 to 1,000 require 1 matched word; results 1,001 to 2,000 need 4 matched words. For more information, see [Optional words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#
|
|
253
|
+
* Words that should be considered optional when found in the query. By default, records must match all words in the search query to be included in the search results. Adding optional words can increase the number of search results by running an additional search query that doesn\'t include the optional words. For example, if the search query is \"action video\" and \"video\" is optional, the search engine runs two queries: one for \"action video\" and one for \"action\". Records that match all words are ranked higher. For a search query with 4 or more words **and** all its words are optional, the number of matched words required for a record to be included in the search results increases for every 1,000 records: - If `optionalWords` has fewer than 10 words, the required number of matched words increases by 1: results 1 to 1,000 require 1 matched word; results 1,001 to 2,000 need 2 matched words. - If `optionalWords` has 10 or more words, the required number of matched words increases by the number of optional words divided by 5 (rounded down). Example: with 18 optional words, results 1 to 1,000 require 1 matched word; results 1,001 to 2,000 need 4 matched words. For more information, see [Optional words](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/empty-or-insufficient-results/#create-a-list-of-optional-words).
|
|
254
254
|
*/
|
|
255
255
|
type OptionalWords = string | Array<string>;
|
|
256
256
|
|
|
@@ -351,6 +351,16 @@ type Banner = {
|
|
|
351
351
|
link?: BannerLink | undefined;
|
|
352
352
|
};
|
|
353
353
|
|
|
354
|
+
/**
|
|
355
|
+
* Agent Studio Result Card to display for a given search.
|
|
356
|
+
*/
|
|
357
|
+
type ResultCard = {
|
|
358
|
+
/**
|
|
359
|
+
* Whether to show the Result Card for the current search.
|
|
360
|
+
*/
|
|
361
|
+
enabled?: boolean | undefined;
|
|
362
|
+
};
|
|
363
|
+
|
|
354
364
|
/**
|
|
355
365
|
* Widgets returned from any rules that are applied to the current search.
|
|
356
366
|
*/
|
|
@@ -359,6 +369,7 @@ type Widgets = {
|
|
|
359
369
|
* Banners defined in the Merchandising Studio for a given search.
|
|
360
370
|
*/
|
|
361
371
|
banners?: Array<Banner> | undefined;
|
|
372
|
+
resultCard?: ResultCard | undefined;
|
|
362
373
|
};
|
|
363
374
|
|
|
364
375
|
/**
|
|
@@ -382,15 +393,15 @@ type TypoTolerance = boolean | TypoToleranceEnum;
|
|
|
382
393
|
|
|
383
394
|
type BaseRecommendIndexSettings = {
|
|
384
395
|
/**
|
|
385
|
-
* Attributes to include in the API response To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
|
|
396
|
+
* Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
|
|
386
397
|
*/
|
|
387
398
|
attributesToRetrieve?: Array<string> | undefined;
|
|
388
399
|
/**
|
|
389
|
-
* Relevancy threshold below which less relevant results aren\'t included in the results You can only set `relevancyStrictness` on [virtual replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/#
|
|
400
|
+
* Relevancy threshold below which less relevant results aren\'t included in the results. You can only set `relevancyStrictness` on [virtual replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/#standard-and-virtual-replicas). Use this setting to strike a balance between the relevance and number of returned results.
|
|
390
401
|
*/
|
|
391
402
|
relevancyStrictness?: number | undefined;
|
|
392
403
|
/**
|
|
393
|
-
* Attributes to highlight By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js).
|
|
404
|
+
* Attributes to highlight. By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js).
|
|
394
405
|
*/
|
|
395
406
|
attributesToHighlight?: Array<string> | undefined;
|
|
396
407
|
/**
|
|
@@ -414,20 +425,20 @@ type BaseRecommendIndexSettings = {
|
|
|
414
425
|
*/
|
|
415
426
|
restrictHighlightAndSnippetArrays?: boolean | undefined;
|
|
416
427
|
/**
|
|
417
|
-
* Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#
|
|
428
|
+
* Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configure-word-size-threshold-for-typos).
|
|
418
429
|
*/
|
|
419
430
|
minWordSizefor1Typo?: number | undefined;
|
|
420
431
|
/**
|
|
421
|
-
* Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#
|
|
432
|
+
* Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configure-word-size-threshold-for-typos).
|
|
422
433
|
*/
|
|
423
434
|
minWordSizefor2Typos?: number | undefined;
|
|
424
435
|
typoTolerance?: TypoTolerance | undefined;
|
|
425
436
|
/**
|
|
426
|
-
* Whether to allow typos on numbers in the search query Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
|
|
437
|
+
* Whether to allow typos on numbers in the search query. Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
|
|
427
438
|
*/
|
|
428
439
|
allowTyposOnNumericTokens?: boolean | undefined;
|
|
429
440
|
/**
|
|
430
|
-
* Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance). Attribute names are case-sensitive Returning only exact matches can help when - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
|
|
441
|
+
* Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance). Attribute names are case-sensitive Returning only exact matches can help when - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions. Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
|
|
431
442
|
*/
|
|
432
443
|
disableTypoToleranceOnAttributes?: Array<string> | undefined;
|
|
433
444
|
ignorePlurals?: IgnorePlurals | undefined;
|
|
@@ -437,7 +448,7 @@ type BaseRecommendIndexSettings = {
|
|
|
437
448
|
*/
|
|
438
449
|
queryLanguages?: Array<SupportedLanguage> | undefined;
|
|
439
450
|
/**
|
|
440
|
-
* Whether to split compound words in the query into their building blocks For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#
|
|
451
|
+
* Whether to split compound words in the query into their building blocks. For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#split-compound-words). Word segmentation is supported for these languages: German, Dutch, Finnish, Swedish, and Norwegian. Decompounding doesn\'t work for words with [non-spacing mark Unicode characters](https://www.charactercodes.net/category/non-spacing_mark). For example, `Gartenstühle` won\'t be decompounded if the `ü` consists of `u` (U+0075) and `◌̈` (U+0308).
|
|
441
452
|
*/
|
|
442
453
|
decompoundQuery?: boolean | undefined;
|
|
443
454
|
/**
|
|
@@ -447,7 +458,7 @@ type BaseRecommendIndexSettings = {
|
|
|
447
458
|
queryType?: QueryType | undefined;
|
|
448
459
|
removeWordsIfNoResults?: RemoveWordsIfNoResults | undefined;
|
|
449
460
|
/**
|
|
450
|
-
* Whether to support phrase matching and excluding words from search queries Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
|
|
461
|
+
* Whether to support phrase matching and excluding words from search queries. Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
|
|
451
462
|
*/
|
|
452
463
|
advancedSyntax?: boolean | undefined;
|
|
453
464
|
optionalWords?: OptionalWords | null | undefined;
|
|
@@ -457,24 +468,24 @@ type BaseRecommendIndexSettings = {
|
|
|
457
468
|
disableExactOnAttributes?: Array<string> | undefined;
|
|
458
469
|
exactOnSingleWordQuery?: ExactOnSingleWordQuery | undefined;
|
|
459
470
|
/**
|
|
460
|
-
* Determine which plurals and synonyms should be considered an exact matches By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example - \"swimsuit\" and \"swimsuits\" are treated the same - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)) - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
|
|
471
|
+
* Determine which plurals and synonyms should be considered an exact matches. By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example: - \"swimsuit\" and \"swimsuits\" are treated the same. - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)). - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches. - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches. - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
|
|
461
472
|
*/
|
|
462
473
|
alternativesAsExact?: Array<AlternativesAsExact> | undefined;
|
|
463
474
|
/**
|
|
464
|
-
* Advanced search syntax features you want to support - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\" - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\" This setting only has an effect if `advancedSyntax` is true.
|
|
475
|
+
* Advanced search syntax features you want to support. - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\". - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\". This setting only has an effect if `advancedSyntax` is true.
|
|
465
476
|
*/
|
|
466
477
|
advancedSyntaxFeatures?: Array<AdvancedSyntaxFeatures> | undefined;
|
|
467
478
|
distinct?: Distinct | undefined;
|
|
468
479
|
/**
|
|
469
|
-
* Whether to replace a highlighted word with the matched synonym By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
|
|
480
|
+
* Whether to replace a highlighted word with the matched synonym. By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
|
|
470
481
|
*/
|
|
471
482
|
replaceSynonymsInHighlight?: boolean | undefined;
|
|
472
483
|
/**
|
|
473
|
-
* Minimum proximity score for two matching words This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
|
|
484
|
+
* Minimum proximity score for two matching words. This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
|
|
474
485
|
*/
|
|
475
486
|
minProximity?: number | undefined;
|
|
476
487
|
/**
|
|
477
|
-
* Properties to include in the API response of search and browse requests By default, all response properties are included. To reduce the response size, you can select which properties should be included An empty list may lead to an empty API response (except properties you can\'t exclude) You can\'t exclude these properties: `message`, `warning`, `cursor`, `abTestVariantID`, or any property added by setting `getRankingInfo` to true Your search depends on the `hits` field. If you omit this field, searches won\'t return any results. Your UI might also depend on other properties, for example, for pagination. Before restricting the response size, check the impact on your search experience.
|
|
488
|
+
* Properties to include in the API response of search and browse requests. By default, all response properties are included. To reduce the response size, you can select which properties should be included An empty list may lead to an empty API response (except properties you can\'t exclude) You can\'t exclude these properties: `message`, `warning`, `cursor`, `abTestVariantID`, or any property added by setting `getRankingInfo` to true Your search depends on the `hits` field. If you omit this field, searches won\'t return any results. Your UI might also depend on other properties, for example, for pagination. Before restricting the response size, check the impact on your search experience.
|
|
478
489
|
*/
|
|
479
490
|
responseFields?: Array<string> | undefined;
|
|
480
491
|
/**
|
|
@@ -482,16 +493,16 @@ type BaseRecommendIndexSettings = {
|
|
|
482
493
|
*/
|
|
483
494
|
maxValuesPerFacet?: number | undefined;
|
|
484
495
|
/**
|
|
485
|
-
* Order in which to retrieve facet values - `count`. Facet values are retrieved by decreasing count. The count is the number of matching records containing this facet value - `alpha`. Retrieve facet values alphabetically This setting doesn\'t influence how facet values are displayed in your UI (see `renderingContent`). For more information, see [facet value display](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/facet-display/js).
|
|
496
|
+
* Order in which to retrieve facet values. - `count`. Facet values are retrieved by decreasing count. The count is the number of matching records containing this facet value. - `alpha`. Retrieve facet values alphabetically. This setting doesn\'t influence how facet values are displayed in your UI (see `renderingContent`). For more information, see [facet value display](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/facet-display/js).
|
|
486
497
|
*/
|
|
487
498
|
sortFacetValuesBy?: string | undefined;
|
|
488
499
|
/**
|
|
489
|
-
* Whether the best matching attribute should be determined by minimum proximity This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting.
|
|
500
|
+
* Whether the best matching attribute should be determined by minimum proximity. This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting. Prefer `attributeCriteriaComputedBy`, which expresses the same two behaviors and adds the `sum` strategy. If you set both, `attributeCriteriaComputedBy` takes precedence.
|
|
490
501
|
*/
|
|
491
502
|
attributeCriteriaComputedByMinProximity?: boolean | undefined;
|
|
492
503
|
renderingContent?: RenderingContent | undefined;
|
|
493
504
|
/**
|
|
494
|
-
* Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking) This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
|
|
505
|
+
* Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking). This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
|
|
495
506
|
*/
|
|
496
507
|
enableReRanking?: boolean | undefined;
|
|
497
508
|
reRankingApplyFilter?: ReRankingApplyFilter | null | undefined;
|
|
@@ -1028,7 +1039,7 @@ type GetRecommendationsResponse = {
|
|
|
1028
1039
|
};
|
|
1029
1040
|
|
|
1030
1041
|
/**
|
|
1031
|
-
* - `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
|
|
1042
|
+
* - `default`: perform a search query. - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
|
|
1032
1043
|
*/
|
|
1033
1044
|
type SearchTypeFacet = 'facet';
|
|
1034
1045
|
|
|
@@ -1059,7 +1070,7 @@ type FacetFilters = Array<FacetFilters> | string;
|
|
|
1059
1070
|
|
|
1060
1071
|
type BaseSearchParamsWithoutQuery = {
|
|
1061
1072
|
/**
|
|
1062
|
-
* Keywords to be used instead of the search query to conduct a more broader search Using the `similarQuery` parameter changes other settings - `queryType` is set to `prefixNone`. - `removeStopWords` is set to true. - `words` is set as the first ranking criterion. - All remaining words are treated as `optionalWords
|
|
1073
|
+
* Keywords to be used instead of the search query to conduct a more broader search. Using the `similarQuery` parameter changes other settings - `queryType` is set to `prefixNone`. - `removeStopWords` is set to true. - `words` is set as the first ranking criterion. - All remaining words are treated as `optionalWords`. Since the `similarQuery` is supposed to do a broad search, they usually return many results. Combine it with `filters` to narrow down the list of results.
|
|
1063
1074
|
*/
|
|
1064
1075
|
similarQuery?: string | undefined;
|
|
1065
1076
|
/**
|
|
@@ -1071,7 +1082,7 @@ type BaseSearchParamsWithoutQuery = {
|
|
|
1071
1082
|
numericFilters?: NumericFilters | undefined;
|
|
1072
1083
|
tagFilters?: TagFilters | undefined;
|
|
1073
1084
|
/**
|
|
1074
|
-
* Whether to sum all filter scores If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#
|
|
1085
|
+
* Whether to sum all filter scores. If true, all filter scores are summed. Otherwise, the maximum filter score is kept. For more information, see [filter scores](https://www.algolia.com/doc/guides/managing-results/refine-results/filtering/in-depth/filter-scoring/#accumulate-scores-with-sumorfiltersscores).
|
|
1075
1086
|
*/
|
|
1076
1087
|
sumOrFiltersScores?: boolean | undefined;
|
|
1077
1088
|
/**
|
|
@@ -1079,11 +1090,11 @@ type BaseSearchParamsWithoutQuery = {
|
|
|
1079
1090
|
*/
|
|
1080
1091
|
restrictSearchableAttributes?: Array<string> | undefined;
|
|
1081
1092
|
/**
|
|
1082
|
-
* Facets for which to retrieve facet values that match the search criteria and the number of matching facet values To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
|
|
1093
|
+
* Facets for which to retrieve facet values that match the search criteria and the number of matching facet values. To retrieve all facets, use the wildcard character `*`. For more information, see [facets](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#contextual-facet-values-and-counts).
|
|
1083
1094
|
*/
|
|
1084
1095
|
facets?: Array<string> | undefined;
|
|
1085
1096
|
/**
|
|
1086
|
-
* Whether faceting should be applied after deduplication with `distinct
|
|
1097
|
+
* Whether faceting should be applied after deduplication with `distinct`. This leads to accurate facet counts when using faceting in combination with `distinct`. It\'s usually better to use `afterDistinct` modifiers in the `attributesForFaceting` setting, as `facetingAfterDistinct` only computes correct facet counts if all records have the same facet values for the `attributeForDistinct`.
|
|
1087
1098
|
*/
|
|
1088
1099
|
facetingAfterDistinct?: boolean | undefined;
|
|
1089
1100
|
/**
|
|
@@ -1118,15 +1129,15 @@ type BaseSearchParamsWithoutQuery = {
|
|
|
1118
1129
|
*/
|
|
1119
1130
|
insidePolygon?: Array<Array<number>> | undefined;
|
|
1120
1131
|
/**
|
|
1121
|
-
* ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches) - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
|
|
1132
|
+
* ISO language codes that adjust settings that are useful for processing natural language queries (as opposed to keyword searches). - Sets `removeStopWords` and `ignorePlurals` to the list of provided languages. - Sets `removeWordsIfNoResults` to `allOptional`. - Adds a `natural_language` attribute to `ruleContexts` and `analyticsTags`.
|
|
1122
1133
|
*/
|
|
1123
1134
|
naturalLanguages?: Array<SupportedLanguage> | undefined;
|
|
1124
1135
|
/**
|
|
1125
|
-
* Assigns a rule context to the search query [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#
|
|
1136
|
+
* Assigns a rule context to the search query. [Rule contexts](https://www.algolia.com/doc/guides/managing-results/rules/rules-overview/how-to/customize-search-results-by-platform/#assign-context) are strings that you can use to trigger matching rules.
|
|
1126
1137
|
*/
|
|
1127
1138
|
ruleContexts?: Array<string> | undefined;
|
|
1128
1139
|
/**
|
|
1129
|
-
* Impact that Personalization should have on this search The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
|
|
1140
|
+
* Impact that Personalization should have on this search. The higher this value is, the more Personalization determines the ranking compared to other factors. For more information, see [Understanding Personalization impact](https://www.algolia.com/doc/guides/personalization/personalizing-results/in-depth/configuring-personalization/#understanding-personalization-impact).
|
|
1130
1141
|
*/
|
|
1131
1142
|
personalizationImpact?: number | undefined;
|
|
1132
1143
|
/**
|
|
@@ -1142,7 +1153,7 @@ type BaseSearchParamsWithoutQuery = {
|
|
|
1142
1153
|
*/
|
|
1143
1154
|
synonyms?: boolean | undefined;
|
|
1144
1155
|
/**
|
|
1145
|
-
* Whether to include a `queryID` attribute in the response The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/doc/guides/sending-events/getting-started).
|
|
1156
|
+
* Whether to include a `queryID` attribute in the response. The query ID is a unique identifier for a search query and is required for tracking [click and conversion events](https://www.algolia.com/doc/guides/sending-events/getting-started).
|
|
1146
1157
|
*/
|
|
1147
1158
|
clickAnalytics?: boolean | undefined;
|
|
1148
1159
|
/**
|
|
@@ -1165,6 +1176,11 @@ type BaseSearchParamsWithoutQuery = {
|
|
|
1165
1176
|
|
|
1166
1177
|
type BaseSearchParams = SearchParamsQuery & BaseSearchParamsWithoutQuery;
|
|
1167
1178
|
|
|
1179
|
+
/**
|
|
1180
|
+
* Strategy for computing the Attribute ranking criterion. This mainly affects multi-word queries with matches in more than one attribute. The `ranking` setting decides whether `best` takes effect. When Attribute comes after Proximity, which is the default order, the engine always uses the `minProximity` strategy and ignores `best`. To select `best`, move Attribute before Proximity in `ranking`. The `sum` strategy applies in both orders. - `minProximity`. Pick the best matching attribute from the attributes that form the best proximity score. On an ordered attribute, the match position breaks ties. - `best`. Pick the best matching attribute from all attributes that match any query word. On an ordered attribute, the match position breaks ties. - `sum`. Add up a score for every query word instead of picking one attribute. Each word\'s score comes from the attribute it matched, and from its position in that attribute when the attribute is ordered. A query word that matches nothing adds a large penalty. A record with a lower total ranks higher. A record therefore cannot rank high only because one word of a multi-word query matched a top attribute. Use `sum` with short, relevant attributes, and set long-text attributes to unordered.
|
|
1181
|
+
*/
|
|
1182
|
+
type AttributeCriteriaComputedBy = 'minProximity' | 'best' | 'sum';
|
|
1183
|
+
|
|
1168
1184
|
/**
|
|
1169
1185
|
* Search mode the index will use to query for results. This setting only applies to indices, for which Algolia enabled NeuralSearch for you.
|
|
1170
1186
|
*/
|
|
@@ -1182,7 +1198,7 @@ type SemanticSearch = {
|
|
|
1182
1198
|
|
|
1183
1199
|
type IndexSettingsAsSearchParams = {
|
|
1184
1200
|
/**
|
|
1185
|
-
* Attributes to include in the API response To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
|
|
1201
|
+
* Attributes to include in the API response. To reduce the size of your response, you can retrieve only some of the attributes. Attribute names are case-sensitive - `*` retrieves all attributes, except attributes included in the `customRanking` and `unretrievableAttributes` settings. - To retrieve all attributes except a specific one, prefix the attribute with a dash and combine it with the `*`: `[\"*\", \"-ATTRIBUTE\"]`. - The `objectID` attribute is always included.
|
|
1186
1202
|
*/
|
|
1187
1203
|
attributesToRetrieve?: Array<string> | undefined;
|
|
1188
1204
|
/**
|
|
@@ -1190,11 +1206,11 @@ type IndexSettingsAsSearchParams = {
|
|
|
1190
1206
|
*/
|
|
1191
1207
|
ranking?: Array<string> | undefined;
|
|
1192
1208
|
/**
|
|
1193
|
-
* Relevancy threshold below which less relevant results aren\'t included in the results You can only set `relevancyStrictness` on [virtual replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/#
|
|
1209
|
+
* Relevancy threshold below which less relevant results aren\'t included in the results. You can only set `relevancyStrictness` on [virtual replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/in-depth/replicas/#standard-and-virtual-replicas). Use this setting to strike a balance between the relevance and number of returned results.
|
|
1194
1210
|
*/
|
|
1195
1211
|
relevancyStrictness?: number | undefined;
|
|
1196
1212
|
/**
|
|
1197
|
-
* Attributes to highlight By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js).
|
|
1213
|
+
* Attributes to highlight. By default, all searchable attributes are highlighted. Use `*` to highlight all attributes or use an empty array `[]` to turn off highlighting. Attribute names are case-sensitive With highlighting, strings that match the search query are surrounded by HTML tags defined by `highlightPreTag` and `highlightPostTag`. You can use this to visually highlight matching parts of a search query in your UI For more information, see [Highlighting and snippeting](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/highlighting-snippeting/js).
|
|
1198
1214
|
*/
|
|
1199
1215
|
attributesToHighlight?: Array<string> | undefined;
|
|
1200
1216
|
/**
|
|
@@ -1222,20 +1238,20 @@ type IndexSettingsAsSearchParams = {
|
|
|
1222
1238
|
*/
|
|
1223
1239
|
hitsPerPage?: number | undefined;
|
|
1224
1240
|
/**
|
|
1225
|
-
* Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#
|
|
1241
|
+
* Minimum number of characters a word in the search query must contain to accept matches with [one typo](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configure-word-size-threshold-for-typos).
|
|
1226
1242
|
*/
|
|
1227
1243
|
minWordSizefor1Typo?: number | undefined;
|
|
1228
1244
|
/**
|
|
1229
|
-
* Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#
|
|
1245
|
+
* Minimum number of characters a word in the search query must contain to accept matches with [two typos](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/in-depth/configuring-typo-tolerance/#configure-word-size-threshold-for-typos).
|
|
1230
1246
|
*/
|
|
1231
1247
|
minWordSizefor2Typos?: number | undefined;
|
|
1232
1248
|
typoTolerance?: TypoTolerance | undefined;
|
|
1233
1249
|
/**
|
|
1234
|
-
* Whether to allow typos on numbers in the search query Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
|
|
1250
|
+
* Whether to allow typos on numbers in the search query. Turn off this setting to reduce the number of irrelevant matches when searching in large sets of similar numbers.
|
|
1235
1251
|
*/
|
|
1236
1252
|
allowTyposOnNumericTokens?: boolean | undefined;
|
|
1237
1253
|
/**
|
|
1238
|
-
* Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance). Attribute names are case-sensitive Returning only exact matches can help when - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
|
|
1254
|
+
* Attributes for which you want to turn off [typo tolerance](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance). Attribute names are case-sensitive Returning only exact matches can help when - [Searching in hyphenated attributes](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/typo-tolerance/how-to/how-to-search-in-hyphenated-attributes). - Reducing the number of matches when you have too many. This can happen with attributes that are long blocks of text, such as product descriptions. Consider alternatives such as `disableTypoToleranceOnWords` or adding synonyms if your attributes have intentional unusual spellings that might look like typos.
|
|
1239
1255
|
*/
|
|
1240
1256
|
disableTypoToleranceOnAttributes?: Array<string> | undefined;
|
|
1241
1257
|
ignorePlurals?: IgnorePlurals | undefined;
|
|
@@ -1245,7 +1261,7 @@ type IndexSettingsAsSearchParams = {
|
|
|
1245
1261
|
*/
|
|
1246
1262
|
queryLanguages?: Array<SupportedLanguage> | undefined;
|
|
1247
1263
|
/**
|
|
1248
|
-
* Whether to split compound words in the query into their building blocks For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#
|
|
1264
|
+
* Whether to split compound words in the query into their building blocks. For more information, see [Word segmentation](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/handling-natural-languages-nlp/in-depth/language-specific-configurations/#split-compound-words). Word segmentation is supported for these languages: German, Dutch, Finnish, Swedish, and Norwegian. Decompounding doesn\'t work for words with [non-spacing mark Unicode characters](https://www.charactercodes.net/category/non-spacing_mark). For example, `Gartenstühle` won\'t be decompounded if the `ü` consists of `u` (U+0075) and `◌̈` (U+0308).
|
|
1249
1265
|
*/
|
|
1250
1266
|
decompoundQuery?: boolean | undefined;
|
|
1251
1267
|
/**
|
|
@@ -1261,7 +1277,7 @@ type IndexSettingsAsSearchParams = {
|
|
|
1261
1277
|
mode?: Mode | undefined;
|
|
1262
1278
|
semanticSearch?: SemanticSearch | undefined;
|
|
1263
1279
|
/**
|
|
1264
|
-
* Whether to support phrase matching and excluding words from search queries Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
|
|
1280
|
+
* Whether to support phrase matching and excluding words from search queries. Use the `advancedSyntaxFeatures` parameter to control which feature is supported.
|
|
1265
1281
|
*/
|
|
1266
1282
|
advancedSyntax?: boolean | undefined;
|
|
1267
1283
|
optionalWords?: OptionalWords | null | undefined;
|
|
@@ -1271,24 +1287,24 @@ type IndexSettingsAsSearchParams = {
|
|
|
1271
1287
|
disableExactOnAttributes?: Array<string> | undefined;
|
|
1272
1288
|
exactOnSingleWordQuery?: ExactOnSingleWordQuery | undefined;
|
|
1273
1289
|
/**
|
|
1274
|
-
* Determine which plurals and synonyms should be considered an exact matches By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example - \"swimsuit\" and \"swimsuits\" are treated the same - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)) - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
|
|
1290
|
+
* Determine which plurals and synonyms should be considered an exact matches. By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching. For example: - \"swimsuit\" and \"swimsuits\" are treated the same. - \"swimsuit\" and \"swimwear\" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)). - `ignorePlurals`. Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches. - `singleWordSynonym`. Single-word synonyms, such as \"NY\" = \"NYC\", are considered exact matches. - `multiWordsSynonym`. Multi-word synonyms, such as \"NY\" = \"New York\", are considered exact matches.
|
|
1275
1291
|
*/
|
|
1276
1292
|
alternativesAsExact?: Array<AlternativesAsExact> | undefined;
|
|
1277
1293
|
/**
|
|
1278
|
-
* Advanced search syntax features you want to support - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\" - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\" This setting only has an effect if `advancedSyntax` is true.
|
|
1294
|
+
* Advanced search syntax features you want to support. - `exactPhrase`. Phrases in quotes must match exactly. For example, `sparkly blue \"iPhone case\"` only returns records with the exact string \"iPhone case\". - `excludeWords`. Query words prefixed with a `-` must not occur in a record. For example, `search -engine` matches records that contain \"search\" but not \"engine\". This setting only has an effect if `advancedSyntax` is true.
|
|
1279
1295
|
*/
|
|
1280
1296
|
advancedSyntaxFeatures?: Array<AdvancedSyntaxFeatures> | undefined;
|
|
1281
1297
|
distinct?: Distinct | undefined;
|
|
1282
1298
|
/**
|
|
1283
|
-
* Whether to replace a highlighted word with the matched synonym By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
|
|
1299
|
+
* Whether to replace a highlighted word with the matched synonym. By default, the original words are highlighted even if a synonym matches. For example, with `home` as a synonym for `house` and a search for `home`, records matching either \"home\" or \"house\" are included in the search results, and either \"home\" or \"house\" are highlighted With `replaceSynonymsInHighlight` set to `true`, a search for `home` still matches the same records, but all occurrences of \"house\" are replaced by \"home\" in the highlighted response.
|
|
1284
1300
|
*/
|
|
1285
1301
|
replaceSynonymsInHighlight?: boolean | undefined;
|
|
1286
1302
|
/**
|
|
1287
|
-
* Minimum proximity score for two matching words This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
|
|
1303
|
+
* Minimum proximity score for two matching words. This adjusts the [Proximity ranking criterion](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#proximity) by equally scoring matches that are farther apart For example, if `minProximity` is 2, neighboring matches and matches with one word between them would have the same score.
|
|
1288
1304
|
*/
|
|
1289
1305
|
minProximity?: number | undefined;
|
|
1290
1306
|
/**
|
|
1291
|
-
* Properties to include in the API response of search and browse requests By default, all response properties are included. To reduce the response size, you can select which properties should be included An empty list may lead to an empty API response (except properties you can\'t exclude) You can\'t exclude these properties: `message`, `warning`, `cursor`, `abTestVariantID`, or any property added by setting `getRankingInfo` to true Your search depends on the `hits` field. If you omit this field, searches won\'t return any results. Your UI might also depend on other properties, for example, for pagination. Before restricting the response size, check the impact on your search experience.
|
|
1307
|
+
* Properties to include in the API response of search and browse requests. By default, all response properties are included. To reduce the response size, you can select which properties should be included An empty list may lead to an empty API response (except properties you can\'t exclude) You can\'t exclude these properties: `message`, `warning`, `cursor`, `abTestVariantID`, or any property added by setting `getRankingInfo` to true Your search depends on the `hits` field. If you omit this field, searches won\'t return any results. Your UI might also depend on other properties, for example, for pagination. Before restricting the response size, check the impact on your search experience.
|
|
1292
1308
|
*/
|
|
1293
1309
|
responseFields?: Array<string> | undefined;
|
|
1294
1310
|
/**
|
|
@@ -1296,16 +1312,17 @@ type IndexSettingsAsSearchParams = {
|
|
|
1296
1312
|
*/
|
|
1297
1313
|
maxValuesPerFacet?: number | undefined;
|
|
1298
1314
|
/**
|
|
1299
|
-
* Order in which to retrieve facet values - `count`. Facet values are retrieved by decreasing count. The count is the number of matching records containing this facet value - `alpha`. Retrieve facet values alphabetically This setting doesn\'t influence how facet values are displayed in your UI (see `renderingContent`). For more information, see [facet value display](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/facet-display/js).
|
|
1315
|
+
* Order in which to retrieve facet values. - `count`. Facet values are retrieved by decreasing count. The count is the number of matching records containing this facet value. - `alpha`. Retrieve facet values alphabetically. This setting doesn\'t influence how facet values are displayed in your UI (see `renderingContent`). For more information, see [facet value display](https://www.algolia.com/doc/guides/building-search-ui/ui-and-ux-patterns/facet-display/js).
|
|
1300
1316
|
*/
|
|
1301
1317
|
sortFacetValuesBy?: string | undefined;
|
|
1302
1318
|
/**
|
|
1303
|
-
* Whether the best matching attribute should be determined by minimum proximity This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting.
|
|
1319
|
+
* Whether the best matching attribute should be determined by minimum proximity. This setting only affects ranking if the Attribute ranking criterion comes before Proximity in the `ranking` setting. If true, the best matching attribute is selected based on the minimum proximity of multiple matches. Otherwise, the best matching attribute is determined by the order in the `searchableAttributes` setting. Prefer `attributeCriteriaComputedBy`, which expresses the same two behaviors and adds the `sum` strategy. If you set both, `attributeCriteriaComputedBy` takes precedence.
|
|
1304
1320
|
*/
|
|
1305
1321
|
attributeCriteriaComputedByMinProximity?: boolean | undefined;
|
|
1322
|
+
attributeCriteriaComputedBy?: AttributeCriteriaComputedBy | undefined;
|
|
1306
1323
|
renderingContent?: RenderingContent | undefined;
|
|
1307
1324
|
/**
|
|
1308
|
-
* Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking) This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
|
|
1325
|
+
* Whether this search will use [Dynamic Re-Ranking](https://www.algolia.com/doc/guides/algolia-ai/re-ranking). This setting only has an effect if you activated Dynamic Re-Ranking for this index in the Algolia dashboard.
|
|
1309
1326
|
*/
|
|
1310
1327
|
enableReRanking?: boolean | undefined;
|
|
1311
1328
|
reRankingApplyFilter?: ReRankingApplyFilter | null | undefined;
|
|
@@ -1352,7 +1369,7 @@ type SearchExtensions = {
|
|
|
1352
1369
|
};
|
|
1353
1370
|
|
|
1354
1371
|
/**
|
|
1355
|
-
* - `default`: perform a search query - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
|
|
1372
|
+
* - `default`: perform a search query. - `facet` [searches for facet values](https://www.algolia.com/doc/guides/managing-results/refine-results/faceting/#search-for-facet-values).
|
|
1356
1373
|
*/
|
|
1357
1374
|
type SearchTypeDefault = 'default';
|
|
1358
1375
|
|
|
@@ -1605,7 +1622,7 @@ type LegacySearchQuery = LegacySearchForFacets | LegacySearchForHits;
|
|
|
1605
1622
|
*/
|
|
1606
1623
|
type LegacySearchMethodProps = LegacySearchQuery[];
|
|
1607
1624
|
|
|
1608
|
-
declare const apiClientVersion = "5.
|
|
1625
|
+
declare const apiClientVersion = "5.61.0";
|
|
1609
1626
|
declare function createLiteClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }: CreateClientOptions): {
|
|
1610
1627
|
transporter: _algolia_client_common.TransporterWithHttpInfo;
|
|
1611
1628
|
/**
|
|
@@ -1745,7 +1762,7 @@ type ApiKey = {
|
|
|
1745
1762
|
*/
|
|
1746
1763
|
description?: string | undefined;
|
|
1747
1764
|
/**
|
|
1748
|
-
* Index names or patterns that this API key can access. By default, an API key can access all indices in the same application. You can use leading and trailing wildcard characters (`*`): - `dev_*` matches all indices starting with \"dev_\" - `*_dev` matches all indices ending with \"_dev\" - `*_products_*` matches all indices containing \"_products_\".
|
|
1765
|
+
* Index names or patterns that this API key can access. By default, an API key can access all indices in the same application. You can use leading and trailing wildcard characters (`*`): - `dev_*` matches all indices starting with \"dev_\". - `*_dev` matches all indices ending with \"_dev\". - `*_products_*` matches all indices containing \"_products_\".
|
|
1749
1766
|
*/
|
|
1750
1767
|
indexes?: Array<string> | undefined;
|
|
1751
1768
|
/**
|
|
@@ -1761,7 +1778,7 @@ type ApiKey = {
|
|
|
1761
1778
|
*/
|
|
1762
1779
|
queryParameters?: string | undefined;
|
|
1763
1780
|
/**
|
|
1764
|
-
* Allowed HTTP referrers for this API key. By default, all referrers are allowed. You can use leading and trailing wildcard characters (`*`): - `https://algolia.com/_*` allows all referrers starting with \"https://algolia.com/\" - `*.algolia.com` allows all referrers ending with \".algolia.com\" - `*algolia.com*` allows all referrers in the domain \"algolia.com\". Like all HTTP headers, referrers can be spoofed. Don\'t rely on them to secure your data. For more information, see [HTTP referrer restrictions](https://www.algolia.com/doc/guides/security/security-best-practices/#http-
|
|
1781
|
+
* Allowed HTTP referrers for this API key. By default, all referrers are allowed. You can use leading and trailing wildcard characters (`*`): - `https://algolia.com/_*` allows all referrers starting with \"https://algolia.com/\". - `*.algolia.com` allows all referrers ending with \".algolia.com\". - `*algolia.com*` allows all referrers in the domain \"algolia.com\". Like all HTTP headers, referrers can be spoofed. Don\'t rely on them to secure your data. For more information, see [HTTP referrer restrictions](https://www.algolia.com/doc/guides/security/security-best-practices/#http-referrer-restrictions).
|
|
1765
1782
|
*/
|
|
1766
1783
|
referers?: Array<string> | undefined;
|
|
1767
1784
|
/**
|
|
@@ -1906,4 +1923,4 @@ type LiteClient = ReturnType<typeof createLiteClient>;
|
|
|
1906
1923
|
|
|
1907
1924
|
declare function liteClient(appId: string, apiKey: string, options?: ClientOptions | undefined): LiteClient;
|
|
1908
1925
|
|
|
1909
|
-
export { type Acl, type AdvancedSyntaxFeatures, type AlternativesAsExact, type ApiKey, type AroundPrecision, type AroundRadius, type AroundRadiusAll, type AutoFilteringFilterEntry, type AutoFilteringResult, type AutomaticFacetFilter, type AutomaticFacetFilters, type Banner, type BannerImage, type BannerImageUrl, type BannerLink, type BaseGetApiKeyResponse, type BaseIndexSettings, type BaseRecommendIndexSettings, type BaseRecommendRequest, type BaseRecommendSearchParams, type BaseSearchParams, type BaseSearchParamsWithoutQuery, type BaseSearchResponse, type BooleanString, type BoughtTogetherQuery, type BrowsePagination, type BrowseParamsObject, type BrowseResponse, type CategoryPrediction, type CategoryPredictionBin, type ConsequenceParams, type ConsequenceQuery, type ConsequenceQueryObject, type Cursor, type CustomPostProps, type Distinct, type Edit, type EditType, type ErrorBase, type ExactOnSingleWordQuery, type Exhaustive, type FacetFilters, type FacetHits, type FacetOrdering, type FacetStats, type FallbackParams, type FbtModel, type FrequentlyBoughtTogether, type GetApiKeyResponse, type GetRecommendationsParams, type GetRecommendationsResponse, type HierarchyPathEntry, type HighlightResult, type HighlightResultOption, type Hit, type IgnorePlurals, type IndexSettings, type IndexSettingsAsSearchParams, type IndexSettingsFacets, type InsideBoundingBox, type LegacyGetRecommendationsParams, type LegacySearchMethodProps, type LiteClient, type LookingSimilar, type LookingSimilarModel, type LookingSimilarQuery, type MatchLevel, type MatchedGeoLocation, type Mode, type NumericFilters, type OptionalFilters, type OptionalWords, type Params, type Personalization, type QueryCategorization, type QueryCategorizationType, type QueryType, type Range, type RankingInfo, type ReRankingApplyFilter, type RecommendHit, type RecommendIndexSettings, type RecommendSearchParams, type RecommendationsHit, type RecommendationsHits, type RecommendationsRequest, type RecommendationsResults, type Redirect, type RedirectRuleIndexData, type RedirectRuleIndexMetadata, type RedirectURL, type RelatedModel, type RelatedProducts, type RelatedQuery, type RemoveStopWords, type RemoveWordsIfNoResults, type RenderingContent, type ResponseExtensions, type SearchExtensions, type SearchExtensionsQueryCategorization, type SearchForFacetValuesResponse, type SearchForFacets, type SearchForFacetsOptions, type SearchForHits, type SearchForHitsOptions, type SearchHits, type SearchMethodParams, type SearchPagination, type SearchParams, type SearchParamsObject, type SearchParamsQuery, type SearchParamsString, type SearchQuery, type SearchResponse, type SearchResponsePartial, type SearchResponses, type SearchResult, type SearchStrategy, type SearchTypeDefault, type SearchTypeFacet, type SemanticSearch, type SettingsResponse, type SnippetResult, type SnippetResultOption, type SortRemainingBy, type SupportedLanguage, type TagFilters, type TrendingFacetHit, type TrendingFacets, type TrendingFacetsModel, type TrendingFacetsQuery, type TrendingItems, type TrendingItemsModel, type TrendingItemsQuery, type TypoTolerance, type TypoToleranceEnum, type Value, type Widgets, type WithPrimary, apiClientVersion, liteClient };
|
|
1926
|
+
export { type Acl, type AdvancedSyntaxFeatures, type AlternativesAsExact, type ApiKey, type AroundPrecision, type AroundRadius, type AroundRadiusAll, type AttributeCriteriaComputedBy, type AutoFilteringFilterEntry, type AutoFilteringResult, type AutomaticFacetFilter, type AutomaticFacetFilters, type Banner, type BannerImage, type BannerImageUrl, type BannerLink, type BaseGetApiKeyResponse, type BaseIndexSettings, type BaseRecommendIndexSettings, type BaseRecommendRequest, type BaseRecommendSearchParams, type BaseSearchParams, type BaseSearchParamsWithoutQuery, type BaseSearchResponse, type BooleanString, type BoughtTogetherQuery, type BrowsePagination, type BrowseParamsObject, type BrowseResponse, type CategoryPrediction, type CategoryPredictionBin, type ConsequenceParams, type ConsequenceQuery, type ConsequenceQueryObject, type Cursor, type CustomPostProps, type Distinct, type Edit, type EditType, type ErrorBase, type ExactOnSingleWordQuery, type Exhaustive, type FacetFilters, type FacetHits, type FacetOrdering, type FacetStats, type FallbackParams, type FbtModel, type FrequentlyBoughtTogether, type GetApiKeyResponse, type GetRecommendationsParams, type GetRecommendationsResponse, type HierarchyPathEntry, type HighlightResult, type HighlightResultOption, type Hit, type IgnorePlurals, type IndexSettings, type IndexSettingsAsSearchParams, type IndexSettingsFacets, type InsideBoundingBox, type LegacyGetRecommendationsParams, type LegacySearchMethodProps, type LiteClient, type LookingSimilar, type LookingSimilarModel, type LookingSimilarQuery, type MatchLevel, type MatchedGeoLocation, type Mode, type NumericFilters, type OptionalFilters, type OptionalWords, type Params, type Personalization, type QueryCategorization, type QueryCategorizationType, type QueryType, type Range, type RankingInfo, type ReRankingApplyFilter, type RecommendHit, type RecommendIndexSettings, type RecommendSearchParams, type RecommendationsHit, type RecommendationsHits, type RecommendationsRequest, type RecommendationsResults, type Redirect, type RedirectRuleIndexData, type RedirectRuleIndexMetadata, type RedirectURL, type RelatedModel, type RelatedProducts, type RelatedQuery, type RemoveStopWords, type RemoveWordsIfNoResults, type RenderingContent, type ResponseExtensions, type ResultCard, type SearchExtensions, type SearchExtensionsQueryCategorization, type SearchForFacetValuesResponse, type SearchForFacets, type SearchForFacetsOptions, type SearchForHits, type SearchForHitsOptions, type SearchHits, type SearchMethodParams, type SearchPagination, type SearchParams, type SearchParamsObject, type SearchParamsQuery, type SearchParamsString, type SearchQuery, type SearchResponse, type SearchResponsePartial, type SearchResponses, type SearchResult, type SearchStrategy, type SearchTypeDefault, type SearchTypeFacet, type SemanticSearch, type SettingsResponse, type SnippetResult, type SnippetResultOption, type SortRemainingBy, type SupportedLanguage, type TagFilters, type TrendingFacetHit, type TrendingFacets, type TrendingFacetsModel, type TrendingFacetsQuery, type TrendingItems, type TrendingItemsModel, type TrendingItemsQuery, type TypoTolerance, type TypoToleranceEnum, type Value, type Widgets, type WithPrimary, apiClientVersion, liteClient };
|