@mixedbread/sdk 0.11.1 → 0.13.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 +27 -0
- package/README.md +0 -31
- package/client.d.mts +6 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +6 -6
- package/client.d.ts.map +1 -1
- package/client.mjs.map +1 -1
- package/core/pagination.d.mts +9 -5
- package/core/pagination.d.mts.map +1 -1
- package/core/pagination.d.ts +9 -5
- package/core/pagination.d.ts.map +1 -1
- package/core/pagination.js +16 -2
- package/core/pagination.js.map +1 -1
- package/core/pagination.mjs +16 -2
- package/core/pagination.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/data-sources/connectors.d.mts +106 -5
- package/resources/data-sources/connectors.d.mts.map +1 -1
- package/resources/data-sources/connectors.d.ts +106 -5
- package/resources/data-sources/connectors.d.ts.map +1 -1
- package/resources/data-sources/connectors.js +1 -2
- package/resources/data-sources/connectors.js.map +1 -1
- package/resources/data-sources/connectors.mjs +1 -2
- package/resources/data-sources/connectors.mjs.map +1 -1
- package/resources/data-sources/data-sources.d.mts +108 -7
- package/resources/data-sources/data-sources.d.mts.map +1 -1
- package/resources/data-sources/data-sources.d.ts +108 -7
- package/resources/data-sources/data-sources.d.ts.map +1 -1
- package/resources/data-sources/data-sources.js +1 -2
- package/resources/data-sources/data-sources.js.map +1 -1
- package/resources/data-sources/data-sources.mjs +1 -2
- package/resources/data-sources/data-sources.mjs.map +1 -1
- package/resources/data-sources/index.d.mts +2 -2
- package/resources/data-sources/index.d.mts.map +1 -1
- package/resources/data-sources/index.d.ts +2 -2
- package/resources/data-sources/index.d.ts.map +1 -1
- package/resources/files.d.mts +107 -5
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +107 -5
- package/resources/files.d.ts.map +1 -1
- package/resources/files.js +1 -2
- package/resources/files.js.map +1 -1
- package/resources/files.mjs +1 -2
- package/resources/files.mjs.map +1 -1
- package/resources/index.d.mts +3 -3
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -3
- package/resources/index.d.ts.map +1 -1
- package/resources/parsing/index.d.mts +1 -1
- package/resources/parsing/index.d.mts.map +1 -1
- package/resources/parsing/index.d.ts +1 -1
- package/resources/parsing/index.d.ts.map +1 -1
- package/resources/parsing/index.js.map +1 -1
- package/resources/parsing/index.mjs.map +1 -1
- package/resources/parsing/jobs.d.mts +134 -29
- package/resources/parsing/jobs.d.mts.map +1 -1
- package/resources/parsing/jobs.d.ts +134 -29
- package/resources/parsing/jobs.d.ts.map +1 -1
- package/resources/parsing/jobs.js +1 -2
- package/resources/parsing/jobs.js.map +1 -1
- package/resources/parsing/jobs.mjs +1 -2
- package/resources/parsing/jobs.mjs.map +1 -1
- package/resources/parsing/parsing.d.mts +2 -2
- package/resources/parsing/parsing.d.mts.map +1 -1
- package/resources/parsing/parsing.d.ts +2 -2
- package/resources/parsing/parsing.d.ts.map +1 -1
- package/resources/parsing/parsing.js.map +1 -1
- package/resources/parsing/parsing.mjs.map +1 -1
- package/resources/vector-stores/files.d.mts +103 -5
- package/resources/vector-stores/files.d.mts.map +1 -1
- package/resources/vector-stores/files.d.ts +103 -5
- package/resources/vector-stores/files.d.ts.map +1 -1
- package/resources/vector-stores/files.js +1 -2
- package/resources/vector-stores/files.js.map +1 -1
- package/resources/vector-stores/files.mjs +1 -2
- package/resources/vector-stores/files.mjs.map +1 -1
- package/resources/vector-stores/index.d.mts +2 -2
- package/resources/vector-stores/index.d.mts.map +1 -1
- package/resources/vector-stores/index.d.ts +2 -2
- package/resources/vector-stores/index.d.ts.map +1 -1
- package/resources/vector-stores/vector-stores.d.mts +105 -7
- package/resources/vector-stores/vector-stores.d.mts.map +1 -1
- package/resources/vector-stores/vector-stores.d.ts +105 -7
- package/resources/vector-stores/vector-stores.d.ts.map +1 -1
- package/resources/vector-stores/vector-stores.js +1 -2
- package/resources/vector-stores/vector-stores.js.map +1 -1
- package/resources/vector-stores/vector-stores.mjs +1 -2
- package/resources/vector-stores/vector-stores.mjs.map +1 -1
- package/src/client.ts +6 -6
- package/src/core/pagination.ts +29 -8
- package/src/resources/data-sources/connectors.ts +118 -11
- package/src/resources/data-sources/data-sources.ts +120 -9
- package/src/resources/data-sources/index.ts +2 -2
- package/src/resources/files.ts +120 -7
- package/src/resources/index.ts +3 -3
- package/src/resources/parsing/index.ts +0 -1
- package/src/resources/parsing/jobs.ts +146 -34
- package/src/resources/parsing/parsing.ts +0 -2
- package/src/resources/vector-stores/files.ts +115 -11
- package/src/resources/vector-stores/index.ts +2 -2
- package/src/resources/vector-stores/vector-stores.ts +117 -9
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
@@ -3,7 +3,6 @@
|
|
3
3
|
import { APIResource } from '../../core/resource';
|
4
4
|
import * as JobsAPI from './jobs';
|
5
5
|
import { APIPromise } from '../../core/api-promise';
|
6
|
-
import { Cursor, type CursorParams, PagePromise } from '../../core/pagination';
|
7
6
|
import { RequestOptions } from '../../internal/request-options';
|
8
7
|
import { path } from '../../internal/utils/path';
|
9
8
|
import * as polling from '../../lib/polling';
|
@@ -39,11 +38,8 @@ export class Jobs extends APIResource {
|
|
39
38
|
*
|
40
39
|
* Returns: List of parsing jobs with pagination.
|
41
40
|
*/
|
42
|
-
list(
|
43
|
-
|
44
|
-
options?: RequestOptions,
|
45
|
-
): PagePromise<JobListResponsesCursor, JobListResponse> {
|
46
|
-
return this._client.getAPIList('/v1/parsing/jobs', Cursor<JobListResponse>, { query, ...options });
|
41
|
+
list(query: JobListParams | null | undefined = {}, options?: RequestOptions): APIPromise<JobListResponse> {
|
42
|
+
return this._client.get('/v1/parsing/jobs', { query, ...options });
|
47
43
|
}
|
48
44
|
|
49
45
|
/**
|
@@ -161,8 +157,6 @@ export class Jobs extends APIResource {
|
|
161
157
|
}
|
162
158
|
}
|
163
159
|
|
164
|
-
export type JobListResponsesCursor = Cursor<JobListResponse>;
|
165
|
-
|
166
160
|
/**
|
167
161
|
* Strategy used for chunking document content.
|
168
162
|
*/
|
@@ -338,48 +332,140 @@ export namespace ParsingJob {
|
|
338
332
|
export type ReturnFormat = 'html' | 'markdown' | 'plain';
|
339
333
|
|
340
334
|
/**
|
341
|
-
* A
|
335
|
+
* A list of parsing jobs with pagination.
|
342
336
|
*/
|
343
337
|
export interface JobListResponse {
|
344
338
|
/**
|
345
|
-
*
|
339
|
+
* Response model for cursor-based pagination.
|
340
|
+
*
|
341
|
+
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
342
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
343
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
344
|
+
*
|
345
|
+
* Final page response:
|
346
|
+
* {
|
347
|
+
* "has_more": false,
|
348
|
+
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
349
|
+
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
350
|
+
* "total": 42
|
351
|
+
* }
|
352
|
+
*
|
353
|
+
* Empty results:
|
354
|
+
* {
|
355
|
+
* "has_more": false,
|
356
|
+
* "first_cursor": null,
|
357
|
+
* "last_cursor": null,
|
358
|
+
* "total": 0
|
359
|
+
* }
|
346
360
|
*/
|
347
|
-
|
361
|
+
pagination: JobListResponse.Pagination;
|
348
362
|
|
349
363
|
/**
|
350
|
-
* The
|
364
|
+
* The list of parsing jobs
|
351
365
|
*/
|
352
|
-
|
366
|
+
data: Array<JobListResponse.Data>;
|
353
367
|
|
354
368
|
/**
|
355
|
-
* The
|
369
|
+
* The object type of the response
|
356
370
|
*/
|
357
|
-
|
371
|
+
object?: 'list';
|
372
|
+
}
|
358
373
|
|
374
|
+
export namespace JobListResponse {
|
359
375
|
/**
|
360
|
-
*
|
361
|
-
|
362
|
-
|
376
|
+
* Response model for cursor-based pagination.
|
377
|
+
*
|
378
|
+
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
379
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
380
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
381
|
+
*
|
382
|
+
* Final page response:
|
383
|
+
* {
|
384
|
+
* "has_more": false,
|
385
|
+
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
386
|
+
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
387
|
+
* "total": 42
|
388
|
+
* }
|
389
|
+
*
|
390
|
+
* Empty results:
|
391
|
+
* {
|
392
|
+
* "has_more": false,
|
393
|
+
* "first_cursor": null,
|
394
|
+
* "last_cursor": null,
|
395
|
+
* "total": 0
|
396
|
+
* }
|
397
|
+
*/
|
398
|
+
export interface Pagination {
|
399
|
+
/**
|
400
|
+
* Contextual direction-aware flag: True if more items exist in the requested
|
401
|
+
* pagination direction. For 'after': more items after this page. For 'before':
|
402
|
+
* more items before this page.
|
403
|
+
*/
|
404
|
+
has_more: boolean;
|
363
405
|
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
406
|
+
/**
|
407
|
+
* Cursor of the first item in this page. Use for backward pagination. None if page
|
408
|
+
* is empty.
|
409
|
+
*/
|
410
|
+
first_cursor: string | null;
|
368
411
|
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
412
|
+
/**
|
413
|
+
* Cursor of the last item in this page. Use for forward pagination. None if page
|
414
|
+
* is empty.
|
415
|
+
*/
|
416
|
+
last_cursor: string | null;
|
373
417
|
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
418
|
+
/**
|
419
|
+
* Total number of items available across all pages. Only included when
|
420
|
+
* include_total=true was requested. Expensive operation - use sparingly.
|
421
|
+
*/
|
422
|
+
total?: number | null;
|
423
|
+
}
|
378
424
|
|
379
425
|
/**
|
380
|
-
*
|
426
|
+
* A parsing job item for list responses, omitting result and error fields.
|
381
427
|
*/
|
382
|
-
|
428
|
+
export interface Data {
|
429
|
+
/**
|
430
|
+
* The ID of the job
|
431
|
+
*/
|
432
|
+
id: string;
|
433
|
+
|
434
|
+
/**
|
435
|
+
* The ID of the file to parse
|
436
|
+
*/
|
437
|
+
file_id: string;
|
438
|
+
|
439
|
+
/**
|
440
|
+
* The status of the job
|
441
|
+
*/
|
442
|
+
status: JobsAPI.ParsingJobStatus;
|
443
|
+
|
444
|
+
/**
|
445
|
+
* The started time of the job
|
446
|
+
*/
|
447
|
+
started_at?: string | null;
|
448
|
+
|
449
|
+
/**
|
450
|
+
* The finished time of the job
|
451
|
+
*/
|
452
|
+
finished_at?: string | null;
|
453
|
+
|
454
|
+
/**
|
455
|
+
* The creation time of the job
|
456
|
+
*/
|
457
|
+
created_at?: string;
|
458
|
+
|
459
|
+
/**
|
460
|
+
* The updated time of the job
|
461
|
+
*/
|
462
|
+
updated_at?: string | null;
|
463
|
+
|
464
|
+
/**
|
465
|
+
* The type of the object
|
466
|
+
*/
|
467
|
+
object?: 'parsing_job';
|
468
|
+
}
|
383
469
|
}
|
384
470
|
|
385
471
|
/**
|
@@ -429,7 +515,34 @@ export interface JobCreateParams {
|
|
429
515
|
mode?: 'fast' | 'high_quality';
|
430
516
|
}
|
431
517
|
|
432
|
-
export interface JobListParams
|
518
|
+
export interface JobListParams {
|
519
|
+
/**
|
520
|
+
* Maximum number of items to return per page (1-100)
|
521
|
+
*/
|
522
|
+
limit?: number;
|
523
|
+
|
524
|
+
/**
|
525
|
+
* Cursor for forward pagination - get items after this position. Use last_cursor
|
526
|
+
* from previous response.
|
527
|
+
*/
|
528
|
+
after?: string | null;
|
529
|
+
|
530
|
+
/**
|
531
|
+
* Cursor for backward pagination - get items before this position. Use
|
532
|
+
* first_cursor from previous response.
|
533
|
+
*/
|
534
|
+
before?: string | null;
|
535
|
+
|
536
|
+
/**
|
537
|
+
* Whether to include total count in response (expensive operation)
|
538
|
+
*/
|
539
|
+
include_total?: boolean;
|
540
|
+
|
541
|
+
/**
|
542
|
+
* Status to filter by
|
543
|
+
*/
|
544
|
+
statuses?: Array<ParsingJobStatus> | null;
|
545
|
+
}
|
433
546
|
|
434
547
|
export declare namespace Jobs {
|
435
548
|
export {
|
@@ -440,7 +553,6 @@ export declare namespace Jobs {
|
|
440
553
|
type ReturnFormat as ReturnFormat,
|
441
554
|
type JobListResponse as JobListResponse,
|
442
555
|
type JobDeleteResponse as JobDeleteResponse,
|
443
|
-
type JobListResponsesCursor as JobListResponsesCursor,
|
444
556
|
type JobCreateParams as JobCreateParams,
|
445
557
|
type JobListParams as JobListParams,
|
446
558
|
};
|
@@ -9,7 +9,6 @@ import {
|
|
9
9
|
JobDeleteResponse,
|
10
10
|
JobListParams,
|
11
11
|
JobListResponse,
|
12
|
-
JobListResponsesCursor,
|
13
12
|
Jobs,
|
14
13
|
ParsingJob,
|
15
14
|
ParsingJobStatus,
|
@@ -32,7 +31,6 @@ export declare namespace Parsing {
|
|
32
31
|
type ReturnFormat as ReturnFormat,
|
33
32
|
type JobListResponse as JobListResponse,
|
34
33
|
type JobDeleteResponse as JobDeleteResponse,
|
35
|
-
type JobListResponsesCursor as JobListResponsesCursor,
|
36
34
|
type JobCreateParams as JobCreateParams,
|
37
35
|
type JobListParams as JobListParams,
|
38
36
|
};
|
@@ -5,7 +5,6 @@ import * as FilesAPI from './files';
|
|
5
5
|
import * as Shared from '../shared';
|
6
6
|
import * as VectorStoresAPI from './vector-stores';
|
7
7
|
import { APIPromise } from '../../core/api-promise';
|
8
|
-
import { Cursor, type CursorParams, PagePromise } from '../../core/pagination';
|
9
8
|
import { RequestOptions } from '../../internal/request-options';
|
10
9
|
import * as polling from '../../lib/polling';
|
11
10
|
import { Uploadable } from '../../uploads';
|
@@ -57,12 +56,8 @@ export class Files extends APIResource {
|
|
57
56
|
vectorStoreIdentifier: string,
|
58
57
|
query: FileListParams | null | undefined = {},
|
59
58
|
options?: RequestOptions,
|
60
|
-
):
|
61
|
-
return this._client.
|
62
|
-
path`/v1/vector_stores/${vectorStoreIdentifier}/files`,
|
63
|
-
Cursor<VectorStoreFile>,
|
64
|
-
{ query, ...options },
|
65
|
-
);
|
59
|
+
): APIPromise<FileListResponse> {
|
60
|
+
return this._client.get(path`/v1/vector_stores/${vectorStoreIdentifier}/files`, { query, ...options });
|
66
61
|
}
|
67
62
|
|
68
63
|
/**
|
@@ -202,8 +197,6 @@ export class Files extends APIResource {
|
|
202
197
|
}
|
203
198
|
}
|
204
199
|
|
205
|
-
export type VectorStoreFilesCursor = Cursor<VectorStoreFile>;
|
206
|
-
|
207
200
|
/**
|
208
201
|
* Represents a reranking configuration.
|
209
202
|
*/
|
@@ -352,6 +345,95 @@ export interface VectorStoreFile {
|
|
352
345
|
object?: 'vector_store.file';
|
353
346
|
}
|
354
347
|
|
348
|
+
export interface FileListResponse {
|
349
|
+
/**
|
350
|
+
* Response model for cursor-based pagination.
|
351
|
+
*
|
352
|
+
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
353
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
354
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
355
|
+
*
|
356
|
+
* Final page response:
|
357
|
+
* {
|
358
|
+
* "has_more": false,
|
359
|
+
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
360
|
+
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
361
|
+
* "total": 42
|
362
|
+
* }
|
363
|
+
*
|
364
|
+
* Empty results:
|
365
|
+
* {
|
366
|
+
* "has_more": false,
|
367
|
+
* "first_cursor": null,
|
368
|
+
* "last_cursor": null,
|
369
|
+
* "total": 0
|
370
|
+
* }
|
371
|
+
*/
|
372
|
+
pagination: FileListResponse.Pagination;
|
373
|
+
|
374
|
+
/**
|
375
|
+
* The object type of the response
|
376
|
+
*/
|
377
|
+
object?: 'list';
|
378
|
+
|
379
|
+
/**
|
380
|
+
* The list of vector store files
|
381
|
+
*/
|
382
|
+
data: Array<VectorStoreFile>;
|
383
|
+
}
|
384
|
+
|
385
|
+
export namespace FileListResponse {
|
386
|
+
/**
|
387
|
+
* Response model for cursor-based pagination.
|
388
|
+
*
|
389
|
+
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
390
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
391
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
392
|
+
*
|
393
|
+
* Final page response:
|
394
|
+
* {
|
395
|
+
* "has_more": false,
|
396
|
+
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
397
|
+
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
398
|
+
* "total": 42
|
399
|
+
* }
|
400
|
+
*
|
401
|
+
* Empty results:
|
402
|
+
* {
|
403
|
+
* "has_more": false,
|
404
|
+
* "first_cursor": null,
|
405
|
+
* "last_cursor": null,
|
406
|
+
* "total": 0
|
407
|
+
* }
|
408
|
+
*/
|
409
|
+
export interface Pagination {
|
410
|
+
/**
|
411
|
+
* Contextual direction-aware flag: True if more items exist in the requested
|
412
|
+
* pagination direction. For 'after': more items after this page. For 'before':
|
413
|
+
* more items before this page.
|
414
|
+
*/
|
415
|
+
has_more: boolean;
|
416
|
+
|
417
|
+
/**
|
418
|
+
* Cursor of the first item in this page. Use for backward pagination. None if page
|
419
|
+
* is empty.
|
420
|
+
*/
|
421
|
+
first_cursor: string | null;
|
422
|
+
|
423
|
+
/**
|
424
|
+
* Cursor of the last item in this page. Use for forward pagination. None if page
|
425
|
+
* is empty.
|
426
|
+
*/
|
427
|
+
last_cursor: string | null;
|
428
|
+
|
429
|
+
/**
|
430
|
+
* Total number of items available across all pages. Only included when
|
431
|
+
* include_total=true was requested. Expensive operation - use sparingly.
|
432
|
+
*/
|
433
|
+
total?: number | null;
|
434
|
+
}
|
435
|
+
}
|
436
|
+
|
355
437
|
/**
|
356
438
|
* Response model for file deletion.
|
357
439
|
*/
|
@@ -425,7 +507,29 @@ export interface FileRetrieveParams {
|
|
425
507
|
vector_store_identifier: string;
|
426
508
|
}
|
427
509
|
|
428
|
-
export interface FileListParams
|
510
|
+
export interface FileListParams {
|
511
|
+
/**
|
512
|
+
* Maximum number of items to return per page (1-100)
|
513
|
+
*/
|
514
|
+
limit?: number;
|
515
|
+
|
516
|
+
/**
|
517
|
+
* Cursor for forward pagination - get items after this position. Use last_cursor
|
518
|
+
* from previous response.
|
519
|
+
*/
|
520
|
+
after?: string | null;
|
521
|
+
|
522
|
+
/**
|
523
|
+
* Cursor for backward pagination - get items before this position. Use
|
524
|
+
* first_cursor from previous response.
|
525
|
+
*/
|
526
|
+
before?: string | null;
|
527
|
+
|
528
|
+
/**
|
529
|
+
* Whether to include total count in response (expensive operation)
|
530
|
+
*/
|
531
|
+
include_total?: boolean;
|
532
|
+
|
429
533
|
/**
|
430
534
|
* Status to filter by
|
431
535
|
*/
|
@@ -523,9 +627,9 @@ export declare namespace Files {
|
|
523
627
|
type ScoredVectorStoreFile as ScoredVectorStoreFile,
|
524
628
|
type VectorStoreFileStatus as VectorStoreFileStatus,
|
525
629
|
type VectorStoreFile as VectorStoreFile,
|
630
|
+
type FileListResponse as FileListResponse,
|
526
631
|
type FileDeleteResponse as FileDeleteResponse,
|
527
632
|
type FileSearchResponse as FileSearchResponse,
|
528
|
-
type VectorStoreFilesCursor as VectorStoreFilesCursor,
|
529
633
|
type FileCreateParams as FileCreateParams,
|
530
634
|
type FileRetrieveParams as FileRetrieveParams,
|
531
635
|
type FileListParams as FileListParams,
|
@@ -6,6 +6,7 @@ export {
|
|
6
6
|
type ScoredVectorStoreFile,
|
7
7
|
type VectorStoreFileStatus,
|
8
8
|
type VectorStoreFile,
|
9
|
+
type FileListResponse,
|
9
10
|
type FileDeleteResponse,
|
10
11
|
type FileSearchResponse,
|
11
12
|
type FileCreateParams,
|
@@ -13,7 +14,6 @@ export {
|
|
13
14
|
type FileListParams,
|
14
15
|
type FileDeleteParams,
|
15
16
|
type FileSearchParams,
|
16
|
-
type VectorStoreFilesCursor,
|
17
17
|
} from './files';
|
18
18
|
export {
|
19
19
|
VectorStores,
|
@@ -24,6 +24,7 @@ export {
|
|
24
24
|
type ScoredVideoURLInputChunk,
|
25
25
|
type VectorStore,
|
26
26
|
type VectorStoreChunkSearchOptions,
|
27
|
+
type VectorStoreListResponse,
|
27
28
|
type VectorStoreDeleteResponse,
|
28
29
|
type VectorStoreQuestionAnsweringResponse,
|
29
30
|
type VectorStoreSearchResponse,
|
@@ -32,5 +33,4 @@ export {
|
|
32
33
|
type VectorStoreListParams,
|
33
34
|
type VectorStoreQuestionAnsweringParams,
|
34
35
|
type VectorStoreSearchParams,
|
35
|
-
type VectorStoresCursor,
|
36
36
|
} from './vector-stores';
|
@@ -8,6 +8,7 @@ import {
|
|
8
8
|
FileDeleteParams,
|
9
9
|
FileDeleteResponse,
|
10
10
|
FileListParams,
|
11
|
+
FileListResponse,
|
11
12
|
FileRetrieveParams,
|
12
13
|
FileSearchParams,
|
13
14
|
FileSearchResponse,
|
@@ -16,10 +17,8 @@ import {
|
|
16
17
|
ScoredVectorStoreFile,
|
17
18
|
VectorStoreFile,
|
18
19
|
VectorStoreFileStatus,
|
19
|
-
VectorStoreFilesCursor,
|
20
20
|
} from './files';
|
21
21
|
import { APIPromise } from '../../core/api-promise';
|
22
|
-
import { Cursor, type CursorParams, PagePromise } from '../../core/pagination';
|
23
22
|
import { RequestOptions } from '../../internal/request-options';
|
24
23
|
import { path } from '../../internal/utils/path';
|
25
24
|
|
@@ -77,8 +76,8 @@ export class VectorStores extends APIResource {
|
|
77
76
|
list(
|
78
77
|
query: VectorStoreListParams | null | undefined = {},
|
79
78
|
options?: RequestOptions,
|
80
|
-
):
|
81
|
-
return this._client.
|
79
|
+
): APIPromise<VectorStoreListResponse> {
|
80
|
+
return this._client.get('/v1/vector_stores', { query, ...options });
|
82
81
|
}
|
83
82
|
|
84
83
|
/**
|
@@ -126,8 +125,6 @@ export class VectorStores extends APIResource {
|
|
126
125
|
}
|
127
126
|
}
|
128
127
|
|
129
|
-
export type VectorStoresCursor = Cursor<VectorStore>;
|
130
|
-
|
131
128
|
/**
|
132
129
|
* Represents an expiration policy for a vector store.
|
133
130
|
*/
|
@@ -579,6 +576,95 @@ export interface VectorStoreChunkSearchOptions {
|
|
579
576
|
return_metadata?: boolean;
|
580
577
|
}
|
581
578
|
|
579
|
+
export interface VectorStoreListResponse {
|
580
|
+
/**
|
581
|
+
* Response model for cursor-based pagination.
|
582
|
+
*
|
583
|
+
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
584
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
585
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
586
|
+
*
|
587
|
+
* Final page response:
|
588
|
+
* {
|
589
|
+
* "has_more": false,
|
590
|
+
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
591
|
+
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
592
|
+
* "total": 42
|
593
|
+
* }
|
594
|
+
*
|
595
|
+
* Empty results:
|
596
|
+
* {
|
597
|
+
* "has_more": false,
|
598
|
+
* "first_cursor": null,
|
599
|
+
* "last_cursor": null,
|
600
|
+
* "total": 0
|
601
|
+
* }
|
602
|
+
*/
|
603
|
+
pagination: VectorStoreListResponse.Pagination;
|
604
|
+
|
605
|
+
/**
|
606
|
+
* The object type of the response
|
607
|
+
*/
|
608
|
+
object?: 'list';
|
609
|
+
|
610
|
+
/**
|
611
|
+
* The list of vector stores
|
612
|
+
*/
|
613
|
+
data: Array<VectorStore>;
|
614
|
+
}
|
615
|
+
|
616
|
+
export namespace VectorStoreListResponse {
|
617
|
+
/**
|
618
|
+
* Response model for cursor-based pagination.
|
619
|
+
*
|
620
|
+
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
621
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
622
|
+
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
623
|
+
*
|
624
|
+
* Final page response:
|
625
|
+
* {
|
626
|
+
* "has_more": false,
|
627
|
+
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
628
|
+
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
629
|
+
* "total": 42
|
630
|
+
* }
|
631
|
+
*
|
632
|
+
* Empty results:
|
633
|
+
* {
|
634
|
+
* "has_more": false,
|
635
|
+
* "first_cursor": null,
|
636
|
+
* "last_cursor": null,
|
637
|
+
* "total": 0
|
638
|
+
* }
|
639
|
+
*/
|
640
|
+
export interface Pagination {
|
641
|
+
/**
|
642
|
+
* Contextual direction-aware flag: True if more items exist in the requested
|
643
|
+
* pagination direction. For 'after': more items after this page. For 'before':
|
644
|
+
* more items before this page.
|
645
|
+
*/
|
646
|
+
has_more: boolean;
|
647
|
+
|
648
|
+
/**
|
649
|
+
* Cursor of the first item in this page. Use for backward pagination. None if page
|
650
|
+
* is empty.
|
651
|
+
*/
|
652
|
+
first_cursor: string | null;
|
653
|
+
|
654
|
+
/**
|
655
|
+
* Cursor of the last item in this page. Use for forward pagination. None if page
|
656
|
+
* is empty.
|
657
|
+
*/
|
658
|
+
last_cursor: string | null;
|
659
|
+
|
660
|
+
/**
|
661
|
+
* Total number of items available across all pages. Only included when
|
662
|
+
* include_total=true was requested. Expensive operation - use sparingly.
|
663
|
+
*/
|
664
|
+
total?: number | null;
|
665
|
+
}
|
666
|
+
}
|
667
|
+
|
582
668
|
/**
|
583
669
|
* Response model for vector store deletion.
|
584
670
|
*/
|
@@ -689,7 +775,29 @@ export interface VectorStoreUpdateParams {
|
|
689
775
|
metadata?: unknown;
|
690
776
|
}
|
691
777
|
|
692
|
-
export interface VectorStoreListParams
|
778
|
+
export interface VectorStoreListParams {
|
779
|
+
/**
|
780
|
+
* Maximum number of items to return per page (1-100)
|
781
|
+
*/
|
782
|
+
limit?: number;
|
783
|
+
|
784
|
+
/**
|
785
|
+
* Cursor for forward pagination - get items after this position. Use last_cursor
|
786
|
+
* from previous response.
|
787
|
+
*/
|
788
|
+
after?: string | null;
|
789
|
+
|
790
|
+
/**
|
791
|
+
* Cursor for backward pagination - get items before this position. Use
|
792
|
+
* first_cursor from previous response.
|
793
|
+
*/
|
794
|
+
before?: string | null;
|
795
|
+
|
796
|
+
/**
|
797
|
+
* Whether to include total count in response (expensive operation)
|
798
|
+
*/
|
799
|
+
include_total?: boolean;
|
800
|
+
|
693
801
|
/**
|
694
802
|
* Search query for fuzzy matching over name and description fields
|
695
803
|
*/
|
@@ -817,10 +925,10 @@ export declare namespace VectorStores {
|
|
817
925
|
type ScoredVideoURLInputChunk as ScoredVideoURLInputChunk,
|
818
926
|
type VectorStore as VectorStore,
|
819
927
|
type VectorStoreChunkSearchOptions as VectorStoreChunkSearchOptions,
|
928
|
+
type VectorStoreListResponse as VectorStoreListResponse,
|
820
929
|
type VectorStoreDeleteResponse as VectorStoreDeleteResponse,
|
821
930
|
type VectorStoreQuestionAnsweringResponse as VectorStoreQuestionAnsweringResponse,
|
822
931
|
type VectorStoreSearchResponse as VectorStoreSearchResponse,
|
823
|
-
type VectorStoresCursor as VectorStoresCursor,
|
824
932
|
type VectorStoreCreateParams as VectorStoreCreateParams,
|
825
933
|
type VectorStoreUpdateParams as VectorStoreUpdateParams,
|
826
934
|
type VectorStoreListParams as VectorStoreListParams,
|
@@ -834,9 +942,9 @@ export declare namespace VectorStores {
|
|
834
942
|
type ScoredVectorStoreFile as ScoredVectorStoreFile,
|
835
943
|
type VectorStoreFileStatus as VectorStoreFileStatus,
|
836
944
|
type VectorStoreFile as VectorStoreFile,
|
945
|
+
type FileListResponse as FileListResponse,
|
837
946
|
type FileDeleteResponse as FileDeleteResponse,
|
838
947
|
type FileSearchResponse as FileSearchResponse,
|
839
|
-
type VectorStoreFilesCursor as VectorStoreFilesCursor,
|
840
948
|
type FileCreateParams as FileCreateParams,
|
841
949
|
type FileRetrieveParams as FileRetrieveParams,
|
842
950
|
type FileListParams as FileListParams,
|
package/src/version.ts
CHANGED
@@ -1 +1 @@
|
|
1
|
-
export const VERSION = '0.
|
1
|
+
export const VERSION = '0.13.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
export declare const VERSION = "0.
|
1
|
+
export declare const VERSION = "0.13.0";
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
export declare const VERSION = "0.
|
1
|
+
export declare const VERSION = "0.13.0";
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
export const VERSION = '0.
|
1
|
+
export const VERSION = '0.13.0'; // x-release-please-version
|
2
2
|
//# sourceMappingURL=version.mjs.map
|