@findlane/server 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.d.ts +9 -0
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -99,6 +99,9 @@ export type SearchRequest = {
99
99
  /** Facets (also in `facets`) counted without the filter on their own field, so a list of choices
100
100
  * keeps its other values, with counts, after one is chosen. */
101
101
  disjunctiveFacets?: string[];
102
+ /** Number fields (up to eight) whose smallest and largest values across the matches to return in
103
+ * `facetStats`, such as a price slider's bounds. Each field's own filter is left out. */
104
+ facetStats?: string[];
102
105
  limit?: number;
103
106
  offset?: number;
104
107
  attributesToRetrieve?: string[];
@@ -126,6 +129,12 @@ export type SearchResponse<T> = {
126
129
  totalRelation?: "eq" | "gte";
127
130
  hasMore?: boolean;
128
131
  facets: Record<string, Record<string, number>>;
132
+ /** With `facetStats`: each field's smallest and largest value across the matches, without the field's
133
+ * own filter. A field no match has is left out. */
134
+ facetStats?: Record<string, {
135
+ min: number;
136
+ max: number;
137
+ }>;
129
138
  tookMs: number;
130
139
  sort?: string;
131
140
  /** With the index's `didYouMean` setting: the query with the words typo tolerance corrected, when the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@findlane/server",
3
- "version": "0.3.0",
3
+ "version": "0.4.0",
4
4
  "description": "Findlane server SDK: upload catalogs, manage index settings, and search with a secret workspace API key.",
5
5
  "keywords": ["findlane", "search", "full-text search", "typo tolerance", "ecommerce search", "search api", "sdk"],
6
6
  "license": "MIT",