exa-js 1.7.4 → 1.8.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.
- package/README.md +7 -8
- package/dist/index.d.mts +200 -131
- package/dist/index.d.ts +200 -131
- package/dist/index.js +76 -30
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +75 -30
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -4
package/dist/index.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ interface RequestBody$1 {
|
|
|
15
15
|
/**
|
|
16
16
|
* Common pagination parameters
|
|
17
17
|
*/
|
|
18
|
-
interface PaginationParams {
|
|
18
|
+
interface PaginationParams$1 {
|
|
19
19
|
/**
|
|
20
20
|
* Cursor for pagination
|
|
21
21
|
*/
|
|
@@ -50,10 +50,10 @@ declare class WebsetsBaseClient {
|
|
|
50
50
|
* @param pagination The pagination parameters
|
|
51
51
|
* @returns QueryParams object with pagination parameters
|
|
52
52
|
*/
|
|
53
|
-
protected buildPaginationParams(pagination?: PaginationParams): QueryParams$1;
|
|
53
|
+
protected buildPaginationParams(pagination?: PaginationParams$1): QueryParams$1;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
-
interface components {
|
|
56
|
+
interface components$1 {
|
|
57
57
|
schemas: {
|
|
58
58
|
CreateCriterionParameters: {
|
|
59
59
|
/** @description The description of the criterion */
|
|
@@ -81,7 +81,7 @@ interface components {
|
|
|
81
81
|
};
|
|
82
82
|
CreateStreamParameters: {
|
|
83
83
|
/** @description Behavior to perform when stream runs */
|
|
84
|
-
behavior: components["schemas"]["StreamBehaviorSearch"] | components["schemas"]["StreamBehaviorRefresh"];
|
|
84
|
+
behavior: components$1["schemas"]["StreamBehaviorSearch"] | components$1["schemas"]["StreamBehaviorRefresh"];
|
|
85
85
|
/** @description How often the stream will run */
|
|
86
86
|
cadence: {
|
|
87
87
|
/** @description Cron expression for stream cadence (must be a valid Unix cron with 5 fields). The schedule must trigger at most once per day. */
|
|
@@ -100,7 +100,7 @@ interface components {
|
|
|
100
100
|
};
|
|
101
101
|
CreateWebhookParameters: {
|
|
102
102
|
/** @description The events to trigger the webhook */
|
|
103
|
-
events: components["schemas"]["EventType"][];
|
|
103
|
+
events: components$1["schemas"]["EventType"][];
|
|
104
104
|
/** @description Set of key-value pairs you want to associate with this object. */
|
|
105
105
|
metadata?: {
|
|
106
106
|
[key: string]: string;
|
|
@@ -113,7 +113,7 @@ interface components {
|
|
|
113
113
|
};
|
|
114
114
|
CreateWebsetParameters: {
|
|
115
115
|
/** @description Add Enrichments for the Webset. */
|
|
116
|
-
enrichments?: components["schemas"]["CreateEnrichmentParameters"][];
|
|
116
|
+
enrichments?: components$1["schemas"]["CreateEnrichmentParameters"][];
|
|
117
117
|
/** @description The external identifier for the webset.
|
|
118
118
|
*
|
|
119
119
|
* You can use this to reference the Webset by your own internal identifiers. */
|
|
@@ -134,11 +134,11 @@ interface components {
|
|
|
134
134
|
/** @description Criteria every item is evaluated against.
|
|
135
135
|
*
|
|
136
136
|
* It's not required to provide your own criteria, we automatically detect the criteria from all the information provided in the query. Only use this when you need more fine control. */
|
|
137
|
-
criteria?: components["schemas"]["CreateCriterionParameters"][];
|
|
137
|
+
criteria?: components$1["schemas"]["CreateCriterionParameters"][];
|
|
138
138
|
/** @description Entity the Webset will return results for.
|
|
139
139
|
*
|
|
140
140
|
* 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. */
|
|
141
|
-
entity?: components["schemas"]["WebsetEntity"];
|
|
141
|
+
entity?: components$1["schemas"]["WebsetEntity"];
|
|
142
142
|
/** @description Your search query.
|
|
143
143
|
*
|
|
144
144
|
* Use this to describe what you are looking for.
|
|
@@ -163,11 +163,11 @@ interface components {
|
|
|
163
163
|
/** @description Criteria every item is evaluated against.
|
|
164
164
|
*
|
|
165
165
|
* It's not required to provide your own criteria, we automatically detect the criteria from all the information provided in the query. */
|
|
166
|
-
criteria?: components["schemas"]["CreateCriterionParameters"][];
|
|
166
|
+
criteria?: components$1["schemas"]["CreateCriterionParameters"][];
|
|
167
167
|
/** @description Entity the Webset will return results for.
|
|
168
168
|
*
|
|
169
169
|
* It is not required to provide it, we automatically detect the entity from all the information provided in the query. */
|
|
170
|
-
entity?: components["schemas"]["WebsetEntity"];
|
|
170
|
+
entity?: components$1["schemas"]["WebsetEntity"];
|
|
171
171
|
/** @description Set of key-value pairs you want to associate with this object. */
|
|
172
172
|
metadata?: {
|
|
173
173
|
[key: string]: string;
|
|
@@ -207,7 +207,7 @@ interface components {
|
|
|
207
207
|
* @description The date and time the event was created
|
|
208
208
|
*/
|
|
209
209
|
createdAt: string;
|
|
210
|
-
data: components["schemas"]["Webset"];
|
|
210
|
+
data: components$1["schemas"]["Webset"];
|
|
211
211
|
/** @description The unique identifier for the event */
|
|
212
212
|
id: string;
|
|
213
213
|
/**
|
|
@@ -226,7 +226,7 @@ interface components {
|
|
|
226
226
|
* @description The date and time the event was created
|
|
227
227
|
*/
|
|
228
228
|
createdAt: string;
|
|
229
|
-
data: components["schemas"]["Webset"];
|
|
229
|
+
data: components$1["schemas"]["Webset"];
|
|
230
230
|
/** @description The unique identifier for the event */
|
|
231
231
|
id: string;
|
|
232
232
|
/**
|
|
@@ -245,7 +245,7 @@ interface components {
|
|
|
245
245
|
* @description The date and time the event was created
|
|
246
246
|
*/
|
|
247
247
|
createdAt: string;
|
|
248
|
-
data: components["schemas"]["Webset"];
|
|
248
|
+
data: components$1["schemas"]["Webset"];
|
|
249
249
|
/** @description The unique identifier for the event */
|
|
250
250
|
id: string;
|
|
251
251
|
/**
|
|
@@ -264,7 +264,7 @@ interface components {
|
|
|
264
264
|
* @description The date and time the event was created
|
|
265
265
|
*/
|
|
266
266
|
createdAt: string;
|
|
267
|
-
data: components["schemas"]["Webset"];
|
|
267
|
+
data: components$1["schemas"]["Webset"];
|
|
268
268
|
/** @description The unique identifier for the event */
|
|
269
269
|
id: string;
|
|
270
270
|
/**
|
|
@@ -283,7 +283,7 @@ interface components {
|
|
|
283
283
|
* @description The date and time the event was created
|
|
284
284
|
*/
|
|
285
285
|
createdAt: string;
|
|
286
|
-
data: components["schemas"]["WebsetItem"];
|
|
286
|
+
data: components$1["schemas"]["WebsetItem"];
|
|
287
287
|
/** @description The unique identifier for the event */
|
|
288
288
|
id: string;
|
|
289
289
|
/**
|
|
@@ -302,7 +302,7 @@ interface components {
|
|
|
302
302
|
* @description The date and time the event was created
|
|
303
303
|
*/
|
|
304
304
|
createdAt: string;
|
|
305
|
-
data: components["schemas"]["WebsetItem"];
|
|
305
|
+
data: components$1["schemas"]["WebsetItem"];
|
|
306
306
|
/** @description The unique identifier for the event */
|
|
307
307
|
id: string;
|
|
308
308
|
/**
|
|
@@ -321,7 +321,7 @@ interface components {
|
|
|
321
321
|
* @description The date and time the event was created
|
|
322
322
|
*/
|
|
323
323
|
createdAt: string;
|
|
324
|
-
data: components["schemas"]["WebsetSearch"];
|
|
324
|
+
data: components$1["schemas"]["WebsetSearch"];
|
|
325
325
|
/** @description The unique identifier for the event */
|
|
326
326
|
id: string;
|
|
327
327
|
/**
|
|
@@ -340,7 +340,7 @@ interface components {
|
|
|
340
340
|
* @description The date and time the event was created
|
|
341
341
|
*/
|
|
342
342
|
createdAt: string;
|
|
343
|
-
data: components["schemas"]["WebsetSearch"];
|
|
343
|
+
data: components$1["schemas"]["WebsetSearch"];
|
|
344
344
|
/** @description The unique identifier for the event */
|
|
345
345
|
id: string;
|
|
346
346
|
/**
|
|
@@ -359,7 +359,7 @@ interface components {
|
|
|
359
359
|
* @description The date and time the event was created
|
|
360
360
|
*/
|
|
361
361
|
createdAt: string;
|
|
362
|
-
data: components["schemas"]["WebsetSearch"];
|
|
362
|
+
data: components$1["schemas"]["WebsetSearch"];
|
|
363
363
|
/** @description The unique identifier for the event */
|
|
364
364
|
id: string;
|
|
365
365
|
/**
|
|
@@ -378,7 +378,7 @@ interface components {
|
|
|
378
378
|
* @description The date and time the event was created
|
|
379
379
|
*/
|
|
380
380
|
createdAt: string;
|
|
381
|
-
data: components["schemas"]["WebsetSearch"];
|
|
381
|
+
data: components$1["schemas"]["WebsetSearch"];
|
|
382
382
|
/** @description The unique identifier for the event */
|
|
383
383
|
id: string;
|
|
384
384
|
/**
|
|
@@ -394,13 +394,13 @@ interface components {
|
|
|
394
394
|
};
|
|
395
395
|
/** @enum {string} */
|
|
396
396
|
EventType: EventType;
|
|
397
|
-
GetWebsetResponse: components["schemas"]["Webset"] & {
|
|
397
|
+
GetWebsetResponse: components$1["schemas"]["Webset"] & {
|
|
398
398
|
/** @description When expand query parameter contains `items`, this will contain the items in the webset */
|
|
399
|
-
items?: components["schemas"]["WebsetItem"][];
|
|
399
|
+
items?: components$1["schemas"]["WebsetItem"][];
|
|
400
400
|
};
|
|
401
401
|
ListEventsResponse: {
|
|
402
402
|
/** @description The list of events */
|
|
403
|
-
data: components["schemas"]["Event"][];
|
|
403
|
+
data: components$1["schemas"]["Event"][];
|
|
404
404
|
/** @description Whether there are more results to paginate through */
|
|
405
405
|
hasMore: boolean;
|
|
406
406
|
/** @description The cursor to paginate through the next set of results */
|
|
@@ -408,7 +408,7 @@ interface components {
|
|
|
408
408
|
};
|
|
409
409
|
ListStreamRunsResponse: {
|
|
410
410
|
/** @description The list of stream runs */
|
|
411
|
-
data: components["schemas"]["StreamRun"][];
|
|
411
|
+
data: components$1["schemas"]["StreamRun"][];
|
|
412
412
|
/** @description Whether there are more results to paginate through */
|
|
413
413
|
hasMore: boolean;
|
|
414
414
|
/** @description The cursor to paginate through the next set of results */
|
|
@@ -416,7 +416,7 @@ interface components {
|
|
|
416
416
|
};
|
|
417
417
|
ListStreamsResponse: {
|
|
418
418
|
/** @description The list of streams */
|
|
419
|
-
data: components["schemas"]["Stream"][];
|
|
419
|
+
data: components$1["schemas"]["Stream"][];
|
|
420
420
|
/** @description Whether there are more results to paginate through */
|
|
421
421
|
hasMore: boolean;
|
|
422
422
|
/** @description The cursor to paginate through the next set of results */
|
|
@@ -424,7 +424,7 @@ interface components {
|
|
|
424
424
|
};
|
|
425
425
|
ListWebhookAttemptsResponse: {
|
|
426
426
|
/** @description The list of webhook attempts */
|
|
427
|
-
data: components["schemas"]["WebhookAttempt"][];
|
|
427
|
+
data: components$1["schemas"]["WebhookAttempt"][];
|
|
428
428
|
/** @description Whether there are more results to paginate through */
|
|
429
429
|
hasMore: boolean;
|
|
430
430
|
/** @description The cursor to paginate through the next set of results */
|
|
@@ -432,7 +432,7 @@ interface components {
|
|
|
432
432
|
};
|
|
433
433
|
ListWebhooksResponse: {
|
|
434
434
|
/** @description The list of webhooks */
|
|
435
|
-
data: components["schemas"]["Webhook"][];
|
|
435
|
+
data: components$1["schemas"]["Webhook"][];
|
|
436
436
|
/** @description Whether there are more results to paginate through */
|
|
437
437
|
hasMore: boolean;
|
|
438
438
|
/** @description The cursor to paginate through the next set of results */
|
|
@@ -440,7 +440,7 @@ interface components {
|
|
|
440
440
|
};
|
|
441
441
|
ListWebsetItemResponse: {
|
|
442
442
|
/** @description The list of webset items */
|
|
443
|
-
data: components["schemas"]["WebsetItem"][];
|
|
443
|
+
data: components$1["schemas"]["WebsetItem"][];
|
|
444
444
|
/** @description Whether there are more Items to paginate through */
|
|
445
445
|
hasMore: boolean;
|
|
446
446
|
/** @description The cursor to paginate through the next set of Items */
|
|
@@ -448,7 +448,7 @@ interface components {
|
|
|
448
448
|
};
|
|
449
449
|
ListWebsetsResponse: {
|
|
450
450
|
/** @description The list of websets */
|
|
451
|
-
data: components["schemas"]["Webset"][];
|
|
451
|
+
data: components$1["schemas"]["Webset"][];
|
|
452
452
|
/** @description Whether there are more results to paginate through */
|
|
453
453
|
hasMore: boolean;
|
|
454
454
|
/** @description The cursor to paginate through the next set of results */
|
|
@@ -456,7 +456,7 @@ interface components {
|
|
|
456
456
|
};
|
|
457
457
|
Stream: {
|
|
458
458
|
/** @description Behavior to perform when stream runs */
|
|
459
|
-
behavior: components["schemas"]["StreamBehaviorSearch"] | components["schemas"]["StreamBehaviorRefresh"];
|
|
459
|
+
behavior: components$1["schemas"]["StreamBehaviorSearch"] | components$1["schemas"]["StreamBehaviorRefresh"];
|
|
460
460
|
/** @description How often the stream will run */
|
|
461
461
|
cadence: {
|
|
462
462
|
/** @description Cron expression for stream cadence (must be a valid Unix cron with 5 fields). The schedule must trigger at most once per day. */
|
|
@@ -478,7 +478,7 @@ interface components {
|
|
|
478
478
|
* StreamRun
|
|
479
479
|
* @description The last run of the stream
|
|
480
480
|
*/
|
|
481
|
-
lastRun: components["schemas"]["StreamRun"];
|
|
481
|
+
lastRun: components$1["schemas"]["StreamRun"];
|
|
482
482
|
/** @description Set of key-value pairs you want to associate with this object. */
|
|
483
483
|
metadata: {
|
|
484
484
|
[key: string]: string;
|
|
@@ -508,7 +508,7 @@ interface components {
|
|
|
508
508
|
};
|
|
509
509
|
StreamBehaviorRefresh: {
|
|
510
510
|
/** @description Specify the target of the refresh */
|
|
511
|
-
config: components["schemas"]["StreamRefreshBehaviorEnrichmentsConfig"] | components["schemas"]["StreamRefreshBehaviorContentsConfig"];
|
|
511
|
+
config: components$1["schemas"]["StreamRefreshBehaviorEnrichmentsConfig"] | components$1["schemas"]["StreamRefreshBehaviorContentsConfig"];
|
|
512
512
|
/**
|
|
513
513
|
* @default refresh
|
|
514
514
|
* @constant
|
|
@@ -528,7 +528,7 @@ interface components {
|
|
|
528
528
|
description: string;
|
|
529
529
|
}[];
|
|
530
530
|
/** WebsetEntity */
|
|
531
|
-
entity: components["schemas"]["WebsetEntity"];
|
|
531
|
+
entity: components$1["schemas"]["WebsetEntity"];
|
|
532
532
|
query: string;
|
|
533
533
|
};
|
|
534
534
|
/**
|
|
@@ -622,7 +622,7 @@ interface components {
|
|
|
622
622
|
};
|
|
623
623
|
UpdateWebhookParameters: {
|
|
624
624
|
/** @description The events to trigger the webhook */
|
|
625
|
-
events?: components["schemas"]["EventType"][];
|
|
625
|
+
events?: components$1["schemas"]["EventType"][];
|
|
626
626
|
/** @description Set of key-value pairs you want to associate with this object. */
|
|
627
627
|
metadata?: {
|
|
628
628
|
[key: string]: string;
|
|
@@ -646,7 +646,7 @@ interface components {
|
|
|
646
646
|
*/
|
|
647
647
|
createdAt: string;
|
|
648
648
|
/** @description The events to trigger the webhook */
|
|
649
|
-
events: components["schemas"]["EventType"][];
|
|
649
|
+
events: components$1["schemas"]["EventType"][];
|
|
650
650
|
/** @description The unique identifier for the webhook */
|
|
651
651
|
id: string;
|
|
652
652
|
/**
|
|
@@ -724,7 +724,7 @@ interface components {
|
|
|
724
724
|
*/
|
|
725
725
|
createdAt: string;
|
|
726
726
|
/** @description The Enrichments to apply to the Webset Items. */
|
|
727
|
-
enrichments: components["schemas"]["WebsetEnrichment"][];
|
|
727
|
+
enrichments: components$1["schemas"]["WebsetEnrichment"][];
|
|
728
728
|
/** @description The external identifier for the webset */
|
|
729
729
|
externalId: string | null;
|
|
730
730
|
/** @description The unique identifier for the webset */
|
|
@@ -742,7 +742,7 @@ interface components {
|
|
|
742
742
|
*/
|
|
743
743
|
object: "webset";
|
|
744
744
|
/** @description The searches that have been performed on the webset. */
|
|
745
|
-
searches: components["schemas"]["WebsetSearch"][];
|
|
745
|
+
searches: components$1["schemas"]["WebsetSearch"][];
|
|
746
746
|
/**
|
|
747
747
|
* WebsetStatus
|
|
748
748
|
* @description The status of the webset
|
|
@@ -750,7 +750,7 @@ interface components {
|
|
|
750
750
|
*/
|
|
751
751
|
status: WebsetStatus;
|
|
752
752
|
/** @description The Streams for the Webset. */
|
|
753
|
-
streams: components["schemas"]["Stream"][];
|
|
753
|
+
streams: components$1["schemas"]["Stream"][];
|
|
754
754
|
/**
|
|
755
755
|
* Format: date-time
|
|
756
756
|
* @description The date and time the webset was updated
|
|
@@ -837,7 +837,7 @@ interface components {
|
|
|
837
837
|
websetId: string;
|
|
838
838
|
};
|
|
839
839
|
/** @enum {string} */
|
|
840
|
-
WebsetEntity: components["schemas"]["WebsetCompanyEntity"] | components["schemas"]["WebsetPersonEntity"] | components["schemas"]["WebsetArticleEntity"] | components["schemas"]["WebsetResearchPaperEntity"] | components["schemas"]["WebsetCustomEntity"];
|
|
840
|
+
WebsetEntity: components$1["schemas"]["WebsetCompanyEntity"] | components$1["schemas"]["WebsetPersonEntity"] | components$1["schemas"]["WebsetArticleEntity"] | components$1["schemas"]["WebsetResearchPaperEntity"] | components$1["schemas"]["WebsetCustomEntity"];
|
|
841
841
|
WebsetItem: {
|
|
842
842
|
/**
|
|
843
843
|
* Format: date-time
|
|
@@ -845,9 +845,9 @@ interface components {
|
|
|
845
845
|
*/
|
|
846
846
|
createdAt: string;
|
|
847
847
|
/** @description The enrichments results of the Webset item */
|
|
848
|
-
enrichments: components["schemas"]["EnrichmentResult"][] | null;
|
|
848
|
+
enrichments: components$1["schemas"]["EnrichmentResult"][] | null;
|
|
849
849
|
/** @description The criteria evaluations of the item */
|
|
850
|
-
evaluations: components["schemas"]["WebsetItemEvaluation"][];
|
|
850
|
+
evaluations: components$1["schemas"]["WebsetItemEvaluation"][];
|
|
851
851
|
/** @description The unique identifier for the Webset Item */
|
|
852
852
|
id: string;
|
|
853
853
|
/**
|
|
@@ -856,7 +856,7 @@ interface components {
|
|
|
856
856
|
*/
|
|
857
857
|
object: "webset_item";
|
|
858
858
|
/** @description The properties of the Item */
|
|
859
|
-
properties: components["schemas"]["WebsetItemPersonProperties"] | components["schemas"]["WebsetItemCompanyProperties"] | components["schemas"]["WebsetItemArticleProperties"] | components["schemas"]["WebsetItemResearchPaperProperties"] | components["schemas"]["WebsetItemCustomProperties"];
|
|
859
|
+
properties: components$1["schemas"]["WebsetItemPersonProperties"] | components$1["schemas"]["WebsetItemCompanyProperties"] | components$1["schemas"]["WebsetItemArticleProperties"] | components$1["schemas"]["WebsetItemResearchPaperProperties"] | components$1["schemas"]["WebsetItemCustomProperties"];
|
|
860
860
|
/**
|
|
861
861
|
* @description The source of the Item
|
|
862
862
|
* @enum {string}
|
|
@@ -1073,7 +1073,7 @@ interface components {
|
|
|
1073
1073
|
/** @description The entity the search will return results for.
|
|
1074
1074
|
*
|
|
1075
1075
|
* When no entity is provided during creation, we will automatically select the best entity based on the query. */
|
|
1076
|
-
entity: components["schemas"]["WebsetEntity"];
|
|
1076
|
+
entity: components$1["schemas"]["WebsetEntity"];
|
|
1077
1077
|
/** @description The unique identifier for the search */
|
|
1078
1078
|
id: string;
|
|
1079
1079
|
/**
|
|
@@ -1116,32 +1116,32 @@ interface components {
|
|
|
1116
1116
|
headers: never;
|
|
1117
1117
|
pathItems: never;
|
|
1118
1118
|
}
|
|
1119
|
-
type CreateEnrichmentParameters = components["schemas"]["CreateEnrichmentParameters"];
|
|
1120
|
-
type CreateStreamParameters = components["schemas"]["CreateStreamParameters"];
|
|
1121
|
-
type CreateWebhookParameters = components["schemas"]["CreateWebhookParameters"];
|
|
1122
|
-
type CreateWebsetParameters = components["schemas"]["CreateWebsetParameters"];
|
|
1123
|
-
type CreateWebsetSearchParameters = components["schemas"]["CreateWebsetSearchParameters"];
|
|
1124
|
-
type EnrichmentResult = components["schemas"]["EnrichmentResult"];
|
|
1125
|
-
type Event = components["schemas"]["Event"];
|
|
1126
|
-
type GetWebsetResponse = components["schemas"]["GetWebsetResponse"];
|
|
1127
|
-
type ListEventsResponse = components["schemas"]["ListEventsResponse"];
|
|
1128
|
-
type ListStreamRunsResponse = components["schemas"]["ListStreamRunsResponse"];
|
|
1129
|
-
type ListStreamsResponse = components["schemas"]["ListStreamsResponse"];
|
|
1130
|
-
type ListWebhookAttemptsResponse = components["schemas"]["ListWebhookAttemptsResponse"];
|
|
1131
|
-
type ListWebhooksResponse = components["schemas"]["ListWebhooksResponse"];
|
|
1132
|
-
type ListWebsetItemResponse = components["schemas"]["ListWebsetItemResponse"];
|
|
1133
|
-
type ListWebsetsResponse = components["schemas"]["ListWebsetsResponse"];
|
|
1134
|
-
type Stream = components["schemas"]["Stream"];
|
|
1135
|
-
type StreamRun = components["schemas"]["StreamRun"];
|
|
1136
|
-
type UpdateStream = components["schemas"]["UpdateStream"];
|
|
1137
|
-
type UpdateWebhookParameters = components["schemas"]["UpdateWebhookParameters"];
|
|
1138
|
-
type UpdateWebsetRequest = components["schemas"]["UpdateWebsetRequest"];
|
|
1139
|
-
type Webhook = components["schemas"]["Webhook"];
|
|
1140
|
-
type WebhookAttempt = components["schemas"]["WebhookAttempt"];
|
|
1141
|
-
type Webset = components["schemas"]["Webset"];
|
|
1142
|
-
type WebsetEnrichment = components["schemas"]["WebsetEnrichment"];
|
|
1143
|
-
type WebsetItem = components["schemas"]["WebsetItem"];
|
|
1144
|
-
type WebsetSearch = components["schemas"]["WebsetSearch"];
|
|
1119
|
+
type CreateEnrichmentParameters = components$1["schemas"]["CreateEnrichmentParameters"];
|
|
1120
|
+
type CreateStreamParameters = components$1["schemas"]["CreateStreamParameters"];
|
|
1121
|
+
type CreateWebhookParameters = components$1["schemas"]["CreateWebhookParameters"];
|
|
1122
|
+
type CreateWebsetParameters = components$1["schemas"]["CreateWebsetParameters"];
|
|
1123
|
+
type CreateWebsetSearchParameters = components$1["schemas"]["CreateWebsetSearchParameters"];
|
|
1124
|
+
type EnrichmentResult = components$1["schemas"]["EnrichmentResult"];
|
|
1125
|
+
type Event = components$1["schemas"]["Event"];
|
|
1126
|
+
type GetWebsetResponse = components$1["schemas"]["GetWebsetResponse"];
|
|
1127
|
+
type ListEventsResponse = components$1["schemas"]["ListEventsResponse"];
|
|
1128
|
+
type ListStreamRunsResponse = components$1["schemas"]["ListStreamRunsResponse"];
|
|
1129
|
+
type ListStreamsResponse = components$1["schemas"]["ListStreamsResponse"];
|
|
1130
|
+
type ListWebhookAttemptsResponse = components$1["schemas"]["ListWebhookAttemptsResponse"];
|
|
1131
|
+
type ListWebhooksResponse = components$1["schemas"]["ListWebhooksResponse"];
|
|
1132
|
+
type ListWebsetItemResponse = components$1["schemas"]["ListWebsetItemResponse"];
|
|
1133
|
+
type ListWebsetsResponse = components$1["schemas"]["ListWebsetsResponse"];
|
|
1134
|
+
type Stream = components$1["schemas"]["Stream"];
|
|
1135
|
+
type StreamRun = components$1["schemas"]["StreamRun"];
|
|
1136
|
+
type UpdateStream = components$1["schemas"]["UpdateStream"];
|
|
1137
|
+
type UpdateWebhookParameters = components$1["schemas"]["UpdateWebhookParameters"];
|
|
1138
|
+
type UpdateWebsetRequest = components$1["schemas"]["UpdateWebsetRequest"];
|
|
1139
|
+
type Webhook = components$1["schemas"]["Webhook"];
|
|
1140
|
+
type WebhookAttempt = components$1["schemas"]["WebhookAttempt"];
|
|
1141
|
+
type Webset = components$1["schemas"]["Webset"];
|
|
1142
|
+
type WebsetEnrichment = components$1["schemas"]["WebsetEnrichment"];
|
|
1143
|
+
type WebsetItem = components$1["schemas"]["WebsetItem"];
|
|
1144
|
+
type WebsetSearch = components$1["schemas"]["WebsetSearch"];
|
|
1145
1145
|
declare enum CreateEnrichmentParametersFormat {
|
|
1146
1146
|
text = "text",
|
|
1147
1147
|
date = "date",
|
|
@@ -1326,21 +1326,21 @@ declare class WebsetItemsClient extends WebsetsBaseClient {
|
|
|
1326
1326
|
* @param params - Optional pagination parameters
|
|
1327
1327
|
* @returns A promise that resolves with the list of Items
|
|
1328
1328
|
*/
|
|
1329
|
-
list(websetId: string, params?: PaginationParams): Promise<ListWebsetItemResponse>;
|
|
1329
|
+
list(websetId: string, params?: PaginationParams$1): Promise<ListWebsetItemResponse>;
|
|
1330
1330
|
/**
|
|
1331
1331
|
* Iterate through all Items in a Webset, handling pagination automatically
|
|
1332
1332
|
* @param websetId The ID of the Webset
|
|
1333
1333
|
* @param options Pagination options
|
|
1334
1334
|
* @returns Async generator of Webset Items
|
|
1335
1335
|
*/
|
|
1336
|
-
listAll(websetId: string, options?: PaginationParams): AsyncGenerator<WebsetItem>;
|
|
1336
|
+
listAll(websetId: string, options?: PaginationParams$1): AsyncGenerator<WebsetItem>;
|
|
1337
1337
|
/**
|
|
1338
1338
|
* Collect all items from a Webset into an array
|
|
1339
1339
|
* @param websetId The ID of the Webset
|
|
1340
1340
|
* @param options Pagination options
|
|
1341
1341
|
* @returns Promise resolving to an array of all Webset Items
|
|
1342
1342
|
*/
|
|
1343
|
-
getAll(websetId: string, options?: PaginationParams): Promise<WebsetItem[]>;
|
|
1343
|
+
getAll(websetId: string, options?: PaginationParams$1): Promise<WebsetItem[]>;
|
|
1344
1344
|
/**
|
|
1345
1345
|
* Get an Item by ID
|
|
1346
1346
|
* @param websetId The ID of the Webset
|
|
@@ -1395,7 +1395,7 @@ declare class WebsetSearchesClient extends WebsetsBaseClient {
|
|
|
1395
1395
|
/**
|
|
1396
1396
|
* Options for listing streams
|
|
1397
1397
|
*/
|
|
1398
|
-
interface ListStreamsOptions extends PaginationParams {
|
|
1398
|
+
interface ListStreamsOptions extends PaginationParams$1 {
|
|
1399
1399
|
/**
|
|
1400
1400
|
* The id of the Webset to list streams for
|
|
1401
1401
|
*/
|
|
@@ -1411,7 +1411,7 @@ declare class WebsetStreamRunsClient extends WebsetsBaseClient {
|
|
|
1411
1411
|
* @param options Pagination options
|
|
1412
1412
|
* @returns The list of Stream runs
|
|
1413
1413
|
*/
|
|
1414
|
-
list(streamId: string, options?: PaginationParams): Promise<ListStreamRunsResponse>;
|
|
1414
|
+
list(streamId: string, options?: PaginationParams$1): Promise<ListStreamRunsResponse>;
|
|
1415
1415
|
/**
|
|
1416
1416
|
* Get a specific Stream run
|
|
1417
1417
|
* @param streamId The ID of the Stream
|
|
@@ -1469,12 +1469,12 @@ declare class WebsetStreamsClient extends WebsetsBaseClient {
|
|
|
1469
1469
|
/**
|
|
1470
1470
|
* Options for listing webhooks (only pagination is supported by API)
|
|
1471
1471
|
*/
|
|
1472
|
-
interface ListWebhooksOptions extends PaginationParams {
|
|
1472
|
+
interface ListWebhooksOptions extends PaginationParams$1 {
|
|
1473
1473
|
}
|
|
1474
1474
|
/**
|
|
1475
1475
|
* Options for listing webhook attempts
|
|
1476
1476
|
*/
|
|
1477
|
-
interface ListWebhookAttemptsOptions extends PaginationParams {
|
|
1477
|
+
interface ListWebhookAttemptsOptions extends PaginationParams$1 {
|
|
1478
1478
|
/**
|
|
1479
1479
|
* The type of event to filter by
|
|
1480
1480
|
*/
|
|
@@ -1557,7 +1557,7 @@ declare class WebsetWebhooksClient extends WebsetsBaseClient {
|
|
|
1557
1557
|
/**
|
|
1558
1558
|
* Options for listing Websets (API only supports pagination)
|
|
1559
1559
|
*/
|
|
1560
|
-
interface ListWebsetsOptions extends PaginationParams {
|
|
1560
|
+
interface ListWebsetsOptions extends PaginationParams$1 {
|
|
1561
1561
|
}
|
|
1562
1562
|
/**
|
|
1563
1563
|
* Client for managing Websets
|
|
@@ -1656,6 +1656,101 @@ declare class WebsetsClient extends WebsetsBaseClient {
|
|
|
1656
1656
|
} | number): Promise<Webset>;
|
|
1657
1657
|
}
|
|
1658
1658
|
|
|
1659
|
+
interface components {
|
|
1660
|
+
schemas: {
|
|
1661
|
+
ListResearchTasksRequestDto: {
|
|
1662
|
+
/** @description The cursor to paginate through the results */
|
|
1663
|
+
cursor?: string;
|
|
1664
|
+
/**
|
|
1665
|
+
* @description The number of results to return
|
|
1666
|
+
* @default 25
|
|
1667
|
+
*/
|
|
1668
|
+
limit: number;
|
|
1669
|
+
};
|
|
1670
|
+
ListResearchTasksResponseDto: {
|
|
1671
|
+
/** @description The list of research tasks */
|
|
1672
|
+
data: components["schemas"]["ResearchTaskDto"][];
|
|
1673
|
+
/** @description Whether there are more results to paginate through */
|
|
1674
|
+
hasMore: boolean;
|
|
1675
|
+
/** @description The cursor to paginate through the next set of results */
|
|
1676
|
+
nextCursor: string | null;
|
|
1677
|
+
};
|
|
1678
|
+
ResearchCreateTaskRequestDto: {
|
|
1679
|
+
/** @description Instructions for what the research task should accomplish */
|
|
1680
|
+
instructions: string;
|
|
1681
|
+
/**
|
|
1682
|
+
* @default exa-research
|
|
1683
|
+
* @enum {string}
|
|
1684
|
+
*/
|
|
1685
|
+
model: ResearchCreateTaskRequestDtoModel;
|
|
1686
|
+
output?: {
|
|
1687
|
+
/** @description A JsonSchema specification of the desired output. See https://json-schema.org/draft-07. */
|
|
1688
|
+
schema?: unknown;
|
|
1689
|
+
};
|
|
1690
|
+
};
|
|
1691
|
+
ResearchCreateTaskResponseDto: {
|
|
1692
|
+
/** @description The unique identifier for the research task */
|
|
1693
|
+
id: string;
|
|
1694
|
+
};
|
|
1695
|
+
ResearchTaskDto: {
|
|
1696
|
+
/** @description Citations grouped by the root field they were used in */
|
|
1697
|
+
citations?: {
|
|
1698
|
+
[key: string]: {
|
|
1699
|
+
id: string;
|
|
1700
|
+
snippet: string;
|
|
1701
|
+
title?: string;
|
|
1702
|
+
url: string;
|
|
1703
|
+
}[];
|
|
1704
|
+
};
|
|
1705
|
+
/** @description The research results data conforming to the specified schema */
|
|
1706
|
+
data?: {
|
|
1707
|
+
[key: string]: unknown;
|
|
1708
|
+
};
|
|
1709
|
+
/** @description The unique identifier for the research task */
|
|
1710
|
+
id: string;
|
|
1711
|
+
/** @description The instructions or query for the research task */
|
|
1712
|
+
instructions: string;
|
|
1713
|
+
/** @description The JSON schema specification for the expected output format */
|
|
1714
|
+
schema?: {
|
|
1715
|
+
[key: string]: unknown;
|
|
1716
|
+
};
|
|
1717
|
+
/**
|
|
1718
|
+
* @description The current status of the research task
|
|
1719
|
+
* @enum {string}
|
|
1720
|
+
*/
|
|
1721
|
+
status: ResearchTaskDtoStatus;
|
|
1722
|
+
};
|
|
1723
|
+
};
|
|
1724
|
+
responses: never;
|
|
1725
|
+
parameters: never;
|
|
1726
|
+
requestBodies: never;
|
|
1727
|
+
headers: never;
|
|
1728
|
+
pathItems: never;
|
|
1729
|
+
}
|
|
1730
|
+
type SchemaListResearchTasksResponseDto = components["schemas"]["ListResearchTasksResponseDto"];
|
|
1731
|
+
type SchemaResearchCreateTaskResponseDto = components["schemas"]["ResearchCreateTaskResponseDto"];
|
|
1732
|
+
type SchemaResearchTaskDto = components["schemas"]["ResearchTaskDto"];
|
|
1733
|
+
declare enum ResearchCreateTaskRequestDtoModel {
|
|
1734
|
+
exa_research = "exa-research",
|
|
1735
|
+
exa_ultra = "exa-ultra"
|
|
1736
|
+
}
|
|
1737
|
+
declare enum ResearchTaskDtoStatus {
|
|
1738
|
+
running = "running",
|
|
1739
|
+
completed = "completed",
|
|
1740
|
+
failed = "failed"
|
|
1741
|
+
}
|
|
1742
|
+
|
|
1743
|
+
interface PaginationParams {
|
|
1744
|
+
/** Cursor for pagination */
|
|
1745
|
+
cursor?: string;
|
|
1746
|
+
/** Maximum number of items per page */
|
|
1747
|
+
limit?: number;
|
|
1748
|
+
}
|
|
1749
|
+
/**
|
|
1750
|
+
* Options for listing research tasks (API only supports pagination)
|
|
1751
|
+
*/
|
|
1752
|
+
type ListResearchTasksOptions = PaginationParams;
|
|
1753
|
+
|
|
1659
1754
|
type QueryParams = Record<string, string | number | boolean | string[] | undefined>;
|
|
1660
1755
|
interface RequestBody {
|
|
1661
1756
|
[key: string]: unknown;
|
|
@@ -1679,6 +1774,12 @@ declare class ResearchBaseClient {
|
|
|
1679
1774
|
* @returns The parsed JSON response
|
|
1680
1775
|
*/
|
|
1681
1776
|
protected request<T = unknown>(endpoint: string, method?: string, data?: RequestBody, params?: QueryParams): Promise<T>;
|
|
1777
|
+
/**
|
|
1778
|
+
* Helper to build pagination parameters.
|
|
1779
|
+
* @param pagination The pagination parameters
|
|
1780
|
+
* @returns QueryParams object with pagination parameters
|
|
1781
|
+
*/
|
|
1782
|
+
protected buildPaginationParams(pagination?: PaginationParams): QueryParams;
|
|
1682
1783
|
}
|
|
1683
1784
|
|
|
1684
1785
|
/**
|
|
@@ -1687,71 +1788,39 @@ declare class ResearchBaseClient {
|
|
|
1687
1788
|
declare class ResearchClient extends ResearchBaseClient {
|
|
1688
1789
|
constructor(client: Exa);
|
|
1689
1790
|
/**
|
|
1690
|
-
* Create a research task.
|
|
1791
|
+
* Create a new research task.
|
|
1691
1792
|
*
|
|
1692
|
-
*
|
|
1693
|
-
*
|
|
1694
|
-
*
|
|
1695
|
-
*
|
|
1696
|
-
* 2. `output`
|
|
1697
|
-
* defines the exact structure you expect back, and guides the research conducted by the agent.
|
|
1698
|
-
* `{ schema: JSONSchema }`.
|
|
1699
|
-
* The agent's response will be validated against this schema.
|
|
1793
|
+
* @param params Object containing:
|
|
1794
|
+
* - model: The research model to use (e.g., ResearchModel.ExaResearch).
|
|
1795
|
+
* - instructions: High-level guidance for the research agent.
|
|
1796
|
+
* - output: An object with a `schema` property (JSONSchema) that defines the expected output structure.
|
|
1700
1797
|
*
|
|
1701
|
-
* @
|
|
1702
|
-
* @param output Object containing the expected output schema.
|
|
1703
|
-
* @returns The ResearchTaskResponse returned by the API.
|
|
1798
|
+
* @returns An object containing the unique ID of the created research task.
|
|
1704
1799
|
*/
|
|
1705
|
-
createTask(
|
|
1800
|
+
createTask(params: {
|
|
1706
1801
|
instructions: string;
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
}>;
|
|
1802
|
+
model?: ResearchCreateTaskRequestDtoModel;
|
|
1803
|
+
output: {
|
|
1804
|
+
schema: JSONSchema;
|
|
1805
|
+
};
|
|
1806
|
+
}): Promise<SchemaResearchCreateTaskResponseDto>;
|
|
1712
1807
|
/**
|
|
1713
1808
|
* Retrieve a research task by ID.
|
|
1714
1809
|
*/
|
|
1715
|
-
getTask(id: string): Promise<
|
|
1810
|
+
getTask(id: string): Promise<SchemaResearchTaskDto>;
|
|
1716
1811
|
/**
|
|
1717
1812
|
* Poll a research task until completion or failure.
|
|
1718
1813
|
* Polls every 1 second with a maximum timeout of 10 minutes.
|
|
1814
|
+
* Resilient to up to 10 consecutive polling failures.
|
|
1719
1815
|
*/
|
|
1720
|
-
pollTask(id: string): Promise<
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
/** The research task is still in progress. */
|
|
1728
|
-
in_progress = "in_progress",
|
|
1729
|
-
/** The research request has finished successfully. */
|
|
1730
|
-
completed = "completed",
|
|
1731
|
-
/** The research task request failed. */
|
|
1732
|
-
failed = "failed"
|
|
1816
|
+
pollTask(id: string): Promise<SchemaResearchTaskDto>;
|
|
1817
|
+
/**
|
|
1818
|
+
* List research tasks
|
|
1819
|
+
* @param options Pagination options
|
|
1820
|
+
* @returns The paginated list of research tasks
|
|
1821
|
+
*/
|
|
1822
|
+
listTasks(options?: ListResearchTasksOptions): Promise<SchemaListResearchTasksResponseDto>;
|
|
1733
1823
|
}
|
|
1734
|
-
/**
|
|
1735
|
-
* Response object returned from the research API.
|
|
1736
|
-
*/
|
|
1737
|
-
type ResearchTask = {
|
|
1738
|
-
/** Unique identifier for the task. */
|
|
1739
|
-
id: string;
|
|
1740
|
-
/** Current status. */
|
|
1741
|
-
status: ResearchStatus;
|
|
1742
|
-
/** The original instructions provided along with the task. */
|
|
1743
|
-
instructions: string;
|
|
1744
|
-
/** The original schema defining the task */
|
|
1745
|
-
schema: Record<string, any>;
|
|
1746
|
-
/** Structured output that follows the user-provided schema (null while running or if failed). */
|
|
1747
|
-
data: Record<string, any> | null;
|
|
1748
|
-
/**
|
|
1749
|
-
* Citations collected while deriving each top-level field in `output`.
|
|
1750
|
-
* The key is the field name, the value is the list of `SearchResult`s that
|
|
1751
|
-
* were used to compute that field.
|
|
1752
|
-
*/
|
|
1753
|
-
citations: Record<string, SearchResult<{}>[]>;
|
|
1754
|
-
};
|
|
1755
1824
|
|
|
1756
1825
|
/**
|
|
1757
1826
|
* HTTP status codes
|
|
@@ -2230,4 +2299,4 @@ declare class Exa {
|
|
|
2230
2299
|
private parseSSEStream;
|
|
2231
2300
|
}
|
|
2232
2301
|
|
|
2233
|
-
export { type AnswerOptions, type AnswerResponse, type AnswerStreamChunk, type AnswerStreamResponse, type BaseSearchOptions, type ContentsOptions, type ContentsResultComponent, type CostDollars, type CostDollarsContents, type CostDollarsSeearch, type CreateEnrichmentParameters, CreateEnrichmentParametersFormat, type CreateStreamParameters, type CreateWebhookParameters, type CreateWebsetParameters, type CreateWebsetSearchParameters, type Default, type EnrichmentResult, type Event, EventType, Exa, ExaError, type ExtrasOptions, type ExtrasResponse, type FindSimilarOptions, type GetWebsetResponse, type HighlightsContentsOptions, type HighlightsResponse, HttpStatusCode, type JSONSchema, type ListEventsResponse, type ListStreamRunsResponse, type ListStreamsOptions, type ListStreamsResponse, type ListWebhooksOptions, type ListWebhooksResponse, type ListWebsetItemResponse, type ListWebsetsOptions, type ListWebsetsResponse, type LivecrawlOptions, type RegularSearchOptions, ResearchClient, ResearchStatus, type ResearchTask, type SearchResponse, type SearchResult, type Stream, type StreamRun, type SubpagesResponse, type SummaryContentsOptions, type SummaryResponse, type TextContentsOptions, type TextResponse, type UpdateStream, UpdateStreamStatus, type UpdateWebhookParameters, type UpdateWebsetRequest, type Webhook, WebhookStatus, type Webset, type WebsetEnrichment, WebsetEnrichmentFormat, WebsetEnrichmentStatus, WebsetEnrichmentsClient, type WebsetItem, WebsetItemEvaluationSatisfied, WebsetItemSource, WebsetItemsClient, type WebsetSearch, WebsetSearchBehavior, WebsetSearchCanceledReason, WebsetSearchStatus, WebsetSearchesClient, WebsetStatus, WebsetStreamsClient, WebsetWebhooksClient, WebsetsClient, Exa as default };
|
|
2302
|
+
export { type AnswerOptions, type AnswerResponse, type AnswerStreamChunk, type AnswerStreamResponse, type BaseSearchOptions, type ContentsOptions, type ContentsResultComponent, type CostDollars, type CostDollarsContents, type CostDollarsSeearch, type CreateEnrichmentParameters, CreateEnrichmentParametersFormat, type CreateStreamParameters, type CreateWebhookParameters, type CreateWebsetParameters, type CreateWebsetSearchParameters, type Default, type EnrichmentResult, type Event, EventType, Exa, ExaError, type ExtrasOptions, type ExtrasResponse, type FindSimilarOptions, type GetWebsetResponse, type HighlightsContentsOptions, type HighlightsResponse, HttpStatusCode, type JSONSchema, type ListEventsResponse, type ListResearchTasksOptions, type SchemaListResearchTasksResponseDto as ListResearchTasksResponse, type ListStreamRunsResponse, type ListStreamsOptions, type ListStreamsResponse, type ListWebhooksOptions, type ListWebhooksResponse, type ListWebsetItemResponse, type ListWebsetsOptions, type ListWebsetsResponse, type LivecrawlOptions, type RegularSearchOptions, ResearchClient, ResearchCreateTaskRequestDtoModel as ResearchModel, ResearchTaskDtoStatus as ResearchStatus, type SchemaResearchTaskDto as ResearchTask, type SearchResponse, type SearchResult, type Stream, type StreamRun, type SubpagesResponse, type SummaryContentsOptions, type SummaryResponse, type TextContentsOptions, type TextResponse, type UpdateStream, UpdateStreamStatus, type UpdateWebhookParameters, type UpdateWebsetRequest, type Webhook, WebhookStatus, type Webset, type WebsetEnrichment, WebsetEnrichmentFormat, WebsetEnrichmentStatus, WebsetEnrichmentsClient, type WebsetItem, WebsetItemEvaluationSatisfied, WebsetItemSource, WebsetItemsClient, type WebsetSearch, WebsetSearchBehavior, WebsetSearchCanceledReason, WebsetSearchStatus, WebsetSearchesClient, WebsetStatus, WebsetStreamsClient, WebsetWebhooksClient, WebsetsClient, Exa as default };
|