@algolia/client-search 5.6.1 → 5.8.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 -6
- package/dist/browser.d.ts +1671 -1651
- package/dist/builds/browser.js +94 -156
- package/dist/builds/browser.js.map +1 -1
- package/dist/builds/browser.min.js +1 -1
- package/dist/builds/browser.min.js.map +1 -1
- package/dist/builds/browser.umd.js +2 -2
- package/dist/builds/fetch.js +94 -156
- package/dist/builds/fetch.js.map +1 -1
- package/dist/builds/node.cjs +89 -151
- package/dist/builds/node.cjs.map +1 -1
- package/dist/builds/node.js +95 -157
- package/dist/builds/node.js.map +1 -1
- package/dist/fetch.d.ts +1424 -1403
- package/dist/node.d.cts +1424 -1403
- package/dist/node.d.ts +1424 -1403
- package/dist/src/searchClient.cjs +87 -149
- package/dist/src/searchClient.cjs.map +1 -1
- package/dist/src/searchClient.js +90 -152
- package/dist/src/searchClient.js.map +1 -1
- package/index.js +1 -1
- package/model/acl.ts +1 -1
- package/model/action.ts +4 -4
- package/model/alternativesAsExact.ts +1 -1
- package/model/anchoring.ts +2 -2
- package/model/apiKey.ts +4 -4
- package/model/aroundPrecision.ts +1 -1
- package/model/aroundRadius.ts +1 -1
- package/model/attributeToUpdate.ts +1 -1
- package/model/automaticFacetFilters.ts +1 -1
- package/model/banner.ts +13 -0
- package/model/bannerImage.ts +12 -0
- package/model/bannerImageUrl.ts +8 -0
- package/model/bannerLink.ts +8 -0
- package/model/banners.ts +10 -0
- package/model/baseIndexSettings.ts +15 -15
- package/model/baseSearchParams.ts +1 -1
- package/model/baseSearchParamsWithoutQuery.ts +8 -8
- package/model/baseSearchResponse.ts +2 -2
- package/model/batchAssignUserIdsParams.ts +1 -1
- package/model/batchDictionaryEntriesParams.ts +1 -1
- package/model/batchParams.ts +1 -1
- package/model/batchResponse.ts +1 -1
- package/model/batchWriteParams.ts +1 -1
- package/model/booleanString.ts +1 -1
- package/model/browseParams.ts +2 -1
- package/model/browseParamsObject.ts +1 -1
- package/model/browseResponse.ts +1 -1
- package/model/builtInOperationType.ts +4 -4
- package/model/builtInOperationValue.ts +1 -1
- package/model/clientMethodProps.ts +50 -34
- package/model/consequence.ts +2 -2
- package/model/consequenceQueryObject.ts +2 -2
- package/model/deleteByParams.ts +3 -3
- package/model/dictionaryEntry.ts +2 -2
- package/model/dictionaryEntryState.ts +1 -1
- package/model/dictionaryType.ts +1 -1
- package/model/facetFilters.ts +1 -1
- package/model/facetOrdering.ts +1 -1
- package/model/facets.ts +1 -1
- package/model/fetchedIndex.ts +1 -1
- package/model/getApiKeyResponse.ts +1 -1
- package/model/getLogsResponse.ts +1 -1
- package/model/getObjectsParams.ts +1 -1
- package/model/getObjectsRequest.ts +1 -1
- package/model/getTopUserIdsResponse.ts +1 -1
- package/model/hasPendingMappingsResponse.ts +1 -1
- package/model/highlightResult.ts +1 -1
- package/model/highlightResultOption.ts +1 -1
- package/model/hit.ts +2 -2
- package/model/ignorePlurals.ts +1 -1
- package/model/index.ts +13 -7
- package/model/indexSettingsAsSearchParams.ts +15 -15
- package/model/listApiKeysResponse.ts +1 -1
- package/model/listClustersResponse.ts +1 -1
- package/model/listIndicesResponse.ts +1 -1
- package/model/listUserIdsResponse.ts +1 -1
- package/model/log.ts +1 -1
- package/model/logType.ts +1 -1
- package/model/matchLevel.ts +1 -1
- package/model/mode.ts +1 -1
- package/model/multipleBatchResponse.ts +2 -2
- package/model/numericFilters.ts +2 -2
- package/model/operationIndexParams.ts +1 -1
- package/model/operationType.ts +1 -1
- package/model/optionalFilters.ts +1 -1
- package/model/promote.ts +1 -1
- package/model/promoteObjectIDs.ts +1 -1
- package/model/queryType.ts +2 -2
- package/model/reRankingApplyFilter.ts +1 -1
- package/model/redirect.ts +1 -1
- package/model/removeStopWords.ts +1 -1
- package/model/removeWordsIfNoResults.ts +1 -1
- package/model/renderingContent.ts +4 -1
- package/model/replaceAllObjectsResponse.ts +1 -1
- package/model/rule.ts +2 -2
- package/model/scopeType.ts +1 -1
- package/model/searchDictionaryEntriesResponse.ts +1 -1
- package/model/searchForFacetValuesResponse.ts +1 -1
- package/model/searchForFacets.ts +1 -1
- package/model/searchForHits.ts +1 -1
- package/model/searchHits.ts +1 -1
- package/model/searchMethodParams.ts +1 -1
- package/model/searchParams.ts +1 -1
- package/model/searchQuery.ts +1 -1
- package/model/searchResponse.ts +1 -1
- package/model/searchResponses.ts +1 -1
- package/model/searchResult.ts +1 -1
- package/model/searchRulesResponse.ts +1 -1
- package/model/searchSynonymsResponse.ts +1 -1
- package/model/searchUserIdsParams.ts +1 -1
- package/model/searchUserIdsResponse.ts +2 -2
- package/model/securedApiKeyRestrictions.ts +1 -1
- package/model/semanticSearch.ts +1 -1
- package/model/snippetResult.ts +1 -1
- package/model/sortRemainingBy.ts +1 -1
- package/model/standardEntries.ts +3 -3
- package/model/supportedLanguage.ts +1 -1
- package/model/synonymHit.ts +3 -3
- package/model/synonymType.ts +1 -1
- package/model/tagFilters.ts +1 -1
- package/model/taskStatus.ts +1 -1
- package/model/typoTolerance.ts +2 -2
- package/model/userHit.ts +1 -1
- package/model/value.ts +2 -2
- package/model/widgets.ts +10 -0
- package/package.json +7 -7
package/dist/builds/browser.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
// builds/browser.ts
|
|
2
|
+
import { createXhrRequester } from "@algolia/requester-browser-xhr";
|
|
2
3
|
import {
|
|
3
|
-
createNullLogger,
|
|
4
|
-
createMemoryCache,
|
|
5
|
-
createFallbackableCache,
|
|
6
4
|
createBrowserLocalStorageCache,
|
|
5
|
+
createFallbackableCache,
|
|
6
|
+
createMemoryCache,
|
|
7
|
+
createNullLogger,
|
|
7
8
|
DEFAULT_CONNECT_TIMEOUT_BROWSER,
|
|
8
9
|
DEFAULT_READ_TIMEOUT_BROWSER,
|
|
9
10
|
DEFAULT_WRITE_TIMEOUT_BROWSER
|
|
10
11
|
} from "@algolia/client-common";
|
|
11
|
-
import { createXhrRequester } from "@algolia/requester-browser-xhr";
|
|
12
12
|
|
|
13
13
|
// src/searchClient.ts
|
|
14
14
|
import {
|
|
15
|
+
ApiError,
|
|
15
16
|
createAuth,
|
|
17
|
+
createIterablePromise,
|
|
16
18
|
createTransporter,
|
|
17
19
|
getAlgoliaAgent,
|
|
18
|
-
shuffle
|
|
19
|
-
ApiError,
|
|
20
|
-
createIterablePromise
|
|
20
|
+
shuffle
|
|
21
21
|
} from "@algolia/client-common";
|
|
22
|
-
var apiClientVersion = "5.
|
|
22
|
+
var apiClientVersion = "5.8.0";
|
|
23
23
|
function getDefaultHosts(appId) {
|
|
24
24
|
return [
|
|
25
25
|
{
|
|
@@ -517,8 +517,7 @@ function createSearchClient({
|
|
|
517
517
|
* Creates a new API key with specific permissions and restrictions.
|
|
518
518
|
*
|
|
519
519
|
* Required API Key ACLs:
|
|
520
|
-
*
|
|
521
|
-
*
|
|
520
|
+
* - admin
|
|
522
521
|
* @param apiKey - The apiKey object.
|
|
523
522
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
524
523
|
*/
|
|
@@ -545,12 +544,11 @@ function createSearchClient({
|
|
|
545
544
|
* If a record with the specified object ID exists, the existing record is replaced. Otherwise, a new record is added to the index. To update _some_ attributes of an existing record, use the [`partial` operation](#tag/Records/operation/partialUpdateObject) instead. To add, update, or replace multiple records, use the [`batch` operation](#tag/Records/operation/batch).
|
|
546
545
|
*
|
|
547
546
|
* Required API Key ACLs:
|
|
548
|
-
*
|
|
549
|
-
*
|
|
547
|
+
* - addObject
|
|
550
548
|
* @param addOrUpdateObject - The addOrUpdateObject object.
|
|
551
549
|
* @param addOrUpdateObject.indexName - Name of the index on which to perform the operation.
|
|
552
550
|
* @param addOrUpdateObject.objectID - Unique record identifier.
|
|
553
|
-
* @param addOrUpdateObject.body - The record
|
|
551
|
+
* @param addOrUpdateObject.body - The record. A schemaless object with attributes that are useful in the context of search and discovery.
|
|
554
552
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
555
553
|
*/
|
|
556
554
|
addOrUpdateObject({ indexName, objectID, body }, requestOptions) {
|
|
@@ -579,8 +577,7 @@ function createSearchClient({
|
|
|
579
577
|
* Adds a source to the list of allowed sources.
|
|
580
578
|
*
|
|
581
579
|
* Required API Key ACLs:
|
|
582
|
-
*
|
|
583
|
-
*
|
|
580
|
+
* - admin
|
|
584
581
|
* @param source - Source to add.
|
|
585
582
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
586
583
|
*/
|
|
@@ -607,8 +604,7 @@ function createSearchClient({
|
|
|
607
604
|
* Assigns or moves a user ID to a cluster. The time it takes to move a user is proportional to the amount of data linked to the user ID.
|
|
608
605
|
*
|
|
609
606
|
* Required API Key ACLs:
|
|
610
|
-
*
|
|
611
|
-
*
|
|
607
|
+
* - admin
|
|
612
608
|
* @param assignUserId - The assignUserId object.
|
|
613
609
|
* @param assignUserId.xAlgoliaUserID - Unique identifier of the user who makes the search request.
|
|
614
610
|
* @param assignUserId.assignUserIdParams - The assignUserIdParams object.
|
|
@@ -641,7 +637,6 @@ function createSearchClient({
|
|
|
641
637
|
},
|
|
642
638
|
/**
|
|
643
639
|
* Adds, updates, or deletes records in one index with a single API request. Batching index updates reduces latency and increases data integrity. - Actions are applied in the order they\'re specified. - Actions are equivalent to the individual API requests of the same name.
|
|
644
|
-
*
|
|
645
640
|
* @param batch - The batch object.
|
|
646
641
|
* @param batch.indexName - Name of the index on which to perform the operation.
|
|
647
642
|
* @param batch.batchWriteParams - The batchWriteParams object.
|
|
@@ -673,8 +668,7 @@ function createSearchClient({
|
|
|
673
668
|
* Assigns multiple user IDs to a cluster. **You can\'t move users with this operation**.
|
|
674
669
|
*
|
|
675
670
|
* Required API Key ACLs:
|
|
676
|
-
*
|
|
677
|
-
*
|
|
671
|
+
* - admin
|
|
678
672
|
* @param batchAssignUserIds - The batchAssignUserIds object.
|
|
679
673
|
* @param batchAssignUserIds.xAlgoliaUserID - Unique identifier of the user who makes the search request.
|
|
680
674
|
* @param batchAssignUserIds.batchAssignUserIdsParams - The batchAssignUserIdsParams object.
|
|
@@ -712,8 +706,7 @@ function createSearchClient({
|
|
|
712
706
|
* Adds or deletes multiple entries from your plurals, segmentation, or stop word dictionaries.
|
|
713
707
|
*
|
|
714
708
|
* Required API Key ACLs:
|
|
715
|
-
*
|
|
716
|
-
*
|
|
709
|
+
* - editSettings
|
|
717
710
|
* @param batchDictionaryEntries - The batchDictionaryEntries object.
|
|
718
711
|
* @param batchDictionaryEntries.dictionaryName - Dictionary type in which to search.
|
|
719
712
|
* @param batchDictionaryEntries.batchDictionaryEntriesParams - The batchDictionaryEntriesParams object.
|
|
@@ -747,11 +740,10 @@ function createSearchClient({
|
|
|
747
740
|
return transporter.request(request, requestOptions);
|
|
748
741
|
},
|
|
749
742
|
/**
|
|
750
|
-
* Retrieves records from an index, up to 1,000 per request. While searching retrieves _hits_ (records augmented with attributes for highlighting and ranking details), browsing _just_ returns matching records. This can be useful if you want to export your indices. - The Analytics API doesn\'t collect data when using `browse`. - Records are ranked by attributes and custom ranking. - There\'s no ranking for: typo-tolerance, number of matched words, proximity, geo distance. Browse requests automatically apply these settings: - `advancedSyntax`: `false` - `attributesToHighlight`: `[]` - `attributesToSnippet`: `[]` - `distinct`: `false` - `enablePersonalization`: `false` - `enableRules`: `false` - `facets`: `[]` - `getRankingInfo`: `false` - `ignorePlurals`: `false` - `optionalFilters`: `[]` - `typoTolerance`: `true` or `false` (`min` and `strict`
|
|
743
|
+
* Retrieves records from an index, up to 1,000 per request. While searching retrieves _hits_ (records augmented with attributes for highlighting and ranking details), browsing _just_ returns matching records. This can be useful if you want to export your indices. - The Analytics API doesn\'t collect data when using `browse`. - Records are ranked by attributes and custom ranking. - There\'s no ranking for: typo-tolerance, number of matched words, proximity, geo distance. Browse requests automatically apply these settings: - `advancedSyntax`: `false` - `attributesToHighlight`: `[]` - `attributesToSnippet`: `[]` - `distinct`: `false` - `enablePersonalization`: `false` - `enableRules`: `false` - `facets`: `[]` - `getRankingInfo`: `false` - `ignorePlurals`: `false` - `optionalFilters`: `[]` - `typoTolerance`: `true` or `false` (`min` and `strict` evaluate to `true`) If you send these parameters with your browse requests, they\'ll be ignored.
|
|
751
744
|
*
|
|
752
745
|
* Required API Key ACLs:
|
|
753
|
-
*
|
|
754
|
-
*
|
|
746
|
+
* - browse
|
|
755
747
|
* @param browse - The browse object.
|
|
756
748
|
* @param browse.indexName - Name of the index on which to perform the operation.
|
|
757
749
|
* @param browse.browseParams - The browseParams object.
|
|
@@ -777,8 +769,7 @@ function createSearchClient({
|
|
|
777
769
|
* Deletes only the records from an index while keeping settings, synonyms, and rules.
|
|
778
770
|
*
|
|
779
771
|
* Required API Key ACLs:
|
|
780
|
-
*
|
|
781
|
-
*
|
|
772
|
+
* - deleteIndex
|
|
782
773
|
* @param clearObjects - The clearObjects object.
|
|
783
774
|
* @param clearObjects.indexName - Name of the index on which to perform the operation.
|
|
784
775
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -802,8 +793,7 @@ function createSearchClient({
|
|
|
802
793
|
* Deletes all rules from the index.
|
|
803
794
|
*
|
|
804
795
|
* Required API Key ACLs:
|
|
805
|
-
*
|
|
806
|
-
*
|
|
796
|
+
* - editSettings
|
|
807
797
|
* @param clearRules - The clearRules object.
|
|
808
798
|
* @param clearRules.indexName - Name of the index on which to perform the operation.
|
|
809
799
|
* @param clearRules.forwardToReplicas - Whether changes are applied to replica indices.
|
|
@@ -817,7 +807,7 @@ function createSearchClient({
|
|
|
817
807
|
const headers = {};
|
|
818
808
|
const queryParameters = {};
|
|
819
809
|
if (forwardToReplicas !== void 0) {
|
|
820
|
-
queryParameters
|
|
810
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
821
811
|
}
|
|
822
812
|
const request = {
|
|
823
813
|
method: "POST",
|
|
@@ -831,8 +821,7 @@ function createSearchClient({
|
|
|
831
821
|
* Deletes all synonyms from the index.
|
|
832
822
|
*
|
|
833
823
|
* Required API Key ACLs:
|
|
834
|
-
*
|
|
835
|
-
*
|
|
824
|
+
* - editSettings
|
|
836
825
|
* @param clearSynonyms - The clearSynonyms object.
|
|
837
826
|
* @param clearSynonyms.indexName - Name of the index on which to perform the operation.
|
|
838
827
|
* @param clearSynonyms.forwardToReplicas - Whether changes are applied to replica indices.
|
|
@@ -846,7 +835,7 @@ function createSearchClient({
|
|
|
846
835
|
const headers = {};
|
|
847
836
|
const queryParameters = {};
|
|
848
837
|
if (forwardToReplicas !== void 0) {
|
|
849
|
-
queryParameters
|
|
838
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
850
839
|
}
|
|
851
840
|
const request = {
|
|
852
841
|
method: "POST",
|
|
@@ -858,7 +847,6 @@ function createSearchClient({
|
|
|
858
847
|
},
|
|
859
848
|
/**
|
|
860
849
|
* This method allow you to send requests to the Algolia REST API.
|
|
861
|
-
*
|
|
862
850
|
* @param customDelete - The customDelete object.
|
|
863
851
|
* @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
864
852
|
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
@@ -881,7 +869,6 @@ function createSearchClient({
|
|
|
881
869
|
},
|
|
882
870
|
/**
|
|
883
871
|
* This method allow you to send requests to the Algolia REST API.
|
|
884
|
-
*
|
|
885
872
|
* @param customGet - The customGet object.
|
|
886
873
|
* @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
887
874
|
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
@@ -904,7 +891,6 @@ function createSearchClient({
|
|
|
904
891
|
},
|
|
905
892
|
/**
|
|
906
893
|
* This method allow you to send requests to the Algolia REST API.
|
|
907
|
-
*
|
|
908
894
|
* @param customPost - The customPost object.
|
|
909
895
|
* @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
910
896
|
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
@@ -929,7 +915,6 @@ function createSearchClient({
|
|
|
929
915
|
},
|
|
930
916
|
/**
|
|
931
917
|
* This method allow you to send requests to the Algolia REST API.
|
|
932
|
-
*
|
|
933
918
|
* @param customPut - The customPut object.
|
|
934
919
|
* @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
|
|
935
920
|
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
@@ -956,8 +941,7 @@ function createSearchClient({
|
|
|
956
941
|
* Deletes the API key.
|
|
957
942
|
*
|
|
958
943
|
* Required API Key ACLs:
|
|
959
|
-
*
|
|
960
|
-
*
|
|
944
|
+
* - admin
|
|
961
945
|
* @param deleteApiKey - The deleteApiKey object.
|
|
962
946
|
* @param deleteApiKey.key - API key.
|
|
963
947
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -981,8 +965,7 @@ function createSearchClient({
|
|
|
981
965
|
* This operation doesn\'t accept empty queries or filters. It\'s more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](#tag/Records/operation/batch).
|
|
982
966
|
*
|
|
983
967
|
* Required API Key ACLs:
|
|
984
|
-
*
|
|
985
|
-
*
|
|
968
|
+
* - deleteIndex
|
|
986
969
|
* @param deleteBy - The deleteBy object.
|
|
987
970
|
* @param deleteBy.indexName - Name of the index on which to perform the operation.
|
|
988
971
|
* @param deleteBy.deleteByParams - The deleteByParams object.
|
|
@@ -1011,8 +994,7 @@ function createSearchClient({
|
|
|
1011
994
|
* Deletes an index and all its settings. - Deleting an index doesn\'t delete its analytics data. - If you try to delete a non-existing index, the operation is ignored without warning. - If the index you want to delete has replica indices, the replicas become independent indices. - If the index you want to delete is a replica index, you must first unlink it from its primary index before you can delete it. For more information, see [Delete replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/deleting-replicas/).
|
|
1012
995
|
*
|
|
1013
996
|
* Required API Key ACLs:
|
|
1014
|
-
*
|
|
1015
|
-
*
|
|
997
|
+
* - deleteIndex
|
|
1016
998
|
* @param deleteIndex - The deleteIndex object.
|
|
1017
999
|
* @param deleteIndex.indexName - Name of the index on which to perform the operation.
|
|
1018
1000
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1036,8 +1018,7 @@ function createSearchClient({
|
|
|
1036
1018
|
* Deletes a record by its object ID. To delete more than one record, use the [`batch` operation](#tag/Records/operation/batch). To delete records matching a query, use the [`deleteByQuery` operation](#tag/Records/operation/deleteBy).
|
|
1037
1019
|
*
|
|
1038
1020
|
* Required API Key ACLs:
|
|
1039
|
-
*
|
|
1040
|
-
*
|
|
1021
|
+
* - deleteObject
|
|
1041
1022
|
* @param deleteObject - The deleteObject object.
|
|
1042
1023
|
* @param deleteObject.indexName - Name of the index on which to perform the operation.
|
|
1043
1024
|
* @param deleteObject.objectID - Unique record identifier.
|
|
@@ -1065,8 +1046,7 @@ function createSearchClient({
|
|
|
1065
1046
|
* Deletes a rule by its ID. To find the object ID for rules, use the [`search` operation](#tag/Rules/operation/searchRules).
|
|
1066
1047
|
*
|
|
1067
1048
|
* Required API Key ACLs:
|
|
1068
|
-
*
|
|
1069
|
-
*
|
|
1049
|
+
* - editSettings
|
|
1070
1050
|
* @param deleteRule - The deleteRule object.
|
|
1071
1051
|
* @param deleteRule.indexName - Name of the index on which to perform the operation.
|
|
1072
1052
|
* @param deleteRule.objectID - Unique identifier of a rule object.
|
|
@@ -1084,7 +1064,7 @@ function createSearchClient({
|
|
|
1084
1064
|
const headers = {};
|
|
1085
1065
|
const queryParameters = {};
|
|
1086
1066
|
if (forwardToReplicas !== void 0) {
|
|
1087
|
-
queryParameters
|
|
1067
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1088
1068
|
}
|
|
1089
1069
|
const request = {
|
|
1090
1070
|
method: "DELETE",
|
|
@@ -1098,8 +1078,7 @@ function createSearchClient({
|
|
|
1098
1078
|
* Deletes a source from the list of allowed sources.
|
|
1099
1079
|
*
|
|
1100
1080
|
* Required API Key ACLs:
|
|
1101
|
-
*
|
|
1102
|
-
*
|
|
1081
|
+
* - admin
|
|
1103
1082
|
* @param deleteSource - The deleteSource object.
|
|
1104
1083
|
* @param deleteSource.source - IP address range of the source.
|
|
1105
1084
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1123,8 +1102,7 @@ function createSearchClient({
|
|
|
1123
1102
|
* Deletes a synonym by its ID. To find the object IDs of your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).
|
|
1124
1103
|
*
|
|
1125
1104
|
* Required API Key ACLs:
|
|
1126
|
-
*
|
|
1127
|
-
*
|
|
1105
|
+
* - editSettings
|
|
1128
1106
|
* @param deleteSynonym - The deleteSynonym object.
|
|
1129
1107
|
* @param deleteSynonym.indexName - Name of the index on which to perform the operation.
|
|
1130
1108
|
* @param deleteSynonym.objectID - Unique identifier of a synonym object.
|
|
@@ -1142,7 +1120,7 @@ function createSearchClient({
|
|
|
1142
1120
|
const headers = {};
|
|
1143
1121
|
const queryParameters = {};
|
|
1144
1122
|
if (forwardToReplicas !== void 0) {
|
|
1145
|
-
queryParameters
|
|
1123
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1146
1124
|
}
|
|
1147
1125
|
const request = {
|
|
1148
1126
|
method: "DELETE",
|
|
@@ -1153,8 +1131,7 @@ function createSearchClient({
|
|
|
1153
1131
|
return transporter.request(request, requestOptions);
|
|
1154
1132
|
},
|
|
1155
1133
|
/**
|
|
1156
|
-
* Gets the permissions and restrictions of an API key. When authenticating with the admin API key, you can request information for any of your application\'s keys. When authenticating with other API keys, you can only retrieve information for that key
|
|
1157
|
-
*
|
|
1134
|
+
* Gets the permissions and restrictions of an API key. When authenticating with the admin API key, you can request information for any of your application\'s keys. When authenticating with other API keys, you can only retrieve information for that key, with the description replaced by `<redacted>`.
|
|
1158
1135
|
* @param getApiKey - The getApiKey object.
|
|
1159
1136
|
* @param getApiKey.key - API key.
|
|
1160
1137
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1178,8 +1155,7 @@ function createSearchClient({
|
|
|
1178
1155
|
* Checks the status of a given application task.
|
|
1179
1156
|
*
|
|
1180
1157
|
* Required API Key ACLs:
|
|
1181
|
-
*
|
|
1182
|
-
*
|
|
1158
|
+
* - editSettings
|
|
1183
1159
|
* @param getAppTask - The getAppTask object.
|
|
1184
1160
|
* @param getAppTask.taskID - Unique task identifier.
|
|
1185
1161
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1203,8 +1179,7 @@ function createSearchClient({
|
|
|
1203
1179
|
* Lists supported languages with their supported dictionary types and number of custom entries.
|
|
1204
1180
|
*
|
|
1205
1181
|
* Required API Key ACLs:
|
|
1206
|
-
*
|
|
1207
|
-
*
|
|
1182
|
+
* - settings
|
|
1208
1183
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1209
1184
|
*/
|
|
1210
1185
|
getDictionaryLanguages(requestOptions) {
|
|
@@ -1223,8 +1198,7 @@ function createSearchClient({
|
|
|
1223
1198
|
* Retrieves the languages for which standard dictionary entries are turned off.
|
|
1224
1199
|
*
|
|
1225
1200
|
* Required API Key ACLs:
|
|
1226
|
-
*
|
|
1227
|
-
*
|
|
1201
|
+
* - settings
|
|
1228
1202
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1229
1203
|
*/
|
|
1230
1204
|
getDictionarySettings(requestOptions) {
|
|
@@ -1243,8 +1217,7 @@ function createSearchClient({
|
|
|
1243
1217
|
* The request must be authenticated by an API key with the [`logs` ACL](https://www.algolia.com/doc/guides/security/api-keys/#access-control-list-acl). - Logs are held for the last seven days. - Up to 1,000 API requests per server are logged. - This request counts towards your [operations quota](https://support.algolia.com/hc/en-us/articles/4406981829777-How-does-Algolia-count-records-and-operations-) but doesn\'t appear in the logs itself.
|
|
1244
1218
|
*
|
|
1245
1219
|
* Required API Key ACLs:
|
|
1246
|
-
*
|
|
1247
|
-
*
|
|
1220
|
+
* - logs
|
|
1248
1221
|
* @param getLogs - The getLogs object.
|
|
1249
1222
|
* @param getLogs.offset - First log entry to retrieve. The most recent entries are listed first.
|
|
1250
1223
|
* @param getLogs.length - Maximum number of entries to retrieve.
|
|
@@ -1257,16 +1230,16 @@ function createSearchClient({
|
|
|
1257
1230
|
const headers = {};
|
|
1258
1231
|
const queryParameters = {};
|
|
1259
1232
|
if (offset !== void 0) {
|
|
1260
|
-
queryParameters
|
|
1233
|
+
queryParameters["offset"] = offset.toString();
|
|
1261
1234
|
}
|
|
1262
1235
|
if (length !== void 0) {
|
|
1263
|
-
queryParameters
|
|
1236
|
+
queryParameters["length"] = length.toString();
|
|
1264
1237
|
}
|
|
1265
1238
|
if (indexName !== void 0) {
|
|
1266
|
-
queryParameters
|
|
1239
|
+
queryParameters["indexName"] = indexName.toString();
|
|
1267
1240
|
}
|
|
1268
1241
|
if (type !== void 0) {
|
|
1269
|
-
queryParameters
|
|
1242
|
+
queryParameters["type"] = type.toString();
|
|
1270
1243
|
}
|
|
1271
1244
|
const request = {
|
|
1272
1245
|
method: "GET",
|
|
@@ -1280,8 +1253,7 @@ function createSearchClient({
|
|
|
1280
1253
|
* Retrieves one record by its object ID. To retrieve more than one record, use the [`objects` operation](#tag/Records/operation/getObjects).
|
|
1281
1254
|
*
|
|
1282
1255
|
* Required API Key ACLs:
|
|
1283
|
-
*
|
|
1284
|
-
*
|
|
1256
|
+
* - search
|
|
1285
1257
|
* @param getObject - The getObject object.
|
|
1286
1258
|
* @param getObject.indexName - Name of the index on which to perform the operation.
|
|
1287
1259
|
* @param getObject.objectID - Unique record identifier.
|
|
@@ -1299,7 +1271,7 @@ function createSearchClient({
|
|
|
1299
1271
|
const headers = {};
|
|
1300
1272
|
const queryParameters = {};
|
|
1301
1273
|
if (attributesToRetrieve !== void 0) {
|
|
1302
|
-
queryParameters
|
|
1274
|
+
queryParameters["attributesToRetrieve"] = attributesToRetrieve.toString();
|
|
1303
1275
|
}
|
|
1304
1276
|
const request = {
|
|
1305
1277
|
method: "GET",
|
|
@@ -1313,8 +1285,7 @@ function createSearchClient({
|
|
|
1313
1285
|
* Retrieves one or more records, potentially from different indices. Records are returned in the same order as the requests.
|
|
1314
1286
|
*
|
|
1315
1287
|
* Required API Key ACLs:
|
|
1316
|
-
*
|
|
1317
|
-
*
|
|
1288
|
+
* - search
|
|
1318
1289
|
* @param getObjectsParams - Request object.
|
|
1319
1290
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1320
1291
|
*/
|
|
@@ -1343,8 +1314,7 @@ function createSearchClient({
|
|
|
1343
1314
|
* Retrieves a rule by its ID. To find the object ID of rules, use the [`search` operation](#tag/Rules/operation/searchRules).
|
|
1344
1315
|
*
|
|
1345
1316
|
* Required API Key ACLs:
|
|
1346
|
-
*
|
|
1347
|
-
*
|
|
1317
|
+
* - settings
|
|
1348
1318
|
* @param getRule - The getRule object.
|
|
1349
1319
|
* @param getRule.indexName - Name of the index on which to perform the operation.
|
|
1350
1320
|
* @param getRule.objectID - Unique identifier of a rule object.
|
|
@@ -1372,8 +1342,7 @@ function createSearchClient({
|
|
|
1372
1342
|
* Retrieves an object with non-null index settings.
|
|
1373
1343
|
*
|
|
1374
1344
|
* Required API Key ACLs:
|
|
1375
|
-
*
|
|
1376
|
-
*
|
|
1345
|
+
* - search
|
|
1377
1346
|
* @param getSettings - The getSettings object.
|
|
1378
1347
|
* @param getSettings.indexName - Name of the index on which to perform the operation.
|
|
1379
1348
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1397,8 +1366,7 @@ function createSearchClient({
|
|
|
1397
1366
|
* Retrieves all allowed IP addresses with access to your application.
|
|
1398
1367
|
*
|
|
1399
1368
|
* Required API Key ACLs:
|
|
1400
|
-
*
|
|
1401
|
-
*
|
|
1369
|
+
* - admin
|
|
1402
1370
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1403
1371
|
*/
|
|
1404
1372
|
getSources(requestOptions) {
|
|
@@ -1414,11 +1382,10 @@ function createSearchClient({
|
|
|
1414
1382
|
return transporter.request(request, requestOptions);
|
|
1415
1383
|
},
|
|
1416
1384
|
/**
|
|
1417
|
-
* Retrieves a
|
|
1385
|
+
* Retrieves a synonym by its ID. To find the object IDs for your synonyms, use the [`search` operation](#tag/Synonyms/operation/searchSynonyms).
|
|
1418
1386
|
*
|
|
1419
1387
|
* Required API Key ACLs:
|
|
1420
|
-
*
|
|
1421
|
-
*
|
|
1388
|
+
* - settings
|
|
1422
1389
|
* @param getSynonym - The getSynonym object.
|
|
1423
1390
|
* @param getSynonym.indexName - Name of the index on which to perform the operation.
|
|
1424
1391
|
* @param getSynonym.objectID - Unique identifier of a synonym object.
|
|
@@ -1446,8 +1413,7 @@ function createSearchClient({
|
|
|
1446
1413
|
* Checks the status of a given task. Indexing tasks are asynchronous. When you add, update, or delete records or indices, a task is created on a queue and completed depending on the load on the server. The indexing tasks\' responses include a task ID that you can use to check the status.
|
|
1447
1414
|
*
|
|
1448
1415
|
* Required API Key ACLs:
|
|
1449
|
-
*
|
|
1450
|
-
*
|
|
1416
|
+
* - addObject
|
|
1451
1417
|
* @param getTask - The getTask object.
|
|
1452
1418
|
* @param getTask.indexName - Name of the index on which to perform the operation.
|
|
1453
1419
|
* @param getTask.taskID - Unique task identifier.
|
|
@@ -1475,8 +1441,7 @@ function createSearchClient({
|
|
|
1475
1441
|
* Get the IDs of the 10 users with the highest number of records per cluster. Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time.
|
|
1476
1442
|
*
|
|
1477
1443
|
* Required API Key ACLs:
|
|
1478
|
-
*
|
|
1479
|
-
*
|
|
1444
|
+
* - admin
|
|
1480
1445
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1481
1446
|
*/
|
|
1482
1447
|
getTopUserIds(requestOptions) {
|
|
@@ -1495,8 +1460,7 @@ function createSearchClient({
|
|
|
1495
1460
|
* Returns the user ID data stored in the mapping. Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time.
|
|
1496
1461
|
*
|
|
1497
1462
|
* Required API Key ACLs:
|
|
1498
|
-
*
|
|
1499
|
-
*
|
|
1463
|
+
* - admin
|
|
1500
1464
|
* @param getUserId - The getUserId object.
|
|
1501
1465
|
* @param getUserId.userID - Unique identifier of the user who makes the search request.
|
|
1502
1466
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1520,8 +1484,7 @@ function createSearchClient({
|
|
|
1520
1484
|
* To determine when the time-consuming process of creating a large batch of users or migrating users from one cluster to another is complete, this operation retrieves the status of the process.
|
|
1521
1485
|
*
|
|
1522
1486
|
* Required API Key ACLs:
|
|
1523
|
-
*
|
|
1524
|
-
*
|
|
1487
|
+
* - admin
|
|
1525
1488
|
* @param hasPendingMappings - The hasPendingMappings object.
|
|
1526
1489
|
* @param hasPendingMappings.getClusters - Whether to include the cluster\'s pending mapping state in the response.
|
|
1527
1490
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1531,7 +1494,7 @@ function createSearchClient({
|
|
|
1531
1494
|
const headers = {};
|
|
1532
1495
|
const queryParameters = {};
|
|
1533
1496
|
if (getClusters !== void 0) {
|
|
1534
|
-
queryParameters
|
|
1497
|
+
queryParameters["getClusters"] = getClusters.toString();
|
|
1535
1498
|
}
|
|
1536
1499
|
const request = {
|
|
1537
1500
|
method: "GET",
|
|
@@ -1545,8 +1508,7 @@ function createSearchClient({
|
|
|
1545
1508
|
* Lists all API keys associated with your Algolia application, including their permissions and restrictions.
|
|
1546
1509
|
*
|
|
1547
1510
|
* Required API Key ACLs:
|
|
1548
|
-
*
|
|
1549
|
-
*
|
|
1511
|
+
* - admin
|
|
1550
1512
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1551
1513
|
*/
|
|
1552
1514
|
listApiKeys(requestOptions) {
|
|
@@ -1565,8 +1527,7 @@ function createSearchClient({
|
|
|
1565
1527
|
* Lists the available clusters in a multi-cluster setup.
|
|
1566
1528
|
*
|
|
1567
1529
|
* Required API Key ACLs:
|
|
1568
|
-
*
|
|
1569
|
-
*
|
|
1530
|
+
* - admin
|
|
1570
1531
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1571
1532
|
*/
|
|
1572
1533
|
listClusters(requestOptions) {
|
|
@@ -1585,8 +1546,7 @@ function createSearchClient({
|
|
|
1585
1546
|
* Lists all indices in the current Algolia application. The request follows any index restrictions of the API key you use to make the request.
|
|
1586
1547
|
*
|
|
1587
1548
|
* Required API Key ACLs:
|
|
1588
|
-
*
|
|
1589
|
-
*
|
|
1549
|
+
* - listIndexes
|
|
1590
1550
|
* @param listIndices - The listIndices object.
|
|
1591
1551
|
* @param listIndices.page - Requested page of the API response. If `null`, the API response is not paginated.
|
|
1592
1552
|
* @param listIndices.hitsPerPage - Number of hits per page.
|
|
@@ -1597,10 +1557,10 @@ function createSearchClient({
|
|
|
1597
1557
|
const headers = {};
|
|
1598
1558
|
const queryParameters = {};
|
|
1599
1559
|
if (page !== void 0) {
|
|
1600
|
-
queryParameters
|
|
1560
|
+
queryParameters["page"] = page.toString();
|
|
1601
1561
|
}
|
|
1602
1562
|
if (hitsPerPage !== void 0) {
|
|
1603
|
-
queryParameters
|
|
1563
|
+
queryParameters["hitsPerPage"] = hitsPerPage.toString();
|
|
1604
1564
|
}
|
|
1605
1565
|
const request = {
|
|
1606
1566
|
method: "GET",
|
|
@@ -1614,8 +1574,7 @@ function createSearchClient({
|
|
|
1614
1574
|
* Lists the userIDs assigned to a multi-cluster application. Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time.
|
|
1615
1575
|
*
|
|
1616
1576
|
* Required API Key ACLs:
|
|
1617
|
-
*
|
|
1618
|
-
*
|
|
1577
|
+
* - admin
|
|
1619
1578
|
* @param listUserIds - The listUserIds object.
|
|
1620
1579
|
* @param listUserIds.page - Requested page of the API response. If `null`, the API response is not paginated.
|
|
1621
1580
|
* @param listUserIds.hitsPerPage - Number of hits per page.
|
|
@@ -1626,10 +1585,10 @@ function createSearchClient({
|
|
|
1626
1585
|
const headers = {};
|
|
1627
1586
|
const queryParameters = {};
|
|
1628
1587
|
if (page !== void 0) {
|
|
1629
|
-
queryParameters
|
|
1588
|
+
queryParameters["page"] = page.toString();
|
|
1630
1589
|
}
|
|
1631
1590
|
if (hitsPerPage !== void 0) {
|
|
1632
|
-
queryParameters
|
|
1591
|
+
queryParameters["hitsPerPage"] = hitsPerPage.toString();
|
|
1633
1592
|
}
|
|
1634
1593
|
const request = {
|
|
1635
1594
|
method: "GET",
|
|
@@ -1641,7 +1600,6 @@ function createSearchClient({
|
|
|
1641
1600
|
},
|
|
1642
1601
|
/**
|
|
1643
1602
|
* Adds, updates, or deletes records in multiple indices with a single API request. - Actions are applied in the order they are specified. - Actions are equivalent to the individual API requests of the same name.
|
|
1644
|
-
*
|
|
1645
1603
|
* @param batchParams - The batchParams object.
|
|
1646
1604
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1647
1605
|
*/
|
|
@@ -1665,11 +1623,10 @@ function createSearchClient({
|
|
|
1665
1623
|
return transporter.request(request, requestOptions);
|
|
1666
1624
|
},
|
|
1667
1625
|
/**
|
|
1668
|
-
* Copies or moves (renames) an index within the same Algolia application. - Existing destination indices are overwritten, except for their analytics data. - If the destination index doesn\'t exist yet, it\'ll be created. **Copy** - Copying a source index that doesn\'t exist creates a new index with 0 records and default settings. - The API keys of the source index are merged with the existing keys in the destination index. - You can\'t copy the `enableReRanking`, `mode`, and `replicas` settings. - You can\'t copy to a destination index that already has replicas. - Be aware of the [size limits](https://www.algolia.com/doc/guides/scaling/algolia-service-limits/#application-record-and-index-limits). - Related guide: [Copy indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/copy-indices/) **Move** - Moving a source index that doesn\'t exist is ignored without returning an error. - When moving an index, the analytics data
|
|
1626
|
+
* Copies or moves (renames) an index within the same Algolia application. - Existing destination indices are overwritten, except for their analytics data. - If the destination index doesn\'t exist yet, it\'ll be created. **Copy** - Copying a source index that doesn\'t exist creates a new index with 0 records and default settings. - The API keys of the source index are merged with the existing keys in the destination index. - You can\'t copy the `enableReRanking`, `mode`, and `replicas` settings. - You can\'t copy to a destination index that already has replicas. - Be aware of the [size limits](https://www.algolia.com/doc/guides/scaling/algolia-service-limits/#application-record-and-index-limits). - Related guide: [Copy indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/copy-indices/) **Move** - Moving a source index that doesn\'t exist is ignored without returning an error. - When moving an index, the analytics data keeps its original name, and a new set of analytics data is started for the new name. To access the original analytics in the dashboard, create an index with the original name. - If the destination index has replicas, moving will overwrite the existing index and copy the data to the replica indices. - Related guide: [Move indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/move-indices/).
|
|
1669
1627
|
*
|
|
1670
1628
|
* Required API Key ACLs:
|
|
1671
|
-
*
|
|
1672
|
-
*
|
|
1629
|
+
* - addObject
|
|
1673
1630
|
* @param operationIndex - The operationIndex object.
|
|
1674
1631
|
* @param operationIndex.indexName - Name of the index on which to perform the operation.
|
|
1675
1632
|
* @param operationIndex.operationIndexParams - The operationIndexParams object.
|
|
@@ -1701,11 +1658,10 @@ function createSearchClient({
|
|
|
1701
1658
|
return transporter.request(request, requestOptions);
|
|
1702
1659
|
},
|
|
1703
1660
|
/**
|
|
1704
|
-
* Adds new attributes to a record, or
|
|
1661
|
+
* Adds new attributes to a record, or updates existing ones. - If a record with the specified object ID doesn\'t exist, a new record is added to the index **if** `createIfNotExists` is true. - If the index doesn\'t exist yet, this method creates a new index. - You can use any first-level attribute but not nested attributes. If you specify a nested attribute, the engine treats it as a replacement for its first-level ancestor. To update an attribute without pushing the entire record, you can use these built-in operations. These operations can be helpful if you don\'t have access to your initial data. - Increment: increment a numeric attribute - Decrement: decrement a numeric attribute - Add: append a number or string element to an array attribute - Remove: remove all matching number or string elements from an array attribute made of numbers or strings - AddUnique: add a number or string element to an array attribute made of numbers or strings only if it\'s not already present - IncrementFrom: increment a numeric integer attribute only if the provided value matches the current value, and otherwise ignore the whole object update. For example, if you pass an IncrementFrom value of 2 for the version attribute, but the current value of the attribute is 1, the engine ignores the update. If the object doesn\'t exist, the engine only creates it if you pass an IncrementFrom value of 0. - IncrementSet: increment a numeric integer attribute only if the provided value is greater than the current value, and otherwise ignore the whole object update. For example, if you pass an IncrementSet value of 2 for the version attribute, and the current value of the attribute is 1, the engine updates the object. If the object doesn\'t exist yet, the engine only creates it if you pass an IncrementSet value greater than 0. You can specify an operation by providing an object with the attribute to update as the key and its value being an object with the following properties: - _operation: the operation to apply on the attribute - value: the right-hand side argument to the operation, for example, increment or decrement step, value to add or remove.
|
|
1705
1662
|
*
|
|
1706
1663
|
* Required API Key ACLs:
|
|
1707
|
-
*
|
|
1708
|
-
*
|
|
1664
|
+
* - addObject
|
|
1709
1665
|
* @param partialUpdateObject - The partialUpdateObject object.
|
|
1710
1666
|
* @param partialUpdateObject.indexName - Name of the index on which to perform the operation.
|
|
1711
1667
|
* @param partialUpdateObject.objectID - Unique record identifier.
|
|
@@ -1727,7 +1683,7 @@ function createSearchClient({
|
|
|
1727
1683
|
const headers = {};
|
|
1728
1684
|
const queryParameters = {};
|
|
1729
1685
|
if (createIfNotExists !== void 0) {
|
|
1730
|
-
queryParameters
|
|
1686
|
+
queryParameters["createIfNotExists"] = createIfNotExists.toString();
|
|
1731
1687
|
}
|
|
1732
1688
|
const request = {
|
|
1733
1689
|
method: "POST",
|
|
@@ -1742,8 +1698,7 @@ function createSearchClient({
|
|
|
1742
1698
|
* Deletes a user ID and its associated data from the clusters.
|
|
1743
1699
|
*
|
|
1744
1700
|
* Required API Key ACLs:
|
|
1745
|
-
*
|
|
1746
|
-
*
|
|
1701
|
+
* - admin
|
|
1747
1702
|
* @param removeUserId - The removeUserId object.
|
|
1748
1703
|
* @param removeUserId.userID - Unique identifier of the user who makes the search request.
|
|
1749
1704
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1767,8 +1722,7 @@ function createSearchClient({
|
|
|
1767
1722
|
* Replaces the list of allowed sources.
|
|
1768
1723
|
*
|
|
1769
1724
|
* Required API Key ACLs:
|
|
1770
|
-
*
|
|
1771
|
-
*
|
|
1725
|
+
* - admin
|
|
1772
1726
|
* @param replaceSources - The replaceSources object.
|
|
1773
1727
|
* @param replaceSources.source - Allowed sources.
|
|
1774
1728
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1793,8 +1747,7 @@ function createSearchClient({
|
|
|
1793
1747
|
* Restores a deleted API key. Restoring resets the `validity` attribute to `0`. Algolia stores up to 1,000 API keys per application. If you create more, the oldest API keys are deleted and can\'t be restored.
|
|
1794
1748
|
*
|
|
1795
1749
|
* Required API Key ACLs:
|
|
1796
|
-
*
|
|
1797
|
-
*
|
|
1750
|
+
* - admin
|
|
1798
1751
|
* @param restoreApiKey - The restoreApiKey object.
|
|
1799
1752
|
* @param restoreApiKey.key - API key.
|
|
1800
1753
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
@@ -1818,11 +1771,10 @@ function createSearchClient({
|
|
|
1818
1771
|
* Adds a record to an index or replace it. - If the record doesn\'t have an object ID, a new record with an auto-generated object ID is added to your index. - If a record with the specified object ID exists, the existing record is replaced. - If a record with the specified object ID doesn\'t exist, a new record is added to your index. - If you add a record to an index that doesn\'t exist yet, a new index is created. To update _some_ attributes of a record, use the [`partial` operation](#tag/Records/operation/partialUpdateObject). To add, update, or replace multiple records, use the [`batch` operation](#tag/Records/operation/batch).
|
|
1819
1772
|
*
|
|
1820
1773
|
* Required API Key ACLs:
|
|
1821
|
-
*
|
|
1822
|
-
*
|
|
1774
|
+
* - addObject
|
|
1823
1775
|
* @param saveObject - The saveObject object.
|
|
1824
1776
|
* @param saveObject.indexName - Name of the index on which to perform the operation.
|
|
1825
|
-
* @param saveObject.body - The record
|
|
1777
|
+
* @param saveObject.body - The record. A schemaless object with attributes that are useful in the context of search and discovery.
|
|
1826
1778
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1827
1779
|
*/
|
|
1828
1780
|
saveObject({ indexName, body }, requestOptions) {
|
|
@@ -1848,8 +1800,7 @@ function createSearchClient({
|
|
|
1848
1800
|
* If a rule with the specified object ID doesn\'t exist, it\'s created. Otherwise, the existing rule is replaced. To create or update more than one rule, use the [`batch` operation](#tag/Rules/operation/saveRules).
|
|
1849
1801
|
*
|
|
1850
1802
|
* Required API Key ACLs:
|
|
1851
|
-
*
|
|
1852
|
-
*
|
|
1803
|
+
* - editSettings
|
|
1853
1804
|
* @param saveRule - The saveRule object.
|
|
1854
1805
|
* @param saveRule.indexName - Name of the index on which to perform the operation.
|
|
1855
1806
|
* @param saveRule.objectID - Unique identifier of a rule object.
|
|
@@ -1874,7 +1825,7 @@ function createSearchClient({
|
|
|
1874
1825
|
const headers = {};
|
|
1875
1826
|
const queryParameters = {};
|
|
1876
1827
|
if (forwardToReplicas !== void 0) {
|
|
1877
|
-
queryParameters
|
|
1828
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1878
1829
|
}
|
|
1879
1830
|
const request = {
|
|
1880
1831
|
method: "PUT",
|
|
@@ -1889,8 +1840,7 @@ function createSearchClient({
|
|
|
1889
1840
|
* Create or update multiple rules. If a rule with the specified object ID doesn\'t exist, Algolia creates a new one. Otherwise, existing rules are replaced.
|
|
1890
1841
|
*
|
|
1891
1842
|
* Required API Key ACLs:
|
|
1892
|
-
*
|
|
1893
|
-
*
|
|
1843
|
+
* - editSettings
|
|
1894
1844
|
* @param saveRules - The saveRules object.
|
|
1895
1845
|
* @param saveRules.indexName - Name of the index on which to perform the operation.
|
|
1896
1846
|
* @param saveRules.rules - The rules object.
|
|
@@ -1909,10 +1859,10 @@ function createSearchClient({
|
|
|
1909
1859
|
const headers = {};
|
|
1910
1860
|
const queryParameters = {};
|
|
1911
1861
|
if (forwardToReplicas !== void 0) {
|
|
1912
|
-
queryParameters
|
|
1862
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1913
1863
|
}
|
|
1914
1864
|
if (clearExistingRules !== void 0) {
|
|
1915
|
-
queryParameters
|
|
1865
|
+
queryParameters["clearExistingRules"] = clearExistingRules.toString();
|
|
1916
1866
|
}
|
|
1917
1867
|
const request = {
|
|
1918
1868
|
method: "POST",
|
|
@@ -1927,8 +1877,7 @@ function createSearchClient({
|
|
|
1927
1877
|
* If a synonym with the specified object ID doesn\'t exist, Algolia adds a new one. Otherwise, the existing synonym is replaced. To add multiple synonyms in a single API request, use the [`batch` operation](#tag/Synonyms/operation/saveSynonyms).
|
|
1928
1878
|
*
|
|
1929
1879
|
* Required API Key ACLs:
|
|
1930
|
-
*
|
|
1931
|
-
*
|
|
1880
|
+
* - editSettings
|
|
1932
1881
|
* @param saveSynonym - The saveSynonym object.
|
|
1933
1882
|
* @param saveSynonym.indexName - Name of the index on which to perform the operation.
|
|
1934
1883
|
* @param saveSynonym.objectID - Unique identifier of a synonym object.
|
|
@@ -1956,7 +1905,7 @@ function createSearchClient({
|
|
|
1956
1905
|
const headers = {};
|
|
1957
1906
|
const queryParameters = {};
|
|
1958
1907
|
if (forwardToReplicas !== void 0) {
|
|
1959
|
-
queryParameters
|
|
1908
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1960
1909
|
}
|
|
1961
1910
|
const request = {
|
|
1962
1911
|
method: "PUT",
|
|
@@ -1971,8 +1920,7 @@ function createSearchClient({
|
|
|
1971
1920
|
* If a synonym with the `objectID` doesn\'t exist, Algolia adds a new one. Otherwise, existing synonyms are replaced.
|
|
1972
1921
|
*
|
|
1973
1922
|
* Required API Key ACLs:
|
|
1974
|
-
*
|
|
1975
|
-
*
|
|
1923
|
+
* - editSettings
|
|
1976
1924
|
* @param saveSynonyms - The saveSynonyms object.
|
|
1977
1925
|
* @param saveSynonyms.indexName - Name of the index on which to perform the operation.
|
|
1978
1926
|
* @param saveSynonyms.synonymHit - The synonymHit object.
|
|
@@ -1991,10 +1939,10 @@ function createSearchClient({
|
|
|
1991
1939
|
const headers = {};
|
|
1992
1940
|
const queryParameters = {};
|
|
1993
1941
|
if (forwardToReplicas !== void 0) {
|
|
1994
|
-
queryParameters
|
|
1942
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1995
1943
|
}
|
|
1996
1944
|
if (replaceExistingSynonyms !== void 0) {
|
|
1997
|
-
queryParameters
|
|
1945
|
+
queryParameters["replaceExistingSynonyms"] = replaceExistingSynonyms.toString();
|
|
1998
1946
|
}
|
|
1999
1947
|
const request = {
|
|
2000
1948
|
method: "POST",
|
|
@@ -2006,11 +1954,10 @@ function createSearchClient({
|
|
|
2006
1954
|
return transporter.request(request, requestOptions);
|
|
2007
1955
|
},
|
|
2008
1956
|
/**
|
|
2009
|
-
* Sends multiple search
|
|
1957
|
+
* Sends multiple search requests to one or more indices. This can be useful in these cases: - Different indices for different purposes, such as, one index for products, another one for marketing content. - Multiple searches to the same index—for example, with different filters.
|
|
2010
1958
|
*
|
|
2011
1959
|
* Required API Key ACLs:
|
|
2012
|
-
*
|
|
2013
|
-
*
|
|
1960
|
+
* - search
|
|
2014
1961
|
* @param searchMethodParams - Muli-search request body. Results are returned in the same order as the requests.
|
|
2015
1962
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2016
1963
|
*/
|
|
@@ -2060,8 +2007,7 @@ function createSearchClient({
|
|
|
2060
2007
|
* Searches for standard and custom dictionary entries.
|
|
2061
2008
|
*
|
|
2062
2009
|
* Required API Key ACLs:
|
|
2063
|
-
*
|
|
2064
|
-
*
|
|
2010
|
+
* - settings
|
|
2065
2011
|
* @param searchDictionaryEntries - The searchDictionaryEntries object.
|
|
2066
2012
|
* @param searchDictionaryEntries.dictionaryName - Dictionary type in which to search.
|
|
2067
2013
|
* @param searchDictionaryEntries.searchDictionaryEntriesParams - The searchDictionaryEntriesParams object.
|
|
@@ -2102,8 +2048,7 @@ function createSearchClient({
|
|
|
2102
2048
|
* Searches for values of a specified facet attribute. - By default, facet values are sorted by decreasing count. You can adjust this with the `sortFacetValueBy` parameter. - Searching for facet values doesn\'t work if you have **more than 65 searchable facets and searchable attributes combined**.
|
|
2103
2049
|
*
|
|
2104
2050
|
* Required API Key ACLs:
|
|
2105
|
-
*
|
|
2106
|
-
*
|
|
2051
|
+
* - search
|
|
2107
2052
|
* @param searchForFacetValues - The searchForFacetValues object.
|
|
2108
2053
|
* @param searchForFacetValues.indexName - Name of the index on which to perform the operation.
|
|
2109
2054
|
* @param searchForFacetValues.facetName - Facet attribute in which to search for values. This attribute must be included in the `attributesForFaceting` index setting with the `searchable()` modifier.
|
|
@@ -2135,8 +2080,7 @@ function createSearchClient({
|
|
|
2135
2080
|
* Searches for rules in your index.
|
|
2136
2081
|
*
|
|
2137
2082
|
* Required API Key ACLs:
|
|
2138
|
-
*
|
|
2139
|
-
*
|
|
2083
|
+
* - settings
|
|
2140
2084
|
* @param searchRules - The searchRules object.
|
|
2141
2085
|
* @param searchRules.indexName - Name of the index on which to perform the operation.
|
|
2142
2086
|
* @param searchRules.searchRulesParams - The searchRulesParams object.
|
|
@@ -2161,11 +2105,10 @@ function createSearchClient({
|
|
|
2161
2105
|
return transporter.request(request, requestOptions);
|
|
2162
2106
|
},
|
|
2163
2107
|
/**
|
|
2164
|
-
* Searches a single index and
|
|
2108
|
+
* Searches a single index and returns matching search results (_hits_). This method lets you retrieve up to 1,000 hits. If you need more, use the [`browse` operation](#tag/Search/operation/browse) or increase the `paginatedLimitedTo` index setting.
|
|
2165
2109
|
*
|
|
2166
2110
|
* Required API Key ACLs:
|
|
2167
|
-
*
|
|
2168
|
-
*
|
|
2111
|
+
* - search
|
|
2169
2112
|
* @param searchSingleIndex - The searchSingleIndex object.
|
|
2170
2113
|
* @param searchSingleIndex.indexName - Name of the index on which to perform the operation.
|
|
2171
2114
|
* @param searchSingleIndex.searchParams - The searchParams object.
|
|
@@ -2193,8 +2136,7 @@ function createSearchClient({
|
|
|
2193
2136
|
* Searches for synonyms in your index.
|
|
2194
2137
|
*
|
|
2195
2138
|
* Required API Key ACLs:
|
|
2196
|
-
*
|
|
2197
|
-
*
|
|
2139
|
+
* - settings
|
|
2198
2140
|
* @param searchSynonyms - The searchSynonyms object.
|
|
2199
2141
|
* @param searchSynonyms.indexName - Name of the index on which to perform the operation.
|
|
2200
2142
|
* @param searchSynonyms.searchSynonymsParams - Body of the `searchSynonyms` operation.
|
|
@@ -2225,8 +2167,7 @@ function createSearchClient({
|
|
|
2225
2167
|
* Since it can take a few seconds to get the data from the different clusters, the response isn\'t real-time. To ensure rapid updates, the user IDs index isn\'t built at the same time as the mapping. Instead, it\'s built every 12 hours, at the same time as the update of user ID usage. For example, if you add or move a user ID, the search will show an old value until the next time the mapping is rebuilt (every 12 hours).
|
|
2226
2168
|
*
|
|
2227
2169
|
* Required API Key ACLs:
|
|
2228
|
-
*
|
|
2229
|
-
*
|
|
2170
|
+
* - admin
|
|
2230
2171
|
* @param searchUserIdsParams - The searchUserIdsParams object.
|
|
2231
2172
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2232
2173
|
*/
|
|
@@ -2255,8 +2196,7 @@ function createSearchClient({
|
|
|
2255
2196
|
* Turns standard stop word dictionary entries on or off for a given language.
|
|
2256
2197
|
*
|
|
2257
2198
|
* Required API Key ACLs:
|
|
2258
|
-
*
|
|
2259
|
-
*
|
|
2199
|
+
* - editSettings
|
|
2260
2200
|
* @param dictionarySettingsParams - The dictionarySettingsParams object.
|
|
2261
2201
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2262
2202
|
*/
|
|
@@ -2285,8 +2225,7 @@ function createSearchClient({
|
|
|
2285
2225
|
* Update the specified index settings. Index settings that you don\'t specify are left unchanged. Specify `null` to reset a setting to its default value. For best performance, update the index settings before you add new records to your index.
|
|
2286
2226
|
*
|
|
2287
2227
|
* Required API Key ACLs:
|
|
2288
|
-
*
|
|
2289
|
-
*
|
|
2228
|
+
* - editSettings
|
|
2290
2229
|
* @param setSettings - The setSettings object.
|
|
2291
2230
|
* @param setSettings.indexName - Name of the index on which to perform the operation.
|
|
2292
2231
|
* @param setSettings.indexSettings - The indexSettings object.
|
|
@@ -2304,7 +2243,7 @@ function createSearchClient({
|
|
|
2304
2243
|
const headers = {};
|
|
2305
2244
|
const queryParameters = {};
|
|
2306
2245
|
if (forwardToReplicas !== void 0) {
|
|
2307
|
-
queryParameters
|
|
2246
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
2308
2247
|
}
|
|
2309
2248
|
const request = {
|
|
2310
2249
|
method: "PUT",
|
|
@@ -2319,8 +2258,7 @@ function createSearchClient({
|
|
|
2319
2258
|
* Replaces the permissions of an existing API key. Any unspecified attribute resets that attribute to its default value.
|
|
2320
2259
|
*
|
|
2321
2260
|
* Required API Key ACLs:
|
|
2322
|
-
*
|
|
2323
|
-
*
|
|
2261
|
+
* - admin
|
|
2324
2262
|
* @param updateApiKey - The updateApiKey object.
|
|
2325
2263
|
* @param updateApiKey.key - API key.
|
|
2326
2264
|
* @param updateApiKey.apiKey - The apiKey object.
|