exa-js 2.0.8 → 2.0.10

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 CHANGED
@@ -2997,6 +2997,7 @@ declare class ExaError extends Error {
2997
2997
  * Options for retrieving page contents
2998
2998
  * @typedef {Object} ContentsOptions
2999
2999
  * @property {TextContentsOptions | boolean} [text] - Options for retrieving text contents.
3000
+ * @property {HighlightsContentsOptions | boolean} [highlights] - Options for retrieving highlights. NOTE: For search type "deep", only "true" is allowed. "query", "numSentences" and "highlightsPerUrl" will not be respected.
3000
3001
  * @property {SummaryContentsOptions | boolean} [summary] - Options for retrieving summary.
3001
3002
  * @property {LivecrawlOptions} [livecrawl] - Options for livecrawling contents. Default is "never" for neural/auto search, "fallback" for keyword search.
3002
3003
  * @property {number} [livecrawlTimeout] - The timeout for livecrawling. Max and default is 10000ms.
@@ -3007,6 +3008,7 @@ declare class ExaError extends Error {
3007
3008
  */
3008
3009
  type ContentsOptions = {
3009
3010
  text?: TextContentsOptions | true;
3011
+ highlights?: HighlightsContentsOptions | true;
3010
3012
  summary?: SummaryContentsOptions | true;
3011
3013
  livecrawl?: LivecrawlOptions;
3012
3014
  context?: ContextOptions | true;
@@ -3119,6 +3121,20 @@ type TextContentsOptions = {
3119
3121
  maxCharacters?: number;
3120
3122
  includeHtmlTags?: boolean;
3121
3123
  };
3124
+ /**
3125
+ * Options for retrieving highlights from page.
3126
+ * NOTE: For search type "deep", these options will not be respected. Highlights will be generated with respect
3127
+ * to your initial query, and may vary in quantity and length.
3128
+ * @typedef {Object} HighlightsContentsOptions
3129
+ * @property {string} [query] - The query string to use for highlights search.
3130
+ * @property {number} [numSentences] - The number of sentences to return for each highlight.
3131
+ * @property {number} [highlightsPerUrl] - The number of highlights to return for each URL.
3132
+ */
3133
+ type HighlightsContentsOptions = {
3134
+ query?: string;
3135
+ numSentences?: number;
3136
+ highlightsPerUrl?: number;
3137
+ };
3122
3138
  /**
3123
3139
  * Options for retrieving summary from page.
3124
3140
  * @typedef {Object} SummaryContentsOptions
@@ -3149,6 +3165,15 @@ type ContextOptions = {
3149
3165
  type TextResponse = {
3150
3166
  text: string;
3151
3167
  };
3168
+ /**
3169
+ * @typedef {Object} HighlightsResponse
3170
+ * @property {string[]} highlights - The highlights as an array of strings.
3171
+ * @property {number[]} highlightScores - The corresponding scores as an array of floats, 0 to 1
3172
+ */
3173
+ type HighlightsResponse = {
3174
+ highlights: string[];
3175
+ highlightScores: number[];
3176
+ };
3152
3177
  /**
3153
3178
  * @typedef {Object} SummaryResponse
3154
3179
  * @property {string} summary - The generated summary of the page content.
@@ -3177,20 +3202,22 @@ type SubpagesResponse<T extends ContentsOptions> = {
3177
3202
  type Default<T extends {}, U> = [keyof T] extends [never] ? U : T;
3178
3203
  /**
3179
3204
  * @typedef {Object} ContentsResultComponent
3180
- * Depending on 'ContentsOptions', this yields a combination of 'TextResponse', 'SummaryResponse', or an empty object.
3205
+ * Depending on 'ContentsOptions', this yields a combination of 'TextResponse', 'HighlightsResponse', 'SummaryResponse', or an empty object.
3181
3206
  *
3182
3207
  * @template T - A type extending from 'ContentsOptions'.
3183
3208
  */
3184
- type ContentsResultComponent<T extends ContentsOptions> = (T["text"] extends object | true ? TextResponse : {}) & (T["summary"] extends object | true ? SummaryResponse : {}) & (T["subpages"] extends number ? SubpagesResponse<T> : {}) & (T["extras"] extends object ? ExtrasResponse : {});
3209
+ type ContentsResultComponent<T extends ContentsOptions> = (T["text"] extends object | true ? TextResponse : {}) & (T["highlights"] extends object | true ? HighlightsResponse : {}) & (T["summary"] extends object | true ? SummaryResponse : {}) & (T["subpages"] extends number ? SubpagesResponse<T> : {}) & (T["extras"] extends object ? ExtrasResponse : {});
3185
3210
  /**
3186
3211
  * Represents the cost breakdown related to contents retrieval. Fields are optional because
3187
3212
  * only non-zero costs are included.
3188
3213
  * @typedef {Object} CostDollarsContents
3189
3214
  * @property {number} [text] - The cost in dollars for retrieving text.
3215
+ * @property {number} [highlights] - The cost in dollars for retrieving highlights.
3190
3216
  * @property {number} [summary] - The cost in dollars for retrieving summary.
3191
3217
  */
3192
3218
  type CostDollarsContents = {
3193
3219
  text?: number;
3220
+ highlights?: number;
3194
3221
  summary?: number;
3195
3222
  };
3196
3223
  /**
@@ -3559,4 +3586,4 @@ declare class Exa {
3559
3586
  private parseSSEStream;
3560
3587
  }
3561
3588
 
3562
- export { type AnswerOptions, type AnswerOptionsTyped, type AnswerResponse, type AnswerResponseTyped, type AnswerStreamChunk, type AnswerStreamResponse, type ArticleEntity, type BaseSearchOptions, type CompanyEntity, type ContentsOptions, type ContentsResultComponent, type ContextOptions, type CostDollars, type CostDollarsContents, type CostDollarsSeearch, type CreateCriterionParameters, type CreateEnrichmentParameters, CreateEnrichmentParametersFormat, type CreateImportParameters, CreateImportParametersFormat, type CreateImportResponse, type CreateImportWithCsvParameters, type CreateMonitorParameters, type CreateWebhookParameters, type CreateWebsetParameters, type CreateWebsetSearchParameters, type CsvDataInput, type CustomEntity, type Default, type EnrichmentResult, type Entity, type Event, EventType, EventsClient, Exa, ExaError, type ExtrasOptions, type ExtrasResponse, type FindSimilarOptions, type GetWebsetResponse, HttpStatusCode, type Import, ImportFailedReason, ImportFormat, ImportObject, ImportStatus, ImportsClient, type JSONSchema, type ListEventsResponse, type ListImportsResponse, type ListMonitorRunsResponse, type ListMonitorsOptions, type ListMonitorsResponse, type ListResearchRequest, type ListResearchResponse, type ListWebhookAttemptsResponse, type ListWebhooksResponse, type ListWebsetItemResponse, type ListWebsetItemsOptions, type ListWebsetsResponse, type LivecrawlOptions, type Monitor, type MonitorBehavior, type MonitorCadence, MonitorObject, type MonitorRun, MonitorRunObject, MonitorRunStatus, MonitorRunType, MonitorStatus, type PersonEntity, type PreviewWebsetParameters, type PreviewWebsetResponse, type RegularSearchOptions, type Research, type ResearchCreateParamsTyped, type ResearchCreateRequest, type ResearchCreateResponse, type ResearchDefinitionEvent, type ResearchEvent, type ResearchOperation, type ResearchOutputEvent, type ResearchPaperEntity, type ResearchPlanDefinitionEvent, type ResearchPlanOperationEvent, type ResearchPlanOutputEvent, type ResearchStatus, type ResearchStreamEvent, type ResearchStreamEventTyped, type ResearchTaskDefinitionEvent, type ResearchTaskOperationEvent, type ResearchTaskOutputEvent, type ResearchTyped, type SearchResponse, type SearchResult, type Status, type SubpagesResponse, type SummaryContentsOptions, type SummaryContentsOptionsTyped, type SummaryResponse, type TextContentsOptions, type TextResponse, type UpdateEnrichmentParameters, type UpdateImport, type UpdateMonitor, UpdateMonitorStatus, type UpdateWebhookParameters, type UpdateWebsetRequest, type WaitUntilCompletedOptions, type Webhook, type WebhookAttempt, WebhookStatus, type Webset, type WebsetEnrichment, WebsetEnrichmentFormat, WebsetEnrichmentStatus, WebsetEnrichmentsClient, WebsetExcludeSource, type WebsetHeadersLike, WebsetImportSource, type WebsetItem, type WebsetItemArticleProperties, type WebsetItemCompanyProperties, type WebsetItemCustomProperties, type WebsetItemEvaluation, WebsetItemEvaluationSatisfied, type WebsetItemPersonProperties, type WebsetItemResearchPaperProperties, WebsetItemSource, WebsetItemsClient, WebsetMonitorsClient, type WebsetSearch, WebsetSearchBehavior, WebsetSearchCanceledReason, WebsetSearchScopeSource, WebsetSearchStatus, WebsetSearchesClient, WebsetStatus, WebsetWebhooksClient, WebsetsClient, Exa as default };
3589
+ export { type AnswerOptions, type AnswerOptionsTyped, type AnswerResponse, type AnswerResponseTyped, type AnswerStreamChunk, type AnswerStreamResponse, type ArticleEntity, type BaseSearchOptions, type CompanyEntity, type ContentsOptions, type ContentsResultComponent, type ContextOptions, type CostDollars, type CostDollarsContents, type CostDollarsSeearch, type CreateCriterionParameters, type CreateEnrichmentParameters, CreateEnrichmentParametersFormat, type CreateImportParameters, CreateImportParametersFormat, type CreateImportResponse, type CreateImportWithCsvParameters, type CreateMonitorParameters, type CreateWebhookParameters, type CreateWebsetParameters, type CreateWebsetSearchParameters, type CsvDataInput, type CustomEntity, type Default, type EnrichmentResult, type Entity, type Event, EventType, EventsClient, Exa, ExaError, type ExtrasOptions, type ExtrasResponse, type FindSimilarOptions, type GetWebsetResponse, type HighlightsContentsOptions, type HighlightsResponse, HttpStatusCode, type Import, ImportFailedReason, ImportFormat, ImportObject, ImportStatus, ImportsClient, type JSONSchema, type ListEventsResponse, type ListImportsResponse, type ListMonitorRunsResponse, type ListMonitorsOptions, type ListMonitorsResponse, type ListResearchRequest, type ListResearchResponse, type ListWebhookAttemptsResponse, type ListWebhooksResponse, type ListWebsetItemResponse, type ListWebsetItemsOptions, type ListWebsetsResponse, type LivecrawlOptions, type Monitor, type MonitorBehavior, type MonitorCadence, MonitorObject, type MonitorRun, MonitorRunObject, MonitorRunStatus, MonitorRunType, MonitorStatus, type PersonEntity, type PreviewWebsetParameters, type PreviewWebsetResponse, type RegularSearchOptions, type Research, type ResearchCreateParamsTyped, type ResearchCreateRequest, type ResearchCreateResponse, type ResearchDefinitionEvent, type ResearchEvent, type ResearchOperation, type ResearchOutputEvent, type ResearchPaperEntity, type ResearchPlanDefinitionEvent, type ResearchPlanOperationEvent, type ResearchPlanOutputEvent, type ResearchStatus, type ResearchStreamEvent, type ResearchStreamEventTyped, type ResearchTaskDefinitionEvent, type ResearchTaskOperationEvent, type ResearchTaskOutputEvent, type ResearchTyped, type SearchResponse, type SearchResult, type Status, type SubpagesResponse, type SummaryContentsOptions, type SummaryContentsOptionsTyped, type SummaryResponse, type TextContentsOptions, type TextResponse, type UpdateEnrichmentParameters, type UpdateImport, type UpdateMonitor, UpdateMonitorStatus, type UpdateWebhookParameters, type UpdateWebsetRequest, type WaitUntilCompletedOptions, type Webhook, type WebhookAttempt, WebhookStatus, type Webset, type WebsetEnrichment, WebsetEnrichmentFormat, WebsetEnrichmentStatus, WebsetEnrichmentsClient, WebsetExcludeSource, type WebsetHeadersLike, WebsetImportSource, type WebsetItem, type WebsetItemArticleProperties, type WebsetItemCompanyProperties, type WebsetItemCustomProperties, type WebsetItemEvaluation, WebsetItemEvaluationSatisfied, type WebsetItemPersonProperties, type WebsetItemResearchPaperProperties, WebsetItemSource, WebsetItemsClient, WebsetMonitorsClient, type WebsetSearch, WebsetSearchBehavior, WebsetSearchCanceledReason, WebsetSearchScopeSource, WebsetSearchStatus, WebsetSearchesClient, WebsetStatus, WebsetWebhooksClient, WebsetsClient, Exa as default };
package/dist/index.d.ts CHANGED
@@ -2997,6 +2997,7 @@ declare class ExaError extends Error {
2997
2997
  * Options for retrieving page contents
2998
2998
  * @typedef {Object} ContentsOptions
2999
2999
  * @property {TextContentsOptions | boolean} [text] - Options for retrieving text contents.
3000
+ * @property {HighlightsContentsOptions | boolean} [highlights] - Options for retrieving highlights. NOTE: For search type "deep", only "true" is allowed. "query", "numSentences" and "highlightsPerUrl" will not be respected.
3000
3001
  * @property {SummaryContentsOptions | boolean} [summary] - Options for retrieving summary.
3001
3002
  * @property {LivecrawlOptions} [livecrawl] - Options for livecrawling contents. Default is "never" for neural/auto search, "fallback" for keyword search.
3002
3003
  * @property {number} [livecrawlTimeout] - The timeout for livecrawling. Max and default is 10000ms.
@@ -3007,6 +3008,7 @@ declare class ExaError extends Error {
3007
3008
  */
3008
3009
  type ContentsOptions = {
3009
3010
  text?: TextContentsOptions | true;
3011
+ highlights?: HighlightsContentsOptions | true;
3010
3012
  summary?: SummaryContentsOptions | true;
3011
3013
  livecrawl?: LivecrawlOptions;
3012
3014
  context?: ContextOptions | true;
@@ -3119,6 +3121,20 @@ type TextContentsOptions = {
3119
3121
  maxCharacters?: number;
3120
3122
  includeHtmlTags?: boolean;
3121
3123
  };
3124
+ /**
3125
+ * Options for retrieving highlights from page.
3126
+ * NOTE: For search type "deep", these options will not be respected. Highlights will be generated with respect
3127
+ * to your initial query, and may vary in quantity and length.
3128
+ * @typedef {Object} HighlightsContentsOptions
3129
+ * @property {string} [query] - The query string to use for highlights search.
3130
+ * @property {number} [numSentences] - The number of sentences to return for each highlight.
3131
+ * @property {number} [highlightsPerUrl] - The number of highlights to return for each URL.
3132
+ */
3133
+ type HighlightsContentsOptions = {
3134
+ query?: string;
3135
+ numSentences?: number;
3136
+ highlightsPerUrl?: number;
3137
+ };
3122
3138
  /**
3123
3139
  * Options for retrieving summary from page.
3124
3140
  * @typedef {Object} SummaryContentsOptions
@@ -3149,6 +3165,15 @@ type ContextOptions = {
3149
3165
  type TextResponse = {
3150
3166
  text: string;
3151
3167
  };
3168
+ /**
3169
+ * @typedef {Object} HighlightsResponse
3170
+ * @property {string[]} highlights - The highlights as an array of strings.
3171
+ * @property {number[]} highlightScores - The corresponding scores as an array of floats, 0 to 1
3172
+ */
3173
+ type HighlightsResponse = {
3174
+ highlights: string[];
3175
+ highlightScores: number[];
3176
+ };
3152
3177
  /**
3153
3178
  * @typedef {Object} SummaryResponse
3154
3179
  * @property {string} summary - The generated summary of the page content.
@@ -3177,20 +3202,22 @@ type SubpagesResponse<T extends ContentsOptions> = {
3177
3202
  type Default<T extends {}, U> = [keyof T] extends [never] ? U : T;
3178
3203
  /**
3179
3204
  * @typedef {Object} ContentsResultComponent
3180
- * Depending on 'ContentsOptions', this yields a combination of 'TextResponse', 'SummaryResponse', or an empty object.
3205
+ * Depending on 'ContentsOptions', this yields a combination of 'TextResponse', 'HighlightsResponse', 'SummaryResponse', or an empty object.
3181
3206
  *
3182
3207
  * @template T - A type extending from 'ContentsOptions'.
3183
3208
  */
3184
- type ContentsResultComponent<T extends ContentsOptions> = (T["text"] extends object | true ? TextResponse : {}) & (T["summary"] extends object | true ? SummaryResponse : {}) & (T["subpages"] extends number ? SubpagesResponse<T> : {}) & (T["extras"] extends object ? ExtrasResponse : {});
3209
+ type ContentsResultComponent<T extends ContentsOptions> = (T["text"] extends object | true ? TextResponse : {}) & (T["highlights"] extends object | true ? HighlightsResponse : {}) & (T["summary"] extends object | true ? SummaryResponse : {}) & (T["subpages"] extends number ? SubpagesResponse<T> : {}) & (T["extras"] extends object ? ExtrasResponse : {});
3185
3210
  /**
3186
3211
  * Represents the cost breakdown related to contents retrieval. Fields are optional because
3187
3212
  * only non-zero costs are included.
3188
3213
  * @typedef {Object} CostDollarsContents
3189
3214
  * @property {number} [text] - The cost in dollars for retrieving text.
3215
+ * @property {number} [highlights] - The cost in dollars for retrieving highlights.
3190
3216
  * @property {number} [summary] - The cost in dollars for retrieving summary.
3191
3217
  */
3192
3218
  type CostDollarsContents = {
3193
3219
  text?: number;
3220
+ highlights?: number;
3194
3221
  summary?: number;
3195
3222
  };
3196
3223
  /**
@@ -3559,4 +3586,4 @@ declare class Exa {
3559
3586
  private parseSSEStream;
3560
3587
  }
3561
3588
 
3562
- export { type AnswerOptions, type AnswerOptionsTyped, type AnswerResponse, type AnswerResponseTyped, type AnswerStreamChunk, type AnswerStreamResponse, type ArticleEntity, type BaseSearchOptions, type CompanyEntity, type ContentsOptions, type ContentsResultComponent, type ContextOptions, type CostDollars, type CostDollarsContents, type CostDollarsSeearch, type CreateCriterionParameters, type CreateEnrichmentParameters, CreateEnrichmentParametersFormat, type CreateImportParameters, CreateImportParametersFormat, type CreateImportResponse, type CreateImportWithCsvParameters, type CreateMonitorParameters, type CreateWebhookParameters, type CreateWebsetParameters, type CreateWebsetSearchParameters, type CsvDataInput, type CustomEntity, type Default, type EnrichmentResult, type Entity, type Event, EventType, EventsClient, Exa, ExaError, type ExtrasOptions, type ExtrasResponse, type FindSimilarOptions, type GetWebsetResponse, HttpStatusCode, type Import, ImportFailedReason, ImportFormat, ImportObject, ImportStatus, ImportsClient, type JSONSchema, type ListEventsResponse, type ListImportsResponse, type ListMonitorRunsResponse, type ListMonitorsOptions, type ListMonitorsResponse, type ListResearchRequest, type ListResearchResponse, type ListWebhookAttemptsResponse, type ListWebhooksResponse, type ListWebsetItemResponse, type ListWebsetItemsOptions, type ListWebsetsResponse, type LivecrawlOptions, type Monitor, type MonitorBehavior, type MonitorCadence, MonitorObject, type MonitorRun, MonitorRunObject, MonitorRunStatus, MonitorRunType, MonitorStatus, type PersonEntity, type PreviewWebsetParameters, type PreviewWebsetResponse, type RegularSearchOptions, type Research, type ResearchCreateParamsTyped, type ResearchCreateRequest, type ResearchCreateResponse, type ResearchDefinitionEvent, type ResearchEvent, type ResearchOperation, type ResearchOutputEvent, type ResearchPaperEntity, type ResearchPlanDefinitionEvent, type ResearchPlanOperationEvent, type ResearchPlanOutputEvent, type ResearchStatus, type ResearchStreamEvent, type ResearchStreamEventTyped, type ResearchTaskDefinitionEvent, type ResearchTaskOperationEvent, type ResearchTaskOutputEvent, type ResearchTyped, type SearchResponse, type SearchResult, type Status, type SubpagesResponse, type SummaryContentsOptions, type SummaryContentsOptionsTyped, type SummaryResponse, type TextContentsOptions, type TextResponse, type UpdateEnrichmentParameters, type UpdateImport, type UpdateMonitor, UpdateMonitorStatus, type UpdateWebhookParameters, type UpdateWebsetRequest, type WaitUntilCompletedOptions, type Webhook, type WebhookAttempt, WebhookStatus, type Webset, type WebsetEnrichment, WebsetEnrichmentFormat, WebsetEnrichmentStatus, WebsetEnrichmentsClient, WebsetExcludeSource, type WebsetHeadersLike, WebsetImportSource, type WebsetItem, type WebsetItemArticleProperties, type WebsetItemCompanyProperties, type WebsetItemCustomProperties, type WebsetItemEvaluation, WebsetItemEvaluationSatisfied, type WebsetItemPersonProperties, type WebsetItemResearchPaperProperties, WebsetItemSource, WebsetItemsClient, WebsetMonitorsClient, type WebsetSearch, WebsetSearchBehavior, WebsetSearchCanceledReason, WebsetSearchScopeSource, WebsetSearchStatus, WebsetSearchesClient, WebsetStatus, WebsetWebhooksClient, WebsetsClient, Exa as default };
3589
+ export { type AnswerOptions, type AnswerOptionsTyped, type AnswerResponse, type AnswerResponseTyped, type AnswerStreamChunk, type AnswerStreamResponse, type ArticleEntity, type BaseSearchOptions, type CompanyEntity, type ContentsOptions, type ContentsResultComponent, type ContextOptions, type CostDollars, type CostDollarsContents, type CostDollarsSeearch, type CreateCriterionParameters, type CreateEnrichmentParameters, CreateEnrichmentParametersFormat, type CreateImportParameters, CreateImportParametersFormat, type CreateImportResponse, type CreateImportWithCsvParameters, type CreateMonitorParameters, type CreateWebhookParameters, type CreateWebsetParameters, type CreateWebsetSearchParameters, type CsvDataInput, type CustomEntity, type Default, type EnrichmentResult, type Entity, type Event, EventType, EventsClient, Exa, ExaError, type ExtrasOptions, type ExtrasResponse, type FindSimilarOptions, type GetWebsetResponse, type HighlightsContentsOptions, type HighlightsResponse, HttpStatusCode, type Import, ImportFailedReason, ImportFormat, ImportObject, ImportStatus, ImportsClient, type JSONSchema, type ListEventsResponse, type ListImportsResponse, type ListMonitorRunsResponse, type ListMonitorsOptions, type ListMonitorsResponse, type ListResearchRequest, type ListResearchResponse, type ListWebhookAttemptsResponse, type ListWebhooksResponse, type ListWebsetItemResponse, type ListWebsetItemsOptions, type ListWebsetsResponse, type LivecrawlOptions, type Monitor, type MonitorBehavior, type MonitorCadence, MonitorObject, type MonitorRun, MonitorRunObject, MonitorRunStatus, MonitorRunType, MonitorStatus, type PersonEntity, type PreviewWebsetParameters, type PreviewWebsetResponse, type RegularSearchOptions, type Research, type ResearchCreateParamsTyped, type ResearchCreateRequest, type ResearchCreateResponse, type ResearchDefinitionEvent, type ResearchEvent, type ResearchOperation, type ResearchOutputEvent, type ResearchPaperEntity, type ResearchPlanDefinitionEvent, type ResearchPlanOperationEvent, type ResearchPlanOutputEvent, type ResearchStatus, type ResearchStreamEvent, type ResearchStreamEventTyped, type ResearchTaskDefinitionEvent, type ResearchTaskOperationEvent, type ResearchTaskOutputEvent, type ResearchTyped, type SearchResponse, type SearchResult, type Status, type SubpagesResponse, type SummaryContentsOptions, type SummaryContentsOptionsTyped, type SummaryResponse, type TextContentsOptions, type TextResponse, type UpdateEnrichmentParameters, type UpdateImport, type UpdateMonitor, UpdateMonitorStatus, type UpdateWebhookParameters, type UpdateWebsetRequest, type WaitUntilCompletedOptions, type Webhook, type WebhookAttempt, WebhookStatus, type Webset, type WebsetEnrichment, WebsetEnrichmentFormat, WebsetEnrichmentStatus, WebsetEnrichmentsClient, WebsetExcludeSource, type WebsetHeadersLike, WebsetImportSource, type WebsetItem, type WebsetItemArticleProperties, type WebsetItemCompanyProperties, type WebsetItemCustomProperties, type WebsetItemEvaluation, WebsetItemEvaluationSatisfied, type WebsetItemPersonProperties, type WebsetItemResearchPaperProperties, WebsetItemSource, WebsetItemsClient, WebsetMonitorsClient, type WebsetSearch, WebsetSearchBehavior, WebsetSearchCanceledReason, WebsetSearchScopeSource, WebsetSearchStatus, WebsetSearchesClient, WebsetStatus, WebsetWebhooksClient, WebsetsClient, Exa as default };
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.8",
77
+ version: "2.0.10",
78
78
  description: "Exa SDK for Node.js and the browser",
79
79
  publishConfig: {
80
80
  access: "public"
@@ -1344,6 +1344,7 @@ var Exa2 = class {
1344
1344
  extractContentsOptions(options) {
1345
1345
  const {
1346
1346
  text,
1347
+ highlights,
1347
1348
  summary,
1348
1349
  subpages,
1349
1350
  subpageTarget,
@@ -1354,10 +1355,11 @@ var Exa2 = class {
1354
1355
  ...rest
1355
1356
  } = options;
1356
1357
  const contentsOptions = {};
1357
- if (text === void 0 && summary === void 0 && extras === void 0) {
1358
+ if (text === void 0 && summary === void 0 && highlights === void 0 && extras === void 0) {
1358
1359
  contentsOptions.text = true;
1359
1360
  }
1360
1361
  if (text !== void 0) contentsOptions.text = text;
1362
+ if (highlights !== void 0) contentsOptions.highlights = highlights;
1361
1363
  if (summary !== void 0) {
1362
1364
  if (typeof summary === "object" && summary !== null && "schema" in summary && summary.schema && isZodSchema(summary.schema)) {
1363
1365
  contentsOptions.summary = {