@algolia/client-query-suggestions 5.7.0 → 5.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/node.d.ts CHANGED
@@ -12,10 +12,40 @@ type BaseResponse = {
12
12
  message?: string;
13
13
  };
14
14
 
15
+ type ConfigStatus = {
16
+ /**
17
+ * Name of the Query Suggestions index (case-sensitive).
18
+ */
19
+ indexName?: string;
20
+ /**
21
+ * Whether the creation or update of the Query Suggestions index is in progress.
22
+ */
23
+ isRunning?: boolean;
24
+ /**
25
+ * Date and time when the Query Suggestions index was last built, in RFC 3339 format.
26
+ */
27
+ lastBuiltAt?: string;
28
+ /**
29
+ * Date and time when the Query Suggestions index was last updated successfully.
30
+ */
31
+ lastSuccessfulBuiltAt?: string;
32
+ /**
33
+ * Duration of the last successful build in seconds.
34
+ */
35
+ lastSuccessfulBuildDuration?: string;
36
+ };
37
+
38
+ type AppID = {
39
+ /**
40
+ * Algolia application ID to which this Query Suggestions configuration belongs.
41
+ */
42
+ appID?: string;
43
+ };
44
+
15
45
  /**
16
46
  * Languages for deduplicating singular and plural suggestions. If specified, only the more popular form is included.
17
47
  */
18
- type Languages = string[] | boolean;
48
+ type Languages = Array<string> | boolean;
19
49
 
20
50
  /**
21
51
  * Facet to use as category.
@@ -43,8 +73,8 @@ type SourceIndex = {
43
73
  * If true, Query Suggestions uses all replica indices to find popular searches. If false, only the primary index is used.
44
74
  */
45
75
  replicas?: boolean;
46
- analyticsTags?: string[] | null;
47
- facets?: Facet[] | null;
76
+ analyticsTags?: Array<string> | null;
77
+ facets?: Array<Facet> | null;
48
78
  /**
49
79
  * Minimum number of hits required to be included as a suggestion. A search query must at least generate `minHits` search results to be included in the Query Suggestions index.
50
80
  */
@@ -53,8 +83,8 @@ type SourceIndex = {
53
83
  * Minimum letters required to be included as a suggestion. A search query must be at least `minLetters` long to be included in the Query Suggestions index.
54
84
  */
55
85
  minLetters?: number;
56
- generate?: string[][] | null;
57
- external?: string[] | null;
86
+ generate?: Array<Array<string>> | null;
87
+ external?: Array<string> | null;
58
88
  };
59
89
 
60
90
  /**
@@ -64,9 +94,9 @@ type Configuration = {
64
94
  /**
65
95
  * Algolia indices from which to get the popular searches for query suggestions.
66
96
  */
67
- sourceIndices: SourceIndex[];
97
+ sourceIndices: Array<SourceIndex>;
68
98
  languages?: Languages;
69
- exclude?: string[] | null;
99
+ exclude?: Array<string> | null;
70
100
  /**
71
101
  * Whether to turn on personalized query suggestions.
72
102
  */
@@ -77,6 +107,37 @@ type Configuration = {
77
107
  allowSpecialCharacters?: boolean;
78
108
  };
79
109
 
110
+ /**
111
+ * Query Suggestions configuration.
112
+ */
113
+ type ConfigurationWithIndex = Record<string, unknown> & Configuration;
114
+
115
+ /**
116
+ * API response for retrieving Query Suggestions configurations.
117
+ */
118
+ type ConfigurationResponse = AppID & ConfigurationWithIndex;
119
+
120
+ /**
121
+ * Type of log entry. - `SKIP`. A query is skipped because it doesn\'t match the conditions for successful inclusion. For example, when a query doesn\'t generate enough search results. - `INFO`. An informative log entry. - `ERROR`. The Query Suggestions process encountered an error.
122
+ */
123
+ type LogLevel = 'SKIP' | 'INFO' | 'ERROR';
124
+
125
+ type LogFile = {
126
+ /**
127
+ * Date and time of the log entry, in RFC 3339 format.
128
+ */
129
+ timestamp?: string;
130
+ level?: LogLevel;
131
+ /**
132
+ * Details about this log entry.
133
+ */
134
+ message?: string;
135
+ /**
136
+ * Level indicating the position of a suggestion in a hierarchy of records. For example, a `contextLevel` of 1 indicates that this suggestion belongs to a previous suggestion with `contextLevel` 0.
137
+ */
138
+ contextLevel?: number;
139
+ };
140
+
80
141
  /**
81
142
  * Properties for the `customDelete` method.
82
143
  */
@@ -88,7 +149,9 @@ type CustomDeleteProps = {
88
149
  /**
89
150
  * Query parameters to apply to the current query.
90
151
  */
91
- parameters?: Record<string, any>;
152
+ parameters?: {
153
+ [key: string]: any;
154
+ };
92
155
  };
93
156
  /**
94
157
  * Properties for the `customGet` method.
@@ -101,7 +164,9 @@ type CustomGetProps = {
101
164
  /**
102
165
  * Query parameters to apply to the current query.
103
166
  */
104
- parameters?: Record<string, any>;
167
+ parameters?: {
168
+ [key: string]: any;
169
+ };
105
170
  };
