@algolia/client-search 5.3.0 → 5.3.1
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/dist/browser.d.ts +1 -1
- package/dist/builds/browser.js +6 -2
- package/dist/builds/browser.js.map +1 -1
- package/dist/builds/browser.min.js +1 -1
- package/dist/builds/browser.min.js.map +1 -1
- package/dist/builds/browser.umd.js +1 -1
- package/dist/builds/node.cjs +6 -2
- package/dist/builds/node.cjs.map +1 -1
- package/dist/builds/node.js +6 -2
- package/dist/builds/node.js.map +1 -1
- package/dist/node.d.cts +1 -1
- package/dist/node.d.ts +1 -1
- package/dist/src/searchClient.cjs +6 -2
- package/dist/src/searchClient.cjs.map +1 -1
- package/dist/src/searchClient.js +6 -2
- package/dist/src/searchClient.js.map +1 -1
- package/package.json +4 -4
package/dist/node.d.cts
CHANGED
|
@@ -2976,7 +2976,7 @@ type ReplaceAllObjectsOptions = {
|
|
|
2976
2976
|
batchSize?: number;
|
|
2977
2977
|
};
|
|
2978
2978
|
|
|
2979
|
-
declare const apiClientVersion = "5.3.
|
|
2979
|
+
declare const apiClientVersion = "5.3.1";
|
|
2980
2980
|
declare function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }: CreateClientOptions): {
|
|
2981
2981
|
transporter: _algolia_client_common.Transporter;
|
|
2982
2982
|
/**
|
package/dist/node.d.ts
CHANGED
|
@@ -2976,7 +2976,7 @@ type ReplaceAllObjectsOptions = {
|
|
|
2976
2976
|
batchSize?: number;
|
|
2977
2977
|
};
|
|
2978
2978
|
|
|
2979
|
-
declare const apiClientVersion = "5.3.
|
|
2979
|
+
declare const apiClientVersion = "5.3.1";
|
|
2980
2980
|
declare function createSearchClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, ...options }: CreateClientOptions): {
|
|
2981
2981
|
transporter: _algolia_client_common.Transporter;
|
|
2982
2982
|
/**
|
|
@@ -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.3.
|
|
28
|
+
var apiClientVersion = "5.3.1";
|
|
29
29
|
function getDefaultHosts(appId) {
|
|
30
30
|
return [
|
|
31
31
|
{
|
|
@@ -119,7 +119,11 @@ function createSearchClient({
|
|
|
119
119
|
* @param params.apiKey - The new API Key to use.
|
|
120
120
|
*/
|
|
121
121
|
setClientApiKey({ apiKey }) {
|
|
122
|
-
|
|
122
|
+
if (!authMode || authMode === "WithinHeaders") {
|
|
123
|
+
this.transporter.baseHeaders["x-algolia-api-key"] = apiKey;
|
|
124
|
+
} else {
|
|
125
|
+
this.transporter.baseQueryParameters["x-algolia-api-key"] = apiKey;
|
|
126
|
+
}
|
|
123
127
|
},
|
|
124
128
|
/**
|
|
125
129
|
* Helper: Wait for a task to be published (completed) for a given `indexName` and `taskID`.
|