exa-js 2.0.0 → 2.0.3
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/index.d.mts +20 -11
- package/dist/index.d.ts +20 -11
- package/dist/index.js +9 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +9 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1549,14 +1549,16 @@ interface components {
|
|
|
1549
1549
|
type: "person";
|
|
1550
1550
|
};
|
|
1551
1551
|
PreviewWebsetParameters: {
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1552
|
+
search: {
|
|
1553
|
+
/** @description Entity used to inform the decomposition.
|
|
1554
|
+
*
|
|
1555
|
+
* It is not required to provide it, we automatically detect the entity from all the information provided in the query. Only use this when you need more fine control. */
|
|
1556
|
+
entity?: components["schemas"]["Entity"];
|
|
1557
|
+
/** @description Natural language search query describing what you are looking for.
|
|
1558
|
+
*
|
|
1559
|
+
* Be specific and descriptive about your requirements, characteristics, and any constraints that help narrow down the results. */
|
|
1560
|
+
query: string;
|
|
1561
|
+
};
|
|
1560
1562
|
};
|
|
1561
1563
|
PreviewWebsetResponse: {
|
|
1562
1564
|
/** @description Detected enrichments from the query. */
|
|
@@ -1734,6 +1736,12 @@ interface components {
|
|
|
1734
1736
|
createdAt: string;
|
|
1735
1737
|
/** @description The Enrichments to apply to the Webset Items. */
|
|
1736
1738
|
enrichments: components["schemas"]["WebsetEnrichment"][];
|
|
1739
|
+
/** @description The Excludes sources (existing imports or websets) that apply to all operations within this Webset. Any results found within these sources will be omitted across all search and import operations. */
|
|
1740
|
+
excludes?: {
|
|
1741
|
+
id: string;
|
|
1742
|
+
/** @enum {string} */
|
|
1743
|
+
source: WebsetExcludeSource;
|
|
1744
|
+
}[];
|
|
1737
1745
|
/** @description The external identifier for the webset */
|
|
1738
1746
|
externalId: string | null;
|
|
1739
1747
|
/** @description The unique identifier for the webset */
|
|
@@ -1762,8 +1770,6 @@ interface components {
|
|
|
1762
1770
|
* @enum {string}
|
|
1763
1771
|
*/
|
|
1764
1772
|
status: WebsetStatus;
|
|
1765
|
-
/** @description The Streams for the Webset. */
|
|
1766
|
-
streams: unknown[];
|
|
1767
1773
|
/** @description The title of the webset */
|
|
1768
1774
|
title: string | null;
|
|
1769
1775
|
/**
|
|
@@ -2865,9 +2871,12 @@ declare class WebsetsClient extends WebsetsBaseClient {
|
|
|
2865
2871
|
/**
|
|
2866
2872
|
* Preview a webset
|
|
2867
2873
|
* @param params The preview parameters
|
|
2874
|
+
* @param options Optional parameters. Search = true allows you to retrieve a preview set of items that could be returned by the webset.
|
|
2868
2875
|
* @returns The preview response showing how the query will be decomposed
|
|
2869
2876
|
*/
|
|
2870
|
-
preview(params: PreviewWebsetParameters
|
|
2877
|
+
preview(params: PreviewWebsetParameters, options?: {
|
|
2878
|
+
search?: boolean;
|
|
2879
|
+
}): Promise<PreviewWebsetResponse>;
|
|
2871
2880
|
/**
|
|
2872
2881
|
* Get a Webset by ID
|
|
2873
2882
|
* @param id The ID of the Webset
|
package/dist/index.d.ts
CHANGED
|
@@ -1549,14 +1549,16 @@ interface components {
|
|
|
1549
1549
|
type: "person";
|
|
1550
1550
|
};
|
|
1551
1551
|
PreviewWebsetParameters: {
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1552
|
+
search: {
|
|
1553
|
+
/** @description Entity used to inform the decomposition.
|
|
1554
|
+
*
|
|
1555
|
+
* It is not required to provide it, we automatically detect the entity from all the information provided in the query. Only use this when you need more fine control. */
|
|
1556
|
+
entity?: components["schemas"]["Entity"];
|
|
1557
|
+
/** @description Natural language search query describing what you are looking for.
|
|
1558
|
+
*
|
|
1559
|
+
* Be specific and descriptive about your requirements, characteristics, and any constraints that help narrow down the results. */
|
|
1560
|
+
query: string;
|
|
1561
|
+
};
|
|
1560
1562
|
};
|
|
1561
1563
|
PreviewWebsetResponse: {
|
|
1562
1564
|
/** @description Detected enrichments from the query. */
|
|
@@ -1734,6 +1736,12 @@ interface components {
|
|
|
1734
1736
|
createdAt: string;
|
|
1735
1737
|
/** @description The Enrichments to apply to the Webset Items. */
|
|
1736
1738
|
enrichments: components["schemas"]["WebsetEnrichment"][];
|
|
1739
|
+
/** @description The Excludes sources (existing imports or websets) that apply to all operations within this Webset. Any results found within these sources will be omitted across all search and import operations. */
|
|
1740
|
+
excludes?: {
|
|
1741
|
+
id: string;
|
|
1742
|
+
/** @enum {string} */
|
|
1743
|
+
source: WebsetExcludeSource;
|
|
1744
|
+
}[];
|
|
1737
1745
|
/** @description The external identifier for the webset */
|
|
1738
1746
|
externalId: string | null;
|
|
1739
1747
|
/** @description The unique identifier for the webset */
|
|
@@ -1762,8 +1770,6 @@ interface components {
|
|
|
1762
1770
|
* @enum {string}
|
|
1763
1771
|
*/
|
|
1764
1772
|
status: WebsetStatus;
|
|
1765
|
-
/** @description The Streams for the Webset. */
|
|
1766
|
-
streams: unknown[];
|
|
1767
1773
|
/** @description The title of the webset */
|
|
1768
1774
|
title: string | null;
|
|
1769
1775
|
/**
|
|
@@ -2865,9 +2871,12 @@ declare class WebsetsClient extends WebsetsBaseClient {
|
|
|
2865
2871
|
/**
|
|
2866
2872
|
* Preview a webset
|
|
2867
2873
|
* @param params The preview parameters
|
|
2874
|
+
* @param options Optional parameters. Search = true allows you to retrieve a preview set of items that could be returned by the webset.
|
|
2868
2875
|
* @returns The preview response showing how the query will be decomposed
|
|
2869
2876
|
*/
|
|
2870
|
-
preview(params: PreviewWebsetParameters
|
|
2877
|
+
preview(params: PreviewWebsetParameters, options?: {
|
|
2878
|
+
search?: boolean;
|
|
2879
|
+
}): Promise<PreviewWebsetResponse>;
|
|
2871
2880
|
/**
|
|
2872
2881
|
* Get a Webset by ID
|
|
2873
2882
|
* @param id The ID of the Webset
|
package/dist/index.js
CHANGED
|
@@ -74,7 +74,7 @@ var import_cross_fetch = __toESM(require("cross-fetch"));
|
|
|
74
74
|
// package.json
|
|
75
75
|
var package_default = {
|
|
76
76
|
name: "exa-js",
|
|
77
|
-
version: "2.0.
|
|
77
|
+
version: "2.0.3",
|
|
78
78
|
description: "Exa SDK for Node.js and the browser",
|
|
79
79
|
publishConfig: {
|
|
80
80
|
access: "public"
|
|
@@ -1191,13 +1191,19 @@ var WebsetsClient = class extends WebsetsBaseClient {
|
|
|
1191
1191
|
/**
|
|
1192
1192
|
* Preview a webset
|
|
1193
1193
|
* @param params The preview parameters
|
|
1194
|
+
* @param options Optional parameters. Search = true allows you to retrieve a preview set of items that could be returned by the webset.
|
|
1194
1195
|
* @returns The preview response showing how the query will be decomposed
|
|
1195
1196
|
*/
|
|
1196
|
-
async preview(params) {
|
|
1197
|
+
async preview(params, options) {
|
|
1198
|
+
const queryParams = {};
|
|
1199
|
+
if (options?.search !== void 0) {
|
|
1200
|
+
queryParams.search = options.search;
|
|
1201
|
+
}
|
|
1197
1202
|
return this.request(
|
|
1198
1203
|
"/v0/websets/preview",
|
|
1199
1204
|
"POST",
|
|
1200
|
-
params
|
|
1205
|
+
params,
|
|
1206
|
+
queryParams
|
|
1201
1207
|
);
|
|
1202
1208
|
}
|
|
1203
1209
|
/**
|