@wix/search 1.0.48 → 1.0.50
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/build/cjs/index.d.ts +2 -2
- package/build/cjs/index.js +2 -2
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/meta.d.ts +2 -2
- package/build/cjs/meta.js +2 -2
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.ts +2 -2
- package/build/es/index.js +2 -2
- package/build/es/index.js.map +1 -1
- package/build/es/meta.d.ts +2 -2
- package/build/es/meta.js +2 -2
- package/build/es/meta.js.map +1 -1
- package/build/es/package.json +3 -0
- package/build/internal/cjs/index.d.ts +3 -0
- package/build/internal/cjs/index.js +31 -0
- package/build/internal/cjs/index.js.map +1 -0
- package/build/internal/cjs/meta.d.ts +2 -0
- package/build/{cjs/context.js → internal/cjs/meta.js} +3 -3
- package/build/internal/cjs/meta.js.map +1 -0
- package/build/internal/es/index.d.ts +3 -0
- package/build/internal/es/index.js +4 -0
- package/build/internal/es/index.js.map +1 -0
- package/build/internal/es/meta.d.ts +2 -0
- package/build/internal/es/meta.js +3 -0
- package/build/internal/es/meta.js.map +1 -0
- package/meta/package.json +1 -5
- package/package.json +24 -18
- package/build/cjs/context.d.ts +0 -2
- package/build/cjs/context.js.map +0 -1
- package/build/es/context.d.ts +0 -2
- package/build/es/context.js +0 -3
- package/build/es/context.js.map +0 -1
- package/context/package.json +0 -7
- package/type-bundles/context.bundle.d.ts +0 -1828
- package/type-bundles/index.bundle.d.ts +0 -1828
- package/type-bundles/meta.bundle.d.ts +0 -1491
|
@@ -1,1491 +0,0 @@
|
|
|
1
|
-
interface SiteDocument$1 {
|
|
2
|
-
/**
|
|
3
|
-
* Result ID.
|
|
4
|
-
* @readonly
|
|
5
|
-
*/
|
|
6
|
-
id?: string;
|
|
7
|
-
/** The document payload. */
|
|
8
|
-
data?: Record<string, any> | null;
|
|
9
|
-
}
|
|
10
|
-
interface SearchRequest$3 {
|
|
11
|
-
/** Search query and aggregation information. */
|
|
12
|
-
search: Search$1;
|
|
13
|
-
/** Document type to search in. */
|
|
14
|
-
documentType: DocumentType$1;
|
|
15
|
-
/** Language to search in. */
|
|
16
|
-
language?: string | null;
|
|
17
|
-
}
|
|
18
|
-
interface Search$1 extends SearchPagingMethodOneOf$1 {
|
|
19
|
-
/** Paging options to limit and skip the number of items. */
|
|
20
|
-
paging?: Paging$1;
|
|
21
|
-
/**
|
|
22
|
-
* Filter object in the following format:
|
|
23
|
-
* `"filter" : {
|
|
24
|
-
* "fieldName1": "value1",
|
|
25
|
-
* "fieldName2":{"$operator":"value2"}
|
|
26
|
-
* }`
|
|
27
|
-
* Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
|
|
28
|
-
*/
|
|
29
|
-
filter?: Record<string, any> | null;
|
|
30
|
-
/**
|
|
31
|
-
* Sort object in the following format:
|
|
32
|
-
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
33
|
-
*/
|
|
34
|
-
sort?: Sorting$1[];
|
|
35
|
-
/** A search method for grouping data into various categories (facets) and providing summaries for each category. For example, use aggregations to categorize search results by specific price ranges, brand names, or ratings. */
|
|
36
|
-
aggregations?: Aggregation$3[];
|
|
37
|
-
/** Search information. */
|
|
38
|
-
search?: SearchDetails$1;
|
|
39
|
-
}
|
|
40
|
-
/** @oneof */
|
|
41
|
-
interface SearchPagingMethodOneOf$1 {
|
|
42
|
-
/** Paging options to limit and skip the number of items. */
|
|
43
|
-
paging?: Paging$1;
|
|
44
|
-
}
|
|
45
|
-
interface Sorting$1 {
|
|
46
|
-
/** Name of the field to sort by. */
|
|
47
|
-
fieldName?: string;
|
|
48
|
-
/** Sort order. */
|
|
49
|
-
order?: SortOrder$1;
|
|
50
|
-
}
|
|
51
|
-
declare enum SortOrder$1 {
|
|
52
|
-
ASC = "ASC",
|
|
53
|
-
DESC = "DESC"
|
|
54
|
-
}
|
|
55
|
-
interface Aggregation$3 extends AggregationKindOneOf$1 {
|
|
56
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
57
|
-
value?: ValueAggregation$1;
|
|
58
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
59
|
-
scalar?: ScalarAggregation$1;
|
|
60
|
-
/** Pass if `type` is `NESTED`. A nested aggregation is applied to the results of another aggregation. Rather than aggregating directly on the primary dataset, first group data using one aggregation and then apply another aggregation within each group. This allows for more complex analyses that summarize data at different levels of detail or hierarchy. For example, to get the number of products that are in stock and out of stock for each price listed, first perform a value aggregation on the field containing the price, and a second value aggregation on the field indicating whether a product is in stock. You can nest up to a maximum of 3 aggregations. Each aggregation can be either value-based or scalar, allowing flexibility in how the data is grouped and analyzed. */
|
|
61
|
-
nested?: NestedAggregation$1;
|
|
62
|
-
/** Aggregation name displayed in the return. */
|
|
63
|
-
name?: string | null;
|
|
64
|
-
/** Type of aggregation to perform. */
|
|
65
|
-
type?: AggregationType$1;
|
|
66
|
-
/** Field to aggregate by. */
|
|
67
|
-
fieldPath?: string;
|
|
68
|
-
}
|
|
69
|
-
/** @oneof */
|
|
70
|
-
interface AggregationKindOneOf$1 {
|
|
71
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
72
|
-
value?: ValueAggregation$1;
|
|
73
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
74
|
-
scalar?: ScalarAggregation$1;
|
|
75
|
-
/** Pass if `type` is `NESTED`. A nested aggregation is applied to the results of another aggregation. Rather than aggregating directly on the primary dataset, first group data using one aggregation and then apply another aggregation within each group. This allows for more complex analyses that summarize data at different levels of detail or hierarchy. For example, to get the number of products that are in stock and out of stock for each price listed, first perform a value aggregation on the field containing the price, and a second value aggregation on the field indicating whether a product is in stock. You can nest up to a maximum of 3 aggregations. Each aggregation can be either value-based or scalar, allowing flexibility in how the data is grouped and analyzed. */
|
|
76
|
-
nested?: NestedAggregation$1;
|
|
77
|
-
}
|
|
78
|
-
declare enum ScalarType$1 {
|
|
79
|
-
/** Unknown scalar type. */
|
|
80
|
-
UNKNOWN_SCALAR_TYPE = "UNKNOWN_SCALAR_TYPE",
|
|
81
|
-
/** Minimum value. */
|
|
82
|
-
MIN = "MIN",
|
|
83
|
-
/** Maximum value. */
|
|
84
|
-
MAX = "MAX",
|
|
85
|
-
/** Sum of values. */
|
|
86
|
-
SUM = "SUM"
|
|
87
|
-
}
|
|
88
|
-
declare enum NestedAggregationType$1 {
|
|
89
|
-
/** Unknown aggregation type. */
|
|
90
|
-
UNKNOWN_AGGREGATION_TYPE = "UNKNOWN_AGGREGATION_TYPE",
|
|
91
|
-
/** An aggregation where result buckets are dynamically built - one per unique value. */
|
|
92
|
-
VALUE = "VALUE",
|
|
93
|
-
/** A single-value metric aggregation - e.g. min, max, sum, avg. */
|
|
94
|
-
SCALAR = "SCALAR"
|
|
95
|
-
}
|
|
96
|
-
interface ValueAggregation$1 {
|
|
97
|
-
/**
|
|
98
|
-
* Maximum number of aggregation results to return.
|
|
99
|
-
* Min: `1`
|
|
100
|
-
* Max: `250`
|
|
101
|
-
* Default: `10`
|
|
102
|
-
*/
|
|
103
|
-
limit?: number | null;
|
|
104
|
-
}
|
|
105
|
-
interface ScalarAggregation$1 {
|
|
106
|
-
/** Type of scalar aggregation. */
|
|
107
|
-
type?: ScalarType$1;
|
|
108
|
-
}
|
|
109
|
-
interface NestedAggregationItem$1 extends NestedAggregationItemKindOneOf$1 {
|
|
110
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
111
|
-
value?: ValueAggregation$1;
|
|
112
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
113
|
-
scalar?: ScalarAggregation$1;
|
|
114
|
-
/** Aggregation name displayed in the return. */
|
|
115
|
-
name?: string | null;
|
|
116
|
-
/** Type of aggregation to perform. */
|
|
117
|
-
type?: NestedAggregationType$1;
|
|
118
|
-
/** Field to aggregate by. */
|
|
119
|
-
fieldPath?: string;
|
|
120
|
-
}
|
|
121
|
-
/** @oneof */
|
|
122
|
-
interface NestedAggregationItemKindOneOf$1 {
|
|
123
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
124
|
-
value?: ValueAggregation$1;
|
|
125
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
126
|
-
scalar?: ScalarAggregation$1;
|
|
127
|
-
}
|
|
128
|
-
declare enum AggregationType$1 {
|
|
129
|
-
UNKNOWN_AGGREGATION_TYPE = "UNKNOWN_AGGREGATION_TYPE",
|
|
130
|
-
/** An aggregation where result buckets are dynamically built - one per unique value. */
|
|
131
|
-
VALUE = "VALUE",
|
|
132
|
-
/** A single-value metric aggregation - e.g. min, max, sum, avg. */
|
|
133
|
-
SCALAR = "SCALAR",
|
|
134
|
-
/** Multi-level aggregation, where each next aggregation is nested within previous one. */
|
|
135
|
-
NESTED = "NESTED"
|
|
136
|
-
}
|
|
137
|
-
/** List of aggregations. Each aggregation is nested within the previous one. */
|
|
138
|
-
interface NestedAggregation$1 {
|
|
139
|
-
/** List of aggregations, where each aggregation is nested within previous one. */
|
|
140
|
-
nestedAggregations?: NestedAggregationItem$1[];
|
|
141
|
-
}
|
|
142
|
-
interface SearchDetails$1 {
|
|
143
|
-
/** Search term or expression. */
|
|
144
|
-
expression?: string | null;
|
|
145
|
-
/**
|
|
146
|
-
* Fields to search in.
|
|
147
|
-
* If the array is empty, all fields are searched.
|
|
148
|
-
*/
|
|
149
|
-
fields?: string[];
|
|
150
|
-
/** Whether to allow the search function to automatically correct typos or minor mistakes in the search expression. The search function uses an algorithm to find results that are close to the text provided. */
|
|
151
|
-
fuzzy?: boolean;
|
|
152
|
-
}
|
|
153
|
-
interface Paging$1 {
|
|
154
|
-
/** Number of items to load. */
|
|
155
|
-
limit?: number | null;
|
|
156
|
-
/** Number of items to skip in the current sort order. */
|
|
157
|
-
offset?: number | null;
|
|
158
|
-
}
|
|
159
|
-
declare enum DocumentType$1 {
|
|
160
|
-
UNSPECIFIED = "UNSPECIFIED",
|
|
161
|
-
BLOG_POSTS = "BLOG_POSTS",
|
|
162
|
-
BOOKING_SERVICES = "BOOKING_SERVICES",
|
|
163
|
-
EVENTS = "EVENTS",
|
|
164
|
-
FORUM_CONTENT = "FORUM_CONTENT",
|
|
165
|
-
ONLINE_PROGRAMS = "ONLINE_PROGRAMS",
|
|
166
|
-
PROGALLERY_ITEM = "PROGALLERY_ITEM",
|
|
167
|
-
STORES_PRODUCTS = "STORES_PRODUCTS"
|
|
168
|
-
}
|
|
169
|
-
interface SearchResponse$3 extends SearchResponsePagingOneOf$1 {
|
|
170
|
-
/** Paging metadata. */
|
|
171
|
-
pagingOffsetMetadata?: PagingMetadata$1;
|
|
172
|
-
/** Documents matching the search query. */
|
|
173
|
-
siteDocumentItems?: SiteDocument$1[];
|
|
174
|
-
/** Aggregated data. */
|
|
175
|
-
aggregationData?: AggregationData$1;
|
|
176
|
-
}
|
|
177
|
-
/** @oneof */
|
|
178
|
-
interface SearchResponsePagingOneOf$1 {
|
|
179
|
-
/** Paging metadata. */
|
|
180
|
-
pagingOffsetMetadata?: PagingMetadata$1;
|
|
181
|
-
}
|
|
182
|
-
interface AggregationData$1 {
|
|
183
|
-
/** List of the aggregated data results. */
|
|
184
|
-
results?: AggregationResults$1[];
|
|
185
|
-
}
|
|
186
|
-
interface ValueAggregationResult$1 {
|
|
187
|
-
/** Value contained in the field specified in `fieldPath` for this aggregation in the request. */
|
|
188
|
-
value?: string;
|
|
189
|
-
/** Number of documents containing the specified value in the specified field. */
|
|
190
|
-
count?: number;
|
|
191
|
-
}
|
|
192
|
-
interface ValueResults$1 {
|
|
193
|
-
/** List of value aggregation results. */
|
|
194
|
-
results?: ValueAggregationResult$1[];
|
|
195
|
-
}
|
|
196
|
-
interface AggregationResultsScalarResult$1 {
|
|
197
|
-
/** Type of scalar aggregation. */
|
|
198
|
-
type?: ScalarType$1;
|
|
199
|
-
/** Value of the scalar aggregation. For example, the minimum, maximum, or total value for the specified field. */
|
|
200
|
-
value?: number;
|
|
201
|
-
}
|
|
202
|
-
interface ValueResult$1 {
|
|
203
|
-
/** Value contained in the field specified in `fieldPath` for this aggregation in the request. */
|
|
204
|
-
value?: string;
|
|
205
|
-
/** Number of documents containing the specified value in the specified field. */
|
|
206
|
-
count?: number | null;
|
|
207
|
-
}
|
|
208
|
-
interface ScalarResult$1 {
|
|
209
|
-
/** Scalar aggregation results. */
|
|
210
|
-
value?: number;
|
|
211
|
-
}
|
|
212
|
-
interface NestedResultValue$1 extends NestedResultValueResultOneOf$1 {
|
|
213
|
-
/** Value aggregation results. */
|
|
214
|
-
value?: ValueResult$1;
|
|
215
|
-
/** Scalar aggregation results. */
|
|
216
|
-
scalar?: ScalarResult$1;
|
|
217
|
-
}
|
|
218
|
-
/** @oneof */
|
|
219
|
-
interface NestedResultValueResultOneOf$1 {
|
|
220
|
-
/** Value aggregation results. */
|
|
221
|
-
value?: ValueResult$1;
|
|
222
|
-
/** Scalar aggregation results. */
|
|
223
|
-
scalar?: ScalarResult$1;
|
|
224
|
-
}
|
|
225
|
-
interface Results$1 {
|
|
226
|
-
/** Aggregation results. */
|
|
227
|
-
results?: Record<string, NestedResultValue$1>;
|
|
228
|
-
}
|
|
229
|
-
/**
|
|
230
|
-
* Results of `NESTED` aggregation type in a flattened form
|
|
231
|
-
* aggregations in resulting array are keyed by requested aggregation `name`.
|
|
232
|
-
*/
|
|
233
|
-
interface NestedResults$1 {
|
|
234
|
-
/** List of nested aggregation results. */
|
|
235
|
-
results?: Results$1[];
|
|
236
|
-
}
|
|
237
|
-
interface AggregationResults$1 extends AggregationResultsResultOneOf$1 {
|
|
238
|
-
/** Value aggregation results. */
|
|
239
|
-
values?: ValueResults$1;
|
|
240
|
-
/** Scalar aggregation results. */
|
|
241
|
-
scalar?: AggregationResultsScalarResult$1;
|
|
242
|
-
/** Nested aggregation results. */
|
|
243
|
-
nested?: NestedResults$1;
|
|
244
|
-
/** Aggregation name defined in the request. */
|
|
245
|
-
name?: string;
|
|
246
|
-
/** Type of aggregation that was performed. */
|
|
247
|
-
type?: AggregationType$1;
|
|
248
|
-
/** Field the data was aggregated by. */
|
|
249
|
-
fieldPath?: string;
|
|
250
|
-
}
|
|
251
|
-
/** @oneof */
|
|
252
|
-
interface AggregationResultsResultOneOf$1 {
|
|
253
|
-
/** Value aggregation results. */
|
|
254
|
-
values?: ValueResults$1;
|
|
255
|
-
/** Scalar aggregation results. */
|
|
256
|
-
scalar?: AggregationResultsScalarResult$1;
|
|
257
|
-
/** Nested aggregation results. */
|
|
258
|
-
nested?: NestedResults$1;
|
|
259
|
-
}
|
|
260
|
-
interface PagingMetadata$1 {
|
|
261
|
-
/** Number of items returned in the response. */
|
|
262
|
-
count?: number | null;
|
|
263
|
-
/** Offset that was requested. */
|
|
264
|
-
offset?: number | null;
|
|
265
|
-
/** Total number of items that match the query. */
|
|
266
|
-
total?: number | null;
|
|
267
|
-
/** Whether the server failed to calculate the `total` field. */
|
|
268
|
-
tooManyToCount?: boolean | null;
|
|
269
|
-
}
|
|
270
|
-
interface SiteDocumentNonNullableFields$1 {
|
|
271
|
-
id: string;
|
|
272
|
-
}
|
|
273
|
-
interface ValueAggregationResultNonNullableFields$1 {
|
|
274
|
-
value: string;
|
|
275
|
-
count: number;
|
|
276
|
-
}
|
|
277
|
-
interface ValueResultsNonNullableFields$1 {
|
|
278
|
-
results: ValueAggregationResultNonNullableFields$1[];
|
|
279
|
-
}
|
|
280
|
-
interface AggregationResultsScalarResultNonNullableFields$1 {
|
|
281
|
-
type: ScalarType$1;
|
|
282
|
-
value: number;
|
|
283
|
-
}
|
|
284
|
-
interface AggregationResultsNonNullableFields$1 {
|
|
285
|
-
values?: ValueResultsNonNullableFields$1;
|
|
286
|
-
scalar?: AggregationResultsScalarResultNonNullableFields$1;
|
|
287
|
-
name: string;
|
|
288
|
-
type: AggregationType$1;
|
|
289
|
-
fieldPath: string;
|
|
290
|
-
}
|
|
291
|
-
interface AggregationDataNonNullableFields$1 {
|
|
292
|
-
results: AggregationResultsNonNullableFields$1[];
|
|
293
|
-
}
|
|
294
|
-
interface SearchResponseNonNullableFields$3 {
|
|
295
|
-
siteDocumentItems: SiteDocumentNonNullableFields$1[];
|
|
296
|
-
aggregationData?: AggregationDataNonNullableFields$1;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
interface SiteDocument {
|
|
300
|
-
/**
|
|
301
|
-
* Result ID.
|
|
302
|
-
* @readonly
|
|
303
|
-
*/
|
|
304
|
-
_id?: string;
|
|
305
|
-
/** The document payload. */
|
|
306
|
-
data?: Record<string, any> | null;
|
|
307
|
-
}
|
|
308
|
-
interface SearchRequest$2 {
|
|
309
|
-
/** Search query and aggregation information. */
|
|
310
|
-
search: Search;
|
|
311
|
-
/** Document type to search in. */
|
|
312
|
-
documentType: DocumentType;
|
|
313
|
-
/** Language to search in. */
|
|
314
|
-
language?: string | null;
|
|
315
|
-
}
|
|
316
|
-
interface Search extends SearchPagingMethodOneOf {
|
|
317
|
-
/** Paging options to limit and skip the number of items. */
|
|
318
|
-
paging?: Paging;
|
|
319
|
-
/**
|
|
320
|
-
* Filter object in the following format:
|
|
321
|
-
* `"filter" : {
|
|
322
|
-
* "fieldName1": "value1",
|
|
323
|
-
* "fieldName2":{"$operator":"value2"}
|
|
324
|
-
* }`
|
|
325
|
-
* Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
|
|
326
|
-
*/
|
|
327
|
-
filter?: Record<string, any> | null;
|
|
328
|
-
/**
|
|
329
|
-
* Sort object in the following format:
|
|
330
|
-
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
331
|
-
*/
|
|
332
|
-
sort?: Sorting[];
|
|
333
|
-
/** A search method for grouping data into various categories (facets) and providing summaries for each category. For example, use aggregations to categorize search results by specific price ranges, brand names, or ratings. */
|
|
334
|
-
aggregations?: Aggregation$2[];
|
|
335
|
-
/** Search information. */
|
|
336
|
-
search?: SearchDetails;
|
|
337
|
-
}
|
|
338
|
-
/** @oneof */
|
|
339
|
-
interface SearchPagingMethodOneOf {
|
|
340
|
-
/** Paging options to limit and skip the number of items. */
|
|
341
|
-
paging?: Paging;
|
|
342
|
-
}
|
|
343
|
-
interface Sorting {
|
|
344
|
-
/** Name of the field to sort by. */
|
|
345
|
-
fieldName?: string;
|
|
346
|
-
/** Sort order. */
|
|
347
|
-
order?: SortOrder;
|
|
348
|
-
}
|
|
349
|
-
declare enum SortOrder {
|
|
350
|
-
ASC = "ASC",
|
|
351
|
-
DESC = "DESC"
|
|
352
|
-
}
|
|
353
|
-
interface Aggregation$2 extends AggregationKindOneOf {
|
|
354
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
355
|
-
value?: ValueAggregation;
|
|
356
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
357
|
-
scalar?: ScalarAggregation;
|
|
358
|
-
/** Pass if `type` is `NESTED`. A nested aggregation is applied to the results of another aggregation. Rather than aggregating directly on the primary dataset, first group data using one aggregation and then apply another aggregation within each group. This allows for more complex analyses that summarize data at different levels of detail or hierarchy. For example, to get the number of products that are in stock and out of stock for each price listed, first perform a value aggregation on the field containing the price, and a second value aggregation on the field indicating whether a product is in stock. You can nest up to a maximum of 3 aggregations. Each aggregation can be either value-based or scalar, allowing flexibility in how the data is grouped and analyzed. */
|
|
359
|
-
nested?: NestedAggregation;
|
|
360
|
-
/** Aggregation name displayed in the return. */
|
|
361
|
-
name?: string | null;
|
|
362
|
-
/** Type of aggregation to perform. */
|
|
363
|
-
type?: AggregationType;
|
|
364
|
-
/** Field to aggregate by. */
|
|
365
|
-
fieldPath?: string;
|
|
366
|
-
}
|
|
367
|
-
/** @oneof */
|
|
368
|
-
interface AggregationKindOneOf {
|
|
369
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
370
|
-
value?: ValueAggregation;
|
|
371
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
372
|
-
scalar?: ScalarAggregation;
|
|
373
|
-
/** Pass if `type` is `NESTED`. A nested aggregation is applied to the results of another aggregation. Rather than aggregating directly on the primary dataset, first group data using one aggregation and then apply another aggregation within each group. This allows for more complex analyses that summarize data at different levels of detail or hierarchy. For example, to get the number of products that are in stock and out of stock for each price listed, first perform a value aggregation on the field containing the price, and a second value aggregation on the field indicating whether a product is in stock. You can nest up to a maximum of 3 aggregations. Each aggregation can be either value-based or scalar, allowing flexibility in how the data is grouped and analyzed. */
|
|
374
|
-
nested?: NestedAggregation;
|
|
375
|
-
}
|
|
376
|
-
declare enum ScalarType {
|
|
377
|
-
/** Unknown scalar type. */
|
|
378
|
-
UNKNOWN_SCALAR_TYPE = "UNKNOWN_SCALAR_TYPE",
|
|
379
|
-
/** Minimum value. */
|
|
380
|
-
MIN = "MIN",
|
|
381
|
-
/** Maximum value. */
|
|
382
|
-
MAX = "MAX",
|
|
383
|
-
/** Sum of values. */
|
|
384
|
-
SUM = "SUM"
|
|
385
|
-
}
|
|
386
|
-
declare enum NestedAggregationType {
|
|
387
|
-
/** Unknown aggregation type. */
|
|
388
|
-
UNKNOWN_AGGREGATION_TYPE = "UNKNOWN_AGGREGATION_TYPE",
|
|
389
|
-
/** An aggregation where result buckets are dynamically built - one per unique value. */
|
|
390
|
-
VALUE = "VALUE",
|
|
391
|
-
/** A single-value metric aggregation - e.g. min, max, sum, avg. */
|
|
392
|
-
SCALAR = "SCALAR"
|
|
393
|
-
}
|
|
394
|
-
interface ValueAggregation {
|
|
395
|
-
/**
|
|
396
|
-
* Maximum number of aggregation results to return.
|
|
397
|
-
* Min: `1`
|
|
398
|
-
* Max: `250`
|
|
399
|
-
* Default: `10`
|
|
400
|
-
*/
|
|
401
|
-
limit?: number | null;
|
|
402
|
-
}
|
|
403
|
-
interface ScalarAggregation {
|
|
404
|
-
/** Type of scalar aggregation. */
|
|
405
|
-
type?: ScalarType;
|
|
406
|
-
}
|
|
407
|
-
interface NestedAggregationItem extends NestedAggregationItemKindOneOf {
|
|
408
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
409
|
-
value?: ValueAggregation;
|
|
410
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
411
|
-
scalar?: ScalarAggregation;
|
|
412
|
-
/** Aggregation name displayed in the return. */
|
|
413
|
-
name?: string | null;
|
|
414
|
-
/** Type of aggregation to perform. */
|
|
415
|
-
type?: NestedAggregationType;
|
|
416
|
-
/** Field to aggregate by. */
|
|
417
|
-
fieldPath?: string;
|
|
418
|
-
}
|
|
419
|
-
/** @oneof */
|
|
420
|
-
interface NestedAggregationItemKindOneOf {
|
|
421
|
-
/** Pass if `type` is `VALUE`. A value aggregation calculates metrics such as count for specific fields within a dataset, providing insights into the overall distribution and key statistics of those values. For example, use a value aggregation to get the number of products (count) for each price listed in the store. */
|
|
422
|
-
value?: ValueAggregation;
|
|
423
|
-
/** Pass if `type` is `SCALAR`. A scalar aggregation calculates a single numerical value from a dataset, such as the total, minimum, or maximum value, summarizing the dataset into one key metric. For example, use a scalar aggregation to get the minimum price listed in a store. */
|
|
424
|
-
scalar?: ScalarAggregation;
|
|
425
|
-
}
|
|
426
|
-
declare enum AggregationType {
|
|
427
|
-
UNKNOWN_AGGREGATION_TYPE = "UNKNOWN_AGGREGATION_TYPE",
|
|
428
|
-
/** An aggregation where result buckets are dynamically built - one per unique value. */
|
|
429
|
-
VALUE = "VALUE",
|
|
430
|
-
/** A single-value metric aggregation - e.g. min, max, sum, avg. */
|
|
431
|
-
SCALAR = "SCALAR",
|
|
432
|
-
/** Multi-level aggregation, where each next aggregation is nested within previous one. */
|
|
433
|
-
NESTED = "NESTED"
|
|
434
|
-
}
|
|
435
|
-
/** List of aggregations. Each aggregation is nested within the previous one. */
|
|
436
|
-
interface NestedAggregation {
|
|
437
|
-
/** List of aggregations, where each aggregation is nested within previous one. */
|
|
438
|
-
nestedAggregations?: NestedAggregationItem[];
|
|
439
|
-
}
|
|
440
|
-
interface SearchDetails {
|
|
441
|
-
/** Search term or expression. */
|
|
442
|
-
expression?: string | null;
|
|
443
|
-
/**
|
|
444
|
-
* Fields to search in.
|
|
445
|
-
* If the array is empty, all fields are searched.
|
|
446
|
-
*/
|
|
447
|
-
fields?: string[];
|
|
448
|
-
/** Whether to allow the search function to automatically correct typos or minor mistakes in the search expression. The search function uses an algorithm to find results that are close to the text provided. */
|
|
449
|
-
fuzzy?: boolean;
|
|
450
|
-
}
|
|
451
|
-
interface Paging {
|
|
452
|
-
/** Number of items to load. */
|
|
453
|
-
limit?: number | null;
|
|
454
|
-
/** Number of items to skip in the current sort order. */
|
|
455
|
-
offset?: number | null;
|
|
456
|
-
}
|
|
457
|
-
declare enum DocumentType {
|
|
458
|
-
UNSPECIFIED = "UNSPECIFIED",
|
|
459
|
-
BLOG_POSTS = "BLOG_POSTS",
|
|
460
|
-
BOOKING_SERVICES = "BOOKING_SERVICES",
|
|
461
|
-
EVENTS = "EVENTS",
|
|
462
|
-
FORUM_CONTENT = "FORUM_CONTENT",
|
|
463
|
-
ONLINE_PROGRAMS = "ONLINE_PROGRAMS",
|
|
464
|
-
PROGALLERY_ITEM = "PROGALLERY_ITEM",
|
|
465
|
-
STORES_PRODUCTS = "STORES_PRODUCTS"
|
|
466
|
-
}
|
|
467
|
-
interface SearchResponse$2 extends SearchResponsePagingOneOf {
|
|
468
|
-
/** Paging metadata. */
|
|
469
|
-
pagingOffsetMetadata?: PagingMetadata;
|
|
470
|
-
/** Documents matching the search query. */
|
|
471
|
-
siteDocumentItems?: SiteDocument[];
|
|
472
|
-
/** Aggregated data. */
|
|
473
|
-
aggregationData?: AggregationData;
|
|
474
|
-
}
|
|
475
|
-
/** @oneof */
|
|
476
|
-
interface SearchResponsePagingOneOf {
|
|
477
|
-
/** Paging metadata. */
|
|
478
|
-
pagingOffsetMetadata?: PagingMetadata;
|
|
479
|
-
}
|
|
480
|
-
interface AggregationData {
|
|
481
|
-
/** List of the aggregated data results. */
|
|
482
|
-
results?: AggregationResults[];
|
|
483
|
-
}
|
|
484
|
-
interface ValueAggregationResult {
|
|
485
|
-
/** Value contained in the field specified in `fieldPath` for this aggregation in the request. */
|
|
486
|
-
value?: string;
|
|
487
|
-
/** Number of documents containing the specified value in the specified field. */
|
|
488
|
-
count?: number;
|
|
489
|
-
}
|
|
490
|
-
interface ValueResults {
|
|
491
|
-
/** List of value aggregation results. */
|
|
492
|
-
results?: ValueAggregationResult[];
|
|
493
|
-
}
|
|
494
|
-
interface AggregationResultsScalarResult {
|
|
495
|
-
/** Type of scalar aggregation. */
|
|
496
|
-
type?: ScalarType;
|
|
497
|
-
/** Value of the scalar aggregation. For example, the minimum, maximum, or total value for the specified field. */
|
|
498
|
-
value?: number;
|
|
499
|
-
}
|
|
500
|
-
interface ValueResult {
|
|
501
|
-
/** Value contained in the field specified in `fieldPath` for this aggregation in the request. */
|
|
502
|
-
value?: string;
|
|
503
|
-
/** Number of documents containing the specified value in the specified field. */
|
|
504
|
-
count?: number | null;
|
|
505
|
-
}
|
|
506
|
-
interface ScalarResult {
|
|
507
|
-
/** Scalar aggregation results. */
|
|
508
|
-
value?: number;
|
|
509
|
-
}
|
|
510
|
-
interface NestedResultValue extends NestedResultValueResultOneOf {
|
|
511
|
-
/** Value aggregation results. */
|
|
512
|
-
value?: ValueResult;
|
|
513
|
-
/** Scalar aggregation results. */
|
|
514
|
-
scalar?: ScalarResult;
|
|
515
|
-
}
|
|
516
|
-
/** @oneof */
|
|
517
|
-
interface NestedResultValueResultOneOf {
|
|
518
|
-
/** Value aggregation results. */
|
|
519
|
-
value?: ValueResult;
|
|
520
|
-
/** Scalar aggregation results. */
|
|
521
|
-
scalar?: ScalarResult;
|
|
522
|
-
}
|
|
523
|
-
interface Results {
|
|
524
|
-
/** Aggregation results. */
|
|
525
|
-
results?: Record<string, NestedResultValue>;
|
|
526
|
-
}
|
|
527
|
-
/**
|
|
528
|
-
* Results of `NESTED` aggregation type in a flattened form
|
|
529
|
-
* aggregations in resulting array are keyed by requested aggregation `name`.
|
|
530
|
-
*/
|
|
531
|
-
interface NestedResults {
|
|
532
|
-
/** List of nested aggregation results. */
|
|
533
|
-
results?: Results[];
|
|
534
|
-
}
|
|
535
|
-
interface AggregationResults extends AggregationResultsResultOneOf {
|
|
536
|
-
/** Value aggregation results. */
|
|
537
|
-
values?: ValueResults;
|
|
538
|
-
/** Scalar aggregation results. */
|
|
539
|
-
scalar?: AggregationResultsScalarResult;
|
|
540
|
-
/** Nested aggregation results. */
|
|
541
|
-
nested?: NestedResults;
|
|
542
|
-
/** Aggregation name defined in the request. */
|
|
543
|
-
name?: string;
|
|
544
|
-
/** Type of aggregation that was performed. */
|
|
545
|
-
type?: AggregationType;
|
|
546
|
-
/** Field the data was aggregated by. */
|
|
547
|
-
fieldPath?: string;
|
|
548
|
-
}
|
|
549
|
-
/** @oneof */
|
|
550
|
-
interface AggregationResultsResultOneOf {
|
|
551
|
-
/** Value aggregation results. */
|
|
552
|
-
values?: ValueResults;
|
|
553
|
-
/** Scalar aggregation results. */
|
|
554
|
-
scalar?: AggregationResultsScalarResult;
|
|
555
|
-
/** Nested aggregation results. */
|
|
556
|
-
nested?: NestedResults;
|
|
557
|
-
}
|
|
558
|
-
interface PagingMetadata {
|
|
559
|
-
/** Number of items returned in the response. */
|
|
560
|
-
count?: number | null;
|
|
561
|
-
/** Offset that was requested. */
|
|
562
|
-
offset?: number | null;
|
|
563
|
-
/** Total number of items that match the query. */
|
|
564
|
-
total?: number | null;
|
|
565
|
-
/** Whether the server failed to calculate the `total` field. */
|
|
566
|
-
tooManyToCount?: boolean | null;
|
|
567
|
-
}
|
|
568
|
-
interface SiteDocumentNonNullableFields {
|
|
569
|
-
_id: string;
|
|
570
|
-
}
|
|
571
|
-
interface ValueAggregationResultNonNullableFields {
|
|
572
|
-
value: string;
|
|
573
|
-
count: number;
|
|
574
|
-
}
|
|
575
|
-
interface ValueResultsNonNullableFields {
|
|
576
|
-
results: ValueAggregationResultNonNullableFields[];
|
|
577
|
-
}
|
|
578
|
-
interface AggregationResultsScalarResultNonNullableFields {
|
|
579
|
-
type: ScalarType;
|
|
580
|
-
value: number;
|
|
581
|
-
}
|
|
582
|
-
interface AggregationResultsNonNullableFields {
|
|
583
|
-
values?: ValueResultsNonNullableFields;
|
|
584
|
-
scalar?: AggregationResultsScalarResultNonNullableFields;
|
|
585
|
-
name: string;
|
|
586
|
-
type: AggregationType;
|
|
587
|
-
fieldPath: string;
|
|
588
|
-
}
|
|
589
|
-
interface AggregationDataNonNullableFields {
|
|
590
|
-
results: AggregationResultsNonNullableFields[];
|
|
591
|
-
}
|
|
592
|
-
interface SearchResponseNonNullableFields$2 {
|
|
593
|
-
siteDocumentItems: SiteDocumentNonNullableFields[];
|
|
594
|
-
aggregationData?: AggregationDataNonNullableFields;
|
|
595
|
-
}
|
|
596
|
-
|
|
597
|
-
type __PublicMethodMetaInfo$1<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
598
|
-
getUrl: (context: any) => string;
|
|
599
|
-
httpMethod: K;
|
|
600
|
-
path: string;
|
|
601
|
-
pathParams: M;
|
|
602
|
-
__requestType: T;
|
|
603
|
-
__originalRequestType: S;
|
|
604
|
-
__responseType: Q;
|
|
605
|
-
__originalResponseType: R;
|
|
606
|
-
};
|
|
607
|
-
declare function search$1(): __PublicMethodMetaInfo$1<'POST', {}, SearchRequest$2, SearchRequest$3, SearchResponse$2 & SearchResponseNonNullableFields$2, SearchResponse$3 & SearchResponseNonNullableFields$3>;
|
|
608
|
-
|
|
609
|
-
declare namespace meta$1 {
|
|
610
|
-
export { type __PublicMethodMetaInfo$1 as __PublicMethodMetaInfo, search$1 as search };
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
interface SearchRequest$1 {
|
|
614
|
-
/** Text to search for. All searchable fields will be searched. */
|
|
615
|
-
query?: string | null;
|
|
616
|
-
/** Document type of documents to search for. All document types are searched if not provided. */
|
|
617
|
-
documentType?: string | null;
|
|
618
|
-
/** Fields to order by. */
|
|
619
|
-
ordering?: OrderingClauses$1;
|
|
620
|
-
/** Paging parameters. */
|
|
621
|
-
paging?: SearchPaging$1;
|
|
622
|
-
/** Language to search in. */
|
|
623
|
-
language?: string | null;
|
|
624
|
-
/** Filter in platformized query language (for example {'field': {'$eq': 'value'}}) */
|
|
625
|
-
filter?: Record<string, any> | null;
|
|
626
|
-
/** The facets to retrieve. */
|
|
627
|
-
facets?: FacetClauses$1;
|
|
628
|
-
/** Enable fuzzy search (eg. query 'kalvin clein' will match document with 'calvin klein' in title). */
|
|
629
|
-
fuzzy?: boolean | null;
|
|
630
|
-
/** Highlight texts matching the query. Highlighted text will be wrapped with <mark/> tag. Defaults to true if not provided. */
|
|
631
|
-
highlight?: boolean | null;
|
|
632
|
-
/** Searchable fields to search in. If not provided, search is executed on all searchable fields in schema */
|
|
633
|
-
searchFields?: string[];
|
|
634
|
-
/** A list of fields to include in the result set. If not provided, all fields of schema will be included. */
|
|
635
|
-
fields?: string[];
|
|
636
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
637
|
-
properties?: SearchProperty$1[];
|
|
638
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
639
|
-
includeSeoHidden?: boolean | null;
|
|
640
|
-
}
|
|
641
|
-
interface OrderingClauses$1 {
|
|
642
|
-
ordering?: OrderingClause$1[];
|
|
643
|
-
}
|
|
644
|
-
interface OrderingClause$1 {
|
|
645
|
-
fieldName?: string | null;
|
|
646
|
-
direction?: Direction$1;
|
|
647
|
-
}
|
|
648
|
-
declare enum Direction$1 {
|
|
649
|
-
UninitializedDirection = "UninitializedDirection",
|
|
650
|
-
ASC = "ASC",
|
|
651
|
-
DESC = "DESC"
|
|
652
|
-
}
|
|
653
|
-
interface SearchPaging$1 {
|
|
654
|
-
/**
|
|
655
|
-
* Number of items to skip in the result set.
|
|
656
|
-
* @deprecated
|
|
657
|
-
*/
|
|
658
|
-
skip?: number;
|
|
659
|
-
/** Number of items to fetch (effectively page size). */
|
|
660
|
-
limit?: number;
|
|
661
|
-
/** Number of items to skip in the result set. */
|
|
662
|
-
offset?: number;
|
|
663
|
-
}
|
|
664
|
-
interface FacetClauses$1 {
|
|
665
|
-
/** Each entry represents a single facet with parameters. */
|
|
666
|
-
clauses?: FacetClause$1[];
|
|
667
|
-
}
|
|
668
|
-
interface FacetClause$1 extends FacetClauseClauseOneOf$1 {
|
|
669
|
-
term?: TermFacet$1;
|
|
670
|
-
aggregation?: AggregationFacet$1;
|
|
671
|
-
hierarchical?: HierarchicalFacet$1;
|
|
672
|
-
}
|
|
673
|
-
/** @oneof */
|
|
674
|
-
interface FacetClauseClauseOneOf$1 {
|
|
675
|
-
term?: TermFacet$1;
|
|
676
|
-
aggregation?: AggregationFacet$1;
|
|
677
|
-
hierarchical?: HierarchicalFacet$1;
|
|
678
|
-
}
|
|
679
|
-
declare enum Aggregation$1 {
|
|
680
|
-
MIN = "MIN",
|
|
681
|
-
MAX = "MAX",
|
|
682
|
-
SUM = "SUM"
|
|
683
|
-
}
|
|
684
|
-
interface HierarchicalFacet$1 extends HierarchicalFacetClauseOneOf$1 {
|
|
685
|
-
term?: TermFacet$1;
|
|
686
|
-
aggregation?: AggregationFacet$1;
|
|
687
|
-
nestedAggregation?: HierarchicalFacet$1;
|
|
688
|
-
}
|
|
689
|
-
/** @oneof */
|
|
690
|
-
interface HierarchicalFacetClauseOneOf$1 {
|
|
691
|
-
term?: TermFacet$1;
|
|
692
|
-
aggregation?: AggregationFacet$1;
|
|
693
|
-
}
|
|
694
|
-
interface TermFacet$1 {
|
|
695
|
-
/** The name of the faceted attribute. */
|
|
696
|
-
name?: string;
|
|
697
|
-
/** Limit the number of facet values returned. Default is 10. */
|
|
698
|
-
limit?: number | null;
|
|
699
|
-
}
|
|
700
|
-
interface AggregationFacet$1 {
|
|
701
|
-
/** The name of the faceted attribute. */
|
|
702
|
-
name?: string;
|
|
703
|
-
/** Aggregation type. */
|
|
704
|
-
aggregation?: Aggregation$1;
|
|
705
|
-
}
|
|
706
|
-
interface SearchProperty$1 {
|
|
707
|
-
name?: string;
|
|
708
|
-
value?: any;
|
|
709
|
-
}
|
|
710
|
-
interface SearchResponse$1 {
|
|
711
|
-
/** Documents matching filter and query. */
|
|
712
|
-
documents?: Record<string, any>[] | null;
|
|
713
|
-
nextPage?: NextPageResponse$1;
|
|
714
|
-
/**
|
|
715
|
-
* Facets provide "counts in categories" view. For example searching for "Nike" would return
|
|
716
|
-
* (Shoes, 5), (Socks, 2) indicating numbers for matching by each faceted field.
|
|
717
|
-
*/
|
|
718
|
-
facets?: FacetsResponse$1[];
|
|
719
|
-
}
|
|
720
|
-
interface NextPageResponse$1 {
|
|
721
|
-
/** Total number of items across all pages */
|
|
722
|
-
total?: number;
|
|
723
|
-
/** The number of items to skip */
|
|
724
|
-
skip?: number;
|
|
725
|
-
/** The number of items to retrieve in one page */
|
|
726
|
-
limit?: number;
|
|
727
|
-
}
|
|
728
|
-
interface FacetsResponse$1 extends FacetsResponseResponseOneOf$1 {
|
|
729
|
-
terms?: TermAggregationResponse$1;
|
|
730
|
-
minAggregation?: MinAggregationResponse$1;
|
|
731
|
-
maxAggregation?: MaxAggregationResponse$1;
|
|
732
|
-
minMaxAggregation?: MinMaxAggregationResponse$1;
|
|
733
|
-
hierarchicalAggregation?: HierarchicalAggregationResponse$1;
|
|
734
|
-
sumAggregation?: SumAggregationResponse$1;
|
|
735
|
-
}
|
|
736
|
-
/** @oneof */
|
|
737
|
-
interface FacetsResponseResponseOneOf$1 {
|
|
738
|
-
terms?: TermAggregationResponse$1;
|
|
739
|
-
minAggregation?: MinAggregationResponse$1;
|
|
740
|
-
maxAggregation?: MaxAggregationResponse$1;
|
|
741
|
-
minMaxAggregation?: MinMaxAggregationResponse$1;
|
|
742
|
-
hierarchicalAggregation?: HierarchicalAggregationResponse$1;
|
|
743
|
-
sumAggregation?: SumAggregationResponse$1;
|
|
744
|
-
}
|
|
745
|
-
interface FacetCountResponse$1 {
|
|
746
|
-
/** Facet field value (for example "Shoes", "Socks") */
|
|
747
|
-
facetValue?: string;
|
|
748
|
-
/** Document count within the group */
|
|
749
|
-
count?: number;
|
|
750
|
-
}
|
|
751
|
-
interface Value$1 {
|
|
752
|
-
value?: string;
|
|
753
|
-
facets?: FacetsResponse$1;
|
|
754
|
-
count?: number;
|
|
755
|
-
}
|
|
756
|
-
interface TermAggregationResponse$1 {
|
|
757
|
-
/** Facet field (for example productCategory) */
|
|
758
|
-
facet?: string;
|
|
759
|
-
/** Facet values and document counts */
|
|
760
|
-
facets?: FacetCountResponse$1[];
|
|
761
|
-
}
|
|
762
|
-
interface MinAggregationResponse$1 {
|
|
763
|
-
/** Facet field (for example productPrice) */
|
|
764
|
-
facet?: string;
|
|
765
|
-
/** The minimum value across all documents */
|
|
766
|
-
minValue?: number | null;
|
|
767
|
-
}
|
|
768
|
-
interface MaxAggregationResponse$1 {
|
|
769
|
-
/** Facet field (for example productPrice) */
|
|
770
|
-
facet?: string;
|
|
771
|
-
/** The maximum value across all documents */
|
|
772
|
-
maxValue?: number | null;
|
|
773
|
-
}
|
|
774
|
-
interface MinMaxAggregationResponse$1 {
|
|
775
|
-
/** Facet field (for example productPrice) */
|
|
776
|
-
facet?: string;
|
|
777
|
-
/** The minimum value across all documents */
|
|
778
|
-
minValue?: number | null;
|
|
779
|
-
/** The maximum value across all documents */
|
|
780
|
-
maxValue?: number | null;
|
|
781
|
-
}
|
|
782
|
-
interface HierarchicalAggregationResponse$1 {
|
|
783
|
-
facet?: string;
|
|
784
|
-
values?: Value$1[];
|
|
785
|
-
}
|
|
786
|
-
interface SumAggregationResponse$1 {
|
|
787
|
-
/** Facet field (for example productPrice) */
|
|
788
|
-
facet?: string;
|
|
789
|
-
/** The sum value across all documents */
|
|
790
|
-
value?: number | null;
|
|
791
|
-
}
|
|
792
|
-
interface FederatedSearchRequest$1 {
|
|
793
|
-
/** Query phrase to use. */
|
|
794
|
-
query?: string | null;
|
|
795
|
-
/** Language to search in. */
|
|
796
|
-
language?: string | null;
|
|
797
|
-
/** Limit of documents to return per document type. */
|
|
798
|
-
limit?: number | null;
|
|
799
|
-
/** Enable fuzzy search (for example query 'kalvin clein' will match document with 'calvin klein' in title). */
|
|
800
|
-
fuzzy?: boolean | null;
|
|
801
|
-
/** Highlight texts matching the query. Highlighted text will be wrapped with <mark/> tag. Defaults to true if not provided. */
|
|
802
|
-
highlight?: boolean | null;
|
|
803
|
-
/** Searchable fields to search in. If not provided, search is executed on all searchable fields in schemas */
|
|
804
|
-
searchFields?: string[];
|
|
805
|
-
/** Document types to search in. If not provided, search is executed on all document types enabled for the site */
|
|
806
|
-
documentTypes?: string[];
|
|
807
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
808
|
-
includeSeoHidden?: boolean | null;
|
|
809
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
810
|
-
properties?: SearchProperty$1[];
|
|
811
|
-
}
|
|
812
|
-
interface FederatedSearchResponse$1 {
|
|
813
|
-
/** Search results from multiple indexes. */
|
|
814
|
-
results?: FederatedSearchDocuments$1[];
|
|
815
|
-
}
|
|
816
|
-
interface FederatedSearchDocuments$1 {
|
|
817
|
-
/** Document type of documents */
|
|
818
|
-
documentType?: string | null;
|
|
819
|
-
/** Documents of document type */
|
|
820
|
-
documents?: Record<string, any>[] | null;
|
|
821
|
-
/** Total count of matching documents for document type */
|
|
822
|
-
total?: number;
|
|
823
|
-
}
|
|
824
|
-
interface SuggestRequest$1 {
|
|
825
|
-
/** Text to search for. Fields configured in suggester configuration will be searched. */
|
|
826
|
-
query?: string | null;
|
|
827
|
-
/** Document type of documents to search for. All document types are searched if not provided. */
|
|
828
|
-
documentType?: string | null;
|
|
829
|
-
/** Fields to order by. */
|
|
830
|
-
ordering?: OrderingClauses$1;
|
|
831
|
-
/** Number of suggested document to return. */
|
|
832
|
-
limit?: number;
|
|
833
|
-
/** Language to search in. */
|
|
834
|
-
language?: string | null;
|
|
835
|
-
/** Filter in platformized query language (for example {'field': {'$eq': 'value'}}) */
|
|
836
|
-
filter?: Record<string, any> | null;
|
|
837
|
-
/** Searchable fields to search in. If not provided, search is executed on all suggestable fields in schema */
|
|
838
|
-
searchFields?: string[];
|
|
839
|
-
/** A list of fields to include in the result set. If not provided, all fields of schema will be included. */
|
|
840
|
-
fields?: string[];
|
|
841
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
842
|
-
includeSeoHidden?: boolean | null;
|
|
843
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
844
|
-
properties?: SearchProperty$1[];
|
|
845
|
-
}
|
|
846
|
-
interface SuggestResponse$1 {
|
|
847
|
-
/** Suggested documents. */
|
|
848
|
-
documents?: Record<string, any>[] | null;
|
|
849
|
-
}
|
|
850
|
-
interface FederatedSuggestRequest$1 {
|
|
851
|
-
/** Text to search for. Fields configured in suggester configuration will be searched. */
|
|
852
|
-
query?: string | null;
|
|
853
|
-
/** Language to search in. */
|
|
854
|
-
language?: string | null;
|
|
855
|
-
/** Number of suggested document to return per document type. */
|
|
856
|
-
limit?: number;
|
|
857
|
-
/** Searchable fields to search in. If not provided, search is executed on all suggestable fields in schemas */
|
|
858
|
-
searchFields?: string[];
|
|
859
|
-
/** Document types to search in. If not provided, search is executed on all document types enabled for the site */
|
|
860
|
-
documentTypes?: string[];
|
|
861
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
862
|
-
includeSeoHidden?: boolean | null;
|
|
863
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
864
|
-
properties?: SearchProperty$1[];
|
|
865
|
-
}
|
|
866
|
-
interface FederatedSuggestResponse$1 {
|
|
867
|
-
/** Suggest results from multiple indexes. */
|
|
868
|
-
results?: FederatedSuggestDocuments$1[];
|
|
869
|
-
}
|
|
870
|
-
interface FederatedSuggestDocuments$1 {
|
|
871
|
-
/** Document type of documents */
|
|
872
|
-
documentType?: string | null;
|
|
873
|
-
/** Documents of document type */
|
|
874
|
-
documents?: Record<string, any>[] | null;
|
|
875
|
-
}
|
|
876
|
-
interface RelatedRequest$1 {
|
|
877
|
-
/** ID of the document to fetch related documents for. */
|
|
878
|
-
documentId?: string | null;
|
|
879
|
-
/** Document type of the document. */
|
|
880
|
-
documentType?: string | null;
|
|
881
|
-
/** Fields to order by. */
|
|
882
|
-
ordering?: OrderingClauses$1;
|
|
883
|
-
/** Language to search in. */
|
|
884
|
-
language?: string | null;
|
|
885
|
-
/** Filter in platformized query language (for example {'field': {'$eq': 'value'}}). */
|
|
886
|
-
filter?: Record<string, any> | null;
|
|
887
|
-
/** Searchable fields to compare documents by. If not provided, all searchable fields in schema are used */
|
|
888
|
-
searchFields?: string[];
|
|
889
|
-
/** A list of fields to include in the result set. If not provided, all fields of schema will be included. */
|
|
890
|
-
fields?: string[];
|
|
891
|
-
/** Number of related documents to return */
|
|
892
|
-
limit?: number;
|
|
893
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`. */
|
|
894
|
-
properties?: SearchProperty$1[];
|
|
895
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
896
|
-
includeSeoHidden?: boolean | null;
|
|
897
|
-
}
|
|
898
|
-
interface RelatedResponse$1 {
|
|
899
|
-
/** Documents matching filter and query. */
|
|
900
|
-
documents?: Record<string, any>[] | null;
|
|
901
|
-
}
|
|
902
|
-
interface AutocompleteRequest$1 {
|
|
903
|
-
/** Query phrase to fetch completions for. */
|
|
904
|
-
query?: string | null;
|
|
905
|
-
/** Document type to use to search for phrases. */
|
|
906
|
-
documentType?: string | null;
|
|
907
|
-
/** Limit of phrases to fetch. */
|
|
908
|
-
limit?: number;
|
|
909
|
-
/** Language to search in. */
|
|
910
|
-
language?: string | null;
|
|
911
|
-
/** Filter in platfromized query language (for example {'field': {'$eq': 'value'}}) */
|
|
912
|
-
filter?: Record<string, any> | null;
|
|
913
|
-
/** Searchable fields to use for query completion. If not provided, all searchable fields in schema are used */
|
|
914
|
-
searchFields?: string[];
|
|
915
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
916
|
-
includeSeoHidden?: boolean | null;
|
|
917
|
-
}
|
|
918
|
-
interface AutocompleteResponse$1 {
|
|
919
|
-
/** Suggested phrases. */
|
|
920
|
-
values?: AutocompleteResponseValue$1[];
|
|
921
|
-
}
|
|
922
|
-
interface AutocompleteResponseValue$1 {
|
|
923
|
-
/** Suggested phrase. */
|
|
924
|
-
query?: string;
|
|
925
|
-
}
|
|
926
|
-
interface FederatedAutocompleteRequest$1 {
|
|
927
|
-
/** Query phrase to fetch completions for. */
|
|
928
|
-
query?: string | null;
|
|
929
|
-
/** Language to search in. */
|
|
930
|
-
language?: string | null;
|
|
931
|
-
/** Number of queries to return per document type. */
|
|
932
|
-
limit?: number;
|
|
933
|
-
/** Searchable fields to search in. If not provided, search is executed on all autocompletable fields in schemas */
|
|
934
|
-
searchFields?: string[];
|
|
935
|
-
/** Document types to autocomplete in. If not provided, autocomplete is executed on all document types enabled for the site */
|
|
936
|
-
documentTypes?: string[];
|
|
937
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
938
|
-
includeSeoHidden?: boolean | null;
|
|
939
|
-
}
|
|
940
|
-
interface FederatedAutocompleteResponse$1 {
|
|
941
|
-
/** Suggested phrases from multiple indexes */
|
|
942
|
-
results?: FederatedAutocompleteResults$1[];
|
|
943
|
-
}
|
|
944
|
-
interface FederatedAutocompleteResults$1 {
|
|
945
|
-
/** Document type of queries */
|
|
946
|
-
documentType?: string | null;
|
|
947
|
-
/** Suggested phrases */
|
|
948
|
-
values?: AutocompleteResponseValue$1[];
|
|
949
|
-
}
|
|
950
|
-
interface TrendingRequest$1 {
|
|
951
|
-
documentTypes?: string[];
|
|
952
|
-
language?: string | null;
|
|
953
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
954
|
-
includeSeoHidden?: boolean | null;
|
|
955
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
956
|
-
properties?: SearchProperty$1[];
|
|
957
|
-
}
|
|
958
|
-
interface TrendingResponse$1 {
|
|
959
|
-
results?: TrendingItems$1[];
|
|
960
|
-
}
|
|
961
|
-
interface TrendingItems$1 {
|
|
962
|
-
documentType?: string;
|
|
963
|
-
documents?: Record<string, any>[] | null;
|
|
964
|
-
}
|
|
965
|
-
interface NextPageResponseNonNullableFields$1 {
|
|
966
|
-
total: number;
|
|
967
|
-
skip: number;
|
|
968
|
-
limit: number;
|
|
969
|
-
}
|
|
970
|
-
interface FacetCountResponseNonNullableFields$1 {
|
|
971
|
-
facetValue: string;
|
|
972
|
-
count: number;
|
|
973
|
-
}
|
|
974
|
-
interface TermAggregationResponseNonNullableFields$1 {
|
|
975
|
-
facet: string;
|
|
976
|
-
facets: FacetCountResponseNonNullableFields$1[];
|
|
977
|
-
}
|
|
978
|
-
interface MinAggregationResponseNonNullableFields$1 {
|
|
979
|
-
facet: string;
|
|
980
|
-
}
|
|
981
|
-
interface MaxAggregationResponseNonNullableFields$1 {
|
|
982
|
-
facet: string;
|
|
983
|
-
}
|
|
984
|
-
interface MinMaxAggregationResponseNonNullableFields$1 {
|
|
985
|
-
facet: string;
|
|
986
|
-
}
|
|
987
|
-
interface ValueNonNullableFields$1 {
|
|
988
|
-
value: string;
|
|
989
|
-
facets?: FacetsResponseNonNullableFields$1;
|
|
990
|
-
count: number;
|
|
991
|
-
}
|
|
992
|
-
interface HierarchicalAggregationResponseNonNullableFields$1 {
|
|
993
|
-
facet: string;
|
|
994
|
-
values: ValueNonNullableFields$1[];
|
|
995
|
-
}
|
|
996
|
-
interface SumAggregationResponseNonNullableFields$1 {
|
|
997
|
-
facet: string;
|
|
998
|
-
}
|
|
999
|
-
interface FacetsResponseNonNullableFields$1 {
|
|
1000
|
-
terms?: TermAggregationResponseNonNullableFields$1;
|
|
1001
|
-
minAggregation?: MinAggregationResponseNonNullableFields$1;
|
|
1002
|
-
maxAggregation?: MaxAggregationResponseNonNullableFields$1;
|
|
1003
|
-
minMaxAggregation?: MinMaxAggregationResponseNonNullableFields$1;
|
|
1004
|
-
hierarchicalAggregation?: HierarchicalAggregationResponseNonNullableFields$1;
|
|
1005
|
-
sumAggregation?: SumAggregationResponseNonNullableFields$1;
|
|
1006
|
-
}
|
|
1007
|
-
interface SearchResponseNonNullableFields$1 {
|
|
1008
|
-
nextPage?: NextPageResponseNonNullableFields$1;
|
|
1009
|
-
facets: FacetsResponseNonNullableFields$1[];
|
|
1010
|
-
}
|
|
1011
|
-
interface FederatedSearchDocumentsNonNullableFields$1 {
|
|
1012
|
-
total: number;
|
|
1013
|
-
}
|
|
1014
|
-
interface FederatedSearchResponseNonNullableFields$1 {
|
|
1015
|
-
results: FederatedSearchDocumentsNonNullableFields$1[];
|
|
1016
|
-
}
|
|
1017
|
-
interface AutocompleteResponseValueNonNullableFields$1 {
|
|
1018
|
-
query: string;
|
|
1019
|
-
}
|
|
1020
|
-
interface AutocompleteResponseNonNullableFields$1 {
|
|
1021
|
-
values: AutocompleteResponseValueNonNullableFields$1[];
|
|
1022
|
-
}
|
|
1023
|
-
interface FederatedAutocompleteResultsNonNullableFields$1 {
|
|
1024
|
-
values: AutocompleteResponseValueNonNullableFields$1[];
|
|
1025
|
-
}
|
|
1026
|
-
interface FederatedAutocompleteResponseNonNullableFields$1 {
|
|
1027
|
-
results: FederatedAutocompleteResultsNonNullableFields$1[];
|
|
1028
|
-
}
|
|
1029
|
-
interface TrendingItemsNonNullableFields$1 {
|
|
1030
|
-
documentType: string;
|
|
1031
|
-
}
|
|
1032
|
-
interface TrendingResponseNonNullableFields$1 {
|
|
1033
|
-
results: TrendingItemsNonNullableFields$1[];
|
|
1034
|
-
}
|
|
1035
|
-
|
|
1036
|
-
interface SearchRequest {
|
|
1037
|
-
/** Text to search for. All searchable fields will be searched. */
|
|
1038
|
-
query?: string | null;
|
|
1039
|
-
/** Document type of documents to search for. All document types are searched if not provided. */
|
|
1040
|
-
documentType?: string | null;
|
|
1041
|
-
/** Fields to order by. */
|
|
1042
|
-
ordering?: OrderingClauses;
|
|
1043
|
-
/** Paging parameters. */
|
|
1044
|
-
paging?: SearchPaging;
|
|
1045
|
-
/** Language to search in. */
|
|
1046
|
-
language?: string | null;
|
|
1047
|
-
/** Filter in platformized query language (for example {'field': {'$eq': 'value'}}) */
|
|
1048
|
-
filter?: Record<string, any> | null;
|
|
1049
|
-
/** The facets to retrieve. */
|
|
1050
|
-
facets?: FacetClauses;
|
|
1051
|
-
/** Enable fuzzy search (eg. query 'kalvin clein' will match document with 'calvin klein' in title). */
|
|
1052
|
-
fuzzy?: boolean | null;
|
|
1053
|
-
/** Highlight texts matching the query. Highlighted text will be wrapped with <mark/> tag. Defaults to true if not provided. */
|
|
1054
|
-
highlight?: boolean | null;
|
|
1055
|
-
/** Searchable fields to search in. If not provided, search is executed on all searchable fields in schema */
|
|
1056
|
-
searchFields?: string[];
|
|
1057
|
-
/** A list of fields to include in the result set. If not provided, all fields of schema will be included. */
|
|
1058
|
-
fields?: string[];
|
|
1059
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
1060
|
-
properties?: SearchProperty[];
|
|
1061
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1062
|
-
includeSeoHidden?: boolean | null;
|
|
1063
|
-
}
|
|
1064
|
-
interface OrderingClauses {
|
|
1065
|
-
ordering?: OrderingClause[];
|
|
1066
|
-
}
|
|
1067
|
-
interface OrderingClause {
|
|
1068
|
-
fieldName?: string | null;
|
|
1069
|
-
direction?: Direction;
|
|
1070
|
-
}
|
|
1071
|
-
declare enum Direction {
|
|
1072
|
-
UninitializedDirection = "UninitializedDirection",
|
|
1073
|
-
ASC = "ASC",
|
|
1074
|
-
DESC = "DESC"
|
|
1075
|
-
}
|
|
1076
|
-
interface SearchPaging {
|
|
1077
|
-
/**
|
|
1078
|
-
* Number of items to skip in the result set.
|
|
1079
|
-
* @deprecated
|
|
1080
|
-
*/
|
|
1081
|
-
skip?: number;
|
|
1082
|
-
/** Number of items to fetch (effectively page size). */
|
|
1083
|
-
limit?: number;
|
|
1084
|
-
/** Number of items to skip in the result set. */
|
|
1085
|
-
offset?: number;
|
|
1086
|
-
}
|
|
1087
|
-
interface FacetClauses {
|
|
1088
|
-
/** Each entry represents a single facet with parameters. */
|
|
1089
|
-
clauses?: FacetClause[];
|
|
1090
|
-
}
|
|
1091
|
-
interface FacetClause extends FacetClauseClauseOneOf {
|
|
1092
|
-
term?: TermFacet;
|
|
1093
|
-
aggregation?: AggregationFacet;
|
|
1094
|
-
hierarchical?: HierarchicalFacet;
|
|
1095
|
-
}
|
|
1096
|
-
/** @oneof */
|
|
1097
|
-
interface FacetClauseClauseOneOf {
|
|
1098
|
-
term?: TermFacet;
|
|
1099
|
-
aggregation?: AggregationFacet;
|
|
1100
|
-
hierarchical?: HierarchicalFacet;
|
|
1101
|
-
}
|
|
1102
|
-
declare enum Aggregation {
|
|
1103
|
-
MIN = "MIN",
|
|
1104
|
-
MAX = "MAX",
|
|
1105
|
-
SUM = "SUM"
|
|
1106
|
-
}
|
|
1107
|
-
interface HierarchicalFacet extends HierarchicalFacetClauseOneOf {
|
|
1108
|
-
term?: TermFacet;
|
|
1109
|
-
aggregation?: AggregationFacet;
|
|
1110
|
-
nestedAggregation?: HierarchicalFacet;
|
|
1111
|
-
}
|
|
1112
|
-
/** @oneof */
|
|
1113
|
-
interface HierarchicalFacetClauseOneOf {
|
|
1114
|
-
term?: TermFacet;
|
|
1115
|
-
aggregation?: AggregationFacet;
|
|
1116
|
-
}
|
|
1117
|
-
interface TermFacet {
|
|
1118
|
-
/** The name of the faceted attribute. */
|
|
1119
|
-
name?: string;
|
|
1120
|
-
/** Limit the number of facet values returned. Default is 10. */
|
|
1121
|
-
limit?: number | null;
|
|
1122
|
-
}
|
|
1123
|
-
interface AggregationFacet {
|
|
1124
|
-
/** The name of the faceted attribute. */
|
|
1125
|
-
name?: string;
|
|
1126
|
-
/** Aggregation type. */
|
|
1127
|
-
aggregation?: Aggregation;
|
|
1128
|
-
}
|
|
1129
|
-
interface SearchProperty {
|
|
1130
|
-
name?: string;
|
|
1131
|
-
value?: any;
|
|
1132
|
-
}
|
|
1133
|
-
interface SearchResponse {
|
|
1134
|
-
/** Documents matching filter and query. */
|
|
1135
|
-
documents?: Record<string, any>[] | null;
|
|
1136
|
-
nextPage?: NextPageResponse;
|
|
1137
|
-
/**
|
|
1138
|
-
* Facets provide "counts in categories" view. For example searching for "Nike" would return
|
|
1139
|
-
* (Shoes, 5), (Socks, 2) indicating numbers for matching by each faceted field.
|
|
1140
|
-
*/
|
|
1141
|
-
facets?: FacetsResponse[];
|
|
1142
|
-
}
|
|
1143
|
-
interface NextPageResponse {
|
|
1144
|
-
/** Total number of items across all pages */
|
|
1145
|
-
total?: number;
|
|
1146
|
-
/** The number of items to skip */
|
|
1147
|
-
skip?: number;
|
|
1148
|
-
/** The number of items to retrieve in one page */
|
|
1149
|
-
limit?: number;
|
|
1150
|
-
}
|
|
1151
|
-
interface FacetsResponse extends FacetsResponseResponseOneOf {
|
|
1152
|
-
terms?: TermAggregationResponse;
|
|
1153
|
-
minAggregation?: MinAggregationResponse;
|
|
1154
|
-
maxAggregation?: MaxAggregationResponse;
|
|
1155
|
-
minMaxAggregation?: MinMaxAggregationResponse;
|
|
1156
|
-
hierarchicalAggregation?: HierarchicalAggregationResponse;
|
|
1157
|
-
sumAggregation?: SumAggregationResponse;
|
|
1158
|
-
}
|
|
1159
|
-
/** @oneof */
|
|
1160
|
-
interface FacetsResponseResponseOneOf {
|
|
1161
|
-
terms?: TermAggregationResponse;
|
|
1162
|
-
minAggregation?: MinAggregationResponse;
|
|
1163
|
-
maxAggregation?: MaxAggregationResponse;
|
|
1164
|
-
minMaxAggregation?: MinMaxAggregationResponse;
|
|
1165
|
-
hierarchicalAggregation?: HierarchicalAggregationResponse;
|
|
1166
|
-
sumAggregation?: SumAggregationResponse;
|
|
1167
|
-
}
|
|
1168
|
-
interface FacetCountResponse {
|
|
1169
|
-
/** Facet field value (for example "Shoes", "Socks") */
|
|
1170
|
-
facetValue?: string;
|
|
1171
|
-
/** Document count within the group */
|
|
1172
|
-
count?: number;
|
|
1173
|
-
}
|
|
1174
|
-
interface Value {
|
|
1175
|
-
value?: string;
|
|
1176
|
-
facets?: FacetsResponse;
|
|
1177
|
-
count?: number;
|
|
1178
|
-
}
|
|
1179
|
-
interface TermAggregationResponse {
|
|
1180
|
-
/** Facet field (for example productCategory) */
|
|
1181
|
-
facet?: string;
|
|
1182
|
-
/** Facet values and document counts */
|
|
1183
|
-
facets?: FacetCountResponse[];
|
|
1184
|
-
}
|
|
1185
|
-
interface MinAggregationResponse {
|
|
1186
|
-
/** Facet field (for example productPrice) */
|
|
1187
|
-
facet?: string;
|
|
1188
|
-
/** The minimum value across all documents */
|
|
1189
|
-
minValue?: number | null;
|
|
1190
|
-
}
|
|
1191
|
-
interface MaxAggregationResponse {
|
|
1192
|
-
/** Facet field (for example productPrice) */
|
|
1193
|
-
facet?: string;
|
|
1194
|
-
/** The maximum value across all documents */
|
|
1195
|
-
maxValue?: number | null;
|
|
1196
|
-
}
|
|
1197
|
-
interface MinMaxAggregationResponse {
|
|
1198
|
-
/** Facet field (for example productPrice) */
|
|
1199
|
-
facet?: string;
|
|
1200
|
-
/** The minimum value across all documents */
|
|
1201
|
-
minValue?: number | null;
|
|
1202
|
-
/** The maximum value across all documents */
|
|
1203
|
-
maxValue?: number | null;
|
|
1204
|
-
}
|
|
1205
|
-
interface HierarchicalAggregationResponse {
|
|
1206
|
-
facet?: string;
|
|
1207
|
-
values?: Value[];
|
|
1208
|
-
}
|
|
1209
|
-
interface SumAggregationResponse {
|
|
1210
|
-
/** Facet field (for example productPrice) */
|
|
1211
|
-
facet?: string;
|
|
1212
|
-
/** The sum value across all documents */
|
|
1213
|
-
value?: number | null;
|
|
1214
|
-
}
|
|
1215
|
-
interface FederatedSearchRequest {
|
|
1216
|
-
/** Query phrase to use. */
|
|
1217
|
-
query?: string | null;
|
|
1218
|
-
/** Language to search in. */
|
|
1219
|
-
language?: string | null;
|
|
1220
|
-
/** Limit of documents to return per document type. */
|
|
1221
|
-
limit?: number | null;
|
|
1222
|
-
/** Enable fuzzy search (for example query 'kalvin clein' will match document with 'calvin klein' in title). */
|
|
1223
|
-
fuzzy?: boolean | null;
|
|
1224
|
-
/** Highlight texts matching the query. Highlighted text will be wrapped with <mark/> tag. Defaults to true if not provided. */
|
|
1225
|
-
highlight?: boolean | null;
|
|
1226
|
-
/** Searchable fields to search in. If not provided, search is executed on all searchable fields in schemas */
|
|
1227
|
-
searchFields?: string[];
|
|
1228
|
-
/** Document types to search in. If not provided, search is executed on all document types enabled for the site */
|
|
1229
|
-
documentTypes?: string[];
|
|
1230
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1231
|
-
includeSeoHidden?: boolean | null;
|
|
1232
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
1233
|
-
properties?: SearchProperty[];
|
|
1234
|
-
}
|
|
1235
|
-
interface FederatedSearchResponse {
|
|
1236
|
-
/** Search results from multiple indexes. */
|
|
1237
|
-
results?: FederatedSearchDocuments[];
|
|
1238
|
-
}
|
|
1239
|
-
interface FederatedSearchDocuments {
|
|
1240
|
-
/** Document type of documents */
|
|
1241
|
-
documentType?: string | null;
|
|
1242
|
-
/** Documents of document type */
|
|
1243
|
-
documents?: Record<string, any>[] | null;
|
|
1244
|
-
/** Total count of matching documents for document type */
|
|
1245
|
-
total?: number;
|
|
1246
|
-
}
|
|
1247
|
-
interface SuggestRequest {
|
|
1248
|
-
/** Text to search for. Fields configured in suggester configuration will be searched. */
|
|
1249
|
-
query?: string | null;
|
|
1250
|
-
/** Document type of documents to search for. All document types are searched if not provided. */
|
|
1251
|
-
documentType?: string | null;
|
|
1252
|
-
/** Fields to order by. */
|
|
1253
|
-
ordering?: OrderingClauses;
|
|
1254
|
-
/** Number of suggested document to return. */
|
|
1255
|
-
limit?: number;
|
|
1256
|
-
/** Language to search in. */
|
|
1257
|
-
language?: string | null;
|
|
1258
|
-
/** Filter in platformized query language (for example {'field': {'$eq': 'value'}}) */
|
|
1259
|
-
filter?: Record<string, any> | null;
|
|
1260
|
-
/** Searchable fields to search in. If not provided, search is executed on all suggestable fields in schema */
|
|
1261
|
-
searchFields?: string[];
|
|
1262
|
-
/** A list of fields to include in the result set. If not provided, all fields of schema will be included. */
|
|
1263
|
-
fields?: string[];
|
|
1264
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1265
|
-
includeSeoHidden?: boolean | null;
|
|
1266
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
1267
|
-
properties?: SearchProperty[];
|
|
1268
|
-
}
|
|
1269
|
-
interface SuggestResponse {
|
|
1270
|
-
/** Suggested documents. */
|
|
1271
|
-
documents?: Record<string, any>[] | null;
|
|
1272
|
-
}
|
|
1273
|
-
interface FederatedSuggestRequest {
|
|
1274
|
-
/** Text to search for. Fields configured in suggester configuration will be searched. */
|
|
1275
|
-
query?: string | null;
|
|
1276
|
-
/** Language to search in. */
|
|
1277
|
-
language?: string | null;
|
|
1278
|
-
/** Number of suggested document to return per document type. */
|
|
1279
|
-
limit?: number;
|
|
1280
|
-
/** Searchable fields to search in. If not provided, search is executed on all suggestable fields in schemas */
|
|
1281
|
-
searchFields?: string[];
|
|
1282
|
-
/** Document types to search in. If not provided, search is executed on all document types enabled for the site */
|
|
1283
|
-
documentTypes?: string[];
|
|
1284
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1285
|
-
includeSeoHidden?: boolean | null;
|
|
1286
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
1287
|
-
properties?: SearchProperty[];
|
|
1288
|
-
}
|
|
1289
|
-
interface FederatedSuggestResponse {
|
|
1290
|
-
/** Suggest results from multiple indexes. */
|
|
1291
|
-
results?: FederatedSuggestDocuments[];
|
|
1292
|
-
}
|
|
1293
|
-
interface FederatedSuggestDocuments {
|
|
1294
|
-
/** Document type of documents */
|
|
1295
|
-
documentType?: string | null;
|
|
1296
|
-
/** Documents of document type */
|
|
1297
|
-
documents?: Record<string, any>[] | null;
|
|
1298
|
-
}
|
|
1299
|
-
interface RelatedRequest {
|
|
1300
|
-
/** ID of the document to fetch related documents for. */
|
|
1301
|
-
documentId?: string | null;
|
|
1302
|
-
/** Document type of the document. */
|
|
1303
|
-
documentType?: string | null;
|
|
1304
|
-
/** Fields to order by. */
|
|
1305
|
-
ordering?: OrderingClauses;
|
|
1306
|
-
/** Language to search in. */
|
|
1307
|
-
language?: string | null;
|
|
1308
|
-
/** Filter in platformized query language (for example {'field': {'$eq': 'value'}}). */
|
|
1309
|
-
filter?: Record<string, any> | null;
|
|
1310
|
-
/** Searchable fields to compare documents by. If not provided, all searchable fields in schema are used */
|
|
1311
|
-
searchFields?: string[];
|
|
1312
|
-
/** A list of fields to include in the result set. If not provided, all fields of schema will be included. */
|
|
1313
|
-
fields?: string[];
|
|
1314
|
-
/** Number of related documents to return */
|
|
1315
|
-
limit?: number;
|
|
1316
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`. */
|
|
1317
|
-
properties?: SearchProperty[];
|
|
1318
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1319
|
-
includeSeoHidden?: boolean | null;
|
|
1320
|
-
}
|
|
1321
|
-
interface RelatedResponse {
|
|
1322
|
-
/** Documents matching filter and query. */
|
|
1323
|
-
documents?: Record<string, any>[] | null;
|
|
1324
|
-
}
|
|
1325
|
-
interface AutocompleteRequest {
|
|
1326
|
-
/** Query phrase to fetch completions for. */
|
|
1327
|
-
query?: string | null;
|
|
1328
|
-
/** Document type to use to search for phrases. */
|
|
1329
|
-
documentType?: string | null;
|
|
1330
|
-
/** Limit of phrases to fetch. */
|
|
1331
|
-
limit?: number;
|
|
1332
|
-
/** Language to search in. */
|
|
1333
|
-
language?: string | null;
|
|
1334
|
-
/** Filter in platfromized query language (for example {'field': {'$eq': 'value'}}) */
|
|
1335
|
-
filter?: Record<string, any> | null;
|
|
1336
|
-
/** Searchable fields to use for query completion. If not provided, all searchable fields in schema are used */
|
|
1337
|
-
searchFields?: string[];
|
|
1338
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1339
|
-
includeSeoHidden?: boolean | null;
|
|
1340
|
-
}
|
|
1341
|
-
interface AutocompleteResponse {
|
|
1342
|
-
/** Suggested phrases. */
|
|
1343
|
-
values?: AutocompleteResponseValue[];
|
|
1344
|
-
}
|
|
1345
|
-
interface AutocompleteResponseValue {
|
|
1346
|
-
/** Suggested phrase. */
|
|
1347
|
-
query?: string;
|
|
1348
|
-
}
|
|
1349
|
-
interface FederatedAutocompleteRequest {
|
|
1350
|
-
/** Query phrase to fetch completions for. */
|
|
1351
|
-
query?: string | null;
|
|
1352
|
-
/** Language to search in. */
|
|
1353
|
-
language?: string | null;
|
|
1354
|
-
/** Number of queries to return per document type. */
|
|
1355
|
-
limit?: number;
|
|
1356
|
-
/** Searchable fields to search in. If not provided, search is executed on all autocompletable fields in schemas */
|
|
1357
|
-
searchFields?: string[];
|
|
1358
|
-
/** Document types to autocomplete in. If not provided, autocomplete is executed on all document types enabled for the site */
|
|
1359
|
-
documentTypes?: string[];
|
|
1360
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1361
|
-
includeSeoHidden?: boolean | null;
|
|
1362
|
-
}
|
|
1363
|
-
interface FederatedAutocompleteResponse {
|
|
1364
|
-
/** Suggested phrases from multiple indexes */
|
|
1365
|
-
results?: FederatedAutocompleteResults[];
|
|
1366
|
-
}
|
|
1367
|
-
interface FederatedAutocompleteResults {
|
|
1368
|
-
/** Document type of queries */
|
|
1369
|
-
documentType?: string | null;
|
|
1370
|
-
/** Suggested phrases */
|
|
1371
|
-
values?: AutocompleteResponseValue[];
|
|
1372
|
-
}
|
|
1373
|
-
interface TrendingRequest {
|
|
1374
|
-
documentTypes?: string[];
|
|
1375
|
-
language?: string | null;
|
|
1376
|
-
/** Include seo hidden documents. Defaults to false if not provided. */
|
|
1377
|
-
includeSeoHidden?: boolean | null;
|
|
1378
|
-
/** The properties/overrides/experiments to enable for this request. Currently supported: `scoring_profile`, `result-format`. */
|
|
1379
|
-
properties?: SearchProperty[];
|
|
1380
|
-
}
|
|
1381
|
-
interface TrendingResponse {
|
|
1382
|
-
results?: TrendingItems[];
|
|
1383
|
-
}
|
|
1384
|
-
interface TrendingItems {
|
|
1385
|
-
documentType?: string;
|
|
1386
|
-
documents?: Record<string, any>[] | null;
|
|
1387
|
-
}
|
|
1388
|
-
interface NextPageResponseNonNullableFields {
|
|
1389
|
-
total: number;
|
|
1390
|
-
skip: number;
|
|
1391
|
-
limit: number;
|
|
1392
|
-
}
|
|
1393
|
-
interface FacetCountResponseNonNullableFields {
|
|
1394
|
-
facetValue: string;
|
|
1395
|
-
count: number;
|
|
1396
|
-
}
|
|
1397
|
-
interface TermAggregationResponseNonNullableFields {
|
|
1398
|
-
facet: string;
|
|
1399
|
-
facets: FacetCountResponseNonNullableFields[];
|
|
1400
|
-
}
|
|
1401
|
-
interface MinAggregationResponseNonNullableFields {
|
|
1402
|
-
facet: string;
|
|
1403
|
-
}
|
|
1404
|
-
interface MaxAggregationResponseNonNullableFields {
|
|
1405
|
-
facet: string;
|
|
1406
|
-
}
|
|
1407
|
-
interface MinMaxAggregationResponseNonNullableFields {
|
|
1408
|
-
facet: string;
|
|
1409
|
-
}
|
|
1410
|
-
interface ValueNonNullableFields {
|
|
1411
|
-
value: string;
|
|
1412
|
-
facets?: FacetsResponseNonNullableFields;
|
|
1413
|
-
count: number;
|
|
1414
|
-
}
|
|
1415
|
-
interface HierarchicalAggregationResponseNonNullableFields {
|
|
1416
|
-
facet: string;
|
|
1417
|
-
values: ValueNonNullableFields[];
|
|
1418
|
-
}
|
|
1419
|
-
interface SumAggregationResponseNonNullableFields {
|
|
1420
|
-
facet: string;
|
|
1421
|
-
}
|
|
1422
|
-
interface FacetsResponseNonNullableFields {
|
|
1423
|
-
terms?: TermAggregationResponseNonNullableFields;
|
|
1424
|
-
minAggregation?: MinAggregationResponseNonNullableFields;
|
|
1425
|
-
maxAggregation?: MaxAggregationResponseNonNullableFields;
|
|
1426
|
-
minMaxAggregation?: MinMaxAggregationResponseNonNullableFields;
|
|
1427
|
-
hierarchicalAggregation?: HierarchicalAggregationResponseNonNullableFields;
|
|
1428
|
-
sumAggregation?: SumAggregationResponseNonNullableFields;
|
|
1429
|
-
}
|
|
1430
|
-
interface SearchResponseNonNullableFields {
|
|
1431
|
-
nextPage?: NextPageResponseNonNullableFields;
|
|
1432
|
-
facets: FacetsResponseNonNullableFields[];
|
|
1433
|
-
}
|
|
1434
|
-
interface FederatedSearchDocumentsNonNullableFields {
|
|
1435
|
-
total: number;
|
|
1436
|
-
}
|
|
1437
|
-
interface FederatedSearchResponseNonNullableFields {
|
|
1438
|
-
results: FederatedSearchDocumentsNonNullableFields[];
|
|
1439
|
-
}
|
|
1440
|
-
interface AutocompleteResponseValueNonNullableFields {
|
|
1441
|
-
query: string;
|
|
1442
|
-
}
|
|
1443
|
-
interface AutocompleteResponseNonNullableFields {
|
|
1444
|
-
values: AutocompleteResponseValueNonNullableFields[];
|
|
1445
|
-
}
|
|
1446
|
-
interface FederatedAutocompleteResultsNonNullableFields {
|
|
1447
|
-
values: AutocompleteResponseValueNonNullableFields[];
|
|
1448
|
-
}
|
|
1449
|
-
interface FederatedAutocompleteResponseNonNullableFields {
|
|
1450
|
-
results: FederatedAutocompleteResultsNonNullableFields[];
|
|
1451
|
-
}
|
|
1452
|
-
interface TrendingItemsNonNullableFields {
|
|
1453
|
-
documentType: string;
|
|
1454
|
-
}
|
|
1455
|
-
interface TrendingResponseNonNullableFields {
|
|
1456
|
-
results: TrendingItemsNonNullableFields[];
|
|
1457
|
-
}
|
|
1458
|
-
|
|
1459
|
-
type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
1460
|
-
getUrl: (context: any) => string;
|
|
1461
|
-
httpMethod: K;
|
|
1462
|
-
path: string;
|
|
1463
|
-
pathParams: M;
|
|
1464
|
-
__requestType: T;
|
|
1465
|
-
__originalRequestType: S;
|
|
1466
|
-
__responseType: Q;
|
|
1467
|
-
__originalResponseType: R;
|
|
1468
|
-
};
|
|
1469
|
-
declare function search(): __PublicMethodMetaInfo<'POST', {}, SearchRequest, SearchRequest$1, SearchResponse & SearchResponseNonNullableFields, SearchResponse$1 & SearchResponseNonNullableFields$1>;
|
|
1470
|
-
declare function federatedSearch(): __PublicMethodMetaInfo<'POST', {}, FederatedSearchRequest, FederatedSearchRequest$1, FederatedSearchResponse & FederatedSearchResponseNonNullableFields, FederatedSearchResponse$1 & FederatedSearchResponseNonNullableFields$1>;
|
|
1471
|
-
declare function suggest(): __PublicMethodMetaInfo<'POST', {}, SuggestRequest, SuggestRequest$1, SuggestResponse, SuggestResponse$1>;
|
|
1472
|
-
declare function federatedSuggest(): __PublicMethodMetaInfo<'POST', {}, FederatedSuggestRequest, FederatedSuggestRequest$1, FederatedSuggestResponse, FederatedSuggestResponse$1>;
|
|
1473
|
-
declare function related(): __PublicMethodMetaInfo<'POST', {}, RelatedRequest, RelatedRequest$1, RelatedResponse, RelatedResponse$1>;
|
|
1474
|
-
declare function autocomplete(): __PublicMethodMetaInfo<'POST', {}, AutocompleteRequest, AutocompleteRequest$1, AutocompleteResponse & AutocompleteResponseNonNullableFields, AutocompleteResponse$1 & AutocompleteResponseNonNullableFields$1>;
|
|
1475
|
-
declare function federatedAutocomplete(): __PublicMethodMetaInfo<'POST', {}, FederatedAutocompleteRequest, FederatedAutocompleteRequest$1, FederatedAutocompleteResponse & FederatedAutocompleteResponseNonNullableFields, FederatedAutocompleteResponse$1 & FederatedAutocompleteResponseNonNullableFields$1>;
|
|
1476
|
-
declare function trending(): __PublicMethodMetaInfo<'POST', {}, TrendingRequest, TrendingRequest$1, TrendingResponse & TrendingResponseNonNullableFields, TrendingResponse$1 & TrendingResponseNonNullableFields$1>;
|
|
1477
|
-
|
|
1478
|
-
type meta___PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = __PublicMethodMetaInfo<K, M, T, S, Q, R>;
|
|
1479
|
-
declare const meta_autocomplete: typeof autocomplete;
|
|
1480
|
-
declare const meta_federatedAutocomplete: typeof federatedAutocomplete;
|
|
1481
|
-
declare const meta_federatedSearch: typeof federatedSearch;
|
|
1482
|
-
declare const meta_federatedSuggest: typeof federatedSuggest;
|
|
1483
|
-
declare const meta_related: typeof related;
|
|
1484
|
-
declare const meta_search: typeof search;
|
|
1485
|
-
declare const meta_suggest: typeof suggest;
|
|
1486
|
-
declare const meta_trending: typeof trending;
|
|
1487
|
-
declare namespace meta {
|
|
1488
|
-
export { type meta___PublicMethodMetaInfo as __PublicMethodMetaInfo, meta_autocomplete as autocomplete, meta_federatedAutocomplete as federatedAutocomplete, meta_federatedSearch as federatedSearch, meta_federatedSuggest as federatedSuggest, meta_related as related, meta_search as search, meta_suggest as suggest, meta_trending as trending };
|
|
1489
|
-
}
|
|
1490
|
-
|
|
1491
|
-
export { meta as siteSearch, meta$1 as wixSiteSearch };
|