@llamaindex/llama-cloud 2.9.0 → 2.10.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/CHANGELOG.md +14 -0
- package/client.d.mts +11 -8
- package/client.d.mts.map +1 -1
- package/client.d.ts +11 -8
- package/client.d.ts.map +1 -1
- package/client.js +3 -0
- package/client.js.map +1 -1
- package/client.mjs +3 -0
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/batches.d.mts +4 -4
- package/resources/batches.d.mts.map +1 -1
- package/resources/batches.d.ts +4 -4
- package/resources/batches.d.ts.map +1 -1
- package/resources/beta/agent-data.d.mts +94 -94
- package/resources/beta/agent-data.d.mts.map +1 -1
- package/resources/beta/agent-data.d.ts +94 -94
- package/resources/beta/agent-data.d.ts.map +1 -1
- package/resources/beta/agent-data.js +41 -41
- package/resources/beta/agent-data.js.map +1 -1
- package/resources/beta/agent-data.mjs +41 -41
- package/resources/beta/agent-data.mjs.map +1 -1
- package/resources/beta/batch/batch.d.mts +36 -29
- package/resources/beta/batch/batch.d.mts.map +1 -1
- package/resources/beta/batch/batch.d.ts +36 -29
- package/resources/beta/batch/batch.d.ts.map +1 -1
- package/resources/beta/batch/batch.js +16 -16
- package/resources/beta/batch/batch.js.map +1 -1
- package/resources/beta/batch/batch.mjs +16 -16
- package/resources/beta/batch/batch.mjs.map +1 -1
- package/resources/beta/batch/index.d.mts +1 -1
- package/resources/beta/batch/index.d.mts.map +1 -1
- package/resources/beta/batch/index.d.ts +1 -1
- package/resources/beta/batch/index.d.ts.map +1 -1
- package/resources/beta/batch/job-items.d.mts +14 -7
- package/resources/beta/batch/job-items.d.mts.map +1 -1
- package/resources/beta/batch/job-items.d.ts +14 -7
- package/resources/beta/batch/job-items.d.ts.map +1 -1
- package/resources/beta/beta.d.mts +6 -6
- package/resources/beta/beta.d.mts.map +1 -1
- package/resources/beta/beta.d.ts +6 -6
- package/resources/beta/beta.d.ts.map +1 -1
- package/resources/beta/chat.d.mts +39 -39
- package/resources/beta/chat.d.mts.map +1 -1
- package/resources/beta/chat.d.ts +39 -39
- package/resources/beta/chat.d.ts.map +1 -1
- package/resources/beta/chat.js +14 -14
- package/resources/beta/chat.js.map +1 -1
- package/resources/beta/chat.mjs +14 -14
- package/resources/beta/chat.mjs.map +1 -1
- package/resources/beta/directories/directories.d.mts +48 -39
- package/resources/beta/directories/directories.d.mts.map +1 -1
- package/resources/beta/directories/directories.d.ts +48 -39
- package/resources/beta/directories/directories.d.ts.map +1 -1
- package/resources/beta/directories/directories.js +30 -30
- package/resources/beta/directories/directories.js.map +1 -1
- package/resources/beta/directories/directories.mjs +30 -30
- package/resources/beta/directories/directories.mjs.map +1 -1
- package/resources/beta/directories/files.d.mts +47 -47
- package/resources/beta/directories/files.d.mts.map +1 -1
- package/resources/beta/directories/files.d.ts +47 -47
- package/resources/beta/directories/files.d.ts.map +1 -1
- package/resources/beta/directories/files.js +32 -32
- package/resources/beta/directories/files.js.map +1 -1
- package/resources/beta/directories/files.mjs +32 -32
- package/resources/beta/directories/files.mjs.map +1 -1
- package/resources/beta/directories/index.d.mts +2 -2
- package/resources/beta/directories/index.d.mts.map +1 -1
- package/resources/beta/directories/index.d.ts +2 -2
- package/resources/beta/directories/index.d.ts.map +1 -1
- package/resources/beta/index.d.mts +6 -6
- package/resources/beta/index.d.mts.map +1 -1
- package/resources/beta/index.d.ts +6 -6
- package/resources/beta/index.d.ts.map +1 -1
- package/resources/beta/indexes.d.mts +44 -32
- package/resources/beta/indexes.d.mts.map +1 -1
- package/resources/beta/indexes.d.ts +44 -32
- package/resources/beta/indexes.d.ts.map +1 -1
- package/resources/beta/indexes.js +28 -28
- package/resources/beta/indexes.js.map +1 -1
- package/resources/beta/indexes.mjs +28 -28
- package/resources/beta/indexes.mjs.map +1 -1
- package/resources/beta/retrieval.d.mts +3 -3
- package/resources/beta/retrieval.d.mts.map +1 -1
- package/resources/beta/retrieval.d.ts +3 -3
- package/resources/beta/retrieval.d.ts.map +1 -1
- package/resources/beta/sheets.d.mts +37 -56
- package/resources/beta/sheets.d.mts.map +1 -1
- package/resources/beta/sheets.d.ts +37 -56
- package/resources/beta/sheets.d.ts.map +1 -1
- package/resources/beta/sheets.js +19 -52
- package/resources/beta/sheets.js.map +1 -1
- package/resources/beta/sheets.mjs +19 -52
- package/resources/beta/sheets.mjs.map +1 -1
- package/resources/beta/split.d.mts +2 -2
- package/resources/beta/split.d.mts.map +1 -1
- package/resources/beta/split.d.ts +2 -2
- package/resources/beta/split.d.ts.map +1 -1
- package/resources/classifier/jobs.d.mts +8 -1
- package/resources/classifier/jobs.d.mts.map +1 -1
- package/resources/classifier/jobs.d.ts +8 -1
- package/resources/classifier/jobs.d.ts.map +1 -1
- package/resources/classify.d.mts +27 -11
- package/resources/classify.d.mts.map +1 -1
- package/resources/classify.d.ts +27 -11
- package/resources/classify.d.ts.map +1 -1
- package/resources/configurations.d.mts +73 -43
- package/resources/configurations.d.mts.map +1 -1
- package/resources/configurations.d.ts +73 -43
- package/resources/configurations.d.ts.map +1 -1
- package/resources/configurations.js +9 -9
- package/resources/configurations.js.map +1 -1
- package/resources/configurations.mjs +9 -9
- package/resources/configurations.mjs.map +1 -1
- package/resources/data-sinks.d.mts +16 -16
- package/resources/data-sinks.d.mts.map +1 -1
- package/resources/data-sinks.d.ts +16 -16
- package/resources/data-sinks.d.ts.map +1 -1
- package/resources/data-sinks.js +12 -12
- package/resources/data-sinks.js.map +1 -1
- package/resources/data-sinks.mjs +12 -12
- package/resources/data-sinks.mjs.map +1 -1
- package/resources/data-sources.d.mts +17 -17
- package/resources/data-sources.d.mts.map +1 -1
- package/resources/data-sources.d.ts +17 -17
- package/resources/data-sources.d.ts.map +1 -1
- package/resources/data-sources.js +13 -13
- package/resources/data-sources.js.map +1 -1
- package/resources/data-sources.mjs +13 -13
- package/resources/data-sources.mjs.map +1 -1
- package/resources/extract.d.mts +62 -46
- package/resources/extract.d.mts.map +1 -1
- package/resources/extract.d.ts +62 -46
- package/resources/extract.d.ts.map +1 -1
- package/resources/extract.js +33 -33
- package/resources/extract.js.map +1 -1
- package/resources/extract.mjs +33 -33
- package/resources/extract.mjs.map +1 -1
- package/resources/files.d.mts +41 -41
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +41 -41
- package/resources/files.d.ts.map +1 -1
- package/resources/files.js +13 -13
- package/resources/files.js.map +1 -1
- package/resources/files.mjs +13 -13
- package/resources/files.mjs.map +1 -1
- package/resources/index.d.mts +9 -8
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +9 -8
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +3 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +1 -0
- package/resources/index.mjs.map +1 -1
- package/resources/parsing.d.mts +131 -51
- package/resources/parsing.d.mts.map +1 -1
- package/resources/parsing.d.ts +131 -51
- package/resources/parsing.d.ts.map +1 -1
- package/resources/parsing.js +33 -12
- package/resources/parsing.js.map +1 -1
- package/resources/parsing.mjs +33 -12
- package/resources/parsing.mjs.map +1 -1
- package/resources/pipelines/data-sources.d.mts +40 -30
- package/resources/pipelines/data-sources.d.mts.map +1 -1
- package/resources/pipelines/data-sources.d.ts +40 -30
- package/resources/pipelines/data-sources.d.ts.map +1 -1
- package/resources/pipelines/data-sources.js +23 -13
- package/resources/pipelines/data-sources.js.map +1 -1
- package/resources/pipelines/data-sources.mjs +23 -13
- package/resources/pipelines/data-sources.mjs.map +1 -1
- package/resources/pipelines/documents.d.mts +28 -12
- package/resources/pipelines/documents.d.mts.map +1 -1
- package/resources/pipelines/documents.d.ts +28 -12
- package/resources/pipelines/documents.d.ts.map +1 -1
- package/resources/pipelines/documents.js +30 -14
- package/resources/pipelines/documents.js.map +1 -1
- package/resources/pipelines/documents.mjs +30 -14
- package/resources/pipelines/documents.mjs.map +1 -1
- package/resources/pipelines/files.d.mts +34 -24
- package/resources/pipelines/files.d.mts.map +1 -1
- package/resources/pipelines/files.d.ts +34 -24
- package/resources/pipelines/files.d.ts.map +1 -1
- package/resources/pipelines/files.js +27 -17
- package/resources/pipelines/files.js.map +1 -1
- package/resources/pipelines/files.mjs +27 -17
- package/resources/pipelines/files.mjs.map +1 -1
- package/resources/pipelines/images.d.mts +17 -17
- package/resources/pipelines/images.d.mts.map +1 -1
- package/resources/pipelines/images.d.ts +17 -17
- package/resources/pipelines/images.d.ts.map +1 -1
- package/resources/pipelines/images.js +13 -13
- package/resources/pipelines/images.js.map +1 -1
- package/resources/pipelines/images.mjs +13 -13
- package/resources/pipelines/images.mjs.map +1 -1
- package/resources/pipelines/index.d.mts +5 -5
- package/resources/pipelines/index.d.mts.map +1 -1
- package/resources/pipelines/index.d.ts +5 -5
- package/resources/pipelines/index.d.ts.map +1 -1
- package/resources/pipelines/metadata.d.mts +4 -0
- package/resources/pipelines/metadata.d.mts.map +1 -1
- package/resources/pipelines/metadata.d.ts +4 -0
- package/resources/pipelines/metadata.d.ts.map +1 -1
- package/resources/pipelines/metadata.js +4 -0
- package/resources/pipelines/metadata.js.map +1 -1
- package/resources/pipelines/metadata.mjs +4 -0
- package/resources/pipelines/metadata.mjs.map +1 -1
- package/resources/pipelines/pipelines.d.mts +149 -126
- package/resources/pipelines/pipelines.d.mts.map +1 -1
- package/resources/pipelines/pipelines.d.ts +149 -126
- package/resources/pipelines/pipelines.d.ts.map +1 -1
- package/resources/pipelines/pipelines.js +39 -23
- package/resources/pipelines/pipelines.js.map +1 -1
- package/resources/pipelines/pipelines.mjs +39 -23
- package/resources/pipelines/pipelines.mjs.map +1 -1
- package/resources/pipelines/sync.d.mts +4 -0
- package/resources/pipelines/sync.d.mts.map +1 -1
- package/resources/pipelines/sync.d.ts +4 -0
- package/resources/pipelines/sync.d.ts.map +1 -1
- package/resources/pipelines/sync.js +4 -0
- package/resources/pipelines/sync.js.map +1 -1
- package/resources/pipelines/sync.mjs +4 -0
- package/resources/pipelines/sync.mjs.map +1 -1
- package/resources/retrievers/index.d.mts +1 -1
- package/resources/retrievers/index.d.mts.map +1 -1
- package/resources/retrievers/index.d.ts +1 -1
- package/resources/retrievers/index.d.ts.map +1 -1
- package/resources/retrievers/retrievers.d.mts +39 -39
- package/resources/retrievers/retrievers.d.mts.map +1 -1
- package/resources/retrievers/retrievers.d.ts +39 -39
- package/resources/retrievers/retrievers.d.ts.map +1 -1
- package/resources/retrievers/retrievers.js +20 -20
- package/resources/retrievers/retrievers.js.map +1 -1
- package/resources/retrievers/retrievers.mjs +20 -20
- package/resources/retrievers/retrievers.mjs.map +1 -1
- package/resources/shared.d.mts +11 -3
- package/resources/shared.d.mts.map +1 -1
- package/resources/shared.d.ts +11 -3
- package/resources/shared.d.ts.map +1 -1
- package/resources/sheets.d.mts +206 -0
- package/resources/sheets.d.mts.map +1 -0
- package/resources/sheets.d.ts +206 -0
- package/resources/sheets.d.ts.map +1 -0
- package/resources/sheets.js +101 -0
- package/resources/sheets.js.map +1 -0
- package/resources/sheets.mjs +97 -0
- package/resources/sheets.mjs.map +1 -0
- package/src/client.ts +33 -12
- package/src/resources/batches.ts +4 -4
- package/src/resources/beta/agent-data.ts +131 -131
- package/src/resources/beta/batch/batch.ts +67 -54
- package/src/resources/beta/batch/index.ts +1 -1
- package/src/resources/beta/batch/job-items.ts +34 -21
- package/src/resources/beta/beta.ts +12 -12
- package/src/resources/beta/chat.ts +57 -57
- package/src/resources/beta/directories/directories.ts +80 -71
- package/src/resources/beta/directories/files.ts +66 -66
- package/src/resources/beta/directories/index.ts +5 -5
- package/src/resources/beta/index.ts +12 -12
- package/src/resources/beta/indexes.ts +68 -53
- package/src/resources/beta/retrieval.ts +3 -3
- package/src/resources/beta/sheets.ts +90 -97
- package/src/resources/beta/split.ts +2 -2
- package/src/resources/classifier/jobs.ts +9 -1
- package/src/resources/classify.ts +67 -39
- package/src/resources/configurations.ts +97 -63
- package/src/resources/data-sinks.ts +26 -26
- package/src/resources/data-sources.ts +43 -43
- package/src/resources/extract.ts +125 -97
- package/src/resources/files.ts +61 -61
- package/src/resources/index.ts +21 -12
- package/src/resources/parsing.ts +285 -204
- package/src/resources/pipelines/data-sources.ts +59 -49
- package/src/resources/pipelines/documents.ts +42 -26
- package/src/resources/pipelines/files.ts +62 -52
- package/src/resources/pipelines/images.ts +36 -36
- package/src/resources/pipelines/index.ts +10 -10
- package/src/resources/pipelines/metadata.ts +4 -0
- package/src/resources/pipelines/pipelines.ts +236 -207
- package/src/resources/pipelines/sync.ts +4 -0
- package/src/resources/retrievers/index.ts +3 -3
- package/src/resources/retrievers/retrievers.ts +64 -64
- package/src/resources/shared.ts +12 -3
- package/src/resources/sheets.ts +322 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
|
@@ -75,6 +75,27 @@ export class Batch extends APIResource {
|
|
|
75
75
|
});
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
+
/**
|
|
79
|
+
* Get detailed status of a batch processing job.
|
|
80
|
+
*
|
|
81
|
+
* Returns current progress percentage, file counts (total, processed, failed,
|
|
82
|
+
* skipped), and timestamps.
|
|
83
|
+
*
|
|
84
|
+
* @example
|
|
85
|
+
* ```ts
|
|
86
|
+
* const response = await client.beta.batch.getStatus(
|
|
87
|
+
* 'job_id',
|
|
88
|
+
* );
|
|
89
|
+
* ```
|
|
90
|
+
*/
|
|
91
|
+
getStatus(
|
|
92
|
+
jobID: string,
|
|
93
|
+
query: BatchGetStatusParams | null | undefined = {},
|
|
94
|
+
options?: RequestOptions,
|
|
95
|
+
): APIPromise<BatchGetStatusResponse> {
|
|
96
|
+
return this._client.get(path`/api/v1/beta/batch-processing/${jobID}`, { query, ...options });
|
|
97
|
+
}
|
|
98
|
+
|
|
78
99
|
/**
|
|
79
100
|
* Cancel a running batch processing job.
|
|
80
101
|
*
|
|
@@ -102,27 +123,6 @@ export class Batch extends APIResource {
|
|
|
102
123
|
]),
|
|
103
124
|
});
|
|
104
125
|
}
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
* Get detailed status of a batch processing job.
|
|
108
|
-
*
|
|
109
|
-
* Returns current progress percentage, file counts (total, processed, failed,
|
|
110
|
-
* skipped), and timestamps.
|
|
111
|
-
*
|
|
112
|
-
* @example
|
|
113
|
-
* ```ts
|
|
114
|
-
* const response = await client.beta.batch.getStatus(
|
|
115
|
-
* 'job_id',
|
|
116
|
-
* );
|
|
117
|
-
* ```
|
|
118
|
-
*/
|
|
119
|
-
getStatus(
|
|
120
|
-
jobID: string,
|
|
121
|
-
query: BatchGetStatusParams | null | undefined = {},
|
|
122
|
-
options?: RequestOptions,
|
|
123
|
-
): APIPromise<BatchGetStatusResponse> {
|
|
124
|
-
return this._client.get(path`/api/v1/beta/batch-processing/${jobID}`, { query, ...options });
|
|
125
|
-
}
|
|
126
126
|
}
|
|
127
127
|
|
|
128
128
|
export type BatchListResponsesPaginatedBatchItems = PaginatedBatchItems<BatchListResponse>;
|
|
@@ -139,7 +139,7 @@ export interface BatchCreateResponse {
|
|
|
139
139
|
/**
|
|
140
140
|
* Type of processing operation (parse or classify)
|
|
141
141
|
*/
|
|
142
|
-
job_type: '
|
|
142
|
+
job_type: 'classify' | 'extract' | 'parse';
|
|
143
143
|
|
|
144
144
|
/**
|
|
145
145
|
* Project this job belongs to
|
|
@@ -149,7 +149,7 @@ export interface BatchCreateResponse {
|
|
|
149
149
|
/**
|
|
150
150
|
* Current job status
|
|
151
151
|
*/
|
|
152
|
-
status: '
|
|
152
|
+
status: 'cancelled' | 'completed' | 'dispatched' | 'failed' | 'pending' | 'running';
|
|
153
153
|
|
|
154
154
|
/**
|
|
155
155
|
* Total number of items in the job
|
|
@@ -226,7 +226,7 @@ export interface BatchListResponse {
|
|
|
226
226
|
/**
|
|
227
227
|
* Type of processing operation (parse or classify)
|
|
228
228
|
*/
|
|
229
|
-
job_type: '
|
|
229
|
+
job_type: 'classify' | 'extract' | 'parse';
|
|
230
230
|
|
|
231
231
|
/**
|
|
232
232
|
* Project this job belongs to
|
|
@@ -236,7 +236,7 @@ export interface BatchListResponse {
|
|
|
236
236
|
/**
|
|
237
237
|
* Current job status
|
|
238
238
|
*/
|
|
239
|
-
status: '
|
|
239
|
+
status: 'cancelled' | 'completed' | 'dispatched' | 'failed' | 'pending' | 'running';
|
|
240
240
|
|
|
241
241
|
/**
|
|
242
242
|
* Total number of items in the job
|
|
@@ -323,7 +323,7 @@ export interface BatchCancelResponse {
|
|
|
323
323
|
/**
|
|
324
324
|
* New status (should be 'cancelled')
|
|
325
325
|
*/
|
|
326
|
-
status: '
|
|
326
|
+
status: 'cancelled' | 'completed' | 'dispatched' | 'failed' | 'pending' | 'running';
|
|
327
327
|
}
|
|
328
328
|
|
|
329
329
|
/**
|
|
@@ -354,7 +354,7 @@ export namespace BatchGetStatusResponse {
|
|
|
354
354
|
/**
|
|
355
355
|
* Type of processing operation (parse or classify)
|
|
356
356
|
*/
|
|
357
|
-
job_type: '
|
|
357
|
+
job_type: 'classify' | 'extract' | 'parse';
|
|
358
358
|
|
|
359
359
|
/**
|
|
360
360
|
* Project this job belongs to
|
|
@@ -364,7 +364,7 @@ export namespace BatchGetStatusResponse {
|
|
|
364
364
|
/**
|
|
365
365
|
* Current job status
|
|
366
366
|
*/
|
|
367
|
-
status: '
|
|
367
|
+
status: 'cancelled' | 'completed' | 'dispatched' | 'failed' | 'pending' | 'running';
|
|
368
368
|
|
|
369
369
|
/**
|
|
370
370
|
* Total number of items in the job
|
|
@@ -650,7 +650,7 @@ export namespace BatchCreateParams {
|
|
|
650
650
|
|
|
651
651
|
ignore_document_elements_for_layout_detection?: boolean | null;
|
|
652
652
|
|
|
653
|
-
images_to_save?: Array<'
|
|
653
|
+
images_to_save?: Array<'embedded' | 'layout' | 'screenshot'> | null;
|
|
654
654
|
|
|
655
655
|
inline_images_in_markdown?: boolean | null;
|
|
656
656
|
|
|
@@ -764,7 +764,7 @@ export namespace BatchCreateParams {
|
|
|
764
764
|
* The priority for the request. This field may be ignored or overwritten depending
|
|
765
765
|
* on the organization tier.
|
|
766
766
|
*/
|
|
767
|
-
priority?: '
|
|
767
|
+
priority?: 'critical' | 'high' | 'low' | 'medium' | null;
|
|
768
768
|
|
|
769
769
|
project_id?: string | null;
|
|
770
770
|
|
|
@@ -856,28 +856,33 @@ export namespace BatchCreateParams {
|
|
|
856
856
|
* events are delivered.
|
|
857
857
|
*/
|
|
858
858
|
webhook_events?: Array<
|
|
859
|
-
| '
|
|
860
|
-
| '
|
|
859
|
+
| 'classify.cancelled'
|
|
860
|
+
| 'classify.error'
|
|
861
|
+
| 'classify.partial_success'
|
|
862
|
+
| 'classify.pending'
|
|
863
|
+
| 'classify.running'
|
|
864
|
+
| 'classify.success'
|
|
865
|
+
| 'extract.cancelled'
|
|
861
866
|
| 'extract.error'
|
|
862
867
|
| 'extract.partial_success'
|
|
863
|
-
| 'extract.
|
|
868
|
+
| 'extract.pending'
|
|
869
|
+
| 'extract.success'
|
|
870
|
+
| 'parse.cancelled'
|
|
871
|
+
| 'parse.error'
|
|
872
|
+
| 'parse.partial_success'
|
|
864
873
|
| 'parse.pending'
|
|
865
874
|
| 'parse.running'
|
|
866
875
|
| 'parse.success'
|
|
867
|
-
| '
|
|
868
|
-
| 'parse.partial_success'
|
|
869
|
-
| 'parse.cancelled'
|
|
870
|
-
| 'classify.pending'
|
|
871
|
-
| 'classify.running'
|
|
872
|
-
| 'classify.success'
|
|
873
|
-
| 'classify.error'
|
|
874
|
-
| 'classify.partial_success'
|
|
875
|
-
| 'classify.cancelled'
|
|
876
|
-
| 'sheets.pending'
|
|
877
|
-
| 'sheets.success'
|
|
876
|
+
| 'sheets.cancelled'
|
|
878
877
|
| 'sheets.error'
|
|
879
878
|
| 'sheets.partial_success'
|
|
880
|
-
| 'sheets.
|
|
879
|
+
| 'sheets.pending'
|
|
880
|
+
| 'sheets.success'
|
|
881
|
+
| 'split.cancelled'
|
|
882
|
+
| 'split.error'
|
|
883
|
+
| 'split.pending'
|
|
884
|
+
| 'split.processing'
|
|
885
|
+
| 'split.success'
|
|
881
886
|
| 'unmapped_event'
|
|
882
887
|
> | null;
|
|
883
888
|
|
|
@@ -891,6 +896,14 @@ export namespace BatchCreateParams {
|
|
|
891
896
|
*/
|
|
892
897
|
webhook_output_format?: string | null;
|
|
893
898
|
|
|
899
|
+
/**
|
|
900
|
+
* Shared signing secret used to sign webhook deliveries. When set, each request
|
|
901
|
+
* includes an HMAC-SHA256 signature of the request body in the 'LC-Signature'
|
|
902
|
+
* header (value 'sha256=<hex>'). Recompute the HMAC over the raw request body with
|
|
903
|
+
* this secret to verify the delivery is authentic.
|
|
904
|
+
*/
|
|
905
|
+
webhook_signing_secret?: string | null;
|
|
906
|
+
|
|
894
907
|
/**
|
|
895
908
|
* URL to receive webhook POST notifications
|
|
896
909
|
*/
|
|
@@ -909,7 +922,7 @@ export interface BatchListParams extends PaginatedBatchItemsParams {
|
|
|
909
922
|
/**
|
|
910
923
|
* Filter by job type (PARSE, EXTRACT, CLASSIFY)
|
|
911
924
|
*/
|
|
912
|
-
job_type?: '
|
|
925
|
+
job_type?: 'classify' | 'extract' | 'parse' | null;
|
|
913
926
|
|
|
914
927
|
organization_id?: string | null;
|
|
915
928
|
|
|
@@ -918,7 +931,13 @@ export interface BatchListParams extends PaginatedBatchItemsParams {
|
|
|
918
931
|
/**
|
|
919
932
|
* Filter by job status (PENDING, RUNNING, COMPLETED, FAILED, CANCELLED)
|
|
920
933
|
*/
|
|
921
|
-
status?: '
|
|
934
|
+
status?: 'cancelled' | 'completed' | 'dispatched' | 'failed' | 'pending' | 'running' | null;
|
|
935
|
+
}
|
|
936
|
+
|
|
937
|
+
export interface BatchGetStatusParams {
|
|
938
|
+
organization_id?: string | null;
|
|
939
|
+
|
|
940
|
+
project_id?: string | null;
|
|
922
941
|
}
|
|
923
942
|
|
|
924
943
|
export interface BatchCancelParams {
|
|
@@ -943,12 +962,6 @@ export interface BatchCancelParams {
|
|
|
943
962
|
'temporal-namespace'?: string;
|
|
944
963
|
}
|
|
945
964
|
|
|
946
|
-
export interface BatchGetStatusParams {
|
|
947
|
-
organization_id?: string | null;
|
|
948
|
-
|
|
949
|
-
project_id?: string | null;
|
|
950
|
-
}
|
|
951
|
-
|
|
952
965
|
Batch.JobItems = JobItems;
|
|
953
966
|
|
|
954
967
|
export declare namespace Batch {
|
|
@@ -960,8 +973,8 @@ export declare namespace Batch {
|
|
|
960
973
|
type BatchListResponsesPaginatedBatchItems as BatchListResponsesPaginatedBatchItems,
|
|
961
974
|
type BatchCreateParams as BatchCreateParams,
|
|
962
975
|
type BatchListParams as BatchListParams,
|
|
963
|
-
type BatchCancelParams as BatchCancelParams,
|
|
964
976
|
type BatchGetStatusParams as BatchGetStatusParams,
|
|
977
|
+
type BatchCancelParams as BatchCancelParams,
|
|
965
978
|
};
|
|
966
979
|
|
|
967
980
|
export {
|
|
@@ -83,7 +83,7 @@ export interface JobItemListResponse {
|
|
|
83
83
|
/**
|
|
84
84
|
* Processing status of this item
|
|
85
85
|
*/
|
|
86
|
-
status: '
|
|
86
|
+
status: 'cancelled' | 'completed' | 'failed' | 'pending' | 'processing' | 'skipped';
|
|
87
87
|
|
|
88
88
|
/**
|
|
89
89
|
* When processing completed for this item
|
|
@@ -156,7 +156,7 @@ export namespace JobItemGetProcessingResultsResponse {
|
|
|
156
156
|
/**
|
|
157
157
|
* Type of processing performed
|
|
158
158
|
*/
|
|
159
|
-
job_type: '
|
|
159
|
+
job_type: 'classify' | 'extract' | 'parse';
|
|
160
160
|
|
|
161
161
|
/**
|
|
162
162
|
* Location of the processing output
|
|
@@ -363,7 +363,7 @@ export namespace JobItemGetProcessingResultsResponse {
|
|
|
363
363
|
|
|
364
364
|
ignore_document_elements_for_layout_detection?: boolean | null;
|
|
365
365
|
|
|
366
|
-
images_to_save?: Array<'
|
|
366
|
+
images_to_save?: Array<'embedded' | 'layout' | 'screenshot'> | null;
|
|
367
367
|
|
|
368
368
|
inline_images_in_markdown?: boolean | null;
|
|
369
369
|
|
|
@@ -477,7 +477,7 @@ export namespace JobItemGetProcessingResultsResponse {
|
|
|
477
477
|
* The priority for the request. This field may be ignored or overwritten depending
|
|
478
478
|
* on the organization tier.
|
|
479
479
|
*/
|
|
480
|
-
priority?: '
|
|
480
|
+
priority?: 'critical' | 'high' | 'low' | 'medium' | null;
|
|
481
481
|
|
|
482
482
|
project_id?: string | null;
|
|
483
483
|
|
|
@@ -569,28 +569,33 @@ export namespace JobItemGetProcessingResultsResponse {
|
|
|
569
569
|
* events are delivered.
|
|
570
570
|
*/
|
|
571
571
|
webhook_events?: Array<
|
|
572
|
-
| '
|
|
573
|
-
| '
|
|
572
|
+
| 'classify.cancelled'
|
|
573
|
+
| 'classify.error'
|
|
574
|
+
| 'classify.partial_success'
|
|
575
|
+
| 'classify.pending'
|
|
576
|
+
| 'classify.running'
|
|
577
|
+
| 'classify.success'
|
|
578
|
+
| 'extract.cancelled'
|
|
574
579
|
| 'extract.error'
|
|
575
580
|
| 'extract.partial_success'
|
|
576
|
-
| 'extract.
|
|
581
|
+
| 'extract.pending'
|
|
582
|
+
| 'extract.success'
|
|
583
|
+
| 'parse.cancelled'
|
|
584
|
+
| 'parse.error'
|
|
585
|
+
| 'parse.partial_success'
|
|
577
586
|
| 'parse.pending'
|
|
578
587
|
| 'parse.running'
|
|
579
588
|
| 'parse.success'
|
|
580
|
-
| '
|
|
581
|
-
| 'parse.partial_success'
|
|
582
|
-
| 'parse.cancelled'
|
|
583
|
-
| 'classify.pending'
|
|
584
|
-
| 'classify.running'
|
|
585
|
-
| 'classify.success'
|
|
586
|
-
| 'classify.error'
|
|
587
|
-
| 'classify.partial_success'
|
|
588
|
-
| 'classify.cancelled'
|
|
589
|
-
| 'sheets.pending'
|
|
590
|
-
| 'sheets.success'
|
|
589
|
+
| 'sheets.cancelled'
|
|
591
590
|
| 'sheets.error'
|
|
592
591
|
| 'sheets.partial_success'
|
|
593
|
-
| 'sheets.
|
|
592
|
+
| 'sheets.pending'
|
|
593
|
+
| 'sheets.success'
|
|
594
|
+
| 'split.cancelled'
|
|
595
|
+
| 'split.error'
|
|
596
|
+
| 'split.pending'
|
|
597
|
+
| 'split.processing'
|
|
598
|
+
| 'split.success'
|
|
594
599
|
| 'unmapped_event'
|
|
595
600
|
> | null;
|
|
596
601
|
|
|
@@ -604,6 +609,14 @@ export namespace JobItemGetProcessingResultsResponse {
|
|
|
604
609
|
*/
|
|
605
610
|
webhook_output_format?: string | null;
|
|
606
611
|
|
|
612
|
+
/**
|
|
613
|
+
* Shared signing secret used to sign webhook deliveries. When set, each request
|
|
614
|
+
* includes an HMAC-SHA256 signature of the request body in the 'LC-Signature'
|
|
615
|
+
* header (value 'sha256=<hex>'). Recompute the HMAC over the raw request body with
|
|
616
|
+
* this secret to verify the delivery is authentic.
|
|
617
|
+
*/
|
|
618
|
+
webhook_signing_secret?: string | null;
|
|
619
|
+
|
|
607
620
|
/**
|
|
608
621
|
* URL to receive webhook POST notifications
|
|
609
622
|
*/
|
|
@@ -622,14 +635,14 @@ export interface JobItemListParams extends PaginatedBatchItemsParams {
|
|
|
622
635
|
/**
|
|
623
636
|
* Filter items by status
|
|
624
637
|
*/
|
|
625
|
-
status?: '
|
|
638
|
+
status?: 'cancelled' | 'completed' | 'failed' | 'pending' | 'processing' | 'skipped' | null;
|
|
626
639
|
}
|
|
627
640
|
|
|
628
641
|
export interface JobItemGetProcessingResultsParams {
|
|
629
642
|
/**
|
|
630
643
|
* Filter results by job type
|
|
631
644
|
*/
|
|
632
|
-
job_type?: '
|
|
645
|
+
job_type?: 'classify' | 'extract' | 'parse' | null;
|
|
633
646
|
|
|
634
647
|
organization_id?: string | null;
|
|
635
648
|
|
|
@@ -144,11 +144,11 @@ export declare namespace Beta {
|
|
|
144
144
|
type IndexGetResponse as IndexGetResponse,
|
|
145
145
|
type IndexSyncResponse as IndexSyncResponse,
|
|
146
146
|
type IndexListResponsesPaginatedCursor as IndexListResponsesPaginatedCursor,
|
|
147
|
-
type IndexCreateParams as IndexCreateParams,
|
|
148
|
-
type IndexListParams as IndexListParams,
|
|
149
|
-
type IndexDeleteParams as IndexDeleteParams,
|
|
150
147
|
type IndexGetParams as IndexGetParams,
|
|
148
|
+
type IndexDeleteParams as IndexDeleteParams,
|
|
149
|
+
type IndexCreateParams as IndexCreateParams,
|
|
151
150
|
type IndexSyncParams as IndexSyncParams,
|
|
151
|
+
type IndexListParams as IndexListParams,
|
|
152
152
|
};
|
|
153
153
|
|
|
154
154
|
export {
|
|
@@ -173,9 +173,9 @@ export declare namespace Beta {
|
|
|
173
173
|
type ChatGetSummaryResponse as ChatGetSummaryResponse,
|
|
174
174
|
type ChatStreamResponse as ChatStreamResponse,
|
|
175
175
|
type ChatListResponsesPaginatedCursor as ChatListResponsesPaginatedCursor,
|
|
176
|
+
type ChatListParams as ChatListParams,
|
|
176
177
|
type ChatCreateParams as ChatCreateParams,
|
|
177
178
|
type ChatRetrieveParams as ChatRetrieveParams,
|
|
178
|
-
type ChatListParams as ChatListParams,
|
|
179
179
|
type ChatDeleteParams as ChatDeleteParams,
|
|
180
180
|
type ChatGetSummaryParams as ChatGetSummaryParams,
|
|
181
181
|
type ChatStreamParams as ChatStreamParams,
|
|
@@ -186,15 +186,15 @@ export declare namespace Beta {
|
|
|
186
186
|
type AgentDataDeleteResponse as AgentDataDeleteResponse,
|
|
187
187
|
type AgentDataAggregateResponse as AgentDataAggregateResponse,
|
|
188
188
|
type AgentDataDeleteByQueryResponse as AgentDataDeleteByQueryResponse,
|
|
189
|
-
type AgentDataAggregateResponsesPaginatedCursorPost as AgentDataAggregateResponsesPaginatedCursorPost,
|
|
190
189
|
type AgentDataPaginatedCursorPost as AgentDataPaginatedCursorPost,
|
|
191
|
-
type
|
|
190
|
+
type AgentDataAggregateResponsesPaginatedCursorPost as AgentDataAggregateResponsesPaginatedCursorPost,
|
|
191
|
+
type AgentDataGetParams as AgentDataGetParams,
|
|
192
192
|
type AgentDataUpdateParams as AgentDataUpdateParams,
|
|
193
193
|
type AgentDataDeleteParams as AgentDataDeleteParams,
|
|
194
|
+
type AgentDataCreateParams as AgentDataCreateParams,
|
|
195
|
+
type AgentDataSearchParams as AgentDataSearchParams,
|
|
194
196
|
type AgentDataAggregateParams as AgentDataAggregateParams,
|
|
195
197
|
type AgentDataDeleteByQueryParams as AgentDataDeleteByQueryParams,
|
|
196
|
-
type AgentDataGetParams as AgentDataGetParams,
|
|
197
|
-
type AgentDataSearchParams as AgentDataSearchParams,
|
|
198
198
|
};
|
|
199
199
|
|
|
200
200
|
export {
|
|
@@ -205,9 +205,9 @@ export declare namespace Beta {
|
|
|
205
205
|
type SheetsJobsPaginatedCursor as SheetsJobsPaginatedCursor,
|
|
206
206
|
type SheetCreateParams as SheetCreateParams,
|
|
207
207
|
type SheetListParams as SheetListParams,
|
|
208
|
-
type SheetDeleteJobParams as SheetDeleteJobParams,
|
|
209
208
|
type SheetGetParams as SheetGetParams,
|
|
210
209
|
type SheetGetResultTableParams as SheetGetResultTableParams,
|
|
210
|
+
type SheetDeleteJobParams as SheetDeleteJobParams,
|
|
211
211
|
};
|
|
212
212
|
|
|
213
213
|
export {
|
|
@@ -218,10 +218,10 @@ export declare namespace Beta {
|
|
|
218
218
|
type DirectoryGetResponse as DirectoryGetResponse,
|
|
219
219
|
type DirectoryListResponsesPaginatedCursor as DirectoryListResponsesPaginatedCursor,
|
|
220
220
|
type DirectoryCreateParams as DirectoryCreateParams,
|
|
221
|
-
type DirectoryUpdateParams as DirectoryUpdateParams,
|
|
222
221
|
type DirectoryListParams as DirectoryListParams,
|
|
223
|
-
type DirectoryDeleteParams as DirectoryDeleteParams,
|
|
224
222
|
type DirectoryGetParams as DirectoryGetParams,
|
|
223
|
+
type DirectoryUpdateParams as DirectoryUpdateParams,
|
|
224
|
+
type DirectoryDeleteParams as DirectoryDeleteParams,
|
|
225
225
|
};
|
|
226
226
|
|
|
227
227
|
export {
|
|
@@ -233,8 +233,8 @@ export declare namespace Beta {
|
|
|
233
233
|
type BatchListResponsesPaginatedBatchItems as BatchListResponsesPaginatedBatchItems,
|
|
234
234
|
type BatchCreateParams as BatchCreateParams,
|
|
235
235
|
type BatchListParams as BatchListParams,
|
|
236
|
-
type BatchCancelParams as BatchCancelParams,
|
|
237
236
|
type BatchGetStatusParams as BatchGetStatusParams,
|
|
237
|
+
type BatchCancelParams as BatchCancelParams,
|
|
238
238
|
};
|
|
239
239
|
|
|
240
240
|
export {
|
|
@@ -8,6 +8,24 @@ import { RequestOptions } from '../../internal/request-options';
|
|
|
8
8
|
import { path } from '../../internal/utils/path';
|
|
9
9
|
|
|
10
10
|
export class Chat extends APIResource {
|
|
11
|
+
/**
|
|
12
|
+
* List all chat sessions for the current project.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* // Automatically fetches more pages as needed.
|
|
17
|
+
* for await (const chatListResponse of client.beta.chat.list()) {
|
|
18
|
+
* // ...
|
|
19
|
+
* }
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
list(
|
|
23
|
+
query: ChatListParams | null | undefined = {},
|
|
24
|
+
options?: RequestOptions,
|
|
25
|
+
): PagePromise<ChatListResponsesPaginatedCursor, ChatListResponse> {
|
|
26
|
+
return this._client.getAPIList('/api/v1/chat', PaginatedCursor<ChatListResponse>, { query, ...options });
|
|
27
|
+
}
|
|
28
|
+
|
|
11
29
|
/**
|
|
12
30
|
* Create a chat session, optionally bound to indexes (locked after the first
|
|
13
31
|
* message).
|
|
@@ -41,24 +59,6 @@ export class Chat extends APIResource {
|
|
|
41
59
|
return this._client.get(path`/api/v1/chat/${sessionID}`, { query, ...options });
|
|
42
60
|
}
|
|
43
61
|
|
|
44
|
-
/**
|
|
45
|
-
* List all chat sessions for the current project.
|
|
46
|
-
*
|
|
47
|
-
* @example
|
|
48
|
-
* ```ts
|
|
49
|
-
* // Automatically fetches more pages as needed.
|
|
50
|
-
* for await (const chatListResponse of client.beta.chat.list()) {
|
|
51
|
-
* // ...
|
|
52
|
-
* }
|
|
53
|
-
* ```
|
|
54
|
-
*/
|
|
55
|
-
list(
|
|
56
|
-
query: ChatListParams | null | undefined = {},
|
|
57
|
-
options?: RequestOptions,
|
|
58
|
-
): PagePromise<ChatListResponsesPaginatedCursor, ChatListResponse> {
|
|
59
|
-
return this._client.getAPIList('/api/v1/chat', PaginatedCursor<ChatListResponse>, { query, ...options });
|
|
60
|
-
}
|
|
61
|
-
|
|
62
62
|
/**
|
|
63
63
|
* Delete a session.
|
|
64
64
|
*
|
|
@@ -185,13 +185,13 @@ export interface ChatRetrieveResponse {
|
|
|
185
185
|
* Ordered list of events that make up the conversation history.
|
|
186
186
|
*/
|
|
187
187
|
events: Array<
|
|
188
|
-
| ChatRetrieveResponse.
|
|
188
|
+
| ChatRetrieveResponse.StopEvent
|
|
189
189
|
| ChatRetrieveResponse.TextDeltaEvent
|
|
190
|
-
| ChatRetrieveResponse.ThinkingEvent
|
|
191
190
|
| ChatRetrieveResponse.TextEvent
|
|
191
|
+
| ChatRetrieveResponse.ThinkingDeltaEvent
|
|
192
|
+
| ChatRetrieveResponse.ThinkingEvent
|
|
192
193
|
| ChatRetrieveResponse.ToolCallEvent
|
|
193
194
|
| ChatRetrieveResponse.ToolResultEvent
|
|
194
|
-
| ChatRetrieveResponse.StopEvent
|
|
195
195
|
| ChatRetrieveResponse.UserInputEvent
|
|
196
196
|
>;
|
|
197
197
|
|
|
@@ -223,10 +223,26 @@ export interface ChatRetrieveResponse {
|
|
|
223
223
|
}
|
|
224
224
|
|
|
225
225
|
export namespace ChatRetrieveResponse {
|
|
226
|
-
export interface
|
|
227
|
-
|
|
226
|
+
export interface StopEvent {
|
|
227
|
+
error: string | null;
|
|
228
228
|
|
|
229
|
-
|
|
229
|
+
is_error: boolean;
|
|
230
|
+
|
|
231
|
+
usage: StopEvent.Usage;
|
|
232
|
+
|
|
233
|
+
type?: 'stop';
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
export namespace StopEvent {
|
|
237
|
+
export interface Usage {
|
|
238
|
+
duration_ms?: number;
|
|
239
|
+
|
|
240
|
+
total_input_tokens?: number | null;
|
|
241
|
+
|
|
242
|
+
total_output_tokens?: number | null;
|
|
243
|
+
|
|
244
|
+
turns?: number;
|
|
245
|
+
}
|
|
230
246
|
}
|
|
231
247
|
|
|
232
248
|
export interface TextDeltaEvent {
|
|
@@ -235,16 +251,22 @@ export namespace ChatRetrieveResponse {
|
|
|
235
251
|
type?: 'text_delta';
|
|
236
252
|
}
|
|
237
253
|
|
|
238
|
-
export interface
|
|
254
|
+
export interface TextEvent {
|
|
239
255
|
content: string;
|
|
240
256
|
|
|
241
|
-
type?: '
|
|
257
|
+
type?: 'text';
|
|
242
258
|
}
|
|
243
259
|
|
|
244
|
-
export interface
|
|
260
|
+
export interface ThinkingDeltaEvent {
|
|
245
261
|
content: string;
|
|
246
262
|
|
|
247
|
-
type?: '
|
|
263
|
+
type?: 'thinking_delta';
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
export interface ThinkingEvent {
|
|
267
|
+
content: string;
|
|
268
|
+
|
|
269
|
+
type?: 'thinking';
|
|
248
270
|
}
|
|
249
271
|
|
|
250
272
|
export interface ToolCallEvent {
|
|
@@ -283,28 +305,6 @@ export namespace ChatRetrieveResponse {
|
|
|
283
305
|
}
|
|
284
306
|
}
|
|
285
307
|
|
|
286
|
-
export interface StopEvent {
|
|
287
|
-
error: string | null;
|
|
288
|
-
|
|
289
|
-
is_error: boolean;
|
|
290
|
-
|
|
291
|
-
usage: StopEvent.Usage;
|
|
292
|
-
|
|
293
|
-
type?: 'stop';
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
export namespace StopEvent {
|
|
297
|
-
export interface Usage {
|
|
298
|
-
duration_ms?: number;
|
|
299
|
-
|
|
300
|
-
total_input_tokens?: number | null;
|
|
301
|
-
|
|
302
|
-
total_output_tokens?: number | null;
|
|
303
|
-
|
|
304
|
-
turns?: number;
|
|
305
|
-
}
|
|
306
|
-
}
|
|
307
|
-
|
|
308
308
|
export interface UserInputEvent {
|
|
309
309
|
content: string;
|
|
310
310
|
|
|
@@ -440,6 +440,12 @@ export namespace ChatGetSummaryResponse {
|
|
|
440
440
|
|
|
441
441
|
export type ChatStreamResponse = unknown;
|
|
442
442
|
|
|
443
|
+
export interface ChatListParams extends PaginatedCursorParams {
|
|
444
|
+
organization_id?: string | null;
|
|
445
|
+
|
|
446
|
+
project_id?: string | null;
|
|
447
|
+
}
|
|
448
|
+
|
|
443
449
|
export interface ChatCreateParams {
|
|
444
450
|
/**
|
|
445
451
|
* Query param
|
|
@@ -465,12 +471,6 @@ export interface ChatRetrieveParams {
|
|
|
465
471
|
project_id?: string | null;
|
|
466
472
|
}
|
|
467
473
|
|
|
468
|
-
export interface ChatListParams extends PaginatedCursorParams {
|
|
469
|
-
organization_id?: string | null;
|
|
470
|
-
|
|
471
|
-
project_id?: string | null;
|
|
472
|
-
}
|
|
473
|
-
|
|
474
474
|
export interface ChatDeleteParams {
|
|
475
475
|
organization_id?: string | null;
|
|
476
476
|
|
|
@@ -513,9 +513,9 @@ export declare namespace Chat {
|
|
|
513
513
|
type ChatGetSummaryResponse as ChatGetSummaryResponse,
|
|
514
514
|
type ChatStreamResponse as ChatStreamResponse,
|
|
515
515
|
type ChatListResponsesPaginatedCursor as ChatListResponsesPaginatedCursor,
|
|
516
|
+
type ChatListParams as ChatListParams,
|
|
516
517
|
type ChatCreateParams as ChatCreateParams,
|
|
517
518
|
type ChatRetrieveParams as ChatRetrieveParams,
|
|
518
|
-
type ChatListParams as ChatListParams,
|
|
519
519
|
type ChatDeleteParams as ChatDeleteParams,
|
|
520
520
|
type ChatGetSummaryParams as ChatGetSummaryParams,
|
|
521
521
|
type ChatStreamParams as ChatStreamParams,
|