106
171
  /**
107
172
  * Properties for the `customPost` method.
@@ -114,7 +179,9 @@ type CustomPostProps = {
114
179
  /**
115
180
  * Query parameters to apply to the current query.
116
181
  */
117
- parameters?: Record<string, any>;
182
+ parameters?: {
183
+ [key: string]: any;
184
+ };
118
185
  /**
119
186
  * Parameters to send with the custom request.
120
187
  */
@@ -131,7 +198,9 @@ type CustomPutProps = {
131
198
  /**
132
199
  * Query parameters to apply to the current query.
133
200
  */
134
- parameters?: Record<string, any>;
201
+ parameters?: {
202
+ [key: string]: any;
203
+ };
135
204
  /**
136
205
  * Parameters to send with the custom request.
137
206
  */
@@ -184,68 +253,7 @@ type UpdateConfigProps = {
184
253
  configuration: Configuration;
185
254
  };
186
255
 
187
- type ConfigStatus = {
188
- /**
189
- * Name of the Query Suggestions index (case-sensitive).
190
- */
191
- indexName?: string;
192
- /**
193
- * Whether the creation or update of the Query Suggestions index is in progress.
194
- */
195
- isRunning?: boolean;
196
- /**
197
- * Date and time when the Query Suggestions index was last built, in RFC 3339 format.
198
- */
199
- lastBuiltAt?: string;
200
- /**
201
- * Date and time when the Query Suggestions index was last updated successfully.
202
- */
203
- lastSuccessfulBuiltAt?: string;
204
- /**
205
- * Duration of the last successful build in seconds.
206
- */
207
- lastSuccessfulBuildDuration?: string;
208
- };
209
-
210
- type AppID = {
211
- /**
212
- * Algolia application ID to which this Query Suggestions configuration belongs.
213
- */
214
- appID?: string;
215
- };
216
-
217
- /**
218
- * Query Suggestions configuration.
219
- */
220
- type ConfigurationWithIndex = Configuration & Record<string, unknown>;
221
-
222
- /**
223
- * API response for retrieving Query Suggestions configurations.
224
- */
225
- type ConfigurationResponse = AppID & ConfigurationWithIndex;
226
-
227
- /**
228
- * Type of log entry. - `SKIP`. A query is skipped because it doesn\'t match the conditions for successful inclusion. For example, when a query doesn\'t generate enough search results. - `INFO`. An informative log entry. - `ERROR`. The Query Suggestions process encountered an error.
229
- */
230
- type LogLevel = 'ERROR' | 'INFO' | 'SKIP';
231
-
232
- type LogFile = {
233
- /**
234
- * Date and time of the log entry, in RFC 3339 format.
235
- */
236
- timestamp?: string;
237
- level?: LogLevel;
238
- /**
239
- * Details about this log entry.
240
- */
241
- message?: string;
242
- /**
243
- * Level indicating the position of a suggestion in a hierarchy of records. For example, a `contextLevel` of 1 indicates that this suggestion belongs to a previous suggestion with `contextLevel` 0.
244
- */
245
- contextLevel?: number;
246
- };
247
-
248
- declare const apiClientVersion = "5.7.0";
256
+ declare const apiClientVersion = "5.8.0";
249
257
  declare const REGIONS: readonly ["eu", "us"];
250
258
  type Region = (typeof REGIONS)[number];
251
259
  declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }: CreateClientOptions & {
@@ -284,15 +292,13 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
284
292
  * Creates a new Query Suggestions configuration. You can have up to 100 configurations per Algolia application.
285
293
  *
286
294
  * Required API Key ACLs:
287
- * - editSettings.
288
- *
295
+ * - editSettings
289
296
  * @param configurationWithIndex - The configurationWithIndex object.
290
297
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
291
298
  */
292
299
  createConfig(configurationWithIndex: ConfigurationWithIndex, requestOptions?: RequestOptions): Promise<BaseResponse>;
293
300
  /**
294
301
  * This method allow you to send requests to the Algolia REST API.
295
- *
296
302
  * @param customDelete - The customDelete object.
297
303
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
298
304
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -301,7 +307,6 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
301
307
  customDelete({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
302
308
  /**
303
309
  * This method allow you to send requests to the Algolia REST API.
304
- *
305
310
  * @param customGet - The customGet object.
306
311
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
307
312
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -310,7 +315,6 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
310
315
  customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
311
316
  /**
312
317
  * This method allow you to send requests to the Algolia REST API.
313
- *
314
318
  * @param customPost - The customPost object.
315
319
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
316
320
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -320,7 +324,6 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
320
324
  customPost({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
321
325
  /**
322
326
  * This method allow you to send requests to the Algolia REST API.
323
- *
324
327
  * @param customPut - The customPut object.
325
328
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
326
329
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -332,8 +335,7 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
332
335
  * Deletes a Query Suggestions configuration. Deleting only removes the configuration and stops updates to the Query Suggestions index. To delete the Query Suggestions index itself, use the Search API and the `Delete an index` operation.
333
336
  *
334
337
  * Required API Key ACLs:
335
- * - editSettings.
336
- *
338
+ * - editSettings
337
339
  * @param deleteConfig - The deleteConfig object.
338
340
  * @param deleteConfig.indexName - Query Suggestions index name.
339
341
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -343,17 +345,15 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
343
345
  * Retrieves all Query Suggestions configurations of your Algolia application.
344
346
  *
345
347
  * Required API Key ACLs:
346
- * - settings.
347
- *
348
+ * - settings
348
349
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
349
350
  */
350
- getAllConfigs(requestOptions?: RequestOptions): Promise<ConfigurationResponse[]>;
351
+ getAllConfigs(requestOptions?: RequestOptions): Promise<Array<ConfigurationResponse>>;
351
352
  /**
352
353
  * Retrieves a single Query Suggestions configuration by its index name.
353
354
  *
354
355
  * Required API Key ACLs:
355
- * - settings.
356
- *
356
+ * - settings
357
357
  * @param getConfig - The getConfig object.
358
358
  * @param getConfig.indexName - Query Suggestions index name.
359
359
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -363,8 +363,7 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
363
363
  * Reports the status of a Query Suggestions index.
364
364
  *
365
365
  * Required API Key ACLs:
366
- * - settings.
367
- *
366
+ * - settings
368
367
  * @param getConfigStatus - The getConfigStatus object.
369
368
  * @param getConfigStatus.indexName - Query Suggestions index name.
370
369
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -374,8 +373,7 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
374
373
  * Retrieves the logs for a single Query Suggestions index.
375
374
  *
376
375
  * Required API Key ACLs:
377
- * - settings.
378
- *
376
+ * - settings
379
377
  * @param getLogFile - The getLogFile object.
380
378
  * @param getLogFile.indexName - Query Suggestions index name.
381
379
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -385,8 +383,7 @@ declare function createQuerySuggestionsClient({ appId: appIdOption, apiKey: apiK
385
383
  * Updates a QuerySuggestions configuration.
386
384
  *
387
385
  * Required API Key ACLs:
388
- * - editSettings.
389
- *
386
+ * - editSettings
390
387
  * @param updateConfig - The updateConfig object.
391
388
  * @param updateConfig.indexName - Query Suggestions index name.
392
389
  * @param updateConfig.configuration - The configuration object.
@@ -26,7 +26,7 @@ __export(querySuggestionsClient_exports, {
26
26
  });
27
27
  module.exports = __toCommonJS(querySuggestionsClient_exports);
28
28
  var import_client_common = require("@algolia/client-common");
29
- var apiClientVersion = "5.7.0";
29
+ var apiClientVersion = "5.8.0";
30
30
  var REGIONS = ["eu", "us"];
31
31
  function getDefaultHosts(region) {
32
32
  const url = "query-suggestions.{region}.algolia.com".replace("{region}", region);
@@ -103,8 +103,7 @@ function createQuerySuggestionsClient({
103
103
  * Creates a new Query Suggestions configuration. You can have up to 100 configurations per Algolia application.
104
104
  *
105
105
  * Required API Key ACLs:
106
- * - editSettings.
107
- *
106
+ * - editSettings
108
107
  * @param configurationWithIndex - The configurationWithIndex object.
109
108
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
110
109
  */
@@ -126,7 +125,6 @@ function createQuerySuggestionsClient({
126
125
  },
127
126
  /**
128
127
  * This method allow you to send requests to the Algolia REST API.
129
- *
130
128
  * @param customDelete - The customDelete object.
131
129
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
132
130
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -149,7 +147,6 @@ function createQuerySuggestionsClient({
149
147
  },
150
148
  /**
151
149
  * This method allow you to send requests to the Algolia REST API.
152
- *
153
150
  * @param customGet - The customGet object.
154
151
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
155
152
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -172,7 +169,6 @@ function createQuerySuggestionsClient({
172
169
  },
173
170
  /**
174
171
  * This method allow you to send requests to the Algolia REST API.
175
- *
176
172
  * @param customPost - The customPost object.
177
173
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
178
174
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -197,7 +193,6 @@ function createQuerySuggestionsClient({
197
193
  },
198
194
  /**
199
195
  * This method allow you to send requests to the Algolia REST API.
200
- *
201
196
  * @param customPut - The customPut object.
202
197
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
203
198
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -224,8 +219,7 @@ function createQuerySuggestionsClient({
224
219
  * Deletes a Query Suggestions configuration. Deleting only removes the configuration and stops updates to the Query Suggestions index. To delete the Query Suggestions index itself, use the Search API and the `Delete an index` operation.
225
220
  *
226
221
  * Required API Key ACLs:
227
- * - editSettings.
228
- *
222
+ * - editSettings
229
223
  * @param deleteConfig - The deleteConfig object.
230
224
  * @param deleteConfig.indexName - Query Suggestions index name.
231
225
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -249,8 +243,7 @@ function createQuerySuggestionsClient({
249
243
  * Retrieves all Query Suggestions configurations of your Algolia application.
250
244
  *
251
245
  * Required API Key ACLs:
252
- * - settings.
253
- *
246
+ * - settings
254
247
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
255
248
  */
256
249
  getAllConfigs(requestOptions) {
@@ -269,8 +262,7 @@ function createQuerySuggestionsClient({
269
262
  * Retrieves a single Query Suggestions configuration by its index name.
270
263
  *
271
264
  * Required API Key ACLs:
272
- * - settings.
273
- *
265
+ * - settings
274
266
  * @param getConfig - The getConfig object.
275
267
  * @param getConfig.indexName - Query Suggestions index name.
276
268
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -294,8 +286,7 @@ function createQuerySuggestionsClient({
294
286
  * Reports the status of a Query Suggestions index.
295
287
  *
296
288
  * Required API Key ACLs:
297
- * - settings.
298
- *
289
+ * - settings
299
290
  * @param getConfigStatus - The getConfigStatus object.
300
291
  * @param getConfigStatus.indexName - Query Suggestions index name.
301
292
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -319,8 +310,7 @@ function createQuerySuggestionsClient({
319
310
  * Retrieves the logs for a single Query Suggestions index.
320
311
  *
321
312
  * Required API Key ACLs:
322
- * - settings.
323
- *
313
+ * - settings
324
314
  * @param getLogFile - The getLogFile object.
325
315
  * @param getLogFile.indexName - Query Suggestions index name.
326
316
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -344,8 +334,7 @@ function createQuerySuggestionsClient({
344
334
  * Updates a QuerySuggestions configuration.
345
335
  *
346
336
  * Required API Key ACLs:
347
- * - editSettings.
348
- *
337
+ * - editSettings
349
338
  * @param updateConfig - The updateConfig object.
350
339
  * @param updateConfig.indexName - Query Suggestions index name.
351
340
  * @param updateConfig.configuration - The configuration object.
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/querySuggestionsClient.ts"],"sourcesContent":["// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.\n\nimport { createAuth, createTransporter, getAlgoliaAgent } from '@algolia/client-common';\nimport type {\n CreateClientOptions,\n Headers,\n Host,\n QueryParameters,\n Request,\n RequestOptions,\n} from '@algolia/client-common';\n\nimport type { BaseResponse } from '../model/baseResponse';\nimport type {\n CustomDeleteProps,\n CustomGetProps,\n CustomPostProps,\n CustomPutProps,\n DeleteConfigProps,\n GetConfigProps,\n GetConfigStatusProps,\n GetLogFileProps,\n UpdateConfigProps,\n} from '../model/clientMethodProps';\nimport type { ConfigStatus } from '../model/configStatus';\nimport type { ConfigurationResponse } from '../model/configurationResponse';\nimport type { ConfigurationWithIndex } from '../model/configurationWithIndex';\nimport type { LogFile } from '../model/logFile';\n\nexport const apiClientVersion = '5.7.0';\n\nexport const REGIONS = ['eu', 'us'] as const;\nexport type Region = (typeof REGIONS)[number];\n\nfunction getDefaultHosts(region: Region): Host[] {\n const url = 'query-suggestions.{region}.algolia.com'.replace('{region}', region);\n\n return [{ url, accept: 'readWrite', protocol: 'https' }];\n}\n\n// eslint-disable-next-line @typescript-eslint/explicit-function-return-type\nexport function createQuerySuggestionsClient({\n appId: appIdOption,\n apiKey: apiKeyOption,\n authMode,\n algoliaAgents,\n region: regionOption,\n ...options\n}: CreateClientOptions & { region: Region }) {\n const auth = createAuth(appIdOption, apiKeyOption, authMode);\n const transporter = createTransporter({\n hosts: getDefaultHosts(regionOption),\n ...options,\n algoliaAgent: getAlgoliaAgent({\n algoliaAgents,\n client: 'QuerySuggestions',\n version: apiClientVersion,\n }),\n baseHeaders: {\n 'content-type': 'text/plain',\n ...auth.headers(),\n ...options.baseHeaders,\n },\n baseQueryParameters: {\n ...auth.queryParameters(),\n ...options.baseQueryParameters,\n },\n });\n\n return {\n transporter,\n\n /**\n * The `appId` currently in use.\n */\n appId: appIdOption,\n\n /**\n * Clears the cache of the transporter for the `requestsCache` and `responsesCache` properties.\n */\n clearCache(): Promise<void> {\n return Promise.all([transporter.requestsCache.clear(), transporter.responsesCache.clear()]).then(() => undefined);\n },\n\n /**\n * Get the value of the `algoliaAgent`, used by our libraries internally and telemetry system.\n */\n get _ua(): string {\n return transporter.algoliaAgent.value;\n },\n\n /**\n * Adds a `segment` to the `x-algolia-agent` sent with every requests.\n *\n * @param segment - The algolia agent (user-agent) segment to add.\n * @param version - The version of the agent.\n */\n addAlgoliaAgent(segment: string, version?: string): void {\n transporter.algoliaAgent.add({ segment, version });\n },\n\n /**\n * Helper method to switch the API key used to authenticate the requests.\n *\n * @param params - Method params.\n * @param params.apiKey - The new API Key to use.\n */\n setClientApiKey({ apiKey }: { apiKey: string }): void {\n if (!authMode || authMode === 'WithinHeaders') {\n transporter.baseHeaders['x-algolia-api-key'] = apiKey;\n } else {\n transporter.baseQueryParameters['x-algolia-api-key'] = apiKey;\n }\n },\n\n /**\n * Creates a new Query Suggestions configuration. You can have up to 100 configurations per Algolia application.\n *\n * Required API Key ACLs:\n * - editSettings.\n *\n * @param configurationWithIndex - The configurationWithIndex object.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n createConfig(\n configurationWithIndex: ConfigurationWithIndex,\n requestOptions?: RequestOptions,\n ): Promise<BaseResponse> {\n if (!configurationWithIndex) {\n throw new Error('Parameter `configurationWithIndex` is required when calling `createConfig`.');\n }\n\n const requestPath = '/1/configs';\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'POST',\n path: requestPath,\n queryParameters,\n headers,\n data: configurationWithIndex,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n *\n * @param customDelete - The customDelete object.\n * @param customDelete.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customDelete.parameters - Query parameters to apply to the current query.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customDelete(\n { path, parameters }: CustomDeleteProps,\n requestOptions?: RequestOptions,\n ): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customDelete`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'DELETE',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n *\n * @param customGet - The customGet object.\n * @param customGet.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customGet.parameters - Query parameters to apply to the current query.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customGet`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n *\n * @param customPost - The customPost object.\n * @param customPost.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customPost.parameters - Query parameters to apply to the current query.\n * @param customPost.body - Parameters to send with the custom request.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customPost(\n { path, parameters, body }: CustomPostProps,\n requestOptions?: RequestOptions,\n ): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customPost`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'POST',\n path: requestPath,\n queryParameters,\n headers,\n data: body ? body : {},\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n *\n * @param customPut - The customPut object.\n * @param customPut.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customPut.parameters - Query parameters to apply to the current query.\n * @param customPut.body - Parameters to send with the custom request.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customPut(\n { path, parameters, body }: CustomPutProps,\n requestOptions?: RequestOptions,\n ): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customPut`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'PUT',\n path: requestPath,\n queryParameters,\n headers,\n data: body ? body : {},\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Deletes a Query Suggestions configuration. Deleting only removes the configuration and stops updates to the Query Suggestions index. To delete the Query Suggestions index itself, use the Search API and the `Delete an index` operation.\n *\n * Required API Key ACLs:\n * - editSettings.\n *\n * @param deleteConfig - The deleteConfig object.\n * @param deleteConfig.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n deleteConfig({ indexName }: DeleteConfigProps, requestOptions?: RequestOptions): Promise<BaseResponse> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `deleteConfig`.');\n }\n\n const requestPath = '/1/configs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'DELETE',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Retrieves all Query Suggestions configurations of your Algolia application.\n *\n * Required API Key ACLs:\n * - settings.\n *\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getAllConfigs(requestOptions?: RequestOptions): Promise<ConfigurationResponse[]> {\n const requestPath = '/1/configs';\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Retrieves a single Query Suggestions configuration by its index name.\n *\n * Required API Key ACLs:\n * - settings.\n *\n * @param getConfig - The getConfig object.\n * @param getConfig.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getConfig({ indexName }: GetConfigProps, requestOptions?: RequestOptions): Promise<ConfigurationResponse> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `getConfig`.');\n }\n\n const requestPath = '/1/configs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Reports the status of a Query Suggestions index.\n *\n * Required API Key ACLs:\n * - settings.\n *\n * @param getConfigStatus - The getConfigStatus object.\n * @param getConfigStatus.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getConfigStatus({ indexName }: GetConfigStatusProps, requestOptions?: RequestOptions): Promise<ConfigStatus> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `getConfigStatus`.');\n }\n\n const requestPath = '/1/configs/{indexName}/status'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Retrieves the logs for a single Query Suggestions index.\n *\n * Required API Key ACLs:\n * - settings.\n *\n * @param getLogFile - The getLogFile object.\n * @param getLogFile.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getLogFile({ indexName }: GetLogFileProps, requestOptions?: RequestOptions): Promise<LogFile> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `getLogFile`.');\n }\n\n const requestPath = '/1/logs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Updates a QuerySuggestions configuration.\n *\n * Required API Key ACLs:\n * - editSettings.\n *\n * @param updateConfig - The updateConfig object.\n * @param updateConfig.indexName - Query Suggestions index name.\n * @param updateConfig.configuration - The configuration object.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n updateConfig(\n { indexName, configuration }: UpdateConfigProps,\n requestOptions?: RequestOptions,\n ): Promise<BaseResponse> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `updateConfig`.');\n }\n\n if (!configuration) {\n throw new Error('Parameter `configuration` is required when calling `updateConfig`.');\n }\n\n if (!configuration.sourceIndices) {\n throw new Error('Parameter `configuration.sourceIndices` is required when calling `updateConfig`.');\n }\n\n const requestPath = '/1/configs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'PUT',\n path: requestPath,\n queryParameters,\n headers,\n data: configuration,\n };\n\n return transporter.request(request, requestOptions);\n },\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,2BA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{"version":3,"sources":["../../src/querySuggestionsClient.ts"],"sourcesContent":["// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.\n\nimport type {\n CreateClientOptions,\n Headers,\n Host,\n QueryParameters,\n Request,\n RequestOptions,\n} from '@algolia/client-common';\nimport { createAuth, createTransporter, getAlgoliaAgent } from '@algolia/client-common';\n\nimport type { BaseResponse } from '../model/baseResponse';\nimport type { ConfigStatus } from '../model/configStatus';\n\nimport type { ConfigurationResponse } from '../model/configurationResponse';\nimport type { ConfigurationWithIndex } from '../model/configurationWithIndex';\n\nimport type { LogFile } from '../model/logFile';\n\nimport type {\n CustomDeleteProps,\n CustomGetProps,\n CustomPostProps,\n CustomPutProps,\n DeleteConfigProps,\n GetConfigProps,\n GetConfigStatusProps,\n GetLogFileProps,\n UpdateConfigProps,\n} from '../model/clientMethodProps';\n\nexport const apiClientVersion = '5.8.0';\n\nexport const REGIONS = ['eu', 'us'] as const;\nexport type Region = (typeof REGIONS)[number];\n\nfunction getDefaultHosts(region: Region): Host[] {\n const url = 'query-suggestions.{region}.algolia.com'.replace('{region}', region);\n\n return [{ url, accept: 'readWrite', protocol: 'https' }];\n}\n\n// eslint-disable-next-line @typescript-eslint/explicit-function-return-type\nexport function createQuerySuggestionsClient({\n appId: appIdOption,\n apiKey: apiKeyOption,\n authMode,\n algoliaAgents,\n region: regionOption,\n ...options\n}: CreateClientOptions & { region: Region }) {\n const auth = createAuth(appIdOption, apiKeyOption, authMode);\n const transporter = createTransporter({\n hosts: getDefaultHosts(regionOption),\n ...options,\n algoliaAgent: getAlgoliaAgent({\n algoliaAgents,\n client: 'QuerySuggestions',\n version: apiClientVersion,\n }),\n baseHeaders: {\n 'content-type': 'text/plain',\n ...auth.headers(),\n ...options.baseHeaders,\n },\n baseQueryParameters: {\n ...auth.queryParameters(),\n ...options.baseQueryParameters,\n },\n });\n\n return {\n transporter,\n\n /**\n * The `appId` currently in use.\n */\n appId: appIdOption,\n\n /**\n * Clears the cache of the transporter for the `requestsCache` and `responsesCache` properties.\n */\n clearCache(): Promise<void> {\n return Promise.all([transporter.requestsCache.clear(), transporter.responsesCache.clear()]).then(() => undefined);\n },\n\n /**\n * Get the value of the `algoliaAgent`, used by our libraries internally and telemetry system.\n */\n get _ua(): string {\n return transporter.algoliaAgent.value;\n },\n\n /**\n * Adds a `segment` to the `x-algolia-agent` sent with every requests.\n *\n * @param segment - The algolia agent (user-agent) segment to add.\n * @param version - The version of the agent.\n */\n addAlgoliaAgent(segment: string, version?: string): void {\n transporter.algoliaAgent.add({ segment, version });\n },\n\n /**\n * Helper method to switch the API key used to authenticate the requests.\n *\n * @param params - Method params.\n * @param params.apiKey - The new API Key to use.\n */\n setClientApiKey({ apiKey }: { apiKey: string }): void {\n if (!authMode || authMode === 'WithinHeaders') {\n transporter.baseHeaders['x-algolia-api-key'] = apiKey;\n } else {\n transporter.baseQueryParameters['x-algolia-api-key'] = apiKey;\n }\n },\n\n /**\n * Creates a new Query Suggestions configuration. You can have up to 100 configurations per Algolia application.\n *\n * Required API Key ACLs:\n * - editSettings\n * @param configurationWithIndex - The configurationWithIndex object.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n createConfig(\n configurationWithIndex: ConfigurationWithIndex,\n requestOptions?: RequestOptions,\n ): Promise<BaseResponse> {\n if (!configurationWithIndex) {\n throw new Error('Parameter `configurationWithIndex` is required when calling `createConfig`.');\n }\n\n const requestPath = '/1/configs';\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'POST',\n path: requestPath,\n queryParameters,\n headers,\n data: configurationWithIndex,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n * @param customDelete - The customDelete object.\n * @param customDelete.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customDelete.parameters - Query parameters to apply to the current query.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customDelete(\n { path, parameters }: CustomDeleteProps,\n requestOptions?: RequestOptions,\n ): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customDelete`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'DELETE',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n * @param customGet - The customGet object.\n * @param customGet.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customGet.parameters - Query parameters to apply to the current query.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customGet`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n * @param customPost - The customPost object.\n * @param customPost.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customPost.parameters - Query parameters to apply to the current query.\n * @param customPost.body - Parameters to send with the custom request.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customPost(\n { path, parameters, body }: CustomPostProps,\n requestOptions?: RequestOptions,\n ): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customPost`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'POST',\n path: requestPath,\n queryParameters,\n headers,\n data: body ? body : {},\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * This method allow you to send requests to the Algolia REST API.\n * @param customPut - The customPut object.\n * @param customPut.path - Path of the endpoint, anything after \\\"/1\\\" must be specified.\n * @param customPut.parameters - Query parameters to apply to the current query.\n * @param customPut.body - Parameters to send with the custom request.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n customPut(\n { path, parameters, body }: CustomPutProps,\n requestOptions?: RequestOptions,\n ): Promise<Record<string, unknown>> {\n if (!path) {\n throw new Error('Parameter `path` is required when calling `customPut`.');\n }\n\n const requestPath = '/{path}'.replace('{path}', path);\n const headers: Headers = {};\n const queryParameters: QueryParameters = parameters ? parameters : {};\n\n const request: Request = {\n method: 'PUT',\n path: requestPath,\n queryParameters,\n headers,\n data: body ? body : {},\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Deletes a Query Suggestions configuration. Deleting only removes the configuration and stops updates to the Query Suggestions index. To delete the Query Suggestions index itself, use the Search API and the `Delete an index` operation.\n *\n * Required API Key ACLs:\n * - editSettings\n * @param deleteConfig - The deleteConfig object.\n * @param deleteConfig.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n deleteConfig({ indexName }: DeleteConfigProps, requestOptions?: RequestOptions): Promise<BaseResponse> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `deleteConfig`.');\n }\n\n const requestPath = '/1/configs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'DELETE',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Retrieves all Query Suggestions configurations of your Algolia application.\n *\n * Required API Key ACLs:\n * - settings\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getAllConfigs(requestOptions?: RequestOptions): Promise<Array<ConfigurationResponse>> {\n const requestPath = '/1/configs';\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Retrieves a single Query Suggestions configuration by its index name.\n *\n * Required API Key ACLs:\n * - settings\n * @param getConfig - The getConfig object.\n * @param getConfig.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getConfig({ indexName }: GetConfigProps, requestOptions?: RequestOptions): Promise<ConfigurationResponse> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `getConfig`.');\n }\n\n const requestPath = '/1/configs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Reports the status of a Query Suggestions index.\n *\n * Required API Key ACLs:\n * - settings\n * @param getConfigStatus - The getConfigStatus object.\n * @param getConfigStatus.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getConfigStatus({ indexName }: GetConfigStatusProps, requestOptions?: RequestOptions): Promise<ConfigStatus> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `getConfigStatus`.');\n }\n\n const requestPath = '/1/configs/{indexName}/status'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Retrieves the logs for a single Query Suggestions index.\n *\n * Required API Key ACLs:\n * - settings\n * @param getLogFile - The getLogFile object.\n * @param getLogFile.indexName - Query Suggestions index name.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n getLogFile({ indexName }: GetLogFileProps, requestOptions?: RequestOptions): Promise<LogFile> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `getLogFile`.');\n }\n\n const requestPath = '/1/logs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'GET',\n path: requestPath,\n queryParameters,\n headers,\n };\n\n return transporter.request(request, requestOptions);\n },\n\n /**\n * Updates a QuerySuggestions configuration.\n *\n * Required API Key ACLs:\n * - editSettings\n * @param updateConfig - The updateConfig object.\n * @param updateConfig.indexName - Query Suggestions index name.\n * @param updateConfig.configuration - The configuration object.\n * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.\n */\n updateConfig(\n { indexName, configuration }: UpdateConfigProps,\n requestOptions?: RequestOptions,\n ): Promise<BaseResponse> {\n if (!indexName) {\n throw new Error('Parameter `indexName` is required when calling `updateConfig`.');\n }\n\n if (!configuration) {\n throw new Error('Parameter `configuration` is required when calling `updateConfig`.');\n }\n\n if (!configuration.sourceIndices) {\n throw new Error('Parameter `configuration.sourceIndices` is required when calling `updateConfig`.');\n }\n\n const requestPath = '/1/configs/{indexName}'.replace('{indexName}', encodeURIComponent(indexName));\n const headers: Headers = {};\n const queryParameters: QueryParameters = {};\n\n const request: Request = {\n method: 'PUT',\n path: requestPath,\n queryParameters,\n headers,\n data: configuration,\n };\n\n return transporter.request(request, requestOptions);\n },\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUA,2BAA+D;AAsBxD,IAAM,mBAAmB;AAEzB,IAAM,UAAU,CAAC,MAAM,IAAI;AAGlC,SAAS,gBAAgB,QAAwB;AAC/C,QAAM,MAAM,yCAAyC,QAAQ,YAAY,MAAM;AAE/E,SAAO,CAAC,EAAE,KAAK,QAAQ,aAAa,UAAU,QAAQ,CAAC;AACzD;AAGO,SAAS,6BAA6B;AAAA,EAC3C,OAAO;AAAA,EACP,QAA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MAAM,8DAA8D;AAAA,MAChF;AAEA,YAAM,cAAc,sBAAsB,QAAQ,eAAe,mBAAmB,SAAS,CAAC;AAC9F,YAAM,UAAmB,CAAC;AAC1B,YAAM,kBAAmC,CAAC;AAE1C,YAAM,UAAmB;AAAA,QACvB,QAAQ;AAAA,QACR,MAAM;AAAA,QACN;AAAA,QACA;AAAA,MACF;AAEA,aAAO,YAAY,QAAQ,SAAS,cAAc;AAAA,IACpD;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAYA,aACE,EAAE,WAAW,cAAc,GAC3B,gBACuB;AACvB,UAAI,CAAC,WAAW;AACd,cAAM,IAAI,MAAM,gEAAgE;AAAA,MAClF;AAEA,UAAI,CAAC,eAAe;AAClB,cAAM,IAAI,MAAM,oEAAoE;AAAA,MACtF;AAEA,UAAI,CAAC,cAAc,eAAe;AAChC,cAAM,IAAI,MAAM,kFAAkF;AAAA,MACpG;AAEA,YAAM,cAAc,yBAAyB,QAAQ,eAAe,mBAAmB,SAAS,CAAC;AACjG,YAAM,UAAmB,CAAC;AAC1B,YAAM,kBAAmC,CAAC;AAE1C,YAAM,UAAmB;AAAA,QACvB,QAAQ;AAAA,QACR,MAAM;AAAA,QACN;AAAA,QACA;AAAA,QACA,MAAM;AAAA,MACR;AAEA,aAAO,YAAY,QAAQ,SAAS,cAAc;AAAA,IACpD;AAAA,EACF;AACF;","names":[]}
@@ -1,6 +1,6 @@
1
1
  // src/querySuggestionsClient.ts
2
2
  import { createAuth, createTransporter, getAlgoliaAgent } from "@algolia/client-common";
3
- var apiClientVersion = "5.7.0";
3
+ var apiClientVersion = "5.8.0";
4
4
  var REGIONS = ["eu", "us"];
5
5
  function getDefaultHosts(region) {
6
6
  const url = "query-suggestions.{region}.algolia.com".replace("{region}", region);
@@ -77,8 +77,7 @@ function createQuerySuggestionsClient({
77
77
  * Creates a new Query Suggestions configuration. You can have up to 100 configurations per Algolia application.
78
78
  *
79
79
  * Required API Key ACLs:
80
- * - editSettings.
81
- *
80
+ * - editSettings
82
81
  * @param configurationWithIndex - The configurationWithIndex object.
83
82
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
84
83
  */
@@ -100,7 +99,6 @@ function createQuerySuggestionsClient({
100
99
  },
101
100
  /**
102
101
  * This method allow you to send requests to the Algolia REST API.
103
- *
104
102
  * @param customDelete - The customDelete object.
105
103
  * @param customDelete.path - Path of the endpoint, anything after \"/1\" must be specified.
106
104
  * @param customDelete.parameters - Query parameters to apply to the current query.
@@ -123,7 +121,6 @@ function createQuerySuggestionsClient({
123
121
  },
124
122
  /**
125
123
  * This method allow you to send requests to the Algolia REST API.
126
- *
127
124
  * @param customGet - The customGet object.
128
125
  * @param customGet.path - Path of the endpoint, anything after \"/1\" must be specified.
129
126
  * @param customGet.parameters - Query parameters to apply to the current query.
@@ -146,7 +143,6 @@ function createQuerySuggestionsClient({
146
143
  },
147
144
  /**
148
145
  * This method allow you to send requests to the Algolia REST API.
149
- *
150
146
  * @param customPost - The customPost object.
151
147
  * @param customPost.path - Path of the endpoint, anything after \"/1\" must be specified.
152
148
  * @param customPost.parameters - Query parameters to apply to the current query.
@@ -171,7 +167,6 @@ function createQuerySuggestionsClient({
171
167
  },
172
168
  /**
173
169
  * This method allow you to send requests to the Algolia REST API.
174
- *
175
170
  * @param customPut - The customPut object.
176
171
  * @param customPut.path - Path of the endpoint, anything after \"/1\" must be specified.
177
172
  * @param customPut.parameters - Query parameters to apply to the current query.
@@ -198,8 +193,7 @@ function createQuerySuggestionsClient({
198
193
  * Deletes a Query Suggestions configuration. Deleting only removes the configuration and stops updates to the Query Suggestions index. To delete the Query Suggestions index itself, use the Search API and the `Delete an index` operation.
199
194
  *
200
195
  * Required API Key ACLs:
201
- * - editSettings.
202
- *
196
+ * - editSettings
203
197
  * @param deleteConfig - The deleteConfig object.
204
198
  * @param deleteConfig.indexName - Query Suggestions index name.
205
199
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -223,8 +217,7 @@ function createQuerySuggestionsClient({
223
217
  * Retrieves all Query Suggestions configurations of your Algolia application.
224
218
  *
225
219
  * Required API Key ACLs:
226
- * - settings.
227
- *
220
+ * - settings
228
221
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
229
222
  */
230
223
  getAllConfigs(requestOptions) {
@@ -243,8 +236,7 @@ function createQuerySuggestionsClient({
243
236
  * Retrieves a single Query Suggestions configuration by its index name.
244
237
  *
245
238
  * Required API Key ACLs:
246
- * - settings.
247
- *
239
+ * - settings
248
240
  * @param getConfig - The getConfig object.
249
241
  * @param getConfig.indexName - Query Suggestions index name.
250
242
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -268,8 +260,7 @@ function createQuerySuggestionsClient({
268
260
  * Reports the status of a Query Suggestions index.
269
261
  *
270
262
  * Required API Key ACLs:
271
- * - settings.
272
- *
263
+ * - settings
273
264
  * @param getConfigStatus - The getConfigStatus object.
274
265
  * @param getConfigStatus.indexName - Query Suggestions index name.
275
266
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -293,8 +284,7 @@ function createQuerySuggestionsClient({
293
284
  * Retrieves the logs for a single Query Suggestions index.
294
285
  *
295
286
  * Required API Key ACLs:
296
- * - settings.
297
- *
287
+ * - settings
298
288
  * @param getLogFile - The getLogFile object.
299
289
  * @param getLogFile.indexName - Query Suggestions index name.
300
290
  * @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
@@ -318,8 +308,7 @@ function createQuerySuggestionsClient({
318
308
  * Updates a QuerySuggestions configuration.
319
309
  *
320
310
  * Required API Key ACLs:
321
- * - editSettings.
322
- *
311
+ * - editSettings
323
312
  * @param updateConfig - The updateConfig object.
324
313
  * @param updateConfig.indexName - Query Suggestions index name.
325
314
  * @param updateConfig.configuration - The configuration object.