@algolia/client-search 5.55.1 → 5.56.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 +4 -4
- package/dist/browser.d.ts +858 -5
- package/dist/builds/browser.js +1909 -91
- package/dist/builds/browser.js.map +1 -1
- package/dist/builds/browser.min.js +4 -4
- package/dist/builds/browser.min.js.map +1 -1
- package/dist/builds/browser.umd.js +6 -6
- package/dist/builds/fetch.js +1909 -91
- package/dist/builds/fetch.js.map +1 -1
- package/dist/builds/node.cjs +1909 -91
- package/dist/builds/node.cjs.map +1 -1
- package/dist/builds/node.js +1909 -91
- package/dist/builds/node.js.map +1 -1
- package/dist/builds/worker.js +1909 -91
- package/dist/builds/worker.js.map +1 -1
- package/dist/fetch.d.ts +858 -5
- package/dist/node.d.cts +858 -5
- package/dist/node.d.ts +858 -5
- package/dist/src/searchClient.cjs +1909 -91
- package/dist/src/searchClient.cjs.map +1 -1
- package/dist/src/searchClient.js +1909 -91
- package/dist/src/searchClient.js.map +1 -1
- package/dist/worker.d.ts +858 -5
- package/package.json +9 -9
|
@@ -25,7 +25,7 @@ __export(searchClient_exports, {
|
|
|
25
25
|
});
|
|
26
26
|
module.exports = __toCommonJS(searchClient_exports);
|
|
27
27
|
var import_client_common = require("@algolia/client-common");
|
|
28
|
-
var apiClientVersion = "5.
|
|
28
|
+
var apiClientVersion = "5.56.0";
|
|
29
29
|
function getDefaultHosts(appId) {
|
|
30
30
|
return [
|
|
31
31
|
{
|
|
@@ -592,6 +592,32 @@ function createSearchClient({
|
|
|
592
592
|
};
|
|
593
593
|
return transporter.request(request, requestOptions);
|
|
594
594
|
},
|
|
595
|
+
/**
|
|
596
|
+
* Creates a new API key with specific permissions and restrictions.
|
|
597
|
+
*
|
|
598
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
599
|
+
*
|
|
600
|
+
* Required API Key ACLs:
|
|
601
|
+
* - admin
|
|
602
|
+
* @param apiKey - The apiKey object.
|
|
603
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
604
|
+
* @see addApiKey for the plain version.
|
|
605
|
+
*/
|
|
606
|
+
addApiKeyWithHTTPInfo(apiKey, requestOptions) {
|
|
607
|
+
(0, import_client_common.validateRequired)("apiKey", "addApiKeyWithHTTPInfo", apiKey);
|
|
608
|
+
(0, import_client_common.validateRequired)("apiKey.acl", "addApiKeyWithHTTPInfo", apiKey.acl);
|
|
609
|
+
const requestPath = "/1/keys";
|
|
610
|
+
const headers = {};
|
|
611
|
+
const queryParameters = {};
|
|
612
|
+
const request = {
|
|
613
|
+
method: "POST",
|
|
614
|
+
path: requestPath,
|
|
615
|
+
queryParameters,
|
|
616
|
+
headers,
|
|
617
|
+
data: apiKey
|
|
618
|
+
};
|
|
619
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
620
|
+
},
|
|
595
621
|
/**
|
|
596
622
|
* If a record with the specified object ID exists, the existing record is replaced. Otherwise, a new record is added to the index. If you want to use auto-generated object IDs, use the [`saveObject` operation](https://www.algolia.com/doc/rest-api/search/save-object). To update _some_ attributes of an existing record, use the [`partial` operation](https://www.algolia.com/doc/rest-api/search/partial-update-object) instead. To add, update, or replace multiple records, use the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch).
|
|
597
623
|
*
|
|
@@ -619,6 +645,36 @@ function createSearchClient({
|
|
|
619
645
|
};
|
|
620
646
|
return transporter.request(request, requestOptions);
|
|
621
647
|
},
|
|
648
|
+
/**
|
|
649
|
+
* If a record with the specified object ID exists, the existing record is replaced. Otherwise, a new record is added to the index. If you want to use auto-generated object IDs, use the [`saveObject` operation](https://www.algolia.com/doc/rest-api/search/save-object). To update _some_ attributes of an existing record, use the [`partial` operation](https://www.algolia.com/doc/rest-api/search/partial-update-object) instead. To add, update, or replace multiple records, use the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch).
|
|
650
|
+
*
|
|
651
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
652
|
+
*
|
|
653
|
+
* Required API Key ACLs:
|
|
654
|
+
* - addObject
|
|
655
|
+
* @param addOrUpdateObject - The addOrUpdateObject object.
|
|
656
|
+
* @param addOrUpdateObject.indexName - Name of the index on which to perform the operation.
|
|
657
|
+
* @param addOrUpdateObject.objectID - Unique record identifier.
|
|
658
|
+
* @param addOrUpdateObject.body - The record. A schemaless object with attributes that are useful in the context of search and discovery.
|
|
659
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
660
|
+
* @see addOrUpdateObject for the plain version.
|
|
661
|
+
*/
|
|
662
|
+
addOrUpdateObjectWithHTTPInfo({ indexName, objectID, body }, requestOptions) {
|
|
663
|
+
(0, import_client_common.validateRequired)("indexName", "addOrUpdateObjectWithHTTPInfo", indexName);
|
|
664
|
+
(0, import_client_common.validateRequired)("objectID", "addOrUpdateObjectWithHTTPInfo", objectID);
|
|
665
|
+
(0, import_client_common.validateRequired)("body", "addOrUpdateObjectWithHTTPInfo", body);
|
|
666
|
+
const requestPath = "/1/indexes/{indexName}/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
667
|
+
const headers = {};
|
|
668
|
+
const queryParameters = {};
|
|
669
|
+
const request = {
|
|
670
|
+
method: "PUT",
|
|
671
|
+
path: requestPath,
|
|
672
|
+
queryParameters,
|
|
673
|
+
headers,
|
|
674
|
+
data: body
|
|
675
|
+
};
|
|
676
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
677
|
+
},
|
|
622
678
|
/**
|
|
623
679
|
* Adds a source to the list of allowed sources.
|
|
624
680
|
*
|
|
@@ -642,6 +698,32 @@ function createSearchClient({
|
|
|
642
698
|
};
|
|
643
699
|
return transporter.request(request, requestOptions);
|
|
644
700
|
},
|
|
701
|
+
/**
|
|
702
|
+
* Adds a source to the list of allowed sources.
|
|
703
|
+
*
|
|
704
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
705
|
+
*
|
|
706
|
+
* Required API Key ACLs:
|
|
707
|
+
* - admin
|
|
708
|
+
* @param source - Source to add.
|
|
709
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
710
|
+
* @see appendSource for the plain version.
|
|
711
|
+
*/
|
|
712
|
+
appendSourceWithHTTPInfo(source, requestOptions) {
|
|
713
|
+
(0, import_client_common.validateRequired)("source", "appendSourceWithHTTPInfo", source);
|
|
714
|
+
(0, import_client_common.validateRequired)("source.source", "appendSourceWithHTTPInfo", source.source);
|
|
715
|
+
const requestPath = "/1/security/sources/append";
|
|
716
|
+
const headers = {};
|
|
717
|
+
const queryParameters = {};
|
|
718
|
+
const request = {
|
|
719
|
+
method: "POST",
|
|
720
|
+
path: requestPath,
|
|
721
|
+
queryParameters,
|
|
722
|
+
headers,
|
|
723
|
+
data: source
|
|
724
|
+
};
|
|
725
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
726
|
+
},
|
|
645
727
|
/**
|
|
646
728
|
* 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.
|
|
647
729
|
*
|
|
@@ -673,6 +755,40 @@ function createSearchClient({
|
|
|
673
755
|
};
|
|
674
756
|
return transporter.request(request, requestOptions);
|
|
675
757
|
},
|
|
758
|
+
/**
|
|
759
|
+
* 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.
|
|
760
|
+
*
|
|
761
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
762
|
+
*
|
|
763
|
+
* Required API Key ACLs:
|
|
764
|
+
* - admin
|
|
765
|
+
*
|
|
766
|
+
* @deprecated
|
|
767
|
+
* @param assignUserId - The assignUserId object.
|
|
768
|
+
* @param assignUserId.xAlgoliaUserID - Unique identifier of the user who makes the search request.
|
|
769
|
+
* @param assignUserId.assignUserIdParams - The assignUserIdParams object.
|
|
770
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
771
|
+
* @see assignUserId for the plain version.
|
|
772
|
+
*/
|
|
773
|
+
assignUserIdWithHTTPInfo({ xAlgoliaUserID, assignUserIdParams }, requestOptions) {
|
|
774
|
+
(0, import_client_common.validateRequired)("xAlgoliaUserID", "assignUserIdWithHTTPInfo", xAlgoliaUserID);
|
|
775
|
+
(0, import_client_common.validateRequired)("assignUserIdParams", "assignUserIdWithHTTPInfo", assignUserIdParams);
|
|
776
|
+
(0, import_client_common.validateRequired)("assignUserIdParams.cluster", "assignUserIdWithHTTPInfo", assignUserIdParams.cluster);
|
|
777
|
+
const requestPath = "/1/clusters/mapping";
|
|
778
|
+
const headers = {};
|
|
779
|
+
const queryParameters = {};
|
|
780
|
+
if (xAlgoliaUserID !== void 0) {
|
|
781
|
+
headers["X-Algolia-User-ID"] = xAlgoliaUserID.toString();
|
|
782
|
+
}
|
|
783
|
+
const request = {
|
|
784
|
+
method: "POST",
|
|
785
|
+
path: requestPath,
|
|
786
|
+
queryParameters,
|
|
787
|
+
headers,
|
|
788
|
+
data: assignUserIdParams
|
|
789
|
+
};
|
|
790
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
791
|
+
},
|
|
676
792
|
/**
|
|
677
793
|
* 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. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
678
794
|
*
|
|
@@ -699,6 +815,35 @@ function createSearchClient({
|
|
|
699
815
|
};
|
|
700
816
|
return transporter.request(request, requestOptions);
|
|
701
817
|
},
|
|
818
|
+
/**
|
|
819
|
+
* 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. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
820
|
+
*
|
|
821
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
822
|
+
*
|
|
823
|
+
* Required API Key ACLs:
|
|
824
|
+
* - addObject
|
|
825
|
+
* @param batch - The batch object.
|
|
826
|
+
* @param batch.indexName - Name of the index on which to perform the operation.
|
|
827
|
+
* @param batch.batchWriteParams - The batchWriteParams object.
|
|
828
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
829
|
+
* @see batch for the plain version.
|
|
830
|
+
*/
|
|
831
|
+
batchWithHTTPInfo({ indexName, batchWriteParams }, requestOptions) {
|
|
832
|
+
(0, import_client_common.validateRequired)("indexName", "batchWithHTTPInfo", indexName);
|
|
833
|
+
(0, import_client_common.validateRequired)("batchWriteParams", "batchWithHTTPInfo", batchWriteParams);
|
|
834
|
+
(0, import_client_common.validateRequired)("batchWriteParams.requests", "batchWithHTTPInfo", batchWriteParams.requests);
|
|
835
|
+
const requestPath = "/1/indexes/{indexName}/batch".replace("{indexName}", encodeURIComponent(indexName));
|
|
836
|
+
const headers = {};
|
|
837
|
+
const queryParameters = {};
|
|
838
|
+
const request = {
|
|
839
|
+
method: "POST",
|
|
840
|
+
path: requestPath,
|
|
841
|
+
queryParameters,
|
|
842
|
+
headers,
|
|
843
|
+
data: batchWriteParams
|
|
844
|
+
};
|
|
845
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
846
|
+
},
|
|
702
847
|
/**
|
|
703
848
|
* Assigns multiple user IDs to a cluster. **You can\'t move users with this operation**.
|
|
704
849
|
*
|
|
@@ -731,6 +876,49 @@ function createSearchClient({
|
|
|
731
876
|
};
|
|
732
877
|
return transporter.request(request, requestOptions);
|
|
733
878
|
},
|
|
879
|
+
/**
|
|
880
|
+
* Assigns multiple user IDs to a cluster. **You can\'t move users with this operation**.
|
|
881
|
+
*
|
|
882
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
883
|
+
*
|
|
884
|
+
* Required API Key ACLs:
|
|
885
|
+
* - admin
|
|
886
|
+
*
|
|
887
|
+
* @deprecated
|
|
888
|
+
* @param batchAssignUserIds - The batchAssignUserIds object.
|
|
889
|
+
* @param batchAssignUserIds.xAlgoliaUserID - Unique identifier of the user who makes the search request.
|
|
890
|
+
* @param batchAssignUserIds.batchAssignUserIdsParams - The batchAssignUserIdsParams object.
|
|
891
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
892
|
+
* @see batchAssignUserIds for the plain version.
|
|
893
|
+
*/
|
|
894
|
+
batchAssignUserIdsWithHTTPInfo({ xAlgoliaUserID, batchAssignUserIdsParams }, requestOptions) {
|
|
895
|
+
(0, import_client_common.validateRequired)("xAlgoliaUserID", "batchAssignUserIdsWithHTTPInfo", xAlgoliaUserID);
|
|
896
|
+
(0, import_client_common.validateRequired)("batchAssignUserIdsParams", "batchAssignUserIdsWithHTTPInfo", batchAssignUserIdsParams);
|
|
897
|
+
(0, import_client_common.validateRequired)(
|
|
898
|
+
"batchAssignUserIdsParams.cluster",
|
|
899
|
+
"batchAssignUserIdsWithHTTPInfo",
|
|
900
|
+
batchAssignUserIdsParams.cluster
|
|
901
|
+
);
|
|
902
|
+
(0, import_client_common.validateRequired)(
|
|
903
|
+
"batchAssignUserIdsParams.users",
|
|
904
|
+
"batchAssignUserIdsWithHTTPInfo",
|
|
905
|
+
batchAssignUserIdsParams.users
|
|
906
|
+
);
|
|
907
|
+
const requestPath = "/1/clusters/mapping/batch";
|
|
908
|
+
const headers = {};
|
|
909
|
+
const queryParameters = {};
|
|
910
|
+
if (xAlgoliaUserID !== void 0) {
|
|
911
|
+
headers["X-Algolia-User-ID"] = xAlgoliaUserID.toString();
|
|
912
|
+
}
|
|
913
|
+
const request = {
|
|
914
|
+
method: "POST",
|
|
915
|
+
path: requestPath,
|
|
916
|
+
queryParameters,
|
|
917
|
+
headers,
|
|
918
|
+
data: batchAssignUserIdsParams
|
|
919
|
+
};
|
|
920
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
921
|
+
},
|
|
734
922
|
/**
|
|
735
923
|
* Adds or deletes multiple entries from your plurals, segmentation, or stop word dictionaries.
|
|
736
924
|
*
|
|
@@ -764,6 +952,46 @@ function createSearchClient({
|
|
|
764
952
|
};
|
|
765
953
|
return transporter.request(request, requestOptions);
|
|
766
954
|
},
|
|
955
|
+
/**
|
|
956
|
+
* Adds or deletes multiple entries from your plurals, segmentation, or stop word dictionaries.
|
|
957
|
+
*
|
|
958
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
959
|
+
*
|
|
960
|
+
* Required API Key ACLs:
|
|
961
|
+
* - editSettings
|
|
962
|
+
* @param batchDictionaryEntries - The batchDictionaryEntries object.
|
|
963
|
+
* @param batchDictionaryEntries.dictionaryName - Dictionary type in which to search.
|
|
964
|
+
* @param batchDictionaryEntries.batchDictionaryEntriesParams - The batchDictionaryEntriesParams object.
|
|
965
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
966
|
+
* @see batchDictionaryEntries for the plain version.
|
|
967
|
+
*/
|
|
968
|
+
batchDictionaryEntriesWithHTTPInfo({ dictionaryName, batchDictionaryEntriesParams }, requestOptions) {
|
|
969
|
+
(0, import_client_common.validateRequired)("dictionaryName", "batchDictionaryEntriesWithHTTPInfo", dictionaryName);
|
|
970
|
+
(0, import_client_common.validateRequired)(
|
|
971
|
+
"batchDictionaryEntriesParams",
|
|
972
|
+
"batchDictionaryEntriesWithHTTPInfo",
|
|
973
|
+
batchDictionaryEntriesParams
|
|
974
|
+
);
|
|
975
|
+
(0, import_client_common.validateRequired)(
|
|
976
|
+
"batchDictionaryEntriesParams.requests",
|
|
977
|
+
"batchDictionaryEntriesWithHTTPInfo",
|
|
978
|
+
batchDictionaryEntriesParams.requests
|
|
979
|
+
);
|
|
980
|
+
const requestPath = "/1/dictionaries/{dictionaryName}/batch".replace(
|
|
981
|
+
"{dictionaryName}",
|
|
982
|
+
encodeURIComponent(dictionaryName)
|
|
983
|
+
);
|
|
984
|
+
const headers = {};
|
|
985
|
+
const queryParameters = {};
|
|
986
|
+
const request = {
|
|
987
|
+
method: "POST",
|
|
988
|
+
path: requestPath,
|
|
989
|
+
queryParameters,
|
|
990
|
+
headers,
|
|
991
|
+
data: batchDictionaryEntriesParams
|
|
992
|
+
};
|
|
993
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
994
|
+
},
|
|
767
995
|
/**
|
|
768
996
|
* Retrieves records from an index, up to 1,000 per request. Searching returns _hits_ (records augmented with highlighting and ranking details). Browsing returns matching records only. Use browse 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, or 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\'re ignored.
|
|
769
997
|
*
|
|
@@ -789,6 +1017,34 @@ function createSearchClient({
|
|
|
789
1017
|
};
|
|
790
1018
|
return transporter.request(request, requestOptions);
|
|
791
1019
|
},
|
|
1020
|
+
/**
|
|
1021
|
+
* Retrieves records from an index, up to 1,000 per request. Searching returns _hits_ (records augmented with highlighting and ranking details). Browsing returns matching records only. Use browse 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, or 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\'re ignored.
|
|
1022
|
+
*
|
|
1023
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1024
|
+
*
|
|
1025
|
+
* Required API Key ACLs:
|
|
1026
|
+
* - browse
|
|
1027
|
+
* @param browse - The browse object.
|
|
1028
|
+
* @param browse.indexName - Name of the index on which to perform the operation.
|
|
1029
|
+
* @param browse.browseParams - The browseParams object.
|
|
1030
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1031
|
+
* @see browse for the plain version.
|
|
1032
|
+
*/
|
|
1033
|
+
browseWithHTTPInfo({ indexName, browseParams }, requestOptions) {
|
|
1034
|
+
(0, import_client_common.validateRequired)("indexName", "browseWithHTTPInfo", indexName);
|
|
1035
|
+
const requestPath = "/1/indexes/{indexName}/browse".replace("{indexName}", encodeURIComponent(indexName));
|
|
1036
|
+
const headers = {};
|
|
1037
|
+
const queryParameters = {};
|
|
1038
|
+
const request = {
|
|
1039
|
+
method: "POST",
|
|
1040
|
+
path: requestPath,
|
|
1041
|
+
queryParameters,
|
|
1042
|
+
headers,
|
|
1043
|
+
data: browseParams ? browseParams : {},
|
|
1044
|
+
useReadTransporter: true
|
|
1045
|
+
};
|
|
1046
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1047
|
+
},
|
|
792
1048
|
/**
|
|
793
1049
|
* Deletes only the records from an index while keeping settings, synonyms, and rules. This operation is resource-intensive and subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
794
1050
|
*
|
|
@@ -811,6 +1067,31 @@ function createSearchClient({
|
|
|
811
1067
|
};
|
|
812
1068
|
return transporter.request(request, requestOptions);
|
|
813
1069
|
},
|
|
1070
|
+
/**
|
|
1071
|
+
* Deletes only the records from an index while keeping settings, synonyms, and rules. This operation is resource-intensive and subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1072
|
+
*
|
|
1073
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1074
|
+
*
|
|
1075
|
+
* Required API Key ACLs:
|
|
1076
|
+
* - deleteIndex
|
|
1077
|
+
* @param clearObjects - The clearObjects object.
|
|
1078
|
+
* @param clearObjects.indexName - Name of the index on which to perform the operation.
|
|
1079
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1080
|
+
* @see clearObjects for the plain version.
|
|
1081
|
+
*/
|
|
1082
|
+
clearObjectsWithHTTPInfo({ indexName }, requestOptions) {
|
|
1083
|
+
(0, import_client_common.validateRequired)("indexName", "clearObjectsWithHTTPInfo", indexName);
|
|
1084
|
+
const requestPath = "/1/indexes/{indexName}/clear".replace("{indexName}", encodeURIComponent(indexName));
|
|
1085
|
+
const headers = {};
|
|
1086
|
+
const queryParameters = {};
|
|
1087
|
+
const request = {
|
|
1088
|
+
method: "POST",
|
|
1089
|
+
path: requestPath,
|
|
1090
|
+
queryParameters,
|
|
1091
|
+
headers
|
|
1092
|
+
};
|
|
1093
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1094
|
+
},
|
|
814
1095
|
/**
|
|
815
1096
|
* Deletes all rules from the index.
|
|
816
1097
|
*
|
|
@@ -838,18 +1119,21 @@ function createSearchClient({
|
|
|
838
1119
|
return transporter.request(request, requestOptions);
|
|
839
1120
|
},
|
|
840
1121
|
/**
|
|
841
|
-
* Deletes all
|
|
1122
|
+
* Deletes all rules from the index.
|
|
1123
|
+
*
|
|
1124
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
842
1125
|
*
|
|
843
1126
|
* Required API Key ACLs:
|
|
844
1127
|
* - editSettings
|
|
845
|
-
* @param
|
|
846
|
-
* @param
|
|
847
|
-
* @param
|
|
1128
|
+
* @param clearRules - The clearRules object.
|
|
1129
|
+
* @param clearRules.indexName - Name of the index on which to perform the operation.
|
|
1130
|
+
* @param clearRules.forwardToReplicas - Whether changes are applied to replica indices.
|
|
848
1131
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1132
|
+
* @see clearRules for the plain version.
|
|
849
1133
|
*/
|
|
850
|
-
|
|
851
|
-
(0, import_client_common.validateRequired)("indexName", "
|
|
852
|
-
const requestPath = "/1/indexes/{indexName}/
|
|
1134
|
+
clearRulesWithHTTPInfo({ indexName, forwardToReplicas }, requestOptions) {
|
|
1135
|
+
(0, import_client_common.validateRequired)("indexName", "clearRulesWithHTTPInfo", indexName);
|
|
1136
|
+
const requestPath = "/1/indexes/{indexName}/rules/clear".replace("{indexName}", encodeURIComponent(indexName));
|
|
853
1137
|
const headers = {};
|
|
854
1138
|
const queryParameters = {};
|
|
855
1139
|
if (forwardToReplicas !== void 0) {
|
|
@@ -861,22 +1145,28 @@ function createSearchClient({
|
|
|
861
1145
|
queryParameters,
|
|
862
1146
|
headers
|
|
863
1147
|
};
|
|
864
|
-
return transporter.
|
|
1148
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
865
1149
|
},
|
|
866
1150
|
/**
|
|
867
|
-
*
|
|
868
|
-
*
|
|
869
|
-
*
|
|
870
|
-
*
|
|
1151
|
+
* Deletes all synonyms from the index.
|
|
1152
|
+
*
|
|
1153
|
+
* Required API Key ACLs:
|
|
1154
|
+
* - editSettings
|
|
1155
|
+
* @param clearSynonyms - The clearSynonyms object.
|
|
1156
|
+
* @param clearSynonyms.indexName - Name of the index on which to perform the operation.
|
|
1157
|
+
* @param clearSynonyms.forwardToReplicas - Whether changes are applied to replica indices.
|
|
871
1158
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
872
1159
|
*/
|
|
873
|
-
|
|
874
|
-
(0, import_client_common.validateRequired)("
|
|
875
|
-
const requestPath = "/{
|
|
1160
|
+
clearSynonyms({ indexName, forwardToReplicas }, requestOptions) {
|
|
1161
|
+
(0, import_client_common.validateRequired)("indexName", "clearSynonyms", indexName);
|
|
1162
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/clear".replace("{indexName}", encodeURIComponent(indexName));
|
|
876
1163
|
const headers = {};
|
|
877
|
-
const queryParameters =
|
|
1164
|
+
const queryParameters = {};
|
|
1165
|
+
if (forwardToReplicas !== void 0) {
|
|
1166
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1167
|
+
}
|
|
878
1168
|
const request = {
|
|
879
|
-
method: "
|
|
1169
|
+
method: "POST",
|
|
880
1170
|
path: requestPath,
|
|
881
1171
|
queryParameters,
|
|
882
1172
|
headers
|
|
@@ -884,7 +1174,79 @@ function createSearchClient({
|
|
|
884
1174
|
return transporter.request(request, requestOptions);
|
|
885
1175
|
},
|
|
886
1176
|
/**
|
|
887
|
-
*
|
|
1177
|
+
* Deletes all synonyms from the index.
|
|
1178
|
+
*
|
|
1179
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1180
|
+
*
|
|
1181
|
+
* Required API Key ACLs:
|
|
1182
|
+
* - editSettings
|
|
1183
|
+
* @param clearSynonyms - The clearSynonyms object.
|
|
1184
|
+
* @param clearSynonyms.indexName - Name of the index on which to perform the operation.
|
|
1185
|
+
* @param clearSynonyms.forwardToReplicas - Whether changes are applied to replica indices.
|
|
1186
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1187
|
+
* @see clearSynonyms for the plain version.
|
|
1188
|
+
*/
|
|
1189
|
+
clearSynonymsWithHTTPInfo({ indexName, forwardToReplicas }, requestOptions) {
|
|
1190
|
+
(0, import_client_common.validateRequired)("indexName", "clearSynonymsWithHTTPInfo", indexName);
|
|
1191
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/clear".replace("{indexName}", encodeURIComponent(indexName));
|
|
1192
|
+
const headers = {};
|
|
1193
|
+
const queryParameters = {};
|
|
1194
|
+
if (forwardToReplicas !== void 0) {
|
|
1195
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1196
|
+
}
|
|
1197
|
+
const request = {
|
|
1198
|
+
method: "POST",
|
|
1199
|
+
path: requestPath,
|
|
1200
|
+
queryParameters,
|
|
1201
|
+
headers
|
|
1202
|
+
};
|
|
1203
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1204
|
+
},
|
|
1205
|
+
/**
|
|
1206
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1207
|
+
* @param customDelete - The customDelete object.
|
|
1208
|
+
* @param customDelete.path - Path of the endpoint, for example `1/newFeature`.
|
|
1209
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
1210
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1211
|
+
*/
|
|
1212
|
+
customDelete({ path, parameters }, requestOptions) {
|
|
1213
|
+
(0, import_client_common.validateRequired)("path", "customDelete", path);
|
|
1214
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
1215
|
+
const headers = {};
|
|
1216
|
+
const queryParameters = parameters ? parameters : {};
|
|
1217
|
+
const request = {
|
|
1218
|
+
method: "DELETE",
|
|
1219
|
+
path: requestPath,
|
|
1220
|
+
queryParameters,
|
|
1221
|
+
headers
|
|
1222
|
+
};
|
|
1223
|
+
return transporter.request(request, requestOptions);
|
|
1224
|
+
},
|
|
1225
|
+
/**
|
|
1226
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1227
|
+
*
|
|
1228
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1229
|
+
* @param customDelete - The customDelete object.
|
|
1230
|
+
* @param customDelete.path - Path of the endpoint, for example `1/newFeature`.
|
|
1231
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
1232
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1233
|
+
* @see customDelete for the plain version.
|
|
1234
|
+
*/
|
|
1235
|
+
customDeleteWithHTTPInfo({ path, parameters }, requestOptions) {
|
|
1236
|
+
(0, import_client_common.validateRequired)("path", "customDeleteWithHTTPInfo", path);
|
|
1237
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
1238
|
+
const headers = {};
|
|
1239
|
+
const queryParameters = parameters ? parameters : {};
|
|
1240
|
+
const request = {
|
|
1241
|
+
method: "DELETE",
|
|
1242
|
+
path: requestPath,
|
|
1243
|
+
queryParameters,
|
|
1244
|
+
headers
|
|
1245
|
+
};
|
|
1246
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1247
|
+
},
|
|
1248
|
+
/**
|
|
1249
|
+
* This method lets you send requests to the Algolia REST API.
|
|
888
1250
|
* @param customGet - The customGet object.
|
|
889
1251
|
* @param customGet.path - Path of the endpoint, for example `1/newFeature`.
|
|
890
1252
|
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
@@ -903,6 +1265,29 @@ function createSearchClient({
|
|
|
903
1265
|
};
|
|
904
1266
|
return transporter.request(request, requestOptions);
|
|
905
1267
|
},
|
|
1268
|
+
/**
|
|
1269
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1270
|
+
*
|
|
1271
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1272
|
+
* @param customGet - The customGet object.
|
|
1273
|
+
* @param customGet.path - Path of the endpoint, for example `1/newFeature`.
|
|
1274
|
+
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
1275
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1276
|
+
* @see customGet for the plain version.
|
|
1277
|
+
*/
|
|
1278
|
+
customGetWithHTTPInfo({ path, parameters }, requestOptions) {
|
|
1279
|
+
(0, import_client_common.validateRequired)("path", "customGetWithHTTPInfo", path);
|
|
1280
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
1281
|
+
const headers = {};
|
|
1282
|
+
const queryParameters = parameters ? parameters : {};
|
|
1283
|
+
const request = {
|
|
1284
|
+
method: "GET",
|
|
1285
|
+
path: requestPath,
|
|
1286
|
+
queryParameters,
|
|
1287
|
+
headers
|
|
1288
|
+
};
|
|
1289
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1290
|
+
},
|
|
906
1291
|
/**
|
|
907
1292
|
* This method lets you send requests to the Algolia REST API.
|
|
908
1293
|
* @param customPost - The customPost object.
|
|
@@ -925,6 +1310,31 @@ function createSearchClient({
|
|
|
925
1310
|
};
|
|
926
1311
|
return transporter.request(request, requestOptions);
|
|
927
1312
|
},
|
|
1313
|
+
/**
|
|
1314
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1315
|
+
*
|
|
1316
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1317
|
+
* @param customPost - The customPost object.
|
|
1318
|
+
* @param customPost.path - Path of the endpoint, for example `1/newFeature`.
|
|
1319
|
+
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
1320
|
+
* @param customPost.body - Parameters to send with the custom request.
|
|
1321
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1322
|
+
* @see customPost for the plain version.
|
|
1323
|
+
*/
|
|
1324
|
+
customPostWithHTTPInfo({ path, parameters, body }, requestOptions) {
|
|
1325
|
+
(0, import_client_common.validateRequired)("path", "customPostWithHTTPInfo", path);
|
|
1326
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
1327
|
+
const headers = {};
|
|
1328
|
+
const queryParameters = parameters ? parameters : {};
|
|
1329
|
+
const request = {
|
|
1330
|
+
method: "POST",
|
|
1331
|
+
path: requestPath,
|
|
1332
|
+
queryParameters,
|
|
1333
|
+
headers,
|
|
1334
|
+
data: body ? body : {}
|
|
1335
|
+
};
|
|
1336
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1337
|
+
},
|
|
928
1338
|
/**
|
|
929
1339
|
* This method lets you send requests to the Algolia REST API.
|
|
930
1340
|
* @param customPut - The customPut object.
|
|
@@ -947,6 +1357,31 @@ function createSearchClient({
|
|
|
947
1357
|
};
|
|
948
1358
|
return transporter.request(request, requestOptions);
|
|
949
1359
|
},
|
|
1360
|
+
/**
|
|
1361
|
+
* This method lets you send requests to the Algolia REST API.
|
|
1362
|
+
*
|
|
1363
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1364
|
+
* @param customPut - The customPut object.
|
|
1365
|
+
* @param customPut.path - Path of the endpoint, for example `1/newFeature`.
|
|
1366
|
+
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
1367
|
+
* @param customPut.body - Parameters to send with the custom request.
|
|
1368
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1369
|
+
* @see customPut for the plain version.
|
|
1370
|
+
*/
|
|
1371
|
+
customPutWithHTTPInfo({ path, parameters, body }, requestOptions) {
|
|
1372
|
+
(0, import_client_common.validateRequired)("path", "customPutWithHTTPInfo", path);
|
|
1373
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
1374
|
+
const headers = {};
|
|
1375
|
+
const queryParameters = parameters ? parameters : {};
|
|
1376
|
+
const request = {
|
|
1377
|
+
method: "PUT",
|
|
1378
|
+
path: requestPath,
|
|
1379
|
+
queryParameters,
|
|
1380
|
+
headers,
|
|
1381
|
+
data: body ? body : {}
|
|
1382
|
+
};
|
|
1383
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1384
|
+
},
|
|
950
1385
|
/**
|
|
951
1386
|
* Deletes the API key.
|
|
952
1387
|
*
|
|
@@ -969,6 +1404,31 @@ function createSearchClient({
|
|
|
969
1404
|
};
|
|
970
1405
|
return transporter.request(request, requestOptions);
|
|
971
1406
|
},
|
|
1407
|
+
/**
|
|
1408
|
+
* Deletes the API key.
|
|
1409
|
+
*
|
|
1410
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1411
|
+
*
|
|
1412
|
+
* Required API Key ACLs:
|
|
1413
|
+
* - admin
|
|
1414
|
+
* @param deleteApiKey - The deleteApiKey object.
|
|
1415
|
+
* @param deleteApiKey.key - API key.
|
|
1416
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1417
|
+
* @see deleteApiKey for the plain version.
|
|
1418
|
+
*/
|
|
1419
|
+
deleteApiKeyWithHTTPInfo({ key }, requestOptions) {
|
|
1420
|
+
(0, import_client_common.validateRequired)("key", "deleteApiKeyWithHTTPInfo", key);
|
|
1421
|
+
const requestPath = "/1/keys/{key}".replace("{key}", encodeURIComponent(key));
|
|
1422
|
+
const headers = {};
|
|
1423
|
+
const queryParameters = {};
|
|
1424
|
+
const request = {
|
|
1425
|
+
method: "DELETE",
|
|
1426
|
+
path: requestPath,
|
|
1427
|
+
queryParameters,
|
|
1428
|
+
headers
|
|
1429
|
+
};
|
|
1430
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1431
|
+
},
|
|
972
1432
|
/**
|
|
973
1433
|
* This operation doesn\'t accept empty filters. This operation is resource-intensive. Use it only if you can\'t get the object IDs of the records you want to delete. It\'s more efficient to get a list of object IDs with the [`browse` operation](https://www.algolia.com/doc/rest-api/search/browse), and then delete the records using the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch). This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
974
1434
|
*
|
|
@@ -994,6 +1454,34 @@ function createSearchClient({
|
|
|
994
1454
|
};
|
|
995
1455
|
return transporter.request(request, requestOptions);
|
|
996
1456
|
},
|
|
1457
|
+
/**
|
|
1458
|
+
* This operation doesn\'t accept empty filters. This operation is resource-intensive. Use it only if you can\'t get the object IDs of the records you want to delete. It\'s more efficient to get a list of object IDs with the [`browse` operation](https://www.algolia.com/doc/rest-api/search/browse), and then delete the records using the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch). This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1459
|
+
*
|
|
1460
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1461
|
+
*
|
|
1462
|
+
* Required API Key ACLs:
|
|
1463
|
+
* - deleteIndex
|
|
1464
|
+
* @param deleteBy - The deleteBy object.
|
|
1465
|
+
* @param deleteBy.indexName - Name of the index on which to perform the operation.
|
|
1466
|
+
* @param deleteBy.deleteByParams - The deleteByParams object.
|
|
1467
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1468
|
+
* @see deleteBy for the plain version.
|
|
1469
|
+
*/
|
|
1470
|
+
deleteByWithHTTPInfo({ indexName, deleteByParams }, requestOptions) {
|
|
1471
|
+
(0, import_client_common.validateRequired)("indexName", "deleteByWithHTTPInfo", indexName);
|
|
1472
|
+
(0, import_client_common.validateRequired)("deleteByParams", "deleteByWithHTTPInfo", deleteByParams);
|
|
1473
|
+
const requestPath = "/1/indexes/{indexName}/deleteByQuery".replace("{indexName}", encodeURIComponent(indexName));
|
|
1474
|
+
const headers = {};
|
|
1475
|
+
const queryParameters = {};
|
|
1476
|
+
const request = {
|
|
1477
|
+
method: "POST",
|
|
1478
|
+
path: requestPath,
|
|
1479
|
+
queryParameters,
|
|
1480
|
+
headers,
|
|
1481
|
+
data: deleteByParams
|
|
1482
|
+
};
|
|
1483
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1484
|
+
},
|
|
997
1485
|
/**
|
|
998
1486
|
* 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).
|
|
999
1487
|
*
|
|
@@ -1016,6 +1504,31 @@ function createSearchClient({
|
|
|
1016
1504
|
};
|
|
1017
1505
|
return transporter.request(request, requestOptions);
|
|
1018
1506
|
},
|
|
1507
|
+
/**
|
|
1508
|
+
* 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).
|
|
1509
|
+
*
|
|
1510
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1511
|
+
*
|
|
1512
|
+
* Required API Key ACLs:
|
|
1513
|
+
* - deleteIndex
|
|
1514
|
+
* @param deleteIndex - The deleteIndex object.
|
|
1515
|
+
* @param deleteIndex.indexName - Name of the index on which to perform the operation.
|
|
1516
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1517
|
+
* @see deleteIndex for the plain version.
|
|
1518
|
+
*/
|
|
1519
|
+
deleteIndexWithHTTPInfo({ indexName }, requestOptions) {
|
|
1520
|
+
(0, import_client_common.validateRequired)("indexName", "deleteIndexWithHTTPInfo", indexName);
|
|
1521
|
+
const requestPath = "/1/indexes/{indexName}".replace("{indexName}", encodeURIComponent(indexName));
|
|
1522
|
+
const headers = {};
|
|
1523
|
+
const queryParameters = {};
|
|
1524
|
+
const request = {
|
|
1525
|
+
method: "DELETE",
|
|
1526
|
+
path: requestPath,
|
|
1527
|
+
queryParameters,
|
|
1528
|
+
headers
|
|
1529
|
+
};
|
|
1530
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1531
|
+
},
|
|
1019
1532
|
/**
|
|
1020
1533
|
* Deletes a record by its object ID. To delete more than one record, use the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch). To delete records matching a query, use the [`deleteBy` operation](https://www.algolia.com/doc/rest-api/search/delete-by).
|
|
1021
1534
|
*
|
|
@@ -1040,6 +1553,33 @@ function createSearchClient({
|
|
|
1040
1553
|
};
|
|
1041
1554
|
return transporter.request(request, requestOptions);
|
|
1042
1555
|
},
|
|
1556
|
+
/**
|
|
1557
|
+
* Deletes a record by its object ID. To delete more than one record, use the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch). To delete records matching a query, use the [`deleteBy` operation](https://www.algolia.com/doc/rest-api/search/delete-by).
|
|
1558
|
+
*
|
|
1559
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1560
|
+
*
|
|
1561
|
+
* Required API Key ACLs:
|
|
1562
|
+
* - deleteObject
|
|
1563
|
+
* @param deleteObject - The deleteObject object.
|
|
1564
|
+
* @param deleteObject.indexName - Name of the index on which to perform the operation.
|
|
1565
|
+
* @param deleteObject.objectID - Unique record identifier.
|
|
1566
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1567
|
+
* @see deleteObject for the plain version.
|
|
1568
|
+
*/
|
|
1569
|
+
deleteObjectWithHTTPInfo({ indexName, objectID }, requestOptions) {
|
|
1570
|
+
(0, import_client_common.validateRequired)("indexName", "deleteObjectWithHTTPInfo", indexName);
|
|
1571
|
+
(0, import_client_common.validateRequired)("objectID", "deleteObjectWithHTTPInfo", objectID);
|
|
1572
|
+
const requestPath = "/1/indexes/{indexName}/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
1573
|
+
const headers = {};
|
|
1574
|
+
const queryParameters = {};
|
|
1575
|
+
const request = {
|
|
1576
|
+
method: "DELETE",
|
|
1577
|
+
path: requestPath,
|
|
1578
|
+
queryParameters,
|
|
1579
|
+
headers
|
|
1580
|
+
};
|
|
1581
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1582
|
+
},
|
|
1043
1583
|
/**
|
|
1044
1584
|
* Deletes a rule by its ID. To find the object ID for rules, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-rules).
|
|
1045
1585
|
*
|
|
@@ -1068,6 +1608,37 @@ function createSearchClient({
|
|
|
1068
1608
|
};
|
|
1069
1609
|
return transporter.request(request, requestOptions);
|
|
1070
1610
|
},
|
|
1611
|
+
/**
|
|
1612
|
+
* Deletes a rule by its ID. To find the object ID for rules, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-rules).
|
|
1613
|
+
*
|
|
1614
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1615
|
+
*
|
|
1616
|
+
* Required API Key ACLs:
|
|
1617
|
+
* - editSettings
|
|
1618
|
+
* @param deleteRule - The deleteRule object.
|
|
1619
|
+
* @param deleteRule.indexName - Name of the index on which to perform the operation.
|
|
1620
|
+
* @param deleteRule.objectID - Unique identifier of a rule object.
|
|
1621
|
+
* @param deleteRule.forwardToReplicas - Whether changes are applied to replica indices.
|
|
1622
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1623
|
+
* @see deleteRule for the plain version.
|
|
1624
|
+
*/
|
|
1625
|
+
deleteRuleWithHTTPInfo({ indexName, objectID, forwardToReplicas }, requestOptions) {
|
|
1626
|
+
(0, import_client_common.validateRequired)("indexName", "deleteRuleWithHTTPInfo", indexName);
|
|
1627
|
+
(0, import_client_common.validateRequired)("objectID", "deleteRuleWithHTTPInfo", objectID);
|
|
1628
|
+
const requestPath = "/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
1629
|
+
const headers = {};
|
|
1630
|
+
const queryParameters = {};
|
|
1631
|
+
if (forwardToReplicas !== void 0) {
|
|
1632
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1633
|
+
}
|
|
1634
|
+
const request = {
|
|
1635
|
+
method: "DELETE",
|
|
1636
|
+
path: requestPath,
|
|
1637
|
+
queryParameters,
|
|
1638
|
+
headers
|
|
1639
|
+
};
|
|
1640
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1641
|
+
},
|
|
1071
1642
|
/**
|
|
1072
1643
|
* Deletes a source from the list of allowed sources.
|
|
1073
1644
|
*
|
|
@@ -1090,6 +1661,31 @@ function createSearchClient({
|
|
|
1090
1661
|
};
|
|
1091
1662
|
return transporter.request(request, requestOptions);
|
|
1092
1663
|
},
|
|
1664
|
+
/**
|
|
1665
|
+
* Deletes a source from the list of allowed sources.
|
|
1666
|
+
*
|
|
1667
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1668
|
+
*
|
|
1669
|
+
* Required API Key ACLs:
|
|
1670
|
+
* - admin
|
|
1671
|
+
* @param deleteSource - The deleteSource object.
|
|
1672
|
+
* @param deleteSource.source - IP address range of the source.
|
|
1673
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1674
|
+
* @see deleteSource for the plain version.
|
|
1675
|
+
*/
|
|
1676
|
+
deleteSourceWithHTTPInfo({ source }, requestOptions) {
|
|
1677
|
+
(0, import_client_common.validateRequired)("source", "deleteSourceWithHTTPInfo", source);
|
|
1678
|
+
const requestPath = "/1/security/sources/{source}".replace("{source}", encodeURIComponent(source));
|
|
1679
|
+
const headers = {};
|
|
1680
|
+
const queryParameters = {};
|
|
1681
|
+
const request = {
|
|
1682
|
+
method: "DELETE",
|
|
1683
|
+
path: requestPath,
|
|
1684
|
+
queryParameters,
|
|
1685
|
+
headers
|
|
1686
|
+
};
|
|
1687
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1688
|
+
},
|
|
1093
1689
|
/**
|
|
1094
1690
|
* Deletes a synonym by its ID. To find the object IDs of your synonyms, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-synonyms).
|
|
1095
1691
|
*
|
|
@@ -1119,13 +1715,44 @@ function createSearchClient({
|
|
|
1119
1715
|
return transporter.request(request, requestOptions);
|
|
1120
1716
|
},
|
|
1121
1717
|
/**
|
|
1122
|
-
*
|
|
1718
|
+
* Deletes a synonym by its ID. To find the object IDs of your synonyms, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-synonyms).
|
|
1719
|
+
*
|
|
1720
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1123
1721
|
*
|
|
1124
1722
|
* Required API Key ACLs:
|
|
1125
|
-
* -
|
|
1126
|
-
* @param
|
|
1127
|
-
* @param
|
|
1128
|
-
* @param
|
|
1723
|
+
* - editSettings
|
|
1724
|
+
* @param deleteSynonym - The deleteSynonym object.
|
|
1725
|
+
* @param deleteSynonym.indexName - Name of the index on which to perform the operation.
|
|
1726
|
+
* @param deleteSynonym.objectID - Unique identifier of a synonym object.
|
|
1727
|
+
* @param deleteSynonym.forwardToReplicas - Whether changes are applied to replica indices.
|
|
1728
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1729
|
+
* @see deleteSynonym for the plain version.
|
|
1730
|
+
*/
|
|
1731
|
+
deleteSynonymWithHTTPInfo({ indexName, objectID, forwardToReplicas }, requestOptions) {
|
|
1732
|
+
(0, import_client_common.validateRequired)("indexName", "deleteSynonymWithHTTPInfo", indexName);
|
|
1733
|
+
(0, import_client_common.validateRequired)("objectID", "deleteSynonymWithHTTPInfo", objectID);
|
|
1734
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
1735
|
+
const headers = {};
|
|
1736
|
+
const queryParameters = {};
|
|
1737
|
+
if (forwardToReplicas !== void 0) {
|
|
1738
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1739
|
+
}
|
|
1740
|
+
const request = {
|
|
1741
|
+
method: "DELETE",
|
|
1742
|
+
path: requestPath,
|
|
1743
|
+
queryParameters,
|
|
1744
|
+
headers
|
|
1745
|
+
};
|
|
1746
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1747
|
+
},
|
|
1748
|
+
/**
|
|
1749
|
+
* 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>`.
|
|
1750
|
+
*
|
|
1751
|
+
* Required API Key ACLs:
|
|
1752
|
+
* - search
|
|
1753
|
+
* @param getApiKey - The getApiKey object.
|
|
1754
|
+
* @param getApiKey.key - API key.
|
|
1755
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1129
1756
|
*/
|
|
1130
1757
|
getApiKey({ key }, requestOptions) {
|
|
1131
1758
|
(0, import_client_common.validateRequired)("key", "getApiKey", key);
|
|
@@ -1140,6 +1767,31 @@ function createSearchClient({
|
|
|
1140
1767
|
};
|
|
1141
1768
|
return transporter.request(request, requestOptions);
|
|
1142
1769
|
},
|
|
1770
|
+
/**
|
|
1771
|
+
* 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>`.
|
|
1772
|
+
*
|
|
1773
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1774
|
+
*
|
|
1775
|
+
* Required API Key ACLs:
|
|
1776
|
+
* - search
|
|
1777
|
+
* @param getApiKey - The getApiKey object.
|
|
1778
|
+
* @param getApiKey.key - API key.
|
|
1779
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1780
|
+
* @see getApiKey for the plain version.
|
|
1781
|
+
*/
|
|
1782
|
+
getApiKeyWithHTTPInfo({ key }, requestOptions) {
|
|
1783
|
+
(0, import_client_common.validateRequired)("key", "getApiKeyWithHTTPInfo", key);
|
|
1784
|
+
const requestPath = "/1/keys/{key}".replace("{key}", encodeURIComponent(key));
|
|
1785
|
+
const headers = {};
|
|
1786
|
+
const queryParameters = {};
|
|
1787
|
+
const request = {
|
|
1788
|
+
method: "GET",
|
|
1789
|
+
path: requestPath,
|
|
1790
|
+
queryParameters,
|
|
1791
|
+
headers
|
|
1792
|
+
};
|
|
1793
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1794
|
+
},
|
|
1143
1795
|
/**
|
|
1144
1796
|
* Checks the status of a given application task.
|
|
1145
1797
|
*
|
|
@@ -1162,6 +1814,31 @@ function createSearchClient({
|
|
|
1162
1814
|
};
|
|
1163
1815
|
return transporter.request(request, requestOptions);
|
|
1164
1816
|
},
|
|
1817
|
+
/**
|
|
1818
|
+
* Checks the status of a given application task.
|
|
1819
|
+
*
|
|
1820
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1821
|
+
*
|
|
1822
|
+
* Required API Key ACLs:
|
|
1823
|
+
* - editSettings
|
|
1824
|
+
* @param getAppTask - The getAppTask object.
|
|
1825
|
+
* @param getAppTask.taskID - Unique task identifier.
|
|
1826
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1827
|
+
* @see getAppTask for the plain version.
|
|
1828
|
+
*/
|
|
1829
|
+
getAppTaskWithHTTPInfo({ taskID }, requestOptions) {
|
|
1830
|
+
(0, import_client_common.validateRequired)("taskID", "getAppTaskWithHTTPInfo", taskID);
|
|
1831
|
+
const requestPath = "/1/task/{taskID}".replace("{taskID}", encodeURIComponent(taskID));
|
|
1832
|
+
const headers = {};
|
|
1833
|
+
const queryParameters = {};
|
|
1834
|
+
const request = {
|
|
1835
|
+
method: "GET",
|
|
1836
|
+
path: requestPath,
|
|
1837
|
+
queryParameters,
|
|
1838
|
+
headers
|
|
1839
|
+
};
|
|
1840
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1841
|
+
},
|
|
1165
1842
|
/**
|
|
1166
1843
|
* Lists supported languages with their supported dictionary types and number of custom entries.
|
|
1167
1844
|
*
|
|
@@ -1181,6 +1858,28 @@ function createSearchClient({
|
|
|
1181
1858
|
};
|
|
1182
1859
|
return transporter.request(request, requestOptions);
|
|
1183
1860
|
},
|
|
1861
|
+
/**
|
|
1862
|
+
* Lists supported languages with their supported dictionary types and number of custom entries.
|
|
1863
|
+
*
|
|
1864
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1865
|
+
*
|
|
1866
|
+
* Required API Key ACLs:
|
|
1867
|
+
* - settings
|
|
1868
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1869
|
+
* @see getDictionaryLanguages for the plain version.
|
|
1870
|
+
*/
|
|
1871
|
+
getDictionaryLanguagesWithHTTPInfo(requestOptions) {
|
|
1872
|
+
const requestPath = "/1/dictionaries/*/languages";
|
|
1873
|
+
const headers = {};
|
|
1874
|
+
const queryParameters = {};
|
|
1875
|
+
const request = {
|
|
1876
|
+
method: "GET",
|
|
1877
|
+
path: requestPath,
|
|
1878
|
+
queryParameters,
|
|
1879
|
+
headers
|
|
1880
|
+
};
|
|
1881
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1882
|
+
},
|
|
1184
1883
|
/**
|
|
1185
1884
|
* Retrieves the languages for which standard dictionary entries are turned off.
|
|
1186
1885
|
*
|
|
@@ -1200,6 +1899,28 @@ function createSearchClient({
|
|
|
1200
1899
|
};
|
|
1201
1900
|
return transporter.request(request, requestOptions);
|
|
1202
1901
|
},
|
|
1902
|
+
/**
|
|
1903
|
+
* Retrieves the languages for which standard dictionary entries are turned off.
|
|
1904
|
+
*
|
|
1905
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1906
|
+
*
|
|
1907
|
+
* Required API Key ACLs:
|
|
1908
|
+
* - settings
|
|
1909
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1910
|
+
* @see getDictionarySettings for the plain version.
|
|
1911
|
+
*/
|
|
1912
|
+
getDictionarySettingsWithHTTPInfo(requestOptions) {
|
|
1913
|
+
const requestPath = "/1/dictionaries/*/settings";
|
|
1914
|
+
const headers = {};
|
|
1915
|
+
const queryParameters = {};
|
|
1916
|
+
const request = {
|
|
1917
|
+
method: "GET",
|
|
1918
|
+
path: requestPath,
|
|
1919
|
+
queryParameters,
|
|
1920
|
+
headers
|
|
1921
|
+
};
|
|
1922
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1923
|
+
},
|
|
1203
1924
|
/**
|
|
1204
1925
|
* 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/articles/17245378392977-How-does-Algolia-count-records-and-operations) but doesn\'t appear in the logs itself.
|
|
1205
1926
|
*
|
|
@@ -1236,6 +1957,45 @@ function createSearchClient({
|
|
|
1236
1957
|
};
|
|
1237
1958
|
return transporter.request(request, requestOptions);
|
|
1238
1959
|
},
|
|
1960
|
+
/**
|
|
1961
|
+
* 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/articles/17245378392977-How-does-Algolia-count-records-and-operations) but doesn\'t appear in the logs itself.
|
|
1962
|
+
*
|
|
1963
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1964
|
+
*
|
|
1965
|
+
* Required API Key ACLs:
|
|
1966
|
+
* - logs
|
|
1967
|
+
* @param getLogs - The getLogs object.
|
|
1968
|
+
* @param getLogs.offset - First log entry to retrieve. The most recent entries are listed first.
|
|
1969
|
+
* @param getLogs.length - Maximum number of entries to retrieve.
|
|
1970
|
+
* @param getLogs.indexName - Index for which to retrieve log entries. By default, log entries are retrieved for all indices.
|
|
1971
|
+
* @param getLogs.type - Type of log entries to retrieve. By default, all log entries are retrieved.
|
|
1972
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1973
|
+
* @see getLogs for the plain version.
|
|
1974
|
+
*/
|
|
1975
|
+
getLogsWithHTTPInfo({ offset, length, indexName, type } = {}, requestOptions = void 0) {
|
|
1976
|
+
const requestPath = "/1/logs";
|
|
1977
|
+
const headers = {};
|
|
1978
|
+
const queryParameters = {};
|
|
1979
|
+
if (offset !== void 0) {
|
|
1980
|
+
queryParameters["offset"] = offset.toString();
|
|
1981
|
+
}
|
|
1982
|
+
if (length !== void 0) {
|
|
1983
|
+
queryParameters["length"] = length.toString();
|
|
1984
|
+
}
|
|
1985
|
+
if (indexName !== void 0) {
|
|
1986
|
+
queryParameters["indexName"] = indexName.toString();
|
|
1987
|
+
}
|
|
1988
|
+
if (type !== void 0) {
|
|
1989
|
+
queryParameters["type"] = type.toString();
|
|
1990
|
+
}
|
|
1991
|
+
const request = {
|
|
1992
|
+
method: "GET",
|
|
1993
|
+
path: requestPath,
|
|
1994
|
+
queryParameters,
|
|
1995
|
+
headers
|
|
1996
|
+
};
|
|
1997
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1998
|
+
},
|
|
1239
1999
|
/**
|
|
1240
2000
|
* Retrieves one record by its object ID. To retrieve more than one record, use the [`objects` operation](https://www.algolia.com/doc/rest-api/search/get-objects).
|
|
1241
2001
|
*
|
|
@@ -1264,6 +2024,37 @@ function createSearchClient({
|
|
|
1264
2024
|
};
|
|
1265
2025
|
return transporter.request(request, requestOptions);
|
|
1266
2026
|
},
|
|
2027
|
+
/**
|
|
2028
|
+
* Retrieves one record by its object ID. To retrieve more than one record, use the [`objects` operation](https://www.algolia.com/doc/rest-api/search/get-objects).
|
|
2029
|
+
*
|
|
2030
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2031
|
+
*
|
|
2032
|
+
* Required API Key ACLs:
|
|
2033
|
+
* - search
|
|
2034
|
+
* @param getObject - The getObject object.
|
|
2035
|
+
* @param getObject.indexName - Name of the index on which to perform the operation.
|
|
2036
|
+
* @param getObject.objectID - Unique record identifier.
|
|
2037
|
+
* @param getObject.attributesToRetrieve - Attributes to include with the records in the response. This is useful to reduce the size of the API response. By default, all retrievable attributes are returned. `objectID` is always retrieved. Attributes included in `unretrievableAttributes` won\'t be retrieved unless the request is authenticated with the admin API key.
|
|
2038
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2039
|
+
* @see getObject for the plain version.
|
|
2040
|
+
*/
|
|
2041
|
+
getObjectWithHTTPInfo({ indexName, objectID, attributesToRetrieve }, requestOptions) {
|
|
2042
|
+
(0, import_client_common.validateRequired)("indexName", "getObjectWithHTTPInfo", indexName);
|
|
2043
|
+
(0, import_client_common.validateRequired)("objectID", "getObjectWithHTTPInfo", objectID);
|
|
2044
|
+
const requestPath = "/1/indexes/{indexName}/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2045
|
+
const headers = {};
|
|
2046
|
+
const queryParameters = {};
|
|
2047
|
+
if (attributesToRetrieve !== void 0) {
|
|
2048
|
+
queryParameters["attributesToRetrieve"] = attributesToRetrieve.toString();
|
|
2049
|
+
}
|
|
2050
|
+
const request = {
|
|
2051
|
+
method: "GET",
|
|
2052
|
+
path: requestPath,
|
|
2053
|
+
queryParameters,
|
|
2054
|
+
headers
|
|
2055
|
+
};
|
|
2056
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2057
|
+
},
|
|
1267
2058
|
/**
|
|
1268
2059
|
* Retrieves one or more records, potentially from different indices. Records are returned in the same order as the requests.
|
|
1269
2060
|
*
|
|
@@ -1289,20 +2080,246 @@ function createSearchClient({
|
|
|
1289
2080
|
};
|
|
1290
2081
|
return transporter.request(request, requestOptions);
|
|
1291
2082
|
},
|
|
2083
|
+
/**
|
|
2084
|
+
* Retrieves one or more records, potentially from different indices. Records are returned in the same order as the requests.
|
|
2085
|
+
*
|
|
2086
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2087
|
+
*
|
|
2088
|
+
* Required API Key ACLs:
|
|
2089
|
+
* - search
|
|
2090
|
+
* @param getObjectsParams - Request object.
|
|
2091
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2092
|
+
* @see getObjects for the plain version.
|
|
2093
|
+
*/
|
|
2094
|
+
getObjectsWithHTTPInfo(getObjectsParams, requestOptions) {
|
|
2095
|
+
(0, import_client_common.validateRequired)("getObjectsParams", "getObjectsWithHTTPInfo", getObjectsParams);
|
|
2096
|
+
(0, import_client_common.validateRequired)("getObjectsParams.requests", "getObjectsWithHTTPInfo", getObjectsParams.requests);
|
|
2097
|
+
const requestPath = "/1/indexes/*/objects";
|
|
2098
|
+
const headers = {};
|
|
2099
|
+
const queryParameters = {};
|
|
2100
|
+
const request = {
|
|
2101
|
+
method: "POST",
|
|
2102
|
+
path: requestPath,
|
|
2103
|
+
queryParameters,
|
|
2104
|
+
headers,
|
|
2105
|
+
data: getObjectsParams,
|
|
2106
|
+
useReadTransporter: true,
|
|
2107
|
+
cacheable: true
|
|
2108
|
+
};
|
|
2109
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2110
|
+
},
|
|
2111
|
+
/**
|
|
2112
|
+
* Retrieves a rule by its ID. To find the object ID of rules, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-rules).
|
|
2113
|
+
*
|
|
2114
|
+
* Required API Key ACLs:
|
|
2115
|
+
* - settings
|
|
2116
|
+
* @param getRule - The getRule object.
|
|
2117
|
+
* @param getRule.indexName - Name of the index on which to perform the operation.
|
|
2118
|
+
* @param getRule.objectID - Unique identifier of a rule object.
|
|
2119
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2120
|
+
*/
|
|
2121
|
+
getRule({ indexName, objectID }, requestOptions) {
|
|
2122
|
+
(0, import_client_common.validateRequired)("indexName", "getRule", indexName);
|
|
2123
|
+
(0, import_client_common.validateRequired)("objectID", "getRule", objectID);
|
|
2124
|
+
const requestPath = "/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2125
|
+
const headers = {};
|
|
2126
|
+
const queryParameters = {};
|
|
2127
|
+
const request = {
|
|
2128
|
+
method: "GET",
|
|
2129
|
+
path: requestPath,
|
|
2130
|
+
queryParameters,
|
|
2131
|
+
headers
|
|
2132
|
+
};
|
|
2133
|
+
return transporter.request(request, requestOptions);
|
|
2134
|
+
},
|
|
1292
2135
|
/**
|
|
1293
2136
|
* Retrieves a rule by its ID. To find the object ID of rules, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-rules).
|
|
1294
2137
|
*
|
|
2138
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2139
|
+
*
|
|
1295
2140
|
* Required API Key ACLs:
|
|
1296
2141
|
* - settings
|
|
1297
2142
|
* @param getRule - The getRule object.
|
|
1298
2143
|
* @param getRule.indexName - Name of the index on which to perform the operation.
|
|
1299
2144
|
* @param getRule.objectID - Unique identifier of a rule object.
|
|
1300
2145
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2146
|
+
* @see getRule for the plain version.
|
|
2147
|
+
*/
|
|
2148
|
+
getRuleWithHTTPInfo({ indexName, objectID }, requestOptions) {
|
|
2149
|
+
(0, import_client_common.validateRequired)("indexName", "getRuleWithHTTPInfo", indexName);
|
|
2150
|
+
(0, import_client_common.validateRequired)("objectID", "getRuleWithHTTPInfo", objectID);
|
|
2151
|
+
const requestPath = "/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2152
|
+
const headers = {};
|
|
2153
|
+
const queryParameters = {};
|
|
2154
|
+
const request = {
|
|
2155
|
+
method: "GET",
|
|
2156
|
+
path: requestPath,
|
|
2157
|
+
queryParameters,
|
|
2158
|
+
headers
|
|
2159
|
+
};
|
|
2160
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2161
|
+
},
|
|
2162
|
+
/**
|
|
2163
|
+
* Retrieves an object with non-null index settings.
|
|
2164
|
+
*
|
|
2165
|
+
* Required API Key ACLs:
|
|
2166
|
+
* - settings
|
|
2167
|
+
* @param getSettings - The getSettings object.
|
|
2168
|
+
* @param getSettings.indexName - Name of the index on which to perform the operation.
|
|
2169
|
+
* @param getSettings.getVersion - When set to 2, the endpoint will not include `synonyms` in the response. This parameter is here for backward compatibility.
|
|
2170
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2171
|
+
*/
|
|
2172
|
+
getSettings({ indexName, getVersion }, requestOptions) {
|
|
2173
|
+
(0, import_client_common.validateRequired)("indexName", "getSettings", indexName);
|
|
2174
|
+
const requestPath = "/1/indexes/{indexName}/settings".replace("{indexName}", encodeURIComponent(indexName));
|
|
2175
|
+
const headers = {};
|
|
2176
|
+
const queryParameters = {};
|
|
2177
|
+
if (getVersion !== void 0) {
|
|
2178
|
+
queryParameters["getVersion"] = getVersion.toString();
|
|
2179
|
+
}
|
|
2180
|
+
const request = {
|
|
2181
|
+
method: "GET",
|
|
2182
|
+
path: requestPath,
|
|
2183
|
+
queryParameters,
|
|
2184
|
+
headers
|
|
2185
|
+
};
|
|
2186
|
+
return transporter.request(request, requestOptions);
|
|
2187
|
+
},
|
|
2188
|
+
/**
|
|
2189
|
+
* Retrieves an object with non-null index settings.
|
|
2190
|
+
*
|
|
2191
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2192
|
+
*
|
|
2193
|
+
* Required API Key ACLs:
|
|
2194
|
+
* - settings
|
|
2195
|
+
* @param getSettings - The getSettings object.
|
|
2196
|
+
* @param getSettings.indexName - Name of the index on which to perform the operation.
|
|
2197
|
+
* @param getSettings.getVersion - When set to 2, the endpoint will not include `synonyms` in the response. This parameter is here for backward compatibility.
|
|
2198
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2199
|
+
* @see getSettings for the plain version.
|
|
2200
|
+
*/
|
|
2201
|
+
getSettingsWithHTTPInfo({ indexName, getVersion }, requestOptions) {
|
|
2202
|
+
(0, import_client_common.validateRequired)("indexName", "getSettingsWithHTTPInfo", indexName);
|
|
2203
|
+
const requestPath = "/1/indexes/{indexName}/settings".replace("{indexName}", encodeURIComponent(indexName));
|
|
2204
|
+
const headers = {};
|
|
2205
|
+
const queryParameters = {};
|
|
2206
|
+
if (getVersion !== void 0) {
|
|
2207
|
+
queryParameters["getVersion"] = getVersion.toString();
|
|
2208
|
+
}
|
|
2209
|
+
const request = {
|
|
2210
|
+
method: "GET",
|
|
2211
|
+
path: requestPath,
|
|
2212
|
+
queryParameters,
|
|
2213
|
+
headers
|
|
2214
|
+
};
|
|
2215
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2216
|
+
},
|
|
2217
|
+
/**
|
|
2218
|
+
* Retrieves all allowed IP addresses with access to your application.
|
|
2219
|
+
*
|
|
2220
|
+
* Required API Key ACLs:
|
|
2221
|
+
* - admin
|
|
2222
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2223
|
+
*/
|
|
2224
|
+
getSources(requestOptions) {
|
|
2225
|
+
const requestPath = "/1/security/sources";
|
|
2226
|
+
const headers = {};
|
|
2227
|
+
const queryParameters = {};
|
|
2228
|
+
const request = {
|
|
2229
|
+
method: "GET",
|
|
2230
|
+
path: requestPath,
|
|
2231
|
+
queryParameters,
|
|
2232
|
+
headers
|
|
2233
|
+
};
|
|
2234
|
+
return transporter.request(request, requestOptions);
|
|
2235
|
+
},
|
|
2236
|
+
/**
|
|
2237
|
+
* Retrieves all allowed IP addresses with access to your application.
|
|
2238
|
+
*
|
|
2239
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2240
|
+
*
|
|
2241
|
+
* Required API Key ACLs:
|
|
2242
|
+
* - admin
|
|
2243
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2244
|
+
* @see getSources for the plain version.
|
|
2245
|
+
*/
|
|
2246
|
+
getSourcesWithHTTPInfo(requestOptions) {
|
|
2247
|
+
const requestPath = "/1/security/sources";
|
|
2248
|
+
const headers = {};
|
|
2249
|
+
const queryParameters = {};
|
|
2250
|
+
const request = {
|
|
2251
|
+
method: "GET",
|
|
2252
|
+
path: requestPath,
|
|
2253
|
+
queryParameters,
|
|
2254
|
+
headers
|
|
2255
|
+
};
|
|
2256
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2257
|
+
},
|
|
2258
|
+
/**
|
|
2259
|
+
* Retrieves a synonym by its ID. To find the object IDs for your synonyms, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-synonyms).
|
|
2260
|
+
*
|
|
2261
|
+
* Required API Key ACLs:
|
|
2262
|
+
* - settings
|
|
2263
|
+
* @param getSynonym - The getSynonym object.
|
|
2264
|
+
* @param getSynonym.indexName - Name of the index on which to perform the operation.
|
|
2265
|
+
* @param getSynonym.objectID - Unique identifier of a synonym object.
|
|
2266
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2267
|
+
*/
|
|
2268
|
+
getSynonym({ indexName, objectID }, requestOptions) {
|
|
2269
|
+
(0, import_client_common.validateRequired)("indexName", "getSynonym", indexName);
|
|
2270
|
+
(0, import_client_common.validateRequired)("objectID", "getSynonym", objectID);
|
|
2271
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2272
|
+
const headers = {};
|
|
2273
|
+
const queryParameters = {};
|
|
2274
|
+
const request = {
|
|
2275
|
+
method: "GET",
|
|
2276
|
+
path: requestPath,
|
|
2277
|
+
queryParameters,
|
|
2278
|
+
headers
|
|
2279
|
+
};
|
|
2280
|
+
return transporter.request(request, requestOptions);
|
|
2281
|
+
},
|
|
2282
|
+
/**
|
|
2283
|
+
* Retrieves a synonym by its ID. To find the object IDs for your synonyms, use the [`search` operation](https://www.algolia.com/doc/rest-api/search/search-synonyms).
|
|
2284
|
+
*
|
|
2285
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2286
|
+
*
|
|
2287
|
+
* Required API Key ACLs:
|
|
2288
|
+
* - settings
|
|
2289
|
+
* @param getSynonym - The getSynonym object.
|
|
2290
|
+
* @param getSynonym.indexName - Name of the index on which to perform the operation.
|
|
2291
|
+
* @param getSynonym.objectID - Unique identifier of a synonym object.
|
|
2292
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2293
|
+
* @see getSynonym for the plain version.
|
|
2294
|
+
*/
|
|
2295
|
+
getSynonymWithHTTPInfo({ indexName, objectID }, requestOptions) {
|
|
2296
|
+
(0, import_client_common.validateRequired)("indexName", "getSynonymWithHTTPInfo", indexName);
|
|
2297
|
+
(0, import_client_common.validateRequired)("objectID", "getSynonymWithHTTPInfo", objectID);
|
|
2298
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2299
|
+
const headers = {};
|
|
2300
|
+
const queryParameters = {};
|
|
2301
|
+
const request = {
|
|
2302
|
+
method: "GET",
|
|
2303
|
+
path: requestPath,
|
|
2304
|
+
queryParameters,
|
|
2305
|
+
headers
|
|
2306
|
+
};
|
|
2307
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2308
|
+
},
|
|
2309
|
+
/**
|
|
2310
|
+
* 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.
|
|
2311
|
+
*
|
|
2312
|
+
* Required API Key ACLs:
|
|
2313
|
+
* - addObject
|
|
2314
|
+
* @param getTask - The getTask object.
|
|
2315
|
+
* @param getTask.indexName - Name of the index on which to perform the operation.
|
|
2316
|
+
* @param getTask.taskID - Unique task identifier.
|
|
2317
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1301
2318
|
*/
|
|
1302
|
-
|
|
1303
|
-
(0, import_client_common.validateRequired)("indexName", "
|
|
1304
|
-
(0, import_client_common.validateRequired)("
|
|
1305
|
-
const requestPath = "/1/indexes/{indexName}/
|
|
2319
|
+
getTask({ indexName, taskID }, requestOptions) {
|
|
2320
|
+
(0, import_client_common.validateRequired)("indexName", "getTask", indexName);
|
|
2321
|
+
(0, import_client_common.validateRequired)("taskID", "getTask", taskID);
|
|
2322
|
+
const requestPath = "/1/indexes/{indexName}/task/{taskID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{taskID}", encodeURIComponent(taskID));
|
|
1306
2323
|
const headers = {};
|
|
1307
2324
|
const queryParameters = {};
|
|
1308
2325
|
const request = {
|
|
@@ -1314,40 +2331,43 @@ function createSearchClient({
|
|
|
1314
2331
|
return transporter.request(request, requestOptions);
|
|
1315
2332
|
},
|
|
1316
2333
|
/**
|
|
1317
|
-
*
|
|
2334
|
+
* 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.
|
|
2335
|
+
*
|
|
2336
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1318
2337
|
*
|
|
1319
2338
|
* Required API Key ACLs:
|
|
1320
|
-
* -
|
|
1321
|
-
* @param
|
|
1322
|
-
* @param
|
|
1323
|
-
* @param
|
|
2339
|
+
* - addObject
|
|
2340
|
+
* @param getTask - The getTask object.
|
|
2341
|
+
* @param getTask.indexName - Name of the index on which to perform the operation.
|
|
2342
|
+
* @param getTask.taskID - Unique task identifier.
|
|
1324
2343
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2344
|
+
* @see getTask for the plain version.
|
|
1325
2345
|
*/
|
|
1326
|
-
|
|
1327
|
-
(0, import_client_common.validateRequired)("indexName", "
|
|
1328
|
-
|
|
2346
|
+
getTaskWithHTTPInfo({ indexName, taskID }, requestOptions) {
|
|
2347
|
+
(0, import_client_common.validateRequired)("indexName", "getTaskWithHTTPInfo", indexName);
|
|
2348
|
+
(0, import_client_common.validateRequired)("taskID", "getTaskWithHTTPInfo", taskID);
|
|
2349
|
+
const requestPath = "/1/indexes/{indexName}/task/{taskID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{taskID}", encodeURIComponent(taskID));
|
|
1329
2350
|
const headers = {};
|
|
1330
2351
|
const queryParameters = {};
|
|
1331
|
-
if (getVersion !== void 0) {
|
|
1332
|
-
queryParameters["getVersion"] = getVersion.toString();
|
|
1333
|
-
}
|
|
1334
2352
|
const request = {
|
|
1335
2353
|
method: "GET",
|
|
1336
2354
|
path: requestPath,
|
|
1337
2355
|
queryParameters,
|
|
1338
2356
|
headers
|
|
1339
2357
|
};
|
|
1340
|
-
return transporter.
|
|
2358
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1341
2359
|
},
|
|
1342
2360
|
/**
|
|
1343
|
-
*
|
|
2361
|
+
* 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.
|
|
1344
2362
|
*
|
|
1345
2363
|
* Required API Key ACLs:
|
|
1346
2364
|
* - admin
|
|
2365
|
+
*
|
|
2366
|
+
* @deprecated
|
|
1347
2367
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1348
2368
|
*/
|
|
1349
|
-
|
|
1350
|
-
const requestPath = "/1/
|
|
2369
|
+
getTopUserIds(requestOptions) {
|
|
2370
|
+
const requestPath = "/1/clusters/mapping/top";
|
|
1351
2371
|
const headers = {};
|
|
1352
2372
|
const queryParameters = {};
|
|
1353
2373
|
const request = {
|
|
@@ -1359,19 +2379,19 @@ function createSearchClient({
|
|
|
1359
2379
|
return transporter.request(request, requestOptions);
|
|
1360
2380
|
},
|
|
1361
2381
|
/**
|
|
1362
|
-
*
|
|
2382
|
+
* 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.
|
|
2383
|
+
*
|
|
2384
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1363
2385
|
*
|
|
1364
2386
|
* Required API Key ACLs:
|
|
1365
|
-
* -
|
|
1366
|
-
*
|
|
1367
|
-
* @
|
|
1368
|
-
* @param getSynonym.objectID - Unique identifier of a synonym object.
|
|
2387
|
+
* - admin
|
|
2388
|
+
*
|
|
2389
|
+
* @deprecated
|
|
1369
2390
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2391
|
+
* @see getTopUserIds for the plain version.
|
|
1370
2392
|
*/
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
(0, import_client_common.validateRequired)("objectID", "getSynonym", objectID);
|
|
1374
|
-
const requestPath = "/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2393
|
+
getTopUserIdsWithHTTPInfo(requestOptions) {
|
|
2394
|
+
const requestPath = "/1/clusters/mapping/top";
|
|
1375
2395
|
const headers = {};
|
|
1376
2396
|
const queryParameters = {};
|
|
1377
2397
|
const request = {
|
|
@@ -1380,22 +2400,22 @@ function createSearchClient({
|
|
|
1380
2400
|
queryParameters,
|
|
1381
2401
|
headers
|
|
1382
2402
|
};
|
|
1383
|
-
return transporter.
|
|
2403
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1384
2404
|
},
|
|
1385
2405
|
/**
|
|
1386
|
-
*
|
|
2406
|
+
* 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.
|
|
1387
2407
|
*
|
|
1388
2408
|
* Required API Key ACLs:
|
|
1389
|
-
* -
|
|
1390
|
-
*
|
|
1391
|
-
* @
|
|
1392
|
-
* @param
|
|
2409
|
+
* - admin
|
|
2410
|
+
*
|
|
2411
|
+
* @deprecated
|
|
2412
|
+
* @param getUserId - The getUserId object.
|
|
2413
|
+
* @param getUserId.userID - Unique identifier of the user who makes the search request.
|
|
1393
2414
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1394
2415
|
*/
|
|
1395
|
-
|
|
1396
|
-
(0, import_client_common.validateRequired)("
|
|
1397
|
-
|
|
1398
|
-
const requestPath = "/1/indexes/{indexName}/task/{taskID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{taskID}", encodeURIComponent(taskID));
|
|
2416
|
+
getUserId({ userID }, requestOptions) {
|
|
2417
|
+
(0, import_client_common.validateRequired)("userID", "getUserId", userID);
|
|
2418
|
+
const requestPath = "/1/clusters/mapping/{userID}".replace("{userID}", encodeURIComponent(userID));
|
|
1399
2419
|
const headers = {};
|
|
1400
2420
|
const queryParameters = {};
|
|
1401
2421
|
const request = {
|
|
@@ -1407,16 +2427,22 @@ function createSearchClient({
|
|
|
1407
2427
|
return transporter.request(request, requestOptions);
|
|
1408
2428
|
},
|
|
1409
2429
|
/**
|
|
1410
|
-
*
|
|
2430
|
+
* 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.
|
|
2431
|
+
*
|
|
2432
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
1411
2433
|
*
|
|
1412
2434
|
* Required API Key ACLs:
|
|
1413
2435
|
* - admin
|
|
1414
2436
|
*
|
|
1415
2437
|
* @deprecated
|
|
2438
|
+
* @param getUserId - The getUserId object.
|
|
2439
|
+
* @param getUserId.userID - Unique identifier of the user who makes the search request.
|
|
1416
2440
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2441
|
+
* @see getUserId for the plain version.
|
|
1417
2442
|
*/
|
|
1418
|
-
|
|
1419
|
-
|
|
2443
|
+
getUserIdWithHTTPInfo({ userID }, requestOptions) {
|
|
2444
|
+
(0, import_client_common.validateRequired)("userID", "getUserIdWithHTTPInfo", userID);
|
|
2445
|
+
const requestPath = "/1/clusters/mapping/{userID}".replace("{userID}", encodeURIComponent(userID));
|
|
1420
2446
|
const headers = {};
|
|
1421
2447
|
const queryParameters = {};
|
|
1422
2448
|
const request = {
|
|
@@ -1425,24 +2451,26 @@ function createSearchClient({
|
|
|
1425
2451
|
queryParameters,
|
|
1426
2452
|
headers
|
|
1427
2453
|
};
|
|
1428
|
-
return transporter.
|
|
2454
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1429
2455
|
},
|
|
1430
2456
|
/**
|
|
1431
|
-
*
|
|
2457
|
+
* 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.
|
|
1432
2458
|
*
|
|
1433
2459
|
* Required API Key ACLs:
|
|
1434
2460
|
* - admin
|
|
1435
2461
|
*
|
|
1436
2462
|
* @deprecated
|
|
1437
|
-
* @param
|
|
1438
|
-
* @param
|
|
2463
|
+
* @param hasPendingMappings - The hasPendingMappings object.
|
|
2464
|
+
* @param hasPendingMappings.getClusters - Whether to include the cluster\'s pending mapping state in the response.
|
|
1439
2465
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
1440
2466
|
*/
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
const requestPath = "/1/clusters/mapping/{userID}".replace("{userID}", encodeURIComponent(userID));
|
|
2467
|
+
hasPendingMappings({ getClusters } = {}, requestOptions = void 0) {
|
|
2468
|
+
const requestPath = "/1/clusters/mapping/pending";
|
|
1444
2469
|
const headers = {};
|
|
1445
2470
|
const queryParameters = {};
|
|
2471
|
+
if (getClusters !== void 0) {
|
|
2472
|
+
queryParameters["getClusters"] = getClusters.toString();
|
|
2473
|
+
}
|
|
1446
2474
|
const request = {
|
|
1447
2475
|
method: "GET",
|
|
1448
2476
|
path: requestPath,
|
|
@@ -1454,6 +2482,8 @@ function createSearchClient({
|
|
|
1454
2482
|
/**
|
|
1455
2483
|
* 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.
|
|
1456
2484
|
*
|
|
2485
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2486
|
+
*
|
|
1457
2487
|
* Required API Key ACLs:
|
|
1458
2488
|
* - admin
|
|
1459
2489
|
*
|
|
@@ -1461,8 +2491,9 @@ function createSearchClient({
|
|
|
1461
2491
|
* @param hasPendingMappings - The hasPendingMappings object.
|
|
1462
2492
|
* @param hasPendingMappings.getClusters - Whether to include the cluster\'s pending mapping state in the response.
|
|
1463
2493
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2494
|
+
* @see hasPendingMappings for the plain version.
|
|
1464
2495
|
*/
|
|
1465
|
-
|
|
2496
|
+
hasPendingMappingsWithHTTPInfo({ getClusters } = {}, requestOptions = void 0) {
|
|
1466
2497
|
const requestPath = "/1/clusters/mapping/pending";
|
|
1467
2498
|
const headers = {};
|
|
1468
2499
|
const queryParameters = {};
|
|
@@ -1475,7 +2506,7 @@ function createSearchClient({
|
|
|
1475
2506
|
queryParameters,
|
|
1476
2507
|
headers
|
|
1477
2508
|
};
|
|
1478
|
-
return transporter.
|
|
2509
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1479
2510
|
},
|
|
1480
2511
|
/**
|
|
1481
2512
|
* Lists all API keys associated with your Algolia application, including their permissions and restrictions.
|
|
@@ -1496,6 +2527,28 @@ function createSearchClient({
|
|
|
1496
2527
|
};
|
|
1497
2528
|
return transporter.request(request, requestOptions);
|
|
1498
2529
|
},
|
|
2530
|
+
/**
|
|
2531
|
+
* Lists all API keys associated with your Algolia application, including their permissions and restrictions.
|
|
2532
|
+
*
|
|
2533
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2534
|
+
*
|
|
2535
|
+
* Required API Key ACLs:
|
|
2536
|
+
* - admin
|
|
2537
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2538
|
+
* @see listApiKeys for the plain version.
|
|
2539
|
+
*/
|
|
2540
|
+
listApiKeysWithHTTPInfo(requestOptions) {
|
|
2541
|
+
const requestPath = "/1/keys";
|
|
2542
|
+
const headers = {};
|
|
2543
|
+
const queryParameters = {};
|
|
2544
|
+
const request = {
|
|
2545
|
+
method: "GET",
|
|
2546
|
+
path: requestPath,
|
|
2547
|
+
queryParameters,
|
|
2548
|
+
headers
|
|
2549
|
+
};
|
|
2550
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2551
|
+
},
|
|
1499
2552
|
/**
|
|
1500
2553
|
* Lists the available clusters in a multi-cluster setup.
|
|
1501
2554
|
*
|
|
@@ -1517,6 +2570,30 @@ function createSearchClient({
|
|
|
1517
2570
|
};
|
|
1518
2571
|
return transporter.request(request, requestOptions);
|
|
1519
2572
|
},
|
|
2573
|
+
/**
|
|
2574
|
+
* Lists the available clusters in a multi-cluster setup.
|
|
2575
|
+
*
|
|
2576
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2577
|
+
*
|
|
2578
|
+
* Required API Key ACLs:
|
|
2579
|
+
* - admin
|
|
2580
|
+
*
|
|
2581
|
+
* @deprecated
|
|
2582
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2583
|
+
* @see listClusters for the plain version.
|
|
2584
|
+
*/
|
|
2585
|
+
listClustersWithHTTPInfo(requestOptions) {
|
|
2586
|
+
const requestPath = "/1/clusters";
|
|
2587
|
+
const headers = {};
|
|
2588
|
+
const queryParameters = {};
|
|
2589
|
+
const request = {
|
|
2590
|
+
method: "GET",
|
|
2591
|
+
path: requestPath,
|
|
2592
|
+
queryParameters,
|
|
2593
|
+
headers
|
|
2594
|
+
};
|
|
2595
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2596
|
+
},
|
|
1520
2597
|
/**
|
|
1521
2598
|
* Lists all indices in the current Algolia application. The request follows any index restrictions of the API key you use to make the request.
|
|
1522
2599
|
*
|
|
@@ -1545,6 +2622,37 @@ function createSearchClient({
|
|
|
1545
2622
|
};
|
|
1546
2623
|
return transporter.request(request, requestOptions);
|
|
1547
2624
|
},
|
|
2625
|
+
/**
|
|
2626
|
+
* Lists all indices in the current Algolia application. The request follows any index restrictions of the API key you use to make the request.
|
|
2627
|
+
*
|
|
2628
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2629
|
+
*
|
|
2630
|
+
* Required API Key ACLs:
|
|
2631
|
+
* - listIndexes
|
|
2632
|
+
* @param listIndices - The listIndices object.
|
|
2633
|
+
* @param listIndices.page - Requested page of the API response. If `null`, the API response is not paginated.
|
|
2634
|
+
* @param listIndices.hitsPerPage - Number of hits per page.
|
|
2635
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2636
|
+
* @see listIndices for the plain version.
|
|
2637
|
+
*/
|
|
2638
|
+
listIndicesWithHTTPInfo({ page, hitsPerPage } = {}, requestOptions = void 0) {
|
|
2639
|
+
const requestPath = "/1/indexes";
|
|
2640
|
+
const headers = {};
|
|
2641
|
+
const queryParameters = {};
|
|
2642
|
+
if (page !== void 0) {
|
|
2643
|
+
queryParameters["page"] = page.toString();
|
|
2644
|
+
}
|
|
2645
|
+
if (hitsPerPage !== void 0) {
|
|
2646
|
+
queryParameters["hitsPerPage"] = hitsPerPage.toString();
|
|
2647
|
+
}
|
|
2648
|
+
const request = {
|
|
2649
|
+
method: "GET",
|
|
2650
|
+
path: requestPath,
|
|
2651
|
+
queryParameters,
|
|
2652
|
+
headers
|
|
2653
|
+
};
|
|
2654
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2655
|
+
},
|
|
1548
2656
|
/**
|
|
1549
2657
|
* 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.
|
|
1550
2658
|
*
|
|
@@ -1575,6 +2683,39 @@ function createSearchClient({
|
|
|
1575
2683
|
};
|
|
1576
2684
|
return transporter.request(request, requestOptions);
|
|
1577
2685
|
},
|
|
2686
|
+
/**
|
|
2687
|
+
* 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.
|
|
2688
|
+
*
|
|
2689
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2690
|
+
*
|
|
2691
|
+
* Required API Key ACLs:
|
|
2692
|
+
* - admin
|
|
2693
|
+
*
|
|
2694
|
+
* @deprecated
|
|
2695
|
+
* @param listUserIds - The listUserIds object.
|
|
2696
|
+
* @param listUserIds.page - Requested page of the API response. If `null`, the API response is not paginated.
|
|
2697
|
+
* @param listUserIds.hitsPerPage - Number of hits per page.
|
|
2698
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2699
|
+
* @see listUserIds for the plain version.
|
|
2700
|
+
*/
|
|
2701
|
+
listUserIdsWithHTTPInfo({ page, hitsPerPage } = {}, requestOptions = void 0) {
|
|
2702
|
+
const requestPath = "/1/clusters/mapping";
|
|
2703
|
+
const headers = {};
|
|
2704
|
+
const queryParameters = {};
|
|
2705
|
+
if (page !== void 0) {
|
|
2706
|
+
queryParameters["page"] = page.toString();
|
|
2707
|
+
}
|
|
2708
|
+
if (hitsPerPage !== void 0) {
|
|
2709
|
+
queryParameters["hitsPerPage"] = hitsPerPage.toString();
|
|
2710
|
+
}
|
|
2711
|
+
const request = {
|
|
2712
|
+
method: "GET",
|
|
2713
|
+
path: requestPath,
|
|
2714
|
+
queryParameters,
|
|
2715
|
+
headers
|
|
2716
|
+
};
|
|
2717
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2718
|
+
},
|
|
1578
2719
|
/**
|
|
1579
2720
|
* 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. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1580
2721
|
*
|
|
@@ -1598,6 +2739,32 @@ function createSearchClient({
|
|
|
1598
2739
|
};
|
|
1599
2740
|
return transporter.request(request, requestOptions);
|
|
1600
2741
|
},
|
|
2742
|
+
/**
|
|
2743
|
+
* 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. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
2744
|
+
*
|
|
2745
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2746
|
+
*
|
|
2747
|
+
* Required API Key ACLs:
|
|
2748
|
+
* - addObject
|
|
2749
|
+
* @param batchParams - The batchParams object.
|
|
2750
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2751
|
+
* @see multipleBatch for the plain version.
|
|
2752
|
+
*/
|
|
2753
|
+
multipleBatchWithHTTPInfo(batchParams, requestOptions) {
|
|
2754
|
+
(0, import_client_common.validateRequired)("batchParams", "multipleBatchWithHTTPInfo", batchParams);
|
|
2755
|
+
(0, import_client_common.validateRequired)("batchParams.requests", "multipleBatchWithHTTPInfo", batchParams.requests);
|
|
2756
|
+
const requestPath = "/1/indexes/*/batch";
|
|
2757
|
+
const headers = {};
|
|
2758
|
+
const queryParameters = {};
|
|
2759
|
+
const request = {
|
|
2760
|
+
method: "POST",
|
|
2761
|
+
path: requestPath,
|
|
2762
|
+
queryParameters,
|
|
2763
|
+
headers,
|
|
2764
|
+
data: batchParams
|
|
2765
|
+
};
|
|
2766
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2767
|
+
},
|
|
1601
2768
|
/**
|
|
1602
2769
|
* Copies or moves (renames) an index within the same Algolia application. Notes: - Existing destination indices are overwritten, except for their analytics data. - If the destination index doesn\'t exist yet, it\'s created. - This operation is resource-intensive. **Copy** - If the source index doesn\'t exist, copying creates a new index with 0 records and default settings. - API keys from 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). - For more information, see [Copy indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/copy-indices). **Move** - If the source index doesn\'t exist, moving 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. - For more information, see [Move indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/move-indices). This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1603
2770
|
*
|
|
@@ -1621,13 +2788,80 @@ function createSearchClient({
|
|
|
1621
2788
|
path: requestPath,
|
|
1622
2789
|
queryParameters,
|
|
1623
2790
|
headers,
|
|
1624
|
-
data: operationIndexParams
|
|
2791
|
+
data: operationIndexParams
|
|
2792
|
+
};
|
|
2793
|
+
return transporter.request(request, requestOptions);
|
|
2794
|
+
},
|
|
2795
|
+
/**
|
|
2796
|
+
* Copies or moves (renames) an index within the same Algolia application. Notes: - Existing destination indices are overwritten, except for their analytics data. - If the destination index doesn\'t exist yet, it\'s created. - This operation is resource-intensive. **Copy** - If the source index doesn\'t exist, copying creates a new index with 0 records and default settings. - API keys from 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). - For more information, see [Copy indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/copy-indices). **Move** - If the source index doesn\'t exist, moving 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. - For more information, see [Move indices](https://www.algolia.com/doc/guides/sending-and-managing-data/manage-indices-and-apps/manage-indices/how-to/move-indices). This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
2797
|
+
*
|
|
2798
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2799
|
+
*
|
|
2800
|
+
* Required API Key ACLs:
|
|
2801
|
+
* - addObject
|
|
2802
|
+
* @param operationIndex - The operationIndex object.
|
|
2803
|
+
* @param operationIndex.indexName - Name of the index on which to perform the operation.
|
|
2804
|
+
* @param operationIndex.operationIndexParams - The operationIndexParams object.
|
|
2805
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2806
|
+
* @see operationIndex for the plain version.
|
|
2807
|
+
*/
|
|
2808
|
+
operationIndexWithHTTPInfo({ indexName, operationIndexParams }, requestOptions) {
|
|
2809
|
+
(0, import_client_common.validateRequired)("indexName", "operationIndexWithHTTPInfo", indexName);
|
|
2810
|
+
(0, import_client_common.validateRequired)("operationIndexParams", "operationIndexWithHTTPInfo", operationIndexParams);
|
|
2811
|
+
(0, import_client_common.validateRequired)("operationIndexParams.operation", "operationIndexWithHTTPInfo", operationIndexParams.operation);
|
|
2812
|
+
(0, import_client_common.validateRequired)(
|
|
2813
|
+
"operationIndexParams.destination",
|
|
2814
|
+
"operationIndexWithHTTPInfo",
|
|
2815
|
+
operationIndexParams.destination
|
|
2816
|
+
);
|
|
2817
|
+
const requestPath = "/1/indexes/{indexName}/operation".replace("{indexName}", encodeURIComponent(indexName));
|
|
2818
|
+
const headers = {};
|
|
2819
|
+
const queryParameters = {};
|
|
2820
|
+
const request = {
|
|
2821
|
+
method: "POST",
|
|
2822
|
+
path: requestPath,
|
|
2823
|
+
queryParameters,
|
|
2824
|
+
headers,
|
|
2825
|
+
data: operationIndexParams
|
|
2826
|
+
};
|
|
2827
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2828
|
+
},
|
|
2829
|
+
/**
|
|
2830
|
+
* 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. - Use first-level attributes only. Nested attributes aren\'t supported. If you specify a nested attribute, this operation replaces its first-level ancestor. To update attributes without replacing the full record, use these built-in operations. These operations are useful when the initial data isn\'t available. - `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. Otherwise, the update is ignored. Example: If you pass an `IncrementFrom` value of 2 for the `version` attribute but the current value is 1, the API ignores the update. If the object doesn\'t exist, the API 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. Otherwise, the update is ignored. Example: If you pass an `IncrementSet` value of 2 for the `version` attribute and the current value is 1, the API updates the object. If the object doesn\'t exist yet, the API only creates it if you pass an `IncrementSet` value greater than 0. Specify an operation by providing an object with the attribute to update as the key and its value as an object with these properties: - `_operation`: the operation to apply on the attribute. - `value`: the right-hand side argument to the operation, for example, increment or decrement step, or a value to add or remove. When updating multiple attributes or using multiple operations targeting the same record, use a single partial update for faster processing. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
2831
|
+
*
|
|
2832
|
+
* Required API Key ACLs:
|
|
2833
|
+
* - addObject
|
|
2834
|
+
* @param partialUpdateObject - The partialUpdateObject object.
|
|
2835
|
+
* @param partialUpdateObject.indexName - Name of the index on which to perform the operation.
|
|
2836
|
+
* @param partialUpdateObject.objectID - Unique record identifier.
|
|
2837
|
+
* @param partialUpdateObject.attributesToUpdate - Attributes with their values.
|
|
2838
|
+
* @param partialUpdateObject.createIfNotExists - Whether to create a new record if it doesn\'t exist.
|
|
2839
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2840
|
+
*/
|
|
2841
|
+
partialUpdateObject({ indexName, objectID, attributesToUpdate, createIfNotExists }, requestOptions) {
|
|
2842
|
+
(0, import_client_common.validateRequired)("indexName", "partialUpdateObject", indexName);
|
|
2843
|
+
(0, import_client_common.validateRequired)("objectID", "partialUpdateObject", objectID);
|
|
2844
|
+
(0, import_client_common.validateRequired)("attributesToUpdate", "partialUpdateObject", attributesToUpdate);
|
|
2845
|
+
const requestPath = "/1/indexes/{indexName}/{objectID}/partial".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
2846
|
+
const headers = {};
|
|
2847
|
+
const queryParameters = {};
|
|
2848
|
+
if (createIfNotExists !== void 0) {
|
|
2849
|
+
queryParameters["createIfNotExists"] = createIfNotExists.toString();
|
|
2850
|
+
}
|
|
2851
|
+
const request = {
|
|
2852
|
+
method: "POST",
|
|
2853
|
+
path: requestPath,
|
|
2854
|
+
queryParameters,
|
|
2855
|
+
headers,
|
|
2856
|
+
data: attributesToUpdate
|
|
1625
2857
|
};
|
|
1626
2858
|
return transporter.request(request, requestOptions);
|
|
1627
2859
|
},
|
|
1628
2860
|
/**
|
|
1629
2861
|
* 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. - Use first-level attributes only. Nested attributes aren\'t supported. If you specify a nested attribute, this operation replaces its first-level ancestor. To update attributes without replacing the full record, use these built-in operations. These operations are useful when the initial data isn\'t available. - `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. Otherwise, the update is ignored. Example: If you pass an `IncrementFrom` value of 2 for the `version` attribute but the current value is 1, the API ignores the update. If the object doesn\'t exist, the API 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. Otherwise, the update is ignored. Example: If you pass an `IncrementSet` value of 2 for the `version` attribute and the current value is 1, the API updates the object. If the object doesn\'t exist yet, the API only creates it if you pass an `IncrementSet` value greater than 0. Specify an operation by providing an object with the attribute to update as the key and its value as an object with these properties: - `_operation`: the operation to apply on the attribute. - `value`: the right-hand side argument to the operation, for example, increment or decrement step, or a value to add or remove. When updating multiple attributes or using multiple operations targeting the same record, use a single partial update for faster processing. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1630
2862
|
*
|
|
2863
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2864
|
+
*
|
|
1631
2865
|
* Required API Key ACLs:
|
|
1632
2866
|
* - addObject
|
|
1633
2867
|
* @param partialUpdateObject - The partialUpdateObject object.
|
|
@@ -1636,11 +2870,12 @@ function createSearchClient({
|
|
|
1636
2870
|
* @param partialUpdateObject.attributesToUpdate - Attributes with their values.
|
|
1637
2871
|
* @param partialUpdateObject.createIfNotExists - Whether to create a new record if it doesn\'t exist.
|
|
1638
2872
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2873
|
+
* @see partialUpdateObject for the plain version.
|
|
1639
2874
|
*/
|
|
1640
|
-
|
|
1641
|
-
(0, import_client_common.validateRequired)("indexName", "
|
|
1642
|
-
(0, import_client_common.validateRequired)("objectID", "
|
|
1643
|
-
(0, import_client_common.validateRequired)("attributesToUpdate", "
|
|
2875
|
+
partialUpdateObjectWithHTTPInfo({ indexName, objectID, attributesToUpdate, createIfNotExists }, requestOptions) {
|
|
2876
|
+
(0, import_client_common.validateRequired)("indexName", "partialUpdateObjectWithHTTPInfo", indexName);
|
|
2877
|
+
(0, import_client_common.validateRequired)("objectID", "partialUpdateObjectWithHTTPInfo", objectID);
|
|
2878
|
+
(0, import_client_common.validateRequired)("attributesToUpdate", "partialUpdateObjectWithHTTPInfo", attributesToUpdate);
|
|
1644
2879
|
const requestPath = "/1/indexes/{indexName}/{objectID}/partial".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
1645
2880
|
const headers = {};
|
|
1646
2881
|
const queryParameters = {};
|
|
@@ -1654,7 +2889,7 @@ function createSearchClient({
|
|
|
1654
2889
|
headers,
|
|
1655
2890
|
data: attributesToUpdate
|
|
1656
2891
|
};
|
|
1657
|
-
return transporter.
|
|
2892
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1658
2893
|
},
|
|
1659
2894
|
/**
|
|
1660
2895
|
* Deletes a user ID and its associated data from the clusters.
|
|
@@ -1680,6 +2915,33 @@ function createSearchClient({
|
|
|
1680
2915
|
};
|
|
1681
2916
|
return transporter.request(request, requestOptions);
|
|
1682
2917
|
},
|
|
2918
|
+
/**
|
|
2919
|
+
* Deletes a user ID and its associated data from the clusters.
|
|
2920
|
+
*
|
|
2921
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2922
|
+
*
|
|
2923
|
+
* Required API Key ACLs:
|
|
2924
|
+
* - admin
|
|
2925
|
+
*
|
|
2926
|
+
* @deprecated
|
|
2927
|
+
* @param removeUserId - The removeUserId object.
|
|
2928
|
+
* @param removeUserId.userID - Unique identifier of the user who makes the search request.
|
|
2929
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2930
|
+
* @see removeUserId for the plain version.
|
|
2931
|
+
*/
|
|
2932
|
+
removeUserIdWithHTTPInfo({ userID }, requestOptions) {
|
|
2933
|
+
(0, import_client_common.validateRequired)("userID", "removeUserIdWithHTTPInfo", userID);
|
|
2934
|
+
const requestPath = "/1/clusters/mapping/{userID}".replace("{userID}", encodeURIComponent(userID));
|
|
2935
|
+
const headers = {};
|
|
2936
|
+
const queryParameters = {};
|
|
2937
|
+
const request = {
|
|
2938
|
+
method: "DELETE",
|
|
2939
|
+
path: requestPath,
|
|
2940
|
+
queryParameters,
|
|
2941
|
+
headers
|
|
2942
|
+
};
|
|
2943
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2944
|
+
},
|
|
1683
2945
|
/**
|
|
1684
2946
|
* Replaces the list of allowed sources.
|
|
1685
2947
|
*
|
|
@@ -1703,6 +2965,32 @@ function createSearchClient({
|
|
|
1703
2965
|
};
|
|
1704
2966
|
return transporter.request(request, requestOptions);
|
|
1705
2967
|
},
|
|
2968
|
+
/**
|
|
2969
|
+
* Replaces the list of allowed sources.
|
|
2970
|
+
*
|
|
2971
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
2972
|
+
*
|
|
2973
|
+
* Required API Key ACLs:
|
|
2974
|
+
* - admin
|
|
2975
|
+
* @param replaceSources - The replaceSources object.
|
|
2976
|
+
* @param replaceSources.source - Allowed sources.
|
|
2977
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
2978
|
+
* @see replaceSources for the plain version.
|
|
2979
|
+
*/
|
|
2980
|
+
replaceSourcesWithHTTPInfo({ source }, requestOptions) {
|
|
2981
|
+
(0, import_client_common.validateRequired)("source", "replaceSourcesWithHTTPInfo", source);
|
|
2982
|
+
const requestPath = "/1/security/sources";
|
|
2983
|
+
const headers = {};
|
|
2984
|
+
const queryParameters = {};
|
|
2985
|
+
const request = {
|
|
2986
|
+
method: "PUT",
|
|
2987
|
+
path: requestPath,
|
|
2988
|
+
queryParameters,
|
|
2989
|
+
headers,
|
|
2990
|
+
data: source
|
|
2991
|
+
};
|
|
2992
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2993
|
+
},
|
|
1706
2994
|
/**
|
|
1707
2995
|
* 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.
|
|
1708
2996
|
*
|
|
@@ -1725,6 +3013,31 @@ function createSearchClient({
|
|
|
1725
3013
|
};
|
|
1726
3014
|
return transporter.request(request, requestOptions);
|
|
1727
3015
|
},
|
|
3016
|
+
/**
|
|
3017
|
+
* 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.
|
|
3018
|
+
*
|
|
3019
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3020
|
+
*
|
|
3021
|
+
* Required API Key ACLs:
|
|
3022
|
+
* - admin
|
|
3023
|
+
* @param restoreApiKey - The restoreApiKey object.
|
|
3024
|
+
* @param restoreApiKey.key - API key.
|
|
3025
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3026
|
+
* @see restoreApiKey for the plain version.
|
|
3027
|
+
*/
|
|
3028
|
+
restoreApiKeyWithHTTPInfo({ key }, requestOptions) {
|
|
3029
|
+
(0, import_client_common.validateRequired)("key", "restoreApiKeyWithHTTPInfo", key);
|
|
3030
|
+
const requestPath = "/1/keys/{key}/restore".replace("{key}", encodeURIComponent(key));
|
|
3031
|
+
const headers = {};
|
|
3032
|
+
const queryParameters = {};
|
|
3033
|
+
const request = {
|
|
3034
|
+
method: "POST",
|
|
3035
|
+
path: requestPath,
|
|
3036
|
+
queryParameters,
|
|
3037
|
+
headers
|
|
3038
|
+
};
|
|
3039
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3040
|
+
},
|
|
1728
3041
|
/**
|
|
1729
3042
|
* Adds a record to an index or replaces 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](https://www.algolia.com/doc/rest-api/search/partial-update-object). To add, update, or replace multiple records, use the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch). This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1730
3043
|
*
|
|
@@ -1750,6 +3063,34 @@ function createSearchClient({
|
|
|
1750
3063
|
};
|
|
1751
3064
|
return transporter.request(request, requestOptions);
|
|
1752
3065
|
},
|
|
3066
|
+
/**
|
|
3067
|
+
* Adds a record to an index or replaces 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](https://www.algolia.com/doc/rest-api/search/partial-update-object). To add, update, or replace multiple records, use the [`batch` operation](https://www.algolia.com/doc/rest-api/search/batch). This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
3068
|
+
*
|
|
3069
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3070
|
+
*
|
|
3071
|
+
* Required API Key ACLs:
|
|
3072
|
+
* - addObject
|
|
3073
|
+
* @param saveObject - The saveObject object.
|
|
3074
|
+
* @param saveObject.indexName - Name of the index on which to perform the operation.
|
|
3075
|
+
* @param saveObject.body - The record. A schemaless object with attributes that are useful in the context of search and discovery.
|
|
3076
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3077
|
+
* @see saveObject for the plain version.
|
|
3078
|
+
*/
|
|
3079
|
+
saveObjectWithHTTPInfo({ indexName, body }, requestOptions) {
|
|
3080
|
+
(0, import_client_common.validateRequired)("indexName", "saveObjectWithHTTPInfo", indexName);
|
|
3081
|
+
(0, import_client_common.validateRequired)("body", "saveObjectWithHTTPInfo", body);
|
|
3082
|
+
const requestPath = "/1/indexes/{indexName}".replace("{indexName}", encodeURIComponent(indexName));
|
|
3083
|
+
const headers = {};
|
|
3084
|
+
const queryParameters = {};
|
|
3085
|
+
const request = {
|
|
3086
|
+
method: "POST",
|
|
3087
|
+
path: requestPath,
|
|
3088
|
+
queryParameters,
|
|
3089
|
+
headers,
|
|
3090
|
+
data: body
|
|
3091
|
+
};
|
|
3092
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3093
|
+
},
|
|
1753
3094
|
/**
|
|
1754
3095
|
* 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](https://www.algolia.com/doc/rest-api/search/save-rules).
|
|
1755
3096
|
*
|
|
@@ -1783,6 +3124,42 @@ function createSearchClient({
|
|
|
1783
3124
|
};
|
|
1784
3125
|
return transporter.request(request, requestOptions);
|
|
1785
3126
|
},
|
|
3127
|
+
/**
|
|
3128
|
+
* 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](https://www.algolia.com/doc/rest-api/search/save-rules).
|
|
3129
|
+
*
|
|
3130
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3131
|
+
*
|
|
3132
|
+
* Required API Key ACLs:
|
|
3133
|
+
* - editSettings
|
|
3134
|
+
* @param saveRule - The saveRule object.
|
|
3135
|
+
* @param saveRule.indexName - Name of the index on which to perform the operation.
|
|
3136
|
+
* @param saveRule.objectID - Unique identifier of a rule object.
|
|
3137
|
+
* @param saveRule.rule - The rule object.
|
|
3138
|
+
* @param saveRule.forwardToReplicas - Whether changes are applied to replica indices.
|
|
3139
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3140
|
+
* @see saveRule for the plain version.
|
|
3141
|
+
*/
|
|
3142
|
+
saveRuleWithHTTPInfo({ indexName, objectID, rule, forwardToReplicas }, requestOptions) {
|
|
3143
|
+
(0, import_client_common.validateRequired)("indexName", "saveRuleWithHTTPInfo", indexName);
|
|
3144
|
+
(0, import_client_common.validateRequired)("objectID", "saveRuleWithHTTPInfo", objectID);
|
|
3145
|
+
(0, import_client_common.validateRequired)("rule", "saveRuleWithHTTPInfo", rule);
|
|
3146
|
+
(0, import_client_common.validateRequired)("rule.objectID", "saveRuleWithHTTPInfo", rule.objectID);
|
|
3147
|
+
(0, import_client_common.validateRequired)("rule.consequence", "saveRuleWithHTTPInfo", rule.consequence);
|
|
3148
|
+
const requestPath = "/1/indexes/{indexName}/rules/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
3149
|
+
const headers = {};
|
|
3150
|
+
const queryParameters = {};
|
|
3151
|
+
if (forwardToReplicas !== void 0) {
|
|
3152
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
3153
|
+
}
|
|
3154
|
+
const request = {
|
|
3155
|
+
method: "PUT",
|
|
3156
|
+
path: requestPath,
|
|
3157
|
+
queryParameters,
|
|
3158
|
+
headers,
|
|
3159
|
+
data: rule
|
|
3160
|
+
};
|
|
3161
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3162
|
+
},
|
|
1786
3163
|
/**
|
|
1787
3164
|
* 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. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1788
3165
|
*
|
|
@@ -1816,6 +3193,42 @@ function createSearchClient({
|
|
|
1816
3193
|
};
|
|
1817
3194
|
return transporter.request(request, requestOptions);
|
|
1818
3195
|
},
|
|
3196
|
+
/**
|
|
3197
|
+
* 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. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
3198
|
+
*
|
|
3199
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3200
|
+
*
|
|
3201
|
+
* Required API Key ACLs:
|
|
3202
|
+
* - editSettings
|
|
3203
|
+
* @param saveRules - The saveRules object.
|
|
3204
|
+
* @param saveRules.indexName - Name of the index on which to perform the operation.
|
|
3205
|
+
* @param saveRules.rules - The rules object.
|
|
3206
|
+
* @param saveRules.forwardToReplicas - Whether changes are applied to replica indices.
|
|
3207
|
+
* @param saveRules.clearExistingRules - Whether existing rules should be deleted before adding this batch.
|
|
3208
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3209
|
+
* @see saveRules for the plain version.
|
|
3210
|
+
*/
|
|
3211
|
+
saveRulesWithHTTPInfo({ indexName, rules, forwardToReplicas, clearExistingRules }, requestOptions) {
|
|
3212
|
+
(0, import_client_common.validateRequired)("indexName", "saveRulesWithHTTPInfo", indexName);
|
|
3213
|
+
(0, import_client_common.validateRequired)("rules", "saveRulesWithHTTPInfo", rules);
|
|
3214
|
+
const requestPath = "/1/indexes/{indexName}/rules/batch".replace("{indexName}", encodeURIComponent(indexName));
|
|
3215
|
+
const headers = {};
|
|
3216
|
+
const queryParameters = {};
|
|
3217
|
+
if (forwardToReplicas !== void 0) {
|
|
3218
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
3219
|
+
}
|
|
3220
|
+
if (clearExistingRules !== void 0) {
|
|
3221
|
+
queryParameters["clearExistingRules"] = clearExistingRules.toString();
|
|
3222
|
+
}
|
|
3223
|
+
const request = {
|
|
3224
|
+
method: "POST",
|
|
3225
|
+
path: requestPath,
|
|
3226
|
+
queryParameters,
|
|
3227
|
+
headers,
|
|
3228
|
+
data: rules
|
|
3229
|
+
};
|
|
3230
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3231
|
+
},
|
|
1819
3232
|
/**
|
|
1820
3233
|
* 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](https://www.algolia.com/doc/rest-api/search/save-synonyms).
|
|
1821
3234
|
*
|
|
@@ -1849,6 +3262,42 @@ function createSearchClient({
|
|
|
1849
3262
|
};
|
|
1850
3263
|
return transporter.request(request, requestOptions);
|
|
1851
3264
|
},
|
|
3265
|
+
/**
|
|
3266
|
+
* 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](https://www.algolia.com/doc/rest-api/search/save-synonyms).
|
|
3267
|
+
*
|
|
3268
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3269
|
+
*
|
|
3270
|
+
* Required API Key ACLs:
|
|
3271
|
+
* - editSettings
|
|
3272
|
+
* @param saveSynonym - The saveSynonym object.
|
|
3273
|
+
* @param saveSynonym.indexName - Name of the index on which to perform the operation.
|
|
3274
|
+
* @param saveSynonym.objectID - Unique identifier of a synonym object.
|
|
3275
|
+
* @param saveSynonym.synonymHit - The synonymHit object.
|
|
3276
|
+
* @param saveSynonym.forwardToReplicas - Whether changes are applied to replica indices.
|
|
3277
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3278
|
+
* @see saveSynonym for the plain version.
|
|
3279
|
+
*/
|
|
3280
|
+
saveSynonymWithHTTPInfo({ indexName, objectID, synonymHit, forwardToReplicas }, requestOptions) {
|
|
3281
|
+
(0, import_client_common.validateRequired)("indexName", "saveSynonymWithHTTPInfo", indexName);
|
|
3282
|
+
(0, import_client_common.validateRequired)("objectID", "saveSynonymWithHTTPInfo", objectID);
|
|
3283
|
+
(0, import_client_common.validateRequired)("synonymHit", "saveSynonymWithHTTPInfo", synonymHit);
|
|
3284
|
+
(0, import_client_common.validateRequired)("synonymHit.objectID", "saveSynonymWithHTTPInfo", synonymHit.objectID);
|
|
3285
|
+
(0, import_client_common.validateRequired)("synonymHit.type", "saveSynonymWithHTTPInfo", synonymHit.type);
|
|
3286
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/{objectID}".replace("{indexName}", encodeURIComponent(indexName)).replace("{objectID}", encodeURIComponent(objectID));
|
|
3287
|
+
const headers = {};
|
|
3288
|
+
const queryParameters = {};
|
|
3289
|
+
if (forwardToReplicas !== void 0) {
|
|
3290
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
3291
|
+
}
|
|
3292
|
+
const request = {
|
|
3293
|
+
method: "PUT",
|
|
3294
|
+
path: requestPath,
|
|
3295
|
+
queryParameters,
|
|
3296
|
+
headers,
|
|
3297
|
+
data: synonymHit
|
|
3298
|
+
};
|
|
3299
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3300
|
+
},
|
|
1852
3301
|
/**
|
|
1853
3302
|
* If a synonym with the `objectID` doesn\'t exist, Algolia adds a new one. Otherwise, existing synonyms are replaced. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
1854
3303
|
*
|
|
@@ -1867,30 +3316,115 @@ function createSearchClient({
|
|
|
1867
3316
|
const requestPath = "/1/indexes/{indexName}/synonyms/batch".replace("{indexName}", encodeURIComponent(indexName));
|
|
1868
3317
|
const headers = {};
|
|
1869
3318
|
const queryParameters = {};
|
|
1870
|
-
if (forwardToReplicas !== void 0) {
|
|
1871
|
-
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
1872
|
-
}
|
|
1873
|
-
if (replaceExistingSynonyms !== void 0) {
|
|
1874
|
-
queryParameters["replaceExistingSynonyms"] = replaceExistingSynonyms.toString();
|
|
1875
|
-
}
|
|
3319
|
+
if (forwardToReplicas !== void 0) {
|
|
3320
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
3321
|
+
}
|
|
3322
|
+
if (replaceExistingSynonyms !== void 0) {
|
|
3323
|
+
queryParameters["replaceExistingSynonyms"] = replaceExistingSynonyms.toString();
|
|
3324
|
+
}
|
|
3325
|
+
const request = {
|
|
3326
|
+
method: "POST",
|
|
3327
|
+
path: requestPath,
|
|
3328
|
+
queryParameters,
|
|
3329
|
+
headers,
|
|
3330
|
+
data: synonymHit
|
|
3331
|
+
};
|
|
3332
|
+
return transporter.request(request, requestOptions);
|
|
3333
|
+
},
|
|
3334
|
+
/**
|
|
3335
|
+
* If a synonym with the `objectID` doesn\'t exist, Algolia adds a new one. Otherwise, existing synonyms are replaced. This operation is subject to [indexing rate limits](https://support.algolia.com/hc/articles/4406975251089-Is-there-a-rate-limit-for-indexing-on-Algolia).
|
|
3336
|
+
*
|
|
3337
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3338
|
+
*
|
|
3339
|
+
* Required API Key ACLs:
|
|
3340
|
+
* - editSettings
|
|
3341
|
+
* @param saveSynonyms - The saveSynonyms object.
|
|
3342
|
+
* @param saveSynonyms.indexName - Name of the index on which to perform the operation.
|
|
3343
|
+
* @param saveSynonyms.synonymHit - The synonymHit object.
|
|
3344
|
+
* @param saveSynonyms.forwardToReplicas - Whether changes are applied to replica indices.
|
|
3345
|
+
* @param saveSynonyms.replaceExistingSynonyms - Whether to replace all synonyms in the index with the ones sent with this request.
|
|
3346
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3347
|
+
* @see saveSynonyms for the plain version.
|
|
3348
|
+
*/
|
|
3349
|
+
saveSynonymsWithHTTPInfo({ indexName, synonymHit, forwardToReplicas, replaceExistingSynonyms }, requestOptions) {
|
|
3350
|
+
(0, import_client_common.validateRequired)("indexName", "saveSynonymsWithHTTPInfo", indexName);
|
|
3351
|
+
(0, import_client_common.validateRequired)("synonymHit", "saveSynonymsWithHTTPInfo", synonymHit);
|
|
3352
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/batch".replace("{indexName}", encodeURIComponent(indexName));
|
|
3353
|
+
const headers = {};
|
|
3354
|
+
const queryParameters = {};
|
|
3355
|
+
if (forwardToReplicas !== void 0) {
|
|
3356
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
3357
|
+
}
|
|
3358
|
+
if (replaceExistingSynonyms !== void 0) {
|
|
3359
|
+
queryParameters["replaceExistingSynonyms"] = replaceExistingSynonyms.toString();
|
|
3360
|
+
}
|
|
3361
|
+
const request = {
|
|
3362
|
+
method: "POST",
|
|
3363
|
+
path: requestPath,
|
|
3364
|
+
queryParameters,
|
|
3365
|
+
headers,
|
|
3366
|
+
data: synonymHit
|
|
3367
|
+
};
|
|
3368
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3369
|
+
},
|
|
3370
|
+
/**
|
|
3371
|
+
* Runs multiple search queries against one or more indices in a single API request. Use cases include: - Searching different indices, such as products and marketing content. - Run multiple queries on the same index with different parameters or filters. If you know the expected result type, use the `searchForHits` or `searchForFacets` helper to simplify the response format.
|
|
3372
|
+
*
|
|
3373
|
+
* Required API Key ACLs:
|
|
3374
|
+
* - search
|
|
3375
|
+
* @param searchMethodParams - Multi-query search request body. Results are returned in the same order as the requests.
|
|
3376
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3377
|
+
*/
|
|
3378
|
+
search(searchMethodParams, requestOptions) {
|
|
3379
|
+
if (searchMethodParams && Array.isArray(searchMethodParams)) {
|
|
3380
|
+
const newSignatureRequest = {
|
|
3381
|
+
requests: searchMethodParams.map(({ params, ...legacyRequest }) => {
|
|
3382
|
+
if (legacyRequest.type === "facet") {
|
|
3383
|
+
return {
|
|
3384
|
+
...legacyRequest,
|
|
3385
|
+
...params,
|
|
3386
|
+
type: "facet"
|
|
3387
|
+
};
|
|
3388
|
+
}
|
|
3389
|
+
return {
|
|
3390
|
+
...legacyRequest,
|
|
3391
|
+
...params,
|
|
3392
|
+
facet: void 0,
|
|
3393
|
+
maxFacetHits: void 0,
|
|
3394
|
+
facetQuery: void 0
|
|
3395
|
+
};
|
|
3396
|
+
})
|
|
3397
|
+
};
|
|
3398
|
+
searchMethodParams = newSignatureRequest;
|
|
3399
|
+
}
|
|
3400
|
+
(0, import_client_common.validateRequired)("searchMethodParams", "search", searchMethodParams);
|
|
3401
|
+
(0, import_client_common.validateRequired)("searchMethodParams.requests", "search", searchMethodParams.requests);
|
|
3402
|
+
const requestPath = "/1/indexes/*/queries";
|
|
3403
|
+
const headers = {};
|
|
3404
|
+
const queryParameters = {};
|
|
1876
3405
|
const request = {
|
|
1877
3406
|
method: "POST",
|
|
1878
3407
|
path: requestPath,
|
|
1879
3408
|
queryParameters,
|
|
1880
3409
|
headers,
|
|
1881
|
-
data:
|
|
3410
|
+
data: searchMethodParams,
|
|
3411
|
+
useReadTransporter: true,
|
|
3412
|
+
cacheable: true
|
|
1882
3413
|
};
|
|
1883
3414
|
return transporter.request(request, requestOptions);
|
|
1884
3415
|
},
|
|
1885
3416
|
/**
|
|
1886
3417
|
* Runs multiple search queries against one or more indices in a single API request. Use cases include: - Searching different indices, such as products and marketing content. - Run multiple queries on the same index with different parameters or filters. If you know the expected result type, use the `searchForHits` or `searchForFacets` helper to simplify the response format.
|
|
1887
3418
|
*
|
|
3419
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3420
|
+
*
|
|
1888
3421
|
* Required API Key ACLs:
|
|
1889
3422
|
* - search
|
|
1890
3423
|
* @param searchMethodParams - Multi-query search request body. Results are returned in the same order as the requests.
|
|
1891
3424
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3425
|
+
* @see search for the plain version.
|
|
1892
3426
|
*/
|
|
1893
|
-
|
|
3427
|
+
searchWithHTTPInfo(searchMethodParams, requestOptions) {
|
|
1894
3428
|
if (searchMethodParams && Array.isArray(searchMethodParams)) {
|
|
1895
3429
|
const newSignatureRequest = {
|
|
1896
3430
|
requests: searchMethodParams.map(({ params, ...legacyRequest }) => {
|
|
@@ -1912,8 +3446,8 @@ function createSearchClient({
|
|
|
1912
3446
|
};
|
|
1913
3447
|
searchMethodParams = newSignatureRequest;
|
|
1914
3448
|
}
|
|
1915
|
-
(0, import_client_common.validateRequired)("searchMethodParams", "
|
|
1916
|
-
(0, import_client_common.validateRequired)("searchMethodParams.requests", "
|
|
3449
|
+
(0, import_client_common.validateRequired)("searchMethodParams", "searchWithHTTPInfo", searchMethodParams);
|
|
3450
|
+
(0, import_client_common.validateRequired)("searchMethodParams.requests", "searchWithHTTPInfo", searchMethodParams.requests);
|
|
1917
3451
|
const requestPath = "/1/indexes/*/queries";
|
|
1918
3452
|
const headers = {};
|
|
1919
3453
|
const queryParameters = {};
|
|
@@ -1926,7 +3460,7 @@ function createSearchClient({
|
|
|
1926
3460
|
useReadTransporter: true,
|
|
1927
3461
|
cacheable: true
|
|
1928
3462
|
};
|
|
1929
|
-
return transporter.
|
|
3463
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
1930
3464
|
},
|
|
1931
3465
|
/**
|
|
1932
3466
|
* Searches for standard and custom dictionary entries.
|
|
@@ -1963,6 +3497,48 @@ function createSearchClient({
|
|
|
1963
3497
|
};
|
|
1964
3498
|
return transporter.request(request, requestOptions);
|
|
1965
3499
|
},
|
|
3500
|
+
/**
|
|
3501
|
+
* Searches for standard and custom dictionary entries.
|
|
3502
|
+
*
|
|
3503
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3504
|
+
*
|
|
3505
|
+
* Required API Key ACLs:
|
|
3506
|
+
* - settings
|
|
3507
|
+
* @param searchDictionaryEntries - The searchDictionaryEntries object.
|
|
3508
|
+
* @param searchDictionaryEntries.dictionaryName - Dictionary type in which to search.
|
|
3509
|
+
* @param searchDictionaryEntries.searchDictionaryEntriesParams - The searchDictionaryEntriesParams object.
|
|
3510
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3511
|
+
* @see searchDictionaryEntries for the plain version.
|
|
3512
|
+
*/
|
|
3513
|
+
searchDictionaryEntriesWithHTTPInfo({ dictionaryName, searchDictionaryEntriesParams }, requestOptions) {
|
|
3514
|
+
(0, import_client_common.validateRequired)("dictionaryName", "searchDictionaryEntriesWithHTTPInfo", dictionaryName);
|
|
3515
|
+
(0, import_client_common.validateRequired)(
|
|
3516
|
+
"searchDictionaryEntriesParams",
|
|
3517
|
+
"searchDictionaryEntriesWithHTTPInfo",
|
|
3518
|
+
searchDictionaryEntriesParams
|
|
3519
|
+
);
|
|
3520
|
+
(0, import_client_common.validateRequired)(
|
|
3521
|
+
"searchDictionaryEntriesParams.query",
|
|
3522
|
+
"searchDictionaryEntriesWithHTTPInfo",
|
|
3523
|
+
searchDictionaryEntriesParams.query
|
|
3524
|
+
);
|
|
3525
|
+
const requestPath = "/1/dictionaries/{dictionaryName}/search".replace(
|
|
3526
|
+
"{dictionaryName}",
|
|
3527
|
+
encodeURIComponent(dictionaryName)
|
|
3528
|
+
);
|
|
3529
|
+
const headers = {};
|
|
3530
|
+
const queryParameters = {};
|
|
3531
|
+
const request = {
|
|
3532
|
+
method: "POST",
|
|
3533
|
+
path: requestPath,
|
|
3534
|
+
queryParameters,
|
|
3535
|
+
headers,
|
|
3536
|
+
data: searchDictionaryEntriesParams,
|
|
3537
|
+
useReadTransporter: true,
|
|
3538
|
+
cacheable: true
|
|
3539
|
+
};
|
|
3540
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3541
|
+
},
|
|
1966
3542
|
/**
|
|
1967
3543
|
* 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**.
|
|
1968
3544
|
*
|
|
@@ -1991,6 +3567,37 @@ function createSearchClient({
|
|
|
1991
3567
|
};
|
|
1992
3568
|
return transporter.request(request, requestOptions);
|
|
1993
3569
|
},
|
|
3570
|
+
/**
|
|
3571
|
+
* 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**.
|
|
3572
|
+
*
|
|
3573
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3574
|
+
*
|
|
3575
|
+
* Required API Key ACLs:
|
|
3576
|
+
* - search
|
|
3577
|
+
* @param searchForFacetValues - The searchForFacetValues object.
|
|
3578
|
+
* @param searchForFacetValues.indexName - Name of the index on which to perform the operation.
|
|
3579
|
+
* @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.
|
|
3580
|
+
* @param searchForFacetValues.searchForFacetValuesRequest - The searchForFacetValuesRequest object.
|
|
3581
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3582
|
+
* @see searchForFacetValues for the plain version.
|
|
3583
|
+
*/
|
|
3584
|
+
searchForFacetValuesWithHTTPInfo({ indexName, facetName, searchForFacetValuesRequest }, requestOptions) {
|
|
3585
|
+
(0, import_client_common.validateRequired)("indexName", "searchForFacetValuesWithHTTPInfo", indexName);
|
|
3586
|
+
(0, import_client_common.validateRequired)("facetName", "searchForFacetValuesWithHTTPInfo", facetName);
|
|
3587
|
+
const requestPath = "/1/indexes/{indexName}/facets/{facetName}/query".replace("{indexName}", encodeURIComponent(indexName)).replace("{facetName}", encodeURIComponent(facetName));
|
|
3588
|
+
const headers = {};
|
|
3589
|
+
const queryParameters = {};
|
|
3590
|
+
const request = {
|
|
3591
|
+
method: "POST",
|
|
3592
|
+
path: requestPath,
|
|
3593
|
+
queryParameters,
|
|
3594
|
+
headers,
|
|
3595
|
+
data: searchForFacetValuesRequest ? searchForFacetValuesRequest : {},
|
|
3596
|
+
useReadTransporter: true,
|
|
3597
|
+
cacheable: true
|
|
3598
|
+
};
|
|
3599
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3600
|
+
},
|
|
1994
3601
|
/**
|
|
1995
3602
|
* Searches for rules in your index.
|
|
1996
3603
|
*
|
|
@@ -2017,6 +3624,35 @@ function createSearchClient({
|
|
|
2017
3624
|
};
|
|
2018
3625
|
return transporter.request(request, requestOptions);
|
|
2019
3626
|
},
|
|
3627
|
+
/**
|
|
3628
|
+
* Searches for rules in your index.
|
|
3629
|
+
*
|
|
3630
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3631
|
+
*
|
|
3632
|
+
* Required API Key ACLs:
|
|
3633
|
+
* - settings
|
|
3634
|
+
* @param searchRules - The searchRules object.
|
|
3635
|
+
* @param searchRules.indexName - Name of the index on which to perform the operation.
|
|
3636
|
+
* @param searchRules.searchRulesParams - The searchRulesParams object.
|
|
3637
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3638
|
+
* @see searchRules for the plain version.
|
|
3639
|
+
*/
|
|
3640
|
+
searchRulesWithHTTPInfo({ indexName, searchRulesParams }, requestOptions) {
|
|
3641
|
+
(0, import_client_common.validateRequired)("indexName", "searchRulesWithHTTPInfo", indexName);
|
|
3642
|
+
const requestPath = "/1/indexes/{indexName}/rules/search".replace("{indexName}", encodeURIComponent(indexName));
|
|
3643
|
+
const headers = {};
|
|
3644
|
+
const queryParameters = {};
|
|
3645
|
+
const request = {
|
|
3646
|
+
method: "POST",
|
|
3647
|
+
path: requestPath,
|
|
3648
|
+
queryParameters,
|
|
3649
|
+
headers,
|
|
3650
|
+
data: searchRulesParams ? searchRulesParams : {},
|
|
3651
|
+
useReadTransporter: true,
|
|
3652
|
+
cacheable: true
|
|
3653
|
+
};
|
|
3654
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3655
|
+
},
|
|
2020
3656
|
/**
|
|
2021
3657
|
* Searches a single index and returns matching search results as hits. This method lets you retrieve up to 1,000 hits. If you need more, use the [`browse` operation](https://www.algolia.com/doc/rest-api/search/browse) or increase the `paginatedLimitedTo` index setting.
|
|
2022
3658
|
*
|
|
@@ -2043,6 +3679,35 @@ function createSearchClient({
|
|
|
2043
3679
|
};
|
|
2044
3680
|
return transporter.request(request, requestOptions);
|
|
2045
3681
|
},
|
|
3682
|
+
/**
|
|
3683
|
+
* Searches a single index and returns matching search results as hits. This method lets you retrieve up to 1,000 hits. If you need more, use the [`browse` operation](https://www.algolia.com/doc/rest-api/search/browse) or increase the `paginatedLimitedTo` index setting.
|
|
3684
|
+
*
|
|
3685
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3686
|
+
*
|
|
3687
|
+
* Required API Key ACLs:
|
|
3688
|
+
* - search
|
|
3689
|
+
* @param searchSingleIndex - The searchSingleIndex object.
|
|
3690
|
+
* @param searchSingleIndex.indexName - Name of the index on which to perform the operation.
|
|
3691
|
+
* @param searchSingleIndex.searchParams - The searchParams object.
|
|
3692
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3693
|
+
* @see searchSingleIndex for the plain version.
|
|
3694
|
+
*/
|
|
3695
|
+
searchSingleIndexWithHTTPInfo({ indexName, searchParams }, requestOptions) {
|
|
3696
|
+
(0, import_client_common.validateRequired)("indexName", "searchSingleIndexWithHTTPInfo", indexName);
|
|
3697
|
+
const requestPath = "/1/indexes/{indexName}/query".replace("{indexName}", encodeURIComponent(indexName));
|
|
3698
|
+
const headers = {};
|
|
3699
|
+
const queryParameters = {};
|
|
3700
|
+
const request = {
|
|
3701
|
+
method: "POST",
|
|
3702
|
+
path: requestPath,
|
|
3703
|
+
queryParameters,
|
|
3704
|
+
headers,
|
|
3705
|
+
data: searchParams ? searchParams : {},
|
|
3706
|
+
useReadTransporter: true,
|
|
3707
|
+
cacheable: true
|
|
3708
|
+
};
|
|
3709
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3710
|
+
},
|
|
2046
3711
|
/**
|
|
2047
3712
|
* Searches for synonyms in your index.
|
|
2048
3713
|
*
|
|
@@ -2072,6 +3737,38 @@ function createSearchClient({
|
|
|
2072
3737
|
};
|
|
2073
3738
|
return transporter.request(request, requestOptions);
|
|
2074
3739
|
},
|
|
3740
|
+
/**
|
|
3741
|
+
* Searches for synonyms in your index.
|
|
3742
|
+
*
|
|
3743
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3744
|
+
*
|
|
3745
|
+
* Required API Key ACLs:
|
|
3746
|
+
* - settings
|
|
3747
|
+
* @param searchSynonyms - The searchSynonyms object.
|
|
3748
|
+
* @param searchSynonyms.indexName - Name of the index on which to perform the operation.
|
|
3749
|
+
* @param searchSynonyms.searchSynonymsParams - Body of the `searchSynonyms` operation.
|
|
3750
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3751
|
+
* @see searchSynonyms for the plain version.
|
|
3752
|
+
*/
|
|
3753
|
+
searchSynonymsWithHTTPInfo({ indexName, searchSynonymsParams }, requestOptions) {
|
|
3754
|
+
(0, import_client_common.validateRequired)("indexName", "searchSynonymsWithHTTPInfo", indexName);
|
|
3755
|
+
const requestPath = "/1/indexes/{indexName}/synonyms/search".replace(
|
|
3756
|
+
"{indexName}",
|
|
3757
|
+
encodeURIComponent(indexName)
|
|
3758
|
+
);
|
|
3759
|
+
const headers = {};
|
|
3760
|
+
const queryParameters = {};
|
|
3761
|
+
const request = {
|
|
3762
|
+
method: "POST",
|
|
3763
|
+
path: requestPath,
|
|
3764
|
+
queryParameters,
|
|
3765
|
+
headers,
|
|
3766
|
+
data: searchSynonymsParams ? searchSynonymsParams : {},
|
|
3767
|
+
useReadTransporter: true,
|
|
3768
|
+
cacheable: true
|
|
3769
|
+
};
|
|
3770
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3771
|
+
},
|
|
2075
3772
|
/**
|
|
2076
3773
|
* 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).
|
|
2077
3774
|
*
|
|
@@ -2099,6 +3796,36 @@ function createSearchClient({
|
|
|
2099
3796
|
};
|
|
2100
3797
|
return transporter.request(request, requestOptions);
|
|
2101
3798
|
},
|
|
3799
|
+
/**
|
|
3800
|
+
* 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).
|
|
3801
|
+
*
|
|
3802
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3803
|
+
*
|
|
3804
|
+
* Required API Key ACLs:
|
|
3805
|
+
* - admin
|
|
3806
|
+
*
|
|
3807
|
+
* @deprecated
|
|
3808
|
+
* @param searchUserIdsParams - The searchUserIdsParams object.
|
|
3809
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3810
|
+
* @see searchUserIds for the plain version.
|
|
3811
|
+
*/
|
|
3812
|
+
searchUserIdsWithHTTPInfo(searchUserIdsParams, requestOptions) {
|
|
3813
|
+
(0, import_client_common.validateRequired)("searchUserIdsParams", "searchUserIdsWithHTTPInfo", searchUserIdsParams);
|
|
3814
|
+
(0, import_client_common.validateRequired)("searchUserIdsParams.query", "searchUserIdsWithHTTPInfo", searchUserIdsParams.query);
|
|
3815
|
+
const requestPath = "/1/clusters/mapping/search";
|
|
3816
|
+
const headers = {};
|
|
3817
|
+
const queryParameters = {};
|
|
3818
|
+
const request = {
|
|
3819
|
+
method: "POST",
|
|
3820
|
+
path: requestPath,
|
|
3821
|
+
queryParameters,
|
|
3822
|
+
headers,
|
|
3823
|
+
data: searchUserIdsParams,
|
|
3824
|
+
useReadTransporter: true,
|
|
3825
|
+
cacheable: true
|
|
3826
|
+
};
|
|
3827
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3828
|
+
},
|
|
2102
3829
|
/**
|
|
2103
3830
|
* Turns standard stop word dictionary entries on or off for a given language.
|
|
2104
3831
|
*
|
|
@@ -2126,6 +3853,36 @@ function createSearchClient({
|
|
|
2126
3853
|
};
|
|
2127
3854
|
return transporter.request(request, requestOptions);
|
|
2128
3855
|
},
|
|
3856
|
+
/**
|
|
3857
|
+
* Turns standard stop word dictionary entries on or off for a given language.
|
|
3858
|
+
*
|
|
3859
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3860
|
+
*
|
|
3861
|
+
* Required API Key ACLs:
|
|
3862
|
+
* - editSettings
|
|
3863
|
+
* @param dictionarySettingsParams - The dictionarySettingsParams object.
|
|
3864
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3865
|
+
* @see setDictionarySettings for the plain version.
|
|
3866
|
+
*/
|
|
3867
|
+
setDictionarySettingsWithHTTPInfo(dictionarySettingsParams, requestOptions) {
|
|
3868
|
+
(0, import_client_common.validateRequired)("dictionarySettingsParams", "setDictionarySettingsWithHTTPInfo", dictionarySettingsParams);
|
|
3869
|
+
(0, import_client_common.validateRequired)(
|
|
3870
|
+
"dictionarySettingsParams.disableStandardEntries",
|
|
3871
|
+
"setDictionarySettingsWithHTTPInfo",
|
|
3872
|
+
dictionarySettingsParams.disableStandardEntries
|
|
3873
|
+
);
|
|
3874
|
+
const requestPath = "/1/dictionaries/*/settings";
|
|
3875
|
+
const headers = {};
|
|
3876
|
+
const queryParameters = {};
|
|
3877
|
+
const request = {
|
|
3878
|
+
method: "PUT",
|
|
3879
|
+
path: requestPath,
|
|
3880
|
+
queryParameters,
|
|
3881
|
+
headers,
|
|
3882
|
+
data: dictionarySettingsParams
|
|
3883
|
+
};
|
|
3884
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3885
|
+
},
|
|
2129
3886
|
/**
|
|
2130
3887
|
* 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.
|
|
2131
3888
|
*
|
|
@@ -2155,6 +3912,38 @@ function createSearchClient({
|
|
|
2155
3912
|
};
|
|
2156
3913
|
return transporter.request(request, requestOptions);
|
|
2157
3914
|
},
|
|
3915
|
+
/**
|
|
3916
|
+
* 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.
|
|
3917
|
+
*
|
|
3918
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3919
|
+
*
|
|
3920
|
+
* Required API Key ACLs:
|
|
3921
|
+
* - editSettings
|
|
3922
|
+
* @param setSettings - The setSettings object.
|
|
3923
|
+
* @param setSettings.indexName - Name of the index on which to perform the operation.
|
|
3924
|
+
* @param setSettings.indexSettings - The indexSettings object.
|
|
3925
|
+
* @param setSettings.forwardToReplicas - Whether changes are applied to replica indices.
|
|
3926
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3927
|
+
* @see setSettings for the plain version.
|
|
3928
|
+
*/
|
|
3929
|
+
setSettingsWithHTTPInfo({ indexName, indexSettings, forwardToReplicas }, requestOptions) {
|
|
3930
|
+
(0, import_client_common.validateRequired)("indexName", "setSettingsWithHTTPInfo", indexName);
|
|
3931
|
+
(0, import_client_common.validateRequired)("indexSettings", "setSettingsWithHTTPInfo", indexSettings);
|
|
3932
|
+
const requestPath = "/1/indexes/{indexName}/settings".replace("{indexName}", encodeURIComponent(indexName));
|
|
3933
|
+
const headers = {};
|
|
3934
|
+
const queryParameters = {};
|
|
3935
|
+
if (forwardToReplicas !== void 0) {
|
|
3936
|
+
queryParameters["forwardToReplicas"] = forwardToReplicas.toString();
|
|
3937
|
+
}
|
|
3938
|
+
const request = {
|
|
3939
|
+
method: "PUT",
|
|
3940
|
+
path: requestPath,
|
|
3941
|
+
queryParameters,
|
|
3942
|
+
headers,
|
|
3943
|
+
data: indexSettings
|
|
3944
|
+
};
|
|
3945
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
3946
|
+
},
|
|
2158
3947
|
/**
|
|
2159
3948
|
* Replaces the permissions of an existing API key. Any unspecified attribute resets that attribute to its default value.
|
|
2160
3949
|
*
|
|
@@ -2180,6 +3969,35 @@ function createSearchClient({
|
|
|
2180
3969
|
data: apiKey
|
|
2181
3970
|
};
|
|
2182
3971
|
return transporter.request(request, requestOptions);
|
|
3972
|
+
},
|
|
3973
|
+
/**
|
|
3974
|
+
* Replaces the permissions of an existing API key. Any unspecified attribute resets that attribute to its default value.
|
|
3975
|
+
*
|
|
3976
|
+
* Resolves with the full HTTP response information: status code, headers (when the requester captures them), raw body and deserialized data. Bypasses the requests and responses caches: always performs the API call.
|
|
3977
|
+
*
|
|
3978
|
+
* Required API Key ACLs:
|
|
3979
|
+
* - admin
|
|
3980
|
+
* @param updateApiKey - The updateApiKey object.
|
|
3981
|
+
* @param updateApiKey.key - API key.
|
|
3982
|
+
* @param updateApiKey.apiKey - The apiKey object.
|
|
3983
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
3984
|
+
* @see updateApiKey for the plain version.
|
|
3985
|
+
*/
|
|
3986
|
+
updateApiKeyWithHTTPInfo({ key, apiKey }, requestOptions) {
|
|
3987
|
+
(0, import_client_common.validateRequired)("key", "updateApiKeyWithHTTPInfo", key);
|
|
3988
|
+
(0, import_client_common.validateRequired)("apiKey", "updateApiKeyWithHTTPInfo", apiKey);
|
|
3989
|
+
(0, import_client_common.validateRequired)("apiKey.acl", "updateApiKeyWithHTTPInfo", apiKey.acl);
|
|
3990
|
+
const requestPath = "/1/keys/{key}".replace("{key}", encodeURIComponent(key));
|
|
3991
|
+
const headers = {};
|
|
3992
|
+
const queryParameters = {};
|
|
3993
|
+
const request = {
|
|
3994
|
+
method: "PUT",
|
|
3995
|
+
path: requestPath,
|
|
3996
|
+
queryParameters,
|
|
3997
|
+
headers,
|
|
3998
|
+
data: apiKey
|
|
3999
|
+
};
|
|
4000
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
2183
4001
|
}
|
|
2184
4002
|
};
|
|
2185
4003
|
}
|