@coveo/platform-client 48.3.0 → 48.3.2
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/cjs/resources/Search/Search.js +1 -1
- package/dist/cjs/resources/Search/Search.js.map +1 -1
- package/dist/esm/resources/Search/Search.js +1 -1
- package/dist/esm/resources/Search/Search.js.map +1 -1
- package/dist/types/resources/Search/SearchInterfaces.d.ts +75 -73
- package/package.json +9 -9
|
@@ -12,7 +12,7 @@ class Search extends Resource_js_1.default {
|
|
|
12
12
|
return this.api.get(this.buildPath(`${Search.baseUrl}/fields`, {
|
|
13
13
|
...params,
|
|
14
14
|
organizationId: params?.organizationId ?? this.api.organizationId,
|
|
15
|
-
}));
|
|
15
|
+
}, { skipEmptyString: false }));
|
|
16
16
|
}
|
|
17
17
|
getFieldValues(fieldName, params) {
|
|
18
18
|
return this.api.get(this.buildPath(`${Search.baseUrl}/values`, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Search.js","sourceRoot":"","sources":["../../../../src/resources/Search/Search.ts"],"names":[],"mappings":";;;AAAA,0EAAmC;AACnC,yEAAuC;AAgBvC,MAAqB,MAAO,SAAQ,qBAAS;IACzC,MAAM,CAAC,OAAO,GAAG,iBAAiB,CAAC;IAEnC,WAAW,CAAC,WAA4B;QACpC,OAAO,IAAI,CAAC,GAAG,CAAC,IAAI,CAAa,GAAG,MAAM,CAAC,OAAO,yBAAyB,oBAAG,CAAC,cAAc,EAAE,EAAE,WAAW,CAAC,CAAC;IAClH,CAAC;IAED,UAAU,CAAC,MAA+B;QACtC,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,CACf,IAAI,CAAC,SAAS,
|
|
1
|
+
{"version":3,"file":"Search.js","sourceRoot":"","sources":["../../../../src/resources/Search/Search.ts"],"names":[],"mappings":";;;AAAA,0EAAmC;AACnC,yEAAuC;AAgBvC,MAAqB,MAAO,SAAQ,qBAAS;IACzC,MAAM,CAAC,OAA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,GAAG,CACf,IAAI,CAAC,SAAS,CACV,GAAG,MAAM,CAAC,OAAO,WAAW,EAC5B;YACI,GAAG,MAAM;YACT,cAAc,EAAE,MAAM,CAAC,cAAc,IAAI,IAAI,CAAC,GAAG,CAAC,cAAc;SACnE,EACD,EAAC,eAAe,EAAE,KAAK,EAAC,CAC3B,CACJ,CAAC;IACN,CAAC;IAED;;OAEG;IACH,WAAW,CAAC,MAAiC;QACzC,MAAM,EAAC,cAAc,EAAE,cAAc,EAAE,GAAG,cAAc,EAAC,GAAG,MAAM,CAAC;QAEnE,OAAO,IAAI,CAAC,GAAG,CAAC,IAAI,CAChB,IAAI,CAAC,SAAS,CAAC,GAAG,MAAM,CAAC,OAAO,QAAQ,EAAE;YACtC,cAAc,EAAE,cAAc,IAAI,IAAI,CAAC,GAAG,CAAC,cAAc;YACzD,cAAc;SACjB,CAAC,EACF,cAAc,CACjB,CAAC;IACN,CAAC;;AApIL,yBAqIC"}
|
|
@@ -9,7 +9,7 @@ export default class Search extends Ressource {
|
|
|
9
9
|
return this.api.get(this.buildPath(`${Search.baseUrl}/fields`, {
|
|
10
10
|
...params,
|
|
11
11
|
organizationId: params?.organizationId ?? this.api.organizationId,
|
|
12
|
-
}));
|
|
12
|
+
}, { skipEmptyString: false }));
|
|
13
13
|
}
|
|
14
14
|
getFieldValues(fieldName, params) {
|
|
15
15
|
return this.api.get(this.buildPath(`${Search.baseUrl}/values`, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Search.js","sourceRoot":"","sources":["../../../../src/resources/Search/Search.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,kBAAkB,CAAC;AACnC,OAAO,SAAS,MAAM,gBAAgB,CAAC;AAgBvC,MAAM,CAAC,OAAO,OAAO,MAAO,SAAQ,SAAS;IACzC,MAAM,CAAC,OAAO,GAAG,iBAAiB,CAAC;IAEnC,WAAW,CAAC,WAA4B;QACpC,OAAO,IAAI,CAAC,GAAG,CAAC,IAAI,CA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iB;QACxB,OAAO,IAAI,CAAC,GAAG,CAAC,IAAI,CAChB,IAAI,CAAC,SAAS,CAAC,GAAG,MAAM,CAAC,OAAO,OAAO,EAAE;YACrC,gBAAgB;YAChB,QAAQ;YACR,YAAY;YACZ,IAAI;YACJ,mBAAmB;YACnB,QAAQ;YACR,cAAc;YACd,cAAc,EAAE,cAAc,IAAI,IAAI,CAAC,GAAG,CAAC,cAAc;SAC5D,CAAC,EACF,IAAI,EACJ,EAAC,kBAAkB,EAAE,MAAM,EAAC,CAC/B,CAAC;IACN,CAAC;IAED;;OAEG;IACH,WAAW,CAAC,MAA4B;QACpC,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,CACf,IAAI,CAAC,SAAS,CACV,GAAG,MAAM,CAAC,OAAO,WAAW,EAC5B;YACI,GAAG,MAAM;YACT,cAAc,EAAE,MAAM,CAAC,cAAc,IAAI,IAAI,CAAC,GAAG,CAAC,cAAc;SACnE,EACD,EAAC,eAAe,EAAE,KAAK,EAAC,CAC3B,CACJ,CAAC;IACN,CAAC;IAED;;OAEG;IACH,WAAW,CAAC,MAAiC;QACzC,MAAM,EAAC,cAAc,EAAE,cAAc,EAAE,GAAG,cAAc,EAAC,GAAG,MAAM,CAAC;QAEnE,OAAO,IAAI,CAAC,GAAG,CAAC,IAAI,CAChB,IAAI,CAAC,SAAS,CAAC,GAAG,MAAM,CAAC,OAAO,QAAQ,EAAE;YACtC,cAAc,EAAE,cAAc,IAAI,IAAI,CAAC,GAAG,CAAC,cAAc;YACzD,cAAc;SACjB,CAAC,EACF,cAAc,CACjB,CAAC;IACN,CAAC"}
|
|
@@ -70,7 +70,80 @@ interface SharedSearchParams {
|
|
|
70
70
|
*/
|
|
71
71
|
index?: string;
|
|
72
72
|
}
|
|
73
|
-
export interface
|
|
73
|
+
export interface SharedFieldsParams extends SharedSearchParams {
|
|
74
|
+
/**
|
|
75
|
+
* The second level of origin of the request, typically the identifier of the selected tab in the graphical search interface from which the request originates.
|
|
76
|
+
*
|
|
77
|
+
* Coveo Machine Learning models use this information to provide contextually relevant output.
|
|
78
|
+
*
|
|
79
|
+
* **Note:** When logging a **Search** usage analytics event for a query, the `originLevel2` field of that event should be set to the `tab` value of the query (or to the `"default"` string, if no `tab` value was specified in the query).
|
|
80
|
+
*
|
|
81
|
+
* See also the `searchHub` parameter.
|
|
82
|
+
*
|
|
83
|
+
* @example `ForumTab`
|
|
84
|
+
*/
|
|
85
|
+
tab?: string;
|
|
86
|
+
/**
|
|
87
|
+
* The third level of origin of the request, typically the URL of the page that linked to the search interface from which the request originates (e.g., in JavaScript, this would correspond to the `document.referrer` value).
|
|
88
|
+
*
|
|
89
|
+
* Coveo Machine Learning models may use this information to provide contextually relevant output.
|
|
90
|
+
*
|
|
91
|
+
* **Note:** When logging a **Search** usage analytics event for a query, the `originLevel3` field of that event should be set to the `referrer` value of the query, if specified.
|
|
92
|
+
*
|
|
93
|
+
* See also the `context` parameter.
|
|
94
|
+
*
|
|
95
|
+
* @example `http://www.example.com`
|
|
96
|
+
*/
|
|
97
|
+
referrer?: string;
|
|
98
|
+
/**
|
|
99
|
+
* The custom context information to send along with the request. Must be a dictionary of key-value pairs (JSON) where each key is a string, and each value is either a string or an array of strings.
|
|
100
|
+
*
|
|
101
|
+
* Coveo Machine Learning models may use this information to provide contextually relevant output. Moreover, this information can be referred to in query expressions and QPL statements by using the `$context` object.
|
|
102
|
+
*
|
|
103
|
+
* **Note:**
|
|
104
|
+
* When logging a **Search** usage analytics event for a query, the `customData` field of that event should include the same data as the `context` parameter of the query. However, each `context` key included in `customData` must be prefixed by `context_` (e.g., the `userRoles` key in `context` becomes `context_userRoles` in `customData`).
|
|
105
|
+
*
|
|
106
|
+
* See also the `referrer` parameter.
|
|
107
|
+
*
|
|
108
|
+
* @example
|
|
109
|
+
* ```json
|
|
110
|
+
* {
|
|
111
|
+
* "userAgeRange":"25-35",
|
|
112
|
+
* "userRoles": ["PremiumCustomer", "ProductReviewer"]
|
|
113
|
+
* }
|
|
114
|
+
* ```
|
|
115
|
+
*/
|
|
116
|
+
context?: RestContextRequest;
|
|
117
|
+
/**
|
|
118
|
+
* The locale of the current user. Must comply with IETF’s [BCP 47](http://www.rfc-editor.org/rfc/bcp/bcp47.txt) definition.
|
|
119
|
+
*
|
|
120
|
+
* Coveo Machine Learning models use this information to provide contextually relevant output. Moreover, this information can be referred to in query expressions and QPL statements by using the `$locale` object.
|
|
121
|
+
*
|
|
122
|
+
* **Note:** When logging a **Search** usage analytics event, the language field of that event should match the language part of the `locale` value of the query (e.g., `en-US` in `locale` becomes `en` in `language`).
|
|
123
|
+
*
|
|
124
|
+
* @example `en-US`
|
|
125
|
+
*/
|
|
126
|
+
locale?: string;
|
|
127
|
+
/**
|
|
128
|
+
* The Base64 encoded identifier of the index mirror to forward the request to. See also the `index` parameter.
|
|
129
|
+
*
|
|
130
|
+
* If you do not specify an `indexToken` (or `index`) value, any index mirror could be used.
|
|
131
|
+
*
|
|
132
|
+
* **Note:** Passing an `indexToken` (or `index`) value has no effect when the results of a specific request can be returned from cache (see the `maximumAge` parameter).
|
|
133
|
+
*
|
|
134
|
+
* @example `ZXhhbXBsZWluZGV4bWlycm9yLS4uLg==`
|
|
135
|
+
*/
|
|
136
|
+
indexToken?: string;
|
|
137
|
+
/**
|
|
138
|
+
* The identifier for a logical group of indexes that have been configured to include documents form the same sources.
|
|
139
|
+
*
|
|
140
|
+
* If you do not specify a `logicalIndex` value, the `default` grouping will be used, typically including all indexes.
|
|
141
|
+
*
|
|
142
|
+
* @example `webcontentonly`
|
|
143
|
+
*/
|
|
144
|
+
logicalIndex?: string;
|
|
145
|
+
}
|
|
146
|
+
export interface SearchListFieldsParams extends SharedFieldsParams {
|
|
74
147
|
}
|
|
75
148
|
export interface SearchListFieldsResponse {
|
|
76
149
|
fields: Array<{
|
|
@@ -127,7 +200,7 @@ export interface PostSearchQueryStringParams extends Pick<SharedSearchParams, 'o
|
|
|
127
200
|
/**
|
|
128
201
|
* Defines the body parameters of the list field values request.
|
|
129
202
|
*/
|
|
130
|
-
export interface ListFieldValuesBodyQueryParams extends
|
|
203
|
+
export interface ListFieldValuesBodyQueryParams extends SharedFieldsParams {
|
|
131
204
|
/**
|
|
132
205
|
* Whether to treat accentuated characters as non-accentuated characters when retrieving field values (e.g., treat é, è, ê, etc., as e).
|
|
133
206
|
*
|
|
@@ -213,49 +286,6 @@ export interface ListFieldValuesBodyQueryParams extends SharedSearchParams {
|
|
|
213
286
|
* @default `-1` (which corresponds to the internal default value (15 minutes))
|
|
214
287
|
*/
|
|
215
288
|
maximumAge?: number;
|
|
216
|
-
/**
|
|
217
|
-
* The second level of origin of the request, typically the identifier of the selected tab in the graphical search interface from which the request originates.
|
|
218
|
-
*
|
|
219
|
-
* Coveo Machine Learning models use this information to provide contextually relevant output.
|
|
220
|
-
*
|
|
221
|
-
* **Note:** When logging a **Search** usage analytics event for a query, the `originLevel2` field of that event should be set to the `tab` value of the query (or to the `"default"` string, if no `tab` value was specified in the query).
|
|
222
|
-
*
|
|
223
|
-
* See also the `searchHub` parameter.
|
|
224
|
-
*
|
|
225
|
-
* @example `ForumTab`
|
|
226
|
-
*/
|
|
227
|
-
tab?: string;
|
|
228
|
-
/**
|
|
229
|
-
* The third level of origin of the request, typically the URL of the page that linked to the search interface from which the request originates (e.g., in JavaScript, this would correspond to the `document.referrer` value).
|
|
230
|
-
*
|
|
231
|
-
* Coveo Machine Learning models may use this information to provide contextually relevant output.
|
|
232
|
-
*
|
|
233
|
-
* **Note:** When logging a **Search** usage analytics event for a query, the `originLevel3` field of that event should be set to the `referrer` value of the query, if specified.
|
|
234
|
-
*
|
|
235
|
-
* See also the `context` parameter.
|
|
236
|
-
*
|
|
237
|
-
* @example `http://www.example.com`
|
|
238
|
-
*/
|
|
239
|
-
referrer?: string;
|
|
240
|
-
/**
|
|
241
|
-
* The custom context information to send along with the request. Must be a dictionary of key-value pairs (JSON) where each key is a string, and each value is either a string or an array of strings.
|
|
242
|
-
*
|
|
243
|
-
* Coveo Machine Learning models may use this information to provide contextually relevant output. Moreover, this information can be referred to in query expressions and QPL statements by using the `$context` object.
|
|
244
|
-
*
|
|
245
|
-
* **Note:**
|
|
246
|
-
* When logging a **Search** usage analytics event for a query, the `customData` field of that event should include the same data as the `context` parameter of the query. However, each `context` key included in `customData` must be prefixed by `context_` (e.g., the `userRoles` key in `context` becomes `context_userRoles` in `customData`).
|
|
247
|
-
*
|
|
248
|
-
* See also the `referrer` parameter.
|
|
249
|
-
*
|
|
250
|
-
* @example
|
|
251
|
-
* ```json
|
|
252
|
-
* {
|
|
253
|
-
* "userAgeRange":"25-35",
|
|
254
|
-
* "userRoles": ["PremiumCustomer", "ProductReviewer"]
|
|
255
|
-
* }
|
|
256
|
-
* ```
|
|
257
|
-
*/
|
|
258
|
-
context?: RestContextRequest;
|
|
259
289
|
/**
|
|
260
290
|
* The query and page view actions previously made by the current user.
|
|
261
291
|
*
|
|
@@ -272,16 +302,6 @@ export interface ListFieldValuesBodyQueryParams extends SharedSearchParams {
|
|
|
272
302
|
* @example `RecommendedProducts`
|
|
273
303
|
*/
|
|
274
304
|
recommendation?: string;
|
|
275
|
-
/**
|
|
276
|
-
* The locale of the current user. Must comply with IETF’s [BCP 47](http://www.rfc-editor.org/rfc/bcp/bcp47.txt) definition.
|
|
277
|
-
*
|
|
278
|
-
* Coveo Machine Learning models use this information to provide contextually relevant output. Moreover, this information can be referred to in query expressions and QPL statements by using the `$locale` object.
|
|
279
|
-
*
|
|
280
|
-
* **Note:** When logging a **Search** usage analytics event, the language field of that event should match the language part of the `locale` value of the query (e.g., `en-US` in `locale` becomes `en` in `language`).
|
|
281
|
-
*
|
|
282
|
-
* @example `en-US`
|
|
283
|
-
*/
|
|
284
|
-
locale?: string;
|
|
285
305
|
/**
|
|
286
306
|
* The format of a successful response.
|
|
287
307
|
*
|
|
@@ -294,16 +314,6 @@ export interface ListFieldValuesBodyQueryParams extends SharedSearchParams {
|
|
|
294
314
|
* @default `json`
|
|
295
315
|
*/
|
|
296
316
|
format?: RestFormat;
|
|
297
|
-
/**
|
|
298
|
-
* The Base64 encoded identifier of the index mirror to forward the request to. See also the `index` parameter.
|
|
299
|
-
*
|
|
300
|
-
* If you do not specify an `indexToken` (or `index`) value, any index mirror could be used.
|
|
301
|
-
*
|
|
302
|
-
* **Note:** Passing an `indexToken` (or `index`) value has no effect when the results of a specific request can be returned from cache (see the `maximumAge` parameter).
|
|
303
|
-
*
|
|
304
|
-
* @example `ZXhhbXBsZWluZGV4bWlycm9yLS4uLg==`
|
|
305
|
-
*/
|
|
306
|
-
indexToken?: string;
|
|
307
317
|
/**
|
|
308
318
|
* A GUID representing the current user, who can be authenticated or anonymous. This GUID is normally generated by the usage analytics service and stored in a non-expiring browser cookie.
|
|
309
319
|
*
|
|
@@ -360,14 +370,6 @@ export interface ListFieldValuesBodyQueryParams extends SharedSearchParams {
|
|
|
360
370
|
* @default `coveo`
|
|
361
371
|
*/
|
|
362
372
|
indexType?: string;
|
|
363
|
-
/**
|
|
364
|
-
* The identifier for a logical group of indexes that have been configured to include documents form the same sources.
|
|
365
|
-
*
|
|
366
|
-
* If you do not specify a `logicalIndex` value, the `default` grouping will be used, typically including all indexes.
|
|
367
|
-
*
|
|
368
|
-
* @example `webcontentonly`
|
|
369
|
-
*/
|
|
370
|
-
logicalIndex?: string;
|
|
371
373
|
/**
|
|
372
374
|
* The maximum number of milliseconds to allow the request to last before timing out. Maximum: 16000
|
|
373
375
|
* Coveo determines the most appropriate timeout to use.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coveo/platform-client",
|
|
3
|
-
"version": "48.3.
|
|
3
|
+
"version": "48.3.2",
|
|
4
4
|
"description": "",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -32,23 +32,23 @@
|
|
|
32
32
|
"prepare": "husky install"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
|
-
"@commitlint/cli": "17.8.
|
|
36
|
-
"@commitlint/config-conventional": "17.8.
|
|
37
|
-
"@types/jest": "29.5.
|
|
38
|
-
"@typescript-eslint/eslint-plugin": "6.
|
|
39
|
-
"@typescript-eslint/parser": "6.
|
|
35
|
+
"@commitlint/cli": "17.8.1",
|
|
36
|
+
"@commitlint/config-conventional": "17.8.1",
|
|
37
|
+
"@types/jest": "29.5.6",
|
|
38
|
+
"@typescript-eslint/eslint-plugin": "6.9.0",
|
|
39
|
+
"@typescript-eslint/parser": "6.9.0",
|
|
40
40
|
"abortcontroller-polyfill": "1.7.5",
|
|
41
41
|
"cz-conventional-changelog": "3.3.0",
|
|
42
|
-
"eslint": "8.
|
|
42
|
+
"eslint": "8.52.0",
|
|
43
43
|
"eslint-config-prettier": "9.0.0",
|
|
44
44
|
"eslint-config-typescript": "3.0.0",
|
|
45
|
-
"eslint-plugin-jest": "27.4.
|
|
45
|
+
"eslint-plugin-jest": "27.4.3",
|
|
46
46
|
"eslint-plugin-prettier": "5.0.1",
|
|
47
47
|
"husky": "8.0.3",
|
|
48
48
|
"jest": "29.7.0",
|
|
49
49
|
"jest-fetch-mock": "3.0.3",
|
|
50
50
|
"jest-runner-eslint": "2.1.2",
|
|
51
|
-
"lint-staged": "15.0.
|
|
51
|
+
"lint-staged": "15.0.2",
|
|
52
52
|
"prettier": "3.0.3",
|
|
53
53
|
"semantic-release": "22.0.5",
|
|
54
54
|
"ts-jest": "29.1.1",
|