@algolia/client-personalization 5.55.2 → 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 +98 -3
- package/dist/builds/browser.js +216 -1
- package/dist/builds/browser.js.map +1 -1
- package/dist/builds/browser.min.js +5 -5
- package/dist/builds/browser.min.js.map +1 -1
- package/dist/builds/browser.umd.js +7 -7
- package/dist/builds/fetch.js +216 -1
- package/dist/builds/fetch.js.map +1 -1
- package/dist/builds/node.cjs +216 -1
- package/dist/builds/node.cjs.map +1 -1
- package/dist/builds/node.js +216 -1
- package/dist/builds/node.js.map +1 -1
- package/dist/builds/worker.js +216 -1
- package/dist/builds/worker.js.map +1 -1
- package/dist/fetch.d.ts +98 -3
- package/dist/node.d.cts +98 -3
- package/dist/node.d.ts +98 -3
- package/dist/src/personalizationClient.cjs +216 -1
- package/dist/src/personalizationClient.cjs.map +1 -1
- package/dist/src/personalizationClient.js +216 -1
- package/dist/src/personalizationClient.js.map +1 -1
- package/dist/worker.d.ts +98 -3
- package/package.json +8 -8
package/dist/node.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _algolia_client_common from '@algolia/client-common';
|
|
2
|
-
import { CreateClientOptions, RequestOptions, ClientOptions } from '@algolia/client-common';
|
|
2
|
+
import { CreateClientOptions, RequestOptions, AlgoliaHttpResponse, ClientOptions } from '@algolia/client-common';
|
|
3
3
|
|
|
4
4
|
type DeleteUserProfileResponse = {
|
|
5
5
|
/**
|
|
@@ -164,14 +164,14 @@ type GetUserTokenProfileProps = {
|
|
|
164
164
|
userToken: string;
|
|
165
165
|
};
|
|
166
166
|
|
|
167
|
-
declare const apiClientVersion = "5.
|
|
167
|
+
declare const apiClientVersion = "5.56.0";
|
|
168
168
|
declare const REGIONS: readonly ["eu", "us"];
|
|
169
169
|
type Region = (typeof REGIONS)[number];
|
|
170
170
|
type RegionOptions = {
|
|
171
171
|
region: Region;
|
|
172
172
|
};
|
|
173
173
|
declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }: CreateClientOptions & RegionOptions): {
|
|
174
|
-
transporter: _algolia_client_common.
|
|
174
|
+
transporter: _algolia_client_common.TransporterWithHttpInfo;
|
|
175
175
|
/**
|
|
176
176
|
* The `appId` currently in use.
|
|
177
177
|
*/
|
|
@@ -212,6 +212,17 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
212
212
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
213
213
|
*/
|
|
214
214
|
customDelete({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
215
|
+
/**
|
|
216
|
+
* This method lets you send requests to the Algolia REST API.
|
|
217
|
+
*
|
|
218
|
+
* 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.
|
|
219
|
+
* @param customDelete - The customDelete object.
|
|
220
|
+
* @param customDelete.path - Path of the endpoint, for example `1/newFeature`.
|
|
221
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
222
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
223
|
+
* @see customDelete for the plain version.
|
|
224
|
+
*/
|
|
225
|
+
customDeleteWithHTTPInfo({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
215
226
|
/**
|
|
216
227
|
* This method lets you send requests to the Algolia REST API.
|
|
217
228
|
* @param customGet - The customGet object.
|
|
@@ -220,6 +231,17 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
220
231
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
221
232
|
*/
|
|
222
233
|
customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
234
|
+
/**
|
|
235
|
+
* This method lets you send requests to the Algolia REST API.
|
|
236
|
+
*
|
|
237
|
+
* 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.
|
|
238
|
+
* @param customGet - The customGet object.
|
|
239
|
+
* @param customGet.path - Path of the endpoint, for example `1/newFeature`.
|
|
240
|
+
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
241
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
242
|
+
* @see customGet for the plain version.
|
|
243
|
+
*/
|
|
244
|
+
customGetWithHTTPInfo({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
223
245
|
/**
|
|
224
246
|
* This method lets you send requests to the Algolia REST API.
|
|
225
247
|
* @param customPost - The customPost object.
|
|
@@ -229,6 +251,18 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
229
251
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
230
252
|
*/
|
|
231
253
|
customPost({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
254
|
+
/**
|
|
255
|
+
* This method lets you send requests to the Algolia REST API.
|
|
256
|
+
*
|
|
257
|
+
* 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.
|
|
258
|
+
* @param customPost - The customPost object.
|
|
259
|
+
* @param customPost.path - Path of the endpoint, for example `1/newFeature`.
|
|
260
|
+
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
261
|
+
* @param customPost.body - Parameters to send with the custom request.
|
|
262
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
263
|
+
* @see customPost for the plain version.
|
|
264
|
+
*/
|
|
265
|
+
customPostWithHTTPInfo({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
232
266
|
/**
|
|
233
267
|
* This method lets you send requests to the Algolia REST API.
|
|
234
268
|
* @param customPut - The customPut object.
|
|
@@ -238,6 +272,18 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
238
272
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
239
273
|
*/
|
|
240
274
|
customPut({ path, parameters, body }: CustomPutProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
275
|
+
/**
|
|
276
|
+
* This method lets you send requests to the Algolia REST API.
|
|
277
|
+
*
|
|
278
|
+
* 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.
|
|
279
|
+
* @param customPut - The customPut object.
|
|
280
|
+
* @param customPut.path - Path of the endpoint, for example `1/newFeature`.
|
|
281
|
+
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
282
|
+
* @param customPut.body - Parameters to send with the custom request.
|
|
283
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
284
|
+
* @see customPut for the plain version.
|
|
285
|
+
*/
|
|
286
|
+
customPutWithHTTPInfo({ path, parameters, body }: CustomPutProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
241
287
|
/**
|
|
242
288
|
* Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
|
|
243
289
|
*
|
|
@@ -248,6 +294,19 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
248
294
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
249
295
|
*/
|
|
250
296
|
deleteUserProfile({ userToken }: DeleteUserProfileProps, requestOptions?: RequestOptions): Promise<DeleteUserProfileResponse>;
|
|
297
|
+
/**
|
|
298
|
+
* Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
|
|
299
|
+
*
|
|
300
|
+
* 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.
|
|
301
|
+
*
|
|
302
|
+
* Required API Key ACLs:
|
|
303
|
+
* - recommendation
|
|
304
|
+
* @param deleteUserProfile - The deleteUserProfile object.
|
|
305
|
+
* @param deleteUserProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
|
|
306
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
307
|
+
* @see deleteUserProfile for the plain version.
|
|
308
|
+
*/
|
|
309
|
+
deleteUserProfileWithHTTPInfo({ userToken }: DeleteUserProfileProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<DeleteUserProfileResponse>>;
|
|
251
310
|
/**
|
|
252
311
|
* Retrieves the current personalization strategy.
|
|
253
312
|
*
|
|
@@ -256,6 +315,17 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
256
315
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
257
316
|
*/
|
|
258
317
|
getPersonalizationStrategy(requestOptions?: RequestOptions | undefined): Promise<PersonalizationStrategyParams>;
|
|
318
|
+
/**
|
|
319
|
+
* Retrieves the current personalization strategy.
|
|
320
|
+
*
|
|
321
|
+
* 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.
|
|
322
|
+
*
|
|
323
|
+
* Required API Key ACLs:
|
|
324
|
+
* - recommendation
|
|
325
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
326
|
+
* @see getPersonalizationStrategy for the plain version.
|
|
327
|
+
*/
|
|
328
|
+
getPersonalizationStrategyWithHTTPInfo(requestOptions?: RequestOptions | undefined): Promise<AlgoliaHttpResponse<PersonalizationStrategyParams>>;
|
|
259
329
|
/**
|
|
260
330
|
* Retrieves a user profile and their affinities for different facets.
|
|
261
331
|
*
|
|
@@ -266,6 +336,19 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
266
336
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
267
337
|
*/
|
|
268
338
|
getUserTokenProfile({ userToken }: GetUserTokenProfileProps, requestOptions?: RequestOptions): Promise<GetUserTokenResponse>;
|
|
339
|
+
/**
|
|
340
|
+
* Retrieves a user profile and their affinities for different facets.
|
|
341
|
+
*
|
|
342
|
+
* 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.
|
|
343
|
+
*
|
|
344
|
+
* Required API Key ACLs:
|
|
345
|
+
* - recommendation
|
|
346
|
+
* @param getUserTokenProfile - The getUserTokenProfile object.
|
|
347
|
+
* @param getUserTokenProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
|
|
348
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
349
|
+
* @see getUserTokenProfile for the plain version.
|
|
350
|
+
*/
|
|
351
|
+
getUserTokenProfileWithHTTPInfo({ userToken }: GetUserTokenProfileProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<GetUserTokenResponse>>;
|
|
269
352
|
/**
|
|
270
353
|
* Creates a new personalization strategy.
|
|
271
354
|
*
|
|
@@ -275,6 +358,18 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
275
358
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
276
359
|
*/
|
|
277
360
|
setPersonalizationStrategy(personalizationStrategyParams: PersonalizationStrategyParams, requestOptions?: RequestOptions): Promise<SetPersonalizationStrategyResponse>;
|
|
361
|
+
/**
|
|
362
|
+
* Creates a new personalization strategy.
|
|
363
|
+
*
|
|
364
|
+
* 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.
|
|
365
|
+
*
|
|
366
|
+
* Required API Key ACLs:
|
|
367
|
+
* - recommendation
|
|
368
|
+
* @param personalizationStrategyParams - The personalizationStrategyParams object.
|
|
369
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
370
|
+
* @see setPersonalizationStrategy for the plain version.
|
|
371
|
+
*/
|
|
372
|
+
setPersonalizationStrategyWithHTTPInfo(personalizationStrategyParams: PersonalizationStrategyParams, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<SetPersonalizationStrategyResponse>>;
|
|
278
373
|
};
|
|
279
374
|
|
|
280
375
|
/**
|
package/dist/node.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as _algolia_client_common from '@algolia/client-common';
|
|
2
|
-
import { CreateClientOptions, RequestOptions, ClientOptions } from '@algolia/client-common';
|
|
2
|
+
import { CreateClientOptions, RequestOptions, AlgoliaHttpResponse, ClientOptions } from '@algolia/client-common';
|
|
3
3
|
|
|
4
4
|
type DeleteUserProfileResponse = {
|
|
5
5
|
/**
|
|
@@ -164,14 +164,14 @@ type GetUserTokenProfileProps = {
|
|
|
164
164
|
userToken: string;
|
|
165
165
|
};
|
|
166
166
|
|
|
167
|
-
declare const apiClientVersion = "5.
|
|
167
|
+
declare const apiClientVersion = "5.56.0";
|
|
168
168
|
declare const REGIONS: readonly ["eu", "us"];
|
|
169
169
|
type Region = (typeof REGIONS)[number];
|
|
170
170
|
type RegionOptions = {
|
|
171
171
|
region: Region;
|
|
172
172
|
};
|
|
173
173
|
declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKeyOption, authMode, algoliaAgents, region: regionOption, ...options }: CreateClientOptions & RegionOptions): {
|
|
174
|
-
transporter: _algolia_client_common.
|
|
174
|
+
transporter: _algolia_client_common.TransporterWithHttpInfo;
|
|
175
175
|
/**
|
|
176
176
|
* The `appId` currently in use.
|
|
177
177
|
*/
|
|
@@ -212,6 +212,17 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
212
212
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
213
213
|
*/
|
|
214
214
|
customDelete({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
215
|
+
/**
|
|
216
|
+
* This method lets you send requests to the Algolia REST API.
|
|
217
|
+
*
|
|
218
|
+
* 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.
|
|
219
|
+
* @param customDelete - The customDelete object.
|
|
220
|
+
* @param customDelete.path - Path of the endpoint, for example `1/newFeature`.
|
|
221
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
222
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
223
|
+
* @see customDelete for the plain version.
|
|
224
|
+
*/
|
|
225
|
+
customDeleteWithHTTPInfo({ path, parameters }: CustomDeleteProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
215
226
|
/**
|
|
216
227
|
* This method lets you send requests to the Algolia REST API.
|
|
217
228
|
* @param customGet - The customGet object.
|
|
@@ -220,6 +231,17 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
220
231
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
221
232
|
*/
|
|
222
233
|
customGet({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
234
|
+
/**
|
|
235
|
+
* This method lets you send requests to the Algolia REST API.
|
|
236
|
+
*
|
|
237
|
+
* 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.
|
|
238
|
+
* @param customGet - The customGet object.
|
|
239
|
+
* @param customGet.path - Path of the endpoint, for example `1/newFeature`.
|
|
240
|
+
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
241
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
242
|
+
* @see customGet for the plain version.
|
|
243
|
+
*/
|
|
244
|
+
customGetWithHTTPInfo({ path, parameters }: CustomGetProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
223
245
|
/**
|
|
224
246
|
* This method lets you send requests to the Algolia REST API.
|
|
225
247
|
* @param customPost - The customPost object.
|
|
@@ -229,6 +251,18 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
229
251
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
230
252
|
*/
|
|
231
253
|
customPost({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
254
|
+
/**
|
|
255
|
+
* This method lets you send requests to the Algolia REST API.
|
|
256
|
+
*
|
|
257
|
+
* 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.
|
|
258
|
+
* @param customPost - The customPost object.
|
|
259
|
+
* @param customPost.path - Path of the endpoint, for example `1/newFeature`.
|
|
260
|
+
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
261
|
+
* @param customPost.body - Parameters to send with the custom request.
|
|
262
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
263
|
+
* @see customPost for the plain version.
|
|
264
|
+
*/
|
|
265
|
+
customPostWithHTTPInfo({ path, parameters, body }: CustomPostProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
232
266
|
/**
|
|
233
267
|
* This method lets you send requests to the Algolia REST API.
|
|
234
268
|
* @param customPut - The customPut object.
|
|
@@ -238,6 +272,18 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
238
272
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
239
273
|
*/
|
|
240
274
|
customPut({ path, parameters, body }: CustomPutProps, requestOptions?: RequestOptions): Promise<Record<string, unknown>>;
|
|
275
|
+
/**
|
|
276
|
+
* This method lets you send requests to the Algolia REST API.
|
|
277
|
+
*
|
|
278
|
+
* 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.
|
|
279
|
+
* @param customPut - The customPut object.
|
|
280
|
+
* @param customPut.path - Path of the endpoint, for example `1/newFeature`.
|
|
281
|
+
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
282
|
+
* @param customPut.body - Parameters to send with the custom request.
|
|
283
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
284
|
+
* @see customPut for the plain version.
|
|
285
|
+
*/
|
|
286
|
+
customPutWithHTTPInfo({ path, parameters, body }: CustomPutProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<Record<string, unknown>>>;
|
|
241
287
|
/**
|
|
242
288
|
* Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
|
|
243
289
|
*
|
|
@@ -248,6 +294,19 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
248
294
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
249
295
|
*/
|
|
250
296
|
deleteUserProfile({ userToken }: DeleteUserProfileProps, requestOptions?: RequestOptions): Promise<DeleteUserProfileResponse>;
|
|
297
|
+
/**
|
|
298
|
+
* Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
|
|
299
|
+
*
|
|
300
|
+
* 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.
|
|
301
|
+
*
|
|
302
|
+
* Required API Key ACLs:
|
|
303
|
+
* - recommendation
|
|
304
|
+
* @param deleteUserProfile - The deleteUserProfile object.
|
|
305
|
+
* @param deleteUserProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
|
|
306
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
307
|
+
* @see deleteUserProfile for the plain version.
|
|
308
|
+
*/
|
|
309
|
+
deleteUserProfileWithHTTPInfo({ userToken }: DeleteUserProfileProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<DeleteUserProfileResponse>>;
|
|
251
310
|
/**
|
|
252
311
|
* Retrieves the current personalization strategy.
|
|
253
312
|
*
|
|
@@ -256,6 +315,17 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
256
315
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
257
316
|
*/
|
|
258
317
|
getPersonalizationStrategy(requestOptions?: RequestOptions | undefined): Promise<PersonalizationStrategyParams>;
|
|
318
|
+
/**
|
|
319
|
+
* Retrieves the current personalization strategy.
|
|
320
|
+
*
|
|
321
|
+
* 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.
|
|
322
|
+
*
|
|
323
|
+
* Required API Key ACLs:
|
|
324
|
+
* - recommendation
|
|
325
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
326
|
+
* @see getPersonalizationStrategy for the plain version.
|
|
327
|
+
*/
|
|
328
|
+
getPersonalizationStrategyWithHTTPInfo(requestOptions?: RequestOptions | undefined): Promise<AlgoliaHttpResponse<PersonalizationStrategyParams>>;
|
|
259
329
|
/**
|
|
260
330
|
* Retrieves a user profile and their affinities for different facets.
|
|
261
331
|
*
|
|
@@ -266,6 +336,19 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
266
336
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
267
337
|
*/
|
|
268
338
|
getUserTokenProfile({ userToken }: GetUserTokenProfileProps, requestOptions?: RequestOptions): Promise<GetUserTokenResponse>;
|
|
339
|
+
/**
|
|
340
|
+
* Retrieves a user profile and their affinities for different facets.
|
|
341
|
+
*
|
|
342
|
+
* 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.
|
|
343
|
+
*
|
|
344
|
+
* Required API Key ACLs:
|
|
345
|
+
* - recommendation
|
|
346
|
+
* @param getUserTokenProfile - The getUserTokenProfile object.
|
|
347
|
+
* @param getUserTokenProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
|
|
348
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
349
|
+
* @see getUserTokenProfile for the plain version.
|
|
350
|
+
*/
|
|
351
|
+
getUserTokenProfileWithHTTPInfo({ userToken }: GetUserTokenProfileProps, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<GetUserTokenResponse>>;
|
|
269
352
|
/**
|
|
270
353
|
* Creates a new personalization strategy.
|
|
271
354
|
*
|
|
@@ -275,6 +358,18 @@ declare function createPersonalizationClient({ appId: appIdOption, apiKey: apiKe
|
|
|
275
358
|
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
276
359
|
*/
|
|
277
360
|
setPersonalizationStrategy(personalizationStrategyParams: PersonalizationStrategyParams, requestOptions?: RequestOptions): Promise<SetPersonalizationStrategyResponse>;
|
|
361
|
+
/**
|
|
362
|
+
* Creates a new personalization strategy.
|
|
363
|
+
*
|
|
364
|
+
* 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.
|
|
365
|
+
*
|
|
366
|
+
* Required API Key ACLs:
|
|
367
|
+
* - recommendation
|
|
368
|
+
* @param personalizationStrategyParams - The personalizationStrategyParams object.
|
|
369
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
370
|
+
* @see setPersonalizationStrategy for the plain version.
|
|
371
|
+
*/
|
|
372
|
+
setPersonalizationStrategyWithHTTPInfo(personalizationStrategyParams: PersonalizationStrategyParams, requestOptions?: RequestOptions): Promise<AlgoliaHttpResponse<SetPersonalizationStrategyResponse>>;
|
|
278
373
|
};
|
|
279
374
|
|
|
280
375
|
/**
|
|
@@ -26,7 +26,7 @@ __export(personalizationClient_exports, {
|
|
|
26
26
|
});
|
|
27
27
|
module.exports = __toCommonJS(personalizationClient_exports);
|
|
28
28
|
var import_client_common = require("@algolia/client-common");
|
|
29
|
-
var apiClientVersion = "5.
|
|
29
|
+
var apiClientVersion = "5.56.0";
|
|
30
30
|
var REGIONS = ["eu", "us"];
|
|
31
31
|
function getDefaultHosts(region) {
|
|
32
32
|
const url = "personalization.{region}.algolia.com".replace("{region}", region);
|
|
@@ -123,6 +123,29 @@ function createPersonalizationClient({
|
|
|
123
123
|
};
|
|
124
124
|
return transporter.request(request, requestOptions);
|
|
125
125
|
},
|
|
126
|
+
/**
|
|
127
|
+
* This method lets you send requests to the Algolia REST API.
|
|
128
|
+
*
|
|
129
|
+
* 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.
|
|
130
|
+
* @param customDelete - The customDelete object.
|
|
131
|
+
* @param customDelete.path - Path of the endpoint, for example `1/newFeature`.
|
|
132
|
+
* @param customDelete.parameters - Query parameters to apply to the current query.
|
|
133
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
134
|
+
* @see customDelete for the plain version.
|
|
135
|
+
*/
|
|
136
|
+
customDeleteWithHTTPInfo({ path, parameters }, requestOptions) {
|
|
137
|
+
(0, import_client_common.validateRequired)("path", "customDeleteWithHTTPInfo", path);
|
|
138
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
139
|
+
const headers = {};
|
|
140
|
+
const queryParameters = parameters ? parameters : {};
|
|
141
|
+
const request = {
|
|
142
|
+
method: "DELETE",
|
|
143
|
+
path: requestPath,
|
|
144
|
+
queryParameters,
|
|
145
|
+
headers
|
|
146
|
+
};
|
|
147
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
148
|
+
},
|
|
126
149
|
/**
|
|
127
150
|
* This method lets you send requests to the Algolia REST API.
|
|
128
151
|
* @param customGet - The customGet object.
|
|
@@ -143,6 +166,29 @@ function createPersonalizationClient({
|
|
|
143
166
|
};
|
|
144
167
|
return transporter.request(request, requestOptions);
|
|
145
168
|
},
|
|
169
|
+
/**
|
|
170
|
+
* This method lets you send requests to the Algolia REST API.
|
|
171
|
+
*
|
|
172
|
+
* 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.
|
|
173
|
+
* @param customGet - The customGet object.
|
|
174
|
+
* @param customGet.path - Path of the endpoint, for example `1/newFeature`.
|
|
175
|
+
* @param customGet.parameters - Query parameters to apply to the current query.
|
|
176
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
177
|
+
* @see customGet for the plain version.
|
|
178
|
+
*/
|
|
179
|
+
customGetWithHTTPInfo({ path, parameters }, requestOptions) {
|
|
180
|
+
(0, import_client_common.validateRequired)("path", "customGetWithHTTPInfo", path);
|
|
181
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
182
|
+
const headers = {};
|
|
183
|
+
const queryParameters = parameters ? parameters : {};
|
|
184
|
+
const request = {
|
|
185
|
+
method: "GET",
|
|
186
|
+
path: requestPath,
|
|
187
|
+
queryParameters,
|
|
188
|
+
headers
|
|
189
|
+
};
|
|
190
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
191
|
+
},
|
|
146
192
|
/**
|
|
147
193
|
* This method lets you send requests to the Algolia REST API.
|
|
148
194
|
* @param customPost - The customPost object.
|
|
@@ -165,6 +211,31 @@ function createPersonalizationClient({
|
|
|
165
211
|
};
|
|
166
212
|
return transporter.request(request, requestOptions);
|
|
167
213
|
},
|
|
214
|
+
/**
|
|
215
|
+
* This method lets you send requests to the Algolia REST API.
|
|
216
|
+
*
|
|
217
|
+
* 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.
|
|
218
|
+
* @param customPost - The customPost object.
|
|
219
|
+
* @param customPost.path - Path of the endpoint, for example `1/newFeature`.
|
|
220
|
+
* @param customPost.parameters - Query parameters to apply to the current query.
|
|
221
|
+
* @param customPost.body - Parameters to send with the custom request.
|
|
222
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
223
|
+
* @see customPost for the plain version.
|
|
224
|
+
*/
|
|
225
|
+
customPostWithHTTPInfo({ path, parameters, body }, requestOptions) {
|
|
226
|
+
(0, import_client_common.validateRequired)("path", "customPostWithHTTPInfo", path);
|
|
227
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
228
|
+
const headers = {};
|
|
229
|
+
const queryParameters = parameters ? parameters : {};
|
|
230
|
+
const request = {
|
|
231
|
+
method: "POST",
|
|
232
|
+
path: requestPath,
|
|
233
|
+
queryParameters,
|
|
234
|
+
headers,
|
|
235
|
+
data: body ? body : {}
|
|
236
|
+
};
|
|
237
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
238
|
+
},
|
|
168
239
|
/**
|
|
169
240
|
* This method lets you send requests to the Algolia REST API.
|
|
170
241
|
* @param customPut - The customPut object.
|
|
@@ -187,6 +258,31 @@ function createPersonalizationClient({
|
|
|
187
258
|
};
|
|
188
259
|
return transporter.request(request, requestOptions);
|
|
189
260
|
},
|
|
261
|
+
/**
|
|
262
|
+
* This method lets you send requests to the Algolia REST API.
|
|
263
|
+
*
|
|
264
|
+
* 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.
|
|
265
|
+
* @param customPut - The customPut object.
|
|
266
|
+
* @param customPut.path - Path of the endpoint, for example `1/newFeature`.
|
|
267
|
+
* @param customPut.parameters - Query parameters to apply to the current query.
|
|
268
|
+
* @param customPut.body - Parameters to send with the custom request.
|
|
269
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
270
|
+
* @see customPut for the plain version.
|
|
271
|
+
*/
|
|
272
|
+
customPutWithHTTPInfo({ path, parameters, body }, requestOptions) {
|
|
273
|
+
(0, import_client_common.validateRequired)("path", "customPutWithHTTPInfo", path);
|
|
274
|
+
const requestPath = "/{path}".replace("{path}", path);
|
|
275
|
+
const headers = {};
|
|
276
|
+
const queryParameters = parameters ? parameters : {};
|
|
277
|
+
const request = {
|
|
278
|
+
method: "PUT",
|
|
279
|
+
path: requestPath,
|
|
280
|
+
queryParameters,
|
|
281
|
+
headers,
|
|
282
|
+
data: body ? body : {}
|
|
283
|
+
};
|
|
284
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
285
|
+
},
|
|
190
286
|
/**
|
|
191
287
|
* Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
|
|
192
288
|
*
|
|
@@ -209,6 +305,31 @@ function createPersonalizationClient({
|
|
|
209
305
|
};
|
|
210
306
|
return transporter.request(request, requestOptions);
|
|
211
307
|
},
|
|
308
|
+
/**
|
|
309
|
+
* Deletes a user profile. The response includes a date and time when the user profile can safely be considered deleted.
|
|
310
|
+
*
|
|
311
|
+
* 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.
|
|
312
|
+
*
|
|
313
|
+
* Required API Key ACLs:
|
|
314
|
+
* - recommendation
|
|
315
|
+
* @param deleteUserProfile - The deleteUserProfile object.
|
|
316
|
+
* @param deleteUserProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
|
|
317
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
318
|
+
* @see deleteUserProfile for the plain version.
|
|
319
|
+
*/
|
|
320
|
+
deleteUserProfileWithHTTPInfo({ userToken }, requestOptions) {
|
|
321
|
+
(0, import_client_common.validateRequired)("userToken", "deleteUserProfileWithHTTPInfo", userToken);
|
|
322
|
+
const requestPath = "/1/profiles/{userToken}".replace("{userToken}", encodeURIComponent(userToken));
|
|
323
|
+
const headers = {};
|
|
324
|
+
const queryParameters = {};
|
|
325
|
+
const request = {
|
|
326
|
+
method: "DELETE",
|
|
327
|
+
path: requestPath,
|
|
328
|
+
queryParameters,
|
|
329
|
+
headers
|
|
330
|
+
};
|
|
331
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
332
|
+
},
|
|
212
333
|
/**
|
|
213
334
|
* Retrieves the current personalization strategy.
|
|
214
335
|
*
|
|
@@ -228,6 +349,28 @@ function createPersonalizationClient({
|
|
|
228
349
|
};
|
|
229
350
|
return transporter.request(request, requestOptions);
|
|
230
351
|
},
|
|
352
|
+
/**
|
|
353
|
+
* Retrieves the current personalization strategy.
|
|
354
|
+
*
|
|
355
|
+
* 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.
|
|
356
|
+
*
|
|
357
|
+
* Required API Key ACLs:
|
|
358
|
+
* - recommendation
|
|
359
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
360
|
+
* @see getPersonalizationStrategy for the plain version.
|
|
361
|
+
*/
|
|
362
|
+
getPersonalizationStrategyWithHTTPInfo(requestOptions) {
|
|
363
|
+
const requestPath = "/1/strategies/personalization";
|
|
364
|
+
const headers = {};
|
|
365
|
+
const queryParameters = {};
|
|
366
|
+
const request = {
|
|
367
|
+
method: "GET",
|
|
368
|
+
path: requestPath,
|
|
369
|
+
queryParameters,
|
|
370
|
+
headers
|
|
371
|
+
};
|
|
372
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
373
|
+
},
|
|
231
374
|
/**
|
|
232
375
|
* Retrieves a user profile and their affinities for different facets.
|
|
233
376
|
*
|
|
@@ -253,6 +396,34 @@ function createPersonalizationClient({
|
|
|
253
396
|
};
|
|
254
397
|
return transporter.request(request, requestOptions);
|
|
255
398
|
},
|
|
399
|
+
/**
|
|
400
|
+
* Retrieves a user profile and their affinities for different facets.
|
|
401
|
+
*
|
|
402
|
+
* 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.
|
|
403
|
+
*
|
|
404
|
+
* Required API Key ACLs:
|
|
405
|
+
* - recommendation
|
|
406
|
+
* @param getUserTokenProfile - The getUserTokenProfile object.
|
|
407
|
+
* @param getUserTokenProfile.userToken - Unique identifier representing a user for which to fetch the personalization profile.
|
|
408
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
409
|
+
* @see getUserTokenProfile for the plain version.
|
|
410
|
+
*/
|
|
411
|
+
getUserTokenProfileWithHTTPInfo({ userToken }, requestOptions) {
|
|
412
|
+
(0, import_client_common.validateRequired)("userToken", "getUserTokenProfileWithHTTPInfo", userToken);
|
|
413
|
+
const requestPath = "/1/profiles/personalization/{userToken}".replace(
|
|
414
|
+
"{userToken}",
|
|
415
|
+
encodeURIComponent(userToken)
|
|
416
|
+
);
|
|
417
|
+
const headers = {};
|
|
418
|
+
const queryParameters = {};
|
|
419
|
+
const request = {
|
|
420
|
+
method: "GET",
|
|
421
|
+
path: requestPath,
|
|
422
|
+
queryParameters,
|
|
423
|
+
headers
|
|
424
|
+
};
|
|
425
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
426
|
+
},
|
|
256
427
|
/**
|
|
257
428
|
* Creates a new personalization strategy.
|
|
258
429
|
*
|
|
@@ -289,6 +460,50 @@ function createPersonalizationClient({
|
|
|
289
460
|
data: personalizationStrategyParams
|
|
290
461
|
};
|
|
291
462
|
return transporter.request(request, requestOptions);
|
|
463
|
+
},
|
|
464
|
+
/**
|
|
465
|
+
* Creates a new personalization strategy.
|
|
466
|
+
*
|
|
467
|
+
* 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.
|
|
468
|
+
*
|
|
469
|
+
* Required API Key ACLs:
|
|
470
|
+
* - recommendation
|
|
471
|
+
* @param personalizationStrategyParams - The personalizationStrategyParams object.
|
|
472
|
+
* @param requestOptions - The requestOptions to send along with the query, they will be merged with the transporter requestOptions.
|
|
473
|
+
* @see setPersonalizationStrategy for the plain version.
|
|
474
|
+
*/
|
|
475
|
+
setPersonalizationStrategyWithHTTPInfo(personalizationStrategyParams, requestOptions) {
|
|
476
|
+
(0, import_client_common.validateRequired)(
|
|
477
|
+
"personalizationStrategyParams",
|
|
478
|
+
"setPersonalizationStrategyWithHTTPInfo",
|
|
479
|
+
personalizationStrategyParams
|
|
480
|
+
);
|
|
481
|
+
(0, import_client_common.validateRequired)(
|
|
482
|
+
"personalizationStrategyParams.eventsScoring",
|
|
483
|
+
"setPersonalizationStrategyWithHTTPInfo",
|
|
484
|
+
personalizationStrategyParams.eventsScoring
|
|
485
|
+
);
|
|
486
|
+
(0, import_client_common.validateRequired)(
|
|
487
|
+
"personalizationStrategyParams.facetsScoring",
|
|
488
|
+
"setPersonalizationStrategyWithHTTPInfo",
|
|
489
|
+
personalizationStrategyParams.facetsScoring
|
|
490
|
+
);
|
|
491
|
+
(0, import_client_common.validateRequired)(
|
|
492
|
+
"personalizationStrategyParams.personalizationImpact",
|
|
493
|
+
"setPersonalizationStrategyWithHTTPInfo",
|
|
494
|
+
personalizationStrategyParams.personalizationImpact
|
|
495
|
+
);
|
|
496
|
+
const requestPath = "/1/strategies/personalization";
|
|
497
|
+
const headers = {};
|
|
498
|
+
const queryParameters = {};
|
|
499
|
+
const request = {
|
|
500
|
+
method: "POST",
|
|
501
|
+
path: requestPath,
|
|
502
|
+
queryParameters,
|
|
503
|
+
headers,
|
|
504
|
+
data: personalizationStrategyParams
|
|
505
|
+
};
|
|
506
|
+
return transporter.requestWithHttpInfo(request, requestOptions);
|
|
292
507
|
}
|
|
293
508
|
};
|
|
294
509
|
}
|