@mixedbread/sdk 0.15.0 → 0.17.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 +22 -0
- package/README.md +31 -0
- package/bin/migration-config.json +4 -0
- package/client.d.mts +8 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +8 -6
- package/client.d.ts.map +1 -1
- package/client.js.map +1 -1
- package/client.mjs.map +1 -1
- package/core/pagination.d.mts +10 -16
- package/core/pagination.d.mts.map +1 -1
- package/core/pagination.d.ts +10 -16
- package/core/pagination.d.ts.map +1 -1
- package/core/pagination.js.map +1 -1
- package/core/pagination.mjs.map +1 -1
- package/internal/request-options.d.mts +42 -0
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts +42 -0
- package/internal/request-options.d.ts.map +1 -1
- package/internal/request-options.js.map +1 -1
- package/internal/request-options.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/data-sources/connectors.d.mts +5 -106
- package/resources/data-sources/connectors.d.mts.map +1 -1
- package/resources/data-sources/connectors.d.ts +5 -106
- package/resources/data-sources/connectors.d.ts.map +1 -1
- package/resources/data-sources/connectors.js +2 -1
- package/resources/data-sources/connectors.js.map +1 -1
- package/resources/data-sources/connectors.mjs +2 -1
- package/resources/data-sources/connectors.mjs.map +1 -1
- package/resources/data-sources/data-sources.d.mts +7 -108
- package/resources/data-sources/data-sources.d.mts.map +1 -1
- package/resources/data-sources/data-sources.d.ts +7 -108
- package/resources/data-sources/data-sources.d.ts.map +1 -1
- package/resources/data-sources/data-sources.js +2 -1
- package/resources/data-sources/data-sources.js.map +1 -1
- package/resources/data-sources/data-sources.mjs +2 -1
- 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/embeddings.d.mts +1 -1
- package/resources/embeddings.d.mts.map +1 -1
- package/resources/embeddings.d.ts +1 -1
- package/resources/embeddings.d.ts.map +1 -1
- package/resources/files.d.mts +5 -103
- package/resources/files.d.mts.map +1 -1
- package/resources/files.d.ts +5 -103
- package/resources/files.d.ts.map +1 -1
- package/resources/files.js +2 -1
- package/resources/files.js.map +1 -1
- package/resources/files.mjs +2 -1
- 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 +33 -134
- package/resources/parsing/jobs.d.mts.map +1 -1
- package/resources/parsing/jobs.d.ts +33 -134
- package/resources/parsing/jobs.d.ts.map +1 -1
- package/resources/parsing/jobs.js +2 -1
- package/resources/parsing/jobs.js.map +1 -1
- package/resources/parsing/jobs.mjs +2 -1
- 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 +135 -95
- package/resources/vector-stores/files.d.mts.map +1 -1
- package/resources/vector-stores/files.d.ts +135 -95
- package/resources/vector-stores/files.d.ts.map +1 -1
- package/resources/vector-stores/files.js +7 -3
- package/resources/vector-stores/files.js.map +1 -1
- package/resources/vector-stores/files.mjs +7 -3
- 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 +23 -117
- package/resources/vector-stores/vector-stores.d.mts.map +1 -1
- package/resources/vector-stores/vector-stores.d.ts +23 -117
- package/resources/vector-stores/vector-stores.d.ts.map +1 -1
- package/resources/vector-stores/vector-stores.js +2 -1
- package/resources/vector-stores/vector-stores.js.map +1 -1
- package/resources/vector-stores/vector-stores.mjs +2 -1
- package/resources/vector-stores/vector-stores.mjs.map +1 -1
- package/src/client.ts +8 -6
- package/src/core/pagination.ts +10 -18
- package/src/internal/request-options.ts +53 -0
- package/src/resources/data-sources/connectors.ts +11 -118
- package/src/resources/data-sources/data-sources.ts +9 -120
- package/src/resources/data-sources/index.ts +2 -2
- package/src/resources/embeddings.ts +2 -1
- package/src/resources/files.ts +7 -115
- package/src/resources/index.ts +3 -3
- package/src/resources/parsing/index.ts +1 -0
- package/src/resources/parsing/jobs.ts +38 -145
- package/src/resources/parsing/parsing.ts +2 -0
- package/src/resources/vector-stores/files.ts +167 -103
- package/src/resources/vector-stores/index.ts +2 -2
- package/src/resources/vector-stores/vector-stores.ts +29 -132
- 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
@@ -1,7 +1,8 @@
|
|
1
1
|
import { APIResource } from "../../core/resource.mjs";
|
2
2
|
import * as ConnectorsAPI from "./connectors.mjs";
|
3
|
-
import { ConnectorCreateParams, ConnectorDeleteParams, ConnectorDeleteResponse, ConnectorListParams,
|
3
|
+
import { ConnectorCreateParams, ConnectorDeleteParams, ConnectorDeleteResponse, ConnectorListParams, ConnectorRetrieveParams, ConnectorUpdateParams, Connectors, DataSourceConnector, DataSourceConnectorsCursor } from "./connectors.mjs";
|
4
4
|
import { APIPromise } from "../../core/api-promise.mjs";
|
5
|
+
import { Cursor, type CursorParams, PagePromise } from "../../core/pagination.mjs";
|
5
6
|
import { RequestOptions } from "../../internal/request-options.mjs";
|
6
7
|
export declare class DataSources extends APIResource {
|
7
8
|
connectors: ConnectorsAPI.Connectors;
|
@@ -35,7 +36,7 @@ export declare class DataSources extends APIResource {
|
|
35
36
|
*
|
36
37
|
* Returns: The list of data sources.
|
37
38
|
*/
|
38
|
-
list(query?: DataSourceListParams | null | undefined, options?: RequestOptions):
|
39
|
+
list(query?: DataSourceListParams | null | undefined, options?: RequestOptions): PagePromise<DataSourcesCursor, DataSource>;
|
39
40
|
/**
|
40
41
|
* Delete a data source.
|
41
42
|
*
|
@@ -43,6 +44,7 @@ export declare class DataSources extends APIResource {
|
|
43
44
|
*/
|
44
45
|
delete(dataSourceID: string, options?: RequestOptions): APIPromise<DataSourceDeleteResponse>;
|
45
46
|
}
|
47
|
+
export type DataSourcesCursor = Cursor<DataSource>;
|
46
48
|
/**
|
47
49
|
* Service-level representation of a data source.
|
48
50
|
*/
|
@@ -190,91 +192,6 @@ export declare namespace NotionDataSource {
|
|
190
192
|
export interface Oauth2Params {
|
191
193
|
type?: 'oauth2';
|
192
194
|
}
|
193
|
-
/**
|
194
|
-
* A list of data sources with pagination.
|
195
|
-
*/
|
196
|
-
export interface DataSourceListResponse {
|
197
|
-
/**
|
198
|
-
* Response model for cursor-based pagination.
|
199
|
-
*
|
200
|
-
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
201
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
202
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
203
|
-
*
|
204
|
-
* Final page response:
|
205
|
-
* {
|
206
|
-
* "has_more": false,
|
207
|
-
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
208
|
-
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
209
|
-
* "total": 42
|
210
|
-
* }
|
211
|
-
*
|
212
|
-
* Empty results:
|
213
|
-
* {
|
214
|
-
* "has_more": false,
|
215
|
-
* "first_cursor": null,
|
216
|
-
* "last_cursor": null,
|
217
|
-
* "total": 0
|
218
|
-
* }
|
219
|
-
*/
|
220
|
-
pagination: DataSourceListResponse.Pagination;
|
221
|
-
/**
|
222
|
-
* The list of data sources
|
223
|
-
*/
|
224
|
-
data: Array<DataSource>;
|
225
|
-
/**
|
226
|
-
* The object type of the response
|
227
|
-
*/
|
228
|
-
object?: 'list';
|
229
|
-
}
|
230
|
-
export declare namespace DataSourceListResponse {
|
231
|
-
/**
|
232
|
-
* Response model for cursor-based pagination.
|
233
|
-
*
|
234
|
-
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
235
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
236
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
237
|
-
*
|
238
|
-
* Final page response:
|
239
|
-
* {
|
240
|
-
* "has_more": false,
|
241
|
-
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
242
|
-
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
243
|
-
* "total": 42
|
244
|
-
* }
|
245
|
-
*
|
246
|
-
* Empty results:
|
247
|
-
* {
|
248
|
-
* "has_more": false,
|
249
|
-
* "first_cursor": null,
|
250
|
-
* "last_cursor": null,
|
251
|
-
* "total": 0
|
252
|
-
* }
|
253
|
-
*/
|
254
|
-
interface Pagination {
|
255
|
-
/**
|
256
|
-
* Contextual direction-aware flag: True if more items exist in the requested
|
257
|
-
* pagination direction. For 'after': more items after this page. For 'before':
|
258
|
-
* more items before this page.
|
259
|
-
*/
|
260
|
-
has_more: boolean;
|
261
|
-
/**
|
262
|
-
* Cursor of the first item in this page. Use for backward pagination. None if page
|
263
|
-
* is empty.
|
264
|
-
*/
|
265
|
-
first_cursor: string | null;
|
266
|
-
/**
|
267
|
-
* Cursor of the last item in this page. Use for forward pagination. None if page
|
268
|
-
* is empty.
|
269
|
-
*/
|
270
|
-
last_cursor: string | null;
|
271
|
-
/**
|
272
|
-
* Total number of items available across all pages. Only included when
|
273
|
-
* include_total=true was requested. Expensive operation - use sparingly.
|
274
|
-
*/
|
275
|
-
total?: number | null;
|
276
|
-
}
|
277
|
-
}
|
278
195
|
/**
|
279
196
|
* Deleted data source.
|
280
197
|
*/
|
@@ -396,28 +313,10 @@ export declare namespace DataSourceUpdateParams {
|
|
396
313
|
auth_params?: Oauth2Params | null;
|
397
314
|
}
|
398
315
|
}
|
399
|
-
export interface DataSourceListParams {
|
400
|
-
/**
|
401
|
-
* Maximum number of items to return per page (1-100)
|
402
|
-
*/
|
403
|
-
limit?: number;
|
404
|
-
/**
|
405
|
-
* Cursor for forward pagination - get items after this position. Use last_cursor
|
406
|
-
* from previous response.
|
407
|
-
*/
|
408
|
-
after?: string | null;
|
409
|
-
/**
|
410
|
-
* Cursor for backward pagination - get items before this position. Use
|
411
|
-
* first_cursor from previous response.
|
412
|
-
*/
|
413
|
-
before?: string | null;
|
414
|
-
/**
|
415
|
-
* Whether to include total count in response (expensive operation)
|
416
|
-
*/
|
417
|
-
include_total?: boolean;
|
316
|
+
export interface DataSourceListParams extends CursorParams {
|
418
317
|
}
|
419
318
|
export declare namespace DataSources {
|
420
|
-
export { type DataSource as DataSource, type DataSourceOauth2Params as DataSourceOauth2Params, type DataSourceType as DataSourceType, type LinearDataSource as LinearDataSource, type NotionDataSource as NotionDataSource, type Oauth2Params as Oauth2Params, type
|
421
|
-
export { Connectors as Connectors, type DataSourceConnector as DataSourceConnector, type
|
319
|
+
export { type DataSource as DataSource, type DataSourceOauth2Params as DataSourceOauth2Params, type DataSourceType as DataSourceType, type LinearDataSource as LinearDataSource, type NotionDataSource as NotionDataSource, type Oauth2Params as Oauth2Params, type DataSourceDeleteResponse as DataSourceDeleteResponse, type DataSourcesCursor as DataSourcesCursor, type DataSourceCreateParams as DataSourceCreateParams, type DataSourceUpdateParams as DataSourceUpdateParams, type DataSourceListParams as DataSourceListParams, };
|
320
|
+
export { Connectors as Connectors, type DataSourceConnector as DataSourceConnector, type ConnectorDeleteResponse as ConnectorDeleteResponse, type DataSourceConnectorsCursor as DataSourceConnectorsCursor, type ConnectorCreateParams as ConnectorCreateParams, type ConnectorRetrieveParams as ConnectorRetrieveParams, type ConnectorUpdateParams as ConnectorUpdateParams, type ConnectorListParams as ConnectorListParams, type ConnectorDeleteParams as ConnectorDeleteParams, };
|
422
321
|
}
|
423
322
|
//# sourceMappingURL=data-sources.d.mts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"data-sources.d.mts","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,aAAa;OAClB,EACL,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB,
|
1
|
+
{"version":3,"file":"data-sources.d.mts","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,aAAa;OAClB,EACL,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB,uBAAuB,EACvB,qBAAqB,EACrB,UAAU,EACV,mBAAmB,EACnB,0BAA0B,EAC3B;OACM,EAAE,UAAU,EAAE;OACd,EAAE,MAAM,EAAE,KAAK,YAAY,EAAE,WAAW,EAAE;OAC1C,EAAE,cAAc,EAAE;AAGzB,qBAAa,WAAY,SAAQ,WAAW;IAC1C,UAAU,EAAE,aAAa,CAAC,UAAU,CAA8C;IAElF;;;;;;OAMG;IACH,MAAM,CAAC,IAAI,EAAE,sBA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,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;CACH"}
|
@@ -1,7 +1,8 @@
|
|
1
1
|
import { APIResource } from "../../core/resource.js";
|
2
2
|
import * as ConnectorsAPI from "./connectors.js";
|
3
|
-
import { ConnectorCreateParams, ConnectorDeleteParams, ConnectorDeleteResponse, ConnectorListParams,
|
3
|
+
import { ConnectorCreateParams, ConnectorDeleteParams, ConnectorDeleteResponse, ConnectorListParams, ConnectorRetrieveParams, ConnectorUpdateParams, Connectors, DataSourceConnector, DataSourceConnectorsCursor } from "./connectors.js";
|
4
4
|
import { APIPromise } from "../../core/api-promise.js";
|
5
|
+
import { Cursor, type CursorParams, PagePromise } from "../../core/pagination.js";
|
5
6
|
import { RequestOptions } from "../../internal/request-options.js";
|
6
7
|
export declare class DataSources extends APIResource {
|
7
8
|
connectors: ConnectorsAPI.Connectors;
|
@@ -35,7 +36,7 @@ export declare class DataSources extends APIResource {
|
|
35
36
|
*
|
36
37
|
* Returns: The list of data sources.
|
37
38
|
*/
|
38
|
-
list(query?: DataSourceListParams | null | undefined, options?: RequestOptions):
|
39
|
+
list(query?: DataSourceListParams | null | undefined, options?: RequestOptions): PagePromise<DataSourcesCursor, DataSource>;
|
39
40
|
/**
|
40
41
|
* Delete a data source.
|
41
42
|
*
|
@@ -43,6 +44,7 @@ export declare class DataSources extends APIResource {
|
|
43
44
|
*/
|
44
45
|
delete(dataSourceID: string, options?: RequestOptions): APIPromise<DataSourceDeleteResponse>;
|
45
46
|
}
|
47
|
+
export type DataSourcesCursor = Cursor<DataSource>;
|
46
48
|
/**
|
47
49
|
* Service-level representation of a data source.
|
48
50
|
*/
|
@@ -190,91 +192,6 @@ export declare namespace NotionDataSource {
|
|
190
192
|
export interface Oauth2Params {
|
191
193
|
type?: 'oauth2';
|
192
194
|
}
|
193
|
-
/**
|
194
|
-
* A list of data sources with pagination.
|
195
|
-
*/
|
196
|
-
export interface DataSourceListResponse {
|
197
|
-
/**
|
198
|
-
* Response model for cursor-based pagination.
|
199
|
-
*
|
200
|
-
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
201
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
202
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
203
|
-
*
|
204
|
-
* Final page response:
|
205
|
-
* {
|
206
|
-
* "has_more": false,
|
207
|
-
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
208
|
-
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
209
|
-
* "total": 42
|
210
|
-
* }
|
211
|
-
*
|
212
|
-
* Empty results:
|
213
|
-
* {
|
214
|
-
* "has_more": false,
|
215
|
-
* "first_cursor": null,
|
216
|
-
* "last_cursor": null,
|
217
|
-
* "total": 0
|
218
|
-
* }
|
219
|
-
*/
|
220
|
-
pagination: DataSourceListResponse.Pagination;
|
221
|
-
/**
|
222
|
-
* The list of data sources
|
223
|
-
*/
|
224
|
-
data: Array<DataSource>;
|
225
|
-
/**
|
226
|
-
* The object type of the response
|
227
|
-
*/
|
228
|
-
object?: 'list';
|
229
|
-
}
|
230
|
-
export declare namespace DataSourceListResponse {
|
231
|
-
/**
|
232
|
-
* Response model for cursor-based pagination.
|
233
|
-
*
|
234
|
-
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
235
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
236
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
237
|
-
*
|
238
|
-
* Final page response:
|
239
|
-
* {
|
240
|
-
* "has_more": false,
|
241
|
-
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
242
|
-
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
243
|
-
* "total": 42
|
244
|
-
* }
|
245
|
-
*
|
246
|
-
* Empty results:
|
247
|
-
* {
|
248
|
-
* "has_more": false,
|
249
|
-
* "first_cursor": null,
|
250
|
-
* "last_cursor": null,
|
251
|
-
* "total": 0
|
252
|
-
* }
|
253
|
-
*/
|
254
|
-
interface Pagination {
|
255
|
-
/**
|
256
|
-
* Contextual direction-aware flag: True if more items exist in the requested
|
257
|
-
* pagination direction. For 'after': more items after this page. For 'before':
|
258
|
-
* more items before this page.
|
259
|
-
*/
|
260
|
-
has_more: boolean;
|
261
|
-
/**
|
262
|
-
* Cursor of the first item in this page. Use for backward pagination. None if page
|
263
|
-
* is empty.
|
264
|
-
*/
|
265
|
-
first_cursor: string | null;
|
266
|
-
/**
|
267
|
-
* Cursor of the last item in this page. Use for forward pagination. None if page
|
268
|
-
* is empty.
|
269
|
-
*/
|
270
|
-
last_cursor: string | null;
|
271
|
-
/**
|
272
|
-
* Total number of items available across all pages. Only included when
|
273
|
-
* include_total=true was requested. Expensive operation - use sparingly.
|
274
|
-
*/
|
275
|
-
total?: number | null;
|
276
|
-
}
|
277
|
-
}
|
278
195
|
/**
|
279
196
|
* Deleted data source.
|
280
197
|
*/
|
@@ -396,28 +313,10 @@ export declare namespace DataSourceUpdateParams {
|
|
396
313
|
auth_params?: Oauth2Params | null;
|
397
314
|
}
|
398
315
|
}
|
399
|
-
export interface DataSourceListParams {
|
400
|
-
/**
|
401
|
-
* Maximum number of items to return per page (1-100)
|
402
|
-
*/
|
403
|
-
limit?: number;
|
404
|
-
/**
|
405
|
-
* Cursor for forward pagination - get items after this position. Use last_cursor
|
406
|
-
* from previous response.
|
407
|
-
*/
|
408
|
-
after?: string | null;
|
409
|
-
/**
|
410
|
-
* Cursor for backward pagination - get items before this position. Use
|
411
|
-
* first_cursor from previous response.
|
412
|
-
*/
|
413
|
-
before?: string | null;
|
414
|
-
/**
|
415
|
-
* Whether to include total count in response (expensive operation)
|
416
|
-
*/
|
417
|
-
include_total?: boolean;
|
316
|
+
export interface DataSourceListParams extends CursorParams {
|
418
317
|
}
|
419
318
|
export declare namespace DataSources {
|
420
|
-
export { type DataSource as DataSource, type DataSourceOauth2Params as DataSourceOauth2Params, type DataSourceType as DataSourceType, type LinearDataSource as LinearDataSource, type NotionDataSource as NotionDataSource, type Oauth2Params as Oauth2Params, type
|
421
|
-
export { Connectors as Connectors, type DataSourceConnector as DataSourceConnector, type
|
319
|
+
export { type DataSource as DataSource, type DataSourceOauth2Params as DataSourceOauth2Params, type DataSourceType as DataSourceType, type LinearDataSource as LinearDataSource, type NotionDataSource as NotionDataSource, type Oauth2Params as Oauth2Params, type DataSourceDeleteResponse as DataSourceDeleteResponse, type DataSourcesCursor as DataSourcesCursor, type DataSourceCreateParams as DataSourceCreateParams, type DataSourceUpdateParams as DataSourceUpdateParams, type DataSourceListParams as DataSourceListParams, };
|
320
|
+
export { Connectors as Connectors, type DataSourceConnector as DataSourceConnector, type ConnectorDeleteResponse as ConnectorDeleteResponse, type DataSourceConnectorsCursor as DataSourceConnectorsCursor, type ConnectorCreateParams as ConnectorCreateParams, type ConnectorRetrieveParams as ConnectorRetrieveParams, type ConnectorUpdateParams as ConnectorUpdateParams, type ConnectorListParams as ConnectorListParams, type ConnectorDeleteParams as ConnectorDeleteParams, };
|
422
321
|
}
|
423
322
|
//# sourceMappingURL=data-sources.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"data-sources.d.ts","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,aAAa;OAClB,EACL,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB,
|
1
|
+
{"version":3,"file":"data-sources.d.ts","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,aAAa;OAClB,EACL,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,mBAAmB,EACnB,uBAAuB,EACvB,qBAAqB,EACrB,UAAU,EACV,mBAAmB,EACnB,0BAA0B,EAC3B;OACM,EAAE,UAAU,EAAE;OACd,EAAE,MAAM,EAAE,KAAK,YAAY,EAAE,WAAW,EAAE;OAC1C,EAAE,cAAc,EAAE;AAGzB,qBAAa,WAAY,SAAQ,WAAW;IAC1C,UAAU,EAAE,aAAa,CAAC,UAAU,CAA8C;IAElF;;;;;;OAMG;IACH,MAAM,CAAC,IAAI,EAAE,sBAAsB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,UAAU,CAAC;IAItF;;;;;;OAMG;IACH,QAAQ,CAAC,YAAY,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,UAAU,CAAC;IAIhF;;;;;;;OAOG;IACH,MAAM,CACJ,YAAY,EAAE,MAAM,EACpB,IAAI,EAAE,sBAAsB,EAC5B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,UAAU,CAAC;IAIzB;;;;OAIG;IACH,IAAI,CACF,KAAK,GAAE,oBAAoB,GAAG,IAAI,GAAG,SAAc,EACnD,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,iBAAiB,EAAE,UAAU,CAAC;IAI7C;;;;OAIG;IACH,MAAM,CAAC,YAAY,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAA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;QAEnB;;WAEG;QACH,WAAW,CAAC,EAAE,YAAY,GAAG,IAAI,CAAC;KACnC;CACF;AAED,MAAM,WAAW,oBAAqB,SAAQ,YAAY;CAAG;AAI7D,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,YAAY,IAAI,YAAY,EACjC,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,oBAAoB,IAAI,oBAAoB,GAClD,CAAC;IAEF,OAAO,EACL,UAAU,IAAI,UAAU,EACxB,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,mBAAmB,IAAI,mBAAmB,EAC/C,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;CACH"}
|
@@ -6,6 +6,7 @@ const tslib_1 = require("../../internal/tslib.js");
|
|
6
6
|
const resource_1 = require("../../core/resource.js");
|
7
7
|
const ConnectorsAPI = tslib_1.__importStar(require("./connectors.js"));
|
8
8
|
const connectors_1 = require("./connectors.js");
|
9
|
+
const pagination_1 = require("../../core/pagination.js");
|
9
10
|
const path_1 = require("../../internal/utils/path.js");
|
10
11
|
class DataSources extends resource_1.APIResource {
|
11
12
|
constructor() {
|
@@ -49,7 +50,7 @@ class DataSources extends resource_1.APIResource {
|
|
49
50
|
* Returns: The list of data sources.
|
50
51
|
*/
|
51
52
|
list(query = {}, options) {
|
52
|
-
return this._client.
|
53
|
+
return this._client.getAPIList('/v1/data_sources/', (pagination_1.Cursor), { query, ...options });
|
53
54
|
}
|
54
55
|
/**
|
55
56
|
* Delete a data source.
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"data-sources.js","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAClD,uEAA8C;AAC9C,gDAUsB;
|
1
|
+
{"version":3,"file":"data-sources.js","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,qDAAkD;AAClD,uEAA8C;AAC9C,gDAUsB;AAEtB,yDAA+E;AAE/E,uDAAiD;AAEjD,MAAa,WAAY,SAAQ,sBAAW;IAA5C;;QACE,eAAU,GAA6B,IAAI,aAAa,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IA4DpF,CAAC;IA1DC;;;;;;OAMG;IACH,MAAM,CAAC,IAA4B,EAAE,OAAwB;QAC3D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,mBAAmB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACtE,CAAC;IAED;;;;;;OAMG;IACH,QAAQ,CAAC,YAAoB,EAAE,OAAwB;QACrD,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,oBAAoB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IAC3E,CAAC;IAED;;;;;;;OAOG;IACH,MAAM,CACJ,YAAoB,EACpB,IAA4B,EAC5B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,oBAAoB,YAAY,EAAE,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACxF,CAAC;IAED;;;;OAIG;IACH,IAAI,CACF,QAAiD,EAAE,EACnD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,mBAAmB,EAAE,CAAA,mBAAkB,CAAA,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACjG,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,YAAoB,EAAE,OAAwB;QACnD,OAAO,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAA,WAAI,EAAA,oBAAoB,YAAY,EAAE,EAAE,OAAO,CAAC,CAAC;IAC9E,CAAC;CACF;AA7DD,kCA6DC;AA2UD,WAAW,CAAC,UAAU,GAAG,uBAAU,CAAC"}
|
@@ -2,6 +2,7 @@
|
|
2
2
|
import { APIResource } from "../../core/resource.mjs";
|
3
3
|
import * as ConnectorsAPI from "./connectors.mjs";
|
4
4
|
import { Connectors, } from "./connectors.mjs";
|
5
|
+
import { Cursor } from "../../core/pagination.mjs";
|
5
6
|
import { path } from "../../internal/utils/path.mjs";
|
6
7
|
export class DataSources extends APIResource {
|
7
8
|
constructor() {
|
@@ -45,7 +46,7 @@ export class DataSources extends APIResource {
|
|
45
46
|
* Returns: The list of data sources.
|
46
47
|
*/
|
47
48
|
list(query = {}, options) {
|
48
|
-
return this._client.
|
49
|
+
return this._client.getAPIList('/v1/data_sources/', (Cursor), { query, ...options });
|
49
50
|
}
|
50
51
|
/**
|
51
52
|
* Delete a data source.
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"data-sources.mjs","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,aAAa;OAClB,
|
1
|
+
{"version":3,"file":"data-sources.mjs","sourceRoot":"","sources":["../../src/resources/data-sources/data-sources.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,aAAa;OAClB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|
-
export { Connectors, type DataSourceConnector, type
|
2
|
-
export { DataSources, type DataSource, type DataSourceOauth2Params, type DataSourceType, type LinearDataSource, type NotionDataSource, type Oauth2Params, type
|
1
|
+
export { Connectors, type DataSourceConnector, type ConnectorDeleteResponse, type ConnectorCreateParams, type ConnectorRetrieveParams, type ConnectorUpdateParams, type ConnectorListParams, type ConnectorDeleteParams, type DataSourceConnectorsCursor, } from "./connectors.mjs";
|
2
|
+
export { DataSources, type DataSource, type DataSourceOauth2Params, type DataSourceType, type LinearDataSource, type NotionDataSource, type Oauth2Params, type DataSourceDeleteResponse, type DataSourceCreateParams, type DataSourceUpdateParams, type DataSourceListParams, type DataSourcesCursor, } from "./data-sources.mjs";
|
3
3
|
//# sourceMappingURL=index.d.mts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/data-sources/index.ts"],"names":[],"mappings":"OAEO,EACL,UAAU,EACV,KAAK,mBAAmB,EACxB,KAAK,
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../src/resources/data-sources/index.ts"],"names":[],"mappings":"OAEO,EACL,UAAU,EACV,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,0BAA0B,GAChC;OACM,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,sBAAsB,EAC3B,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,GACvB"}
|
@@ -1,3 +1,3 @@
|
|
1
|
-
export { Connectors, type DataSourceConnector, type
|
2
|
-
export { DataSources, type DataSource, type DataSourceOauth2Params, type DataSourceType, type LinearDataSource, type NotionDataSource, type Oauth2Params, type
|
1
|
+
export { Connectors, type DataSourceConnector, type ConnectorDeleteResponse, type ConnectorCreateParams, type ConnectorRetrieveParams, type ConnectorUpdateParams, type ConnectorListParams, type ConnectorDeleteParams, type DataSourceConnectorsCursor, } from "./connectors.js";
|
2
|
+
export { DataSources, type DataSource, type DataSourceOauth2Params, type DataSourceType, type LinearDataSource, type NotionDataSource, type Oauth2Params, type DataSourceDeleteResponse, type DataSourceCreateParams, type DataSourceUpdateParams, type DataSourceListParams, type DataSourcesCursor, } from "./data-sources.js";
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/data-sources/index.ts"],"names":[],"mappings":"OAEO,EACL,UAAU,EACV,KAAK,mBAAmB,EACxB,KAAK,
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/resources/data-sources/index.ts"],"names":[],"mappings":"OAEO,EACL,UAAU,EACV,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,qBAAqB,EAC1B,KAAK,0BAA0B,GAChC;OACM,EACL,WAAW,EACX,KAAK,UAAU,EACf,KAAK,sBAAsB,EAC3B,KAAK,cAAc,EACnB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,wBAAwB,EAC7B,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,GACvB"}
|
@@ -17,7 +17,7 @@ export declare class Embeddings extends APIResource {
|
|
17
17
|
* Enumeration of encoding formats.
|
18
18
|
*/
|
19
19
|
export type EncodingFormat = 'float' | 'float16' | 'base64' | 'binary' | 'ubinary' | 'int8' | 'uint8';
|
20
|
-
export type ObjectType = 'list' | 'parsing_job' | 'extraction_job' | 'embedding' | 'embedding_dict' | 'rank_result' | 'file' | 'vector_store' | 'vector_store.file' | 'api_key' | 'data_source' | 'data_source.connector';
|
20
|
+
export type ObjectType = 'list' | 'parsing_job' | 'extraction_job' | 'embedding' | 'embedding_dict' | 'rank_result' | 'file' | 'vector_store' | 'vector_store.file' | 'api_key' | 'data_source' | 'data_source.connector' | 'vector_store.histogram';
|
21
21
|
export interface EmbeddingCreateParams {
|
22
22
|
/**
|
23
23
|
* The model to use for creating embeddings.
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"embeddings.d.mts","sourceRoot":"","sources":["../src/resources/embeddings.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,UAAW,SAAQ,WAAW;IACzC;;;;;;;OAOG;IACH,MAAM,CACJ,IAAI,EAAE,qBAAqB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,WAAW,CAAC,uBAAuB,CAAC;CAGnD;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,CAAC;AAEtG,MAAM,MAAM,UAAU,GAClB,MAAM,GACN,aAAa,GACb,gBAAgB,GAChB,WAAW,GACX,gBAAgB,GAChB,aAAa,GACb,MAAM,GACN,cAAc,GACd,mBAAmB,GACnB,SAAS,GACT,aAAa,GACb,uBAAuB,CAAC;
|
1
|
+
{"version":3,"file":"embeddings.d.mts","sourceRoot":"","sources":["../src/resources/embeddings.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,UAAW,SAAQ,WAAW;IACzC;;;;;;;OAOG;IACH,MAAM,CACJ,IAAI,EAAE,qBAAqB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,WAAW,CAAC,uBAAuB,CAAC;CAGnD;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,CAAC;AAEtG,MAAM,MAAM,UAAU,GAClB,MAAM,GACN,aAAa,GACb,gBAAgB,GAChB,WAAW,GACX,gBAAgB,GAChB,aAAa,GACb,MAAM,GACN,cAAc,GACd,mBAAmB,GACnB,SAAS,GACT,aAAa,GACb,uBAAuB,GACvB,wBAAwB,CAAC;AAE7B,MAAM,WAAW,qBAAqB;IACpC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,KAAK,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;IAE9B;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE3B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvB;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB;;;OAGG;IACH,eAAe,CAAC,EAAE,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC,CAAC;CAC1D;AAED,MAAM,CAAC,OAAO,WAAW,UAAU,CAAC;IAClC,OAAO,EACL,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;CACH"}
|
@@ -17,7 +17,7 @@ export declare class Embeddings extends APIResource {
|
|
17
17
|
* Enumeration of encoding formats.
|
18
18
|
*/
|
19
19
|
export type EncodingFormat = 'float' | 'float16' | 'base64' | 'binary' | 'ubinary' | 'int8' | 'uint8';
|
20
|
-
export type ObjectType = 'list' | 'parsing_job' | 'extraction_job' | 'embedding' | 'embedding_dict' | 'rank_result' | 'file' | 'vector_store' | 'vector_store.file' | 'api_key' | 'data_source' | 'data_source.connector';
|
20
|
+
export type ObjectType = 'list' | 'parsing_job' | 'extraction_job' | 'embedding' | 'embedding_dict' | 'rank_result' | 'file' | 'vector_store' | 'vector_store.file' | 'api_key' | 'data_source' | 'data_source.connector' | 'vector_store.histogram';
|
21
21
|
export interface EmbeddingCreateParams {
|
22
22
|
/**
|
23
23
|
* The model to use for creating embeddings.
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"embeddings.d.ts","sourceRoot":"","sources":["../src/resources/embeddings.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,UAAW,SAAQ,WAAW;IACzC;;;;;;;OAOG;IACH,MAAM,CACJ,IAAI,EAAE,qBAAqB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,WAAW,CAAC,uBAAuB,CAAC;CAGnD;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,CAAC;AAEtG,MAAM,MAAM,UAAU,GAClB,MAAM,GACN,aAAa,GACb,gBAAgB,GAChB,WAAW,GACX,gBAAgB,GAChB,aAAa,GACb,MAAM,GACN,cAAc,GACd,mBAAmB,GACnB,SAAS,GACT,aAAa,GACb,uBAAuB,CAAC;
|
1
|
+
{"version":3,"file":"embeddings.d.ts","sourceRoot":"","sources":["../src/resources/embeddings.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB,qBAAa,UAAW,SAAQ,WAAW;IACzC;;;;;;;OAOG;IACH,MAAM,CACJ,IAAI,EAAE,qBAAqB,EAC3B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,WAAW,CAAC,uBAAuB,CAAC;CAGnD;AAED;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,SAAS,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,CAAC;AAEtG,MAAM,MAAM,UAAU,GAClB,MAAM,GACN,aAAa,GACb,gBAAgB,GAChB,WAAW,GACX,gBAAgB,GAChB,aAAa,GACb,MAAM,GACN,cAAc,GACd,mBAAmB,GACnB,SAAS,GACT,aAAa,GACb,uBAAuB,GACvB,wBAAwB,CAAC;AAE7B,MAAM,WAAW,qBAAqB;IACpC;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,KAAK,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;IAE9B;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAE3B;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvB;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IAErB;;;OAGG;IACH,eAAe,CAAC,EAAE,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC,CAAC;CAC1D;AAED,MAAM,CAAC,OAAO,WAAW,UAAU,CAAC;IAClC,OAAO,EACL,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,UAAU,IAAI,UAAU,EAC7B,KAAK,qBAAqB,IAAI,qBAAqB,GACpD,CAAC;CACH"}
|
package/resources/files.d.mts
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
import { APIResource } from "../core/resource.mjs";
|
2
2
|
import { APIPromise } from "../core/api-promise.mjs";
|
3
|
+
import { Cursor, type CursorParams, PagePromise } from "../core/pagination.mjs";
|
3
4
|
import { type Uploadable } from "../core/uploads.mjs";
|
4
5
|
import { RequestOptions } from "../internal/request-options.mjs";
|
5
6
|
export declare class Files extends APIResource {
|
@@ -34,7 +35,7 @@ export declare class Files extends APIResource {
|
|
34
35
|
*
|
35
36
|
* Returns: A list of files belonging to the user.
|
36
37
|
*/
|
37
|
-
list(query?: FileListParams | null | undefined, options?: RequestOptions):
|
38
|
+
list(query?: FileListParams | null | undefined, options?: RequestOptions): PagePromise<FileObjectsCursor, FileObject>;
|
38
39
|
/**
|
39
40
|
* Delete a specific file by its ID.
|
40
41
|
*
|
@@ -52,6 +53,7 @@ export declare class Files extends APIResource {
|
|
52
53
|
*/
|
53
54
|
content(fileID: string, options?: RequestOptions): APIPromise<Response>;
|
54
55
|
}
|
56
|
+
export type FileObjectsCursor = Cursor<FileObject>;
|
55
57
|
/**
|
56
58
|
* A model representing a file object in the system.
|
57
59
|
*
|
@@ -105,88 +107,6 @@ export interface PaginationWithTotal {
|
|
105
107
|
*/
|
106
108
|
total?: number;
|
107
109
|
}
|
108
|
-
export interface FileListResponse {
|
109
|
-
/**
|
110
|
-
* Response model for cursor-based pagination.
|
111
|
-
*
|
112
|
-
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
113
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
114
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
115
|
-
*
|
116
|
-
* Final page response:
|
117
|
-
* {
|
118
|
-
* "has_more": false,
|
119
|
-
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
120
|
-
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
121
|
-
* "total": 42
|
122
|
-
* }
|
123
|
-
*
|
124
|
-
* Empty results:
|
125
|
-
* {
|
126
|
-
* "has_more": false,
|
127
|
-
* "first_cursor": null,
|
128
|
-
* "last_cursor": null,
|
129
|
-
* "total": 0
|
130
|
-
* }
|
131
|
-
*/
|
132
|
-
pagination: FileListResponse.Pagination;
|
133
|
-
/**
|
134
|
-
* The object type of the response
|
135
|
-
*/
|
136
|
-
object?: 'list';
|
137
|
-
/**
|
138
|
-
* The list of files
|
139
|
-
*/
|
140
|
-
data: Array<FileObject>;
|
141
|
-
}
|
142
|
-
export declare namespace FileListResponse {
|
143
|
-
/**
|
144
|
-
* Response model for cursor-based pagination.
|
145
|
-
*
|
146
|
-
* Examples: Forward pagination response: { "has_more": true, "first_cursor":
|
147
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMSIsImlkIjoiYWJjMTIzIn0=", "last_cursor":
|
148
|
-
* "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0zMCIsImlkIjoieHl6Nzg5In0=", "total": null }
|
149
|
-
*
|
150
|
-
* Final page response:
|
151
|
-
* {
|
152
|
-
* "has_more": false,
|
153
|
-
* "first_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOSIsImlkIjoibGFzdDEyMyJ9",
|
154
|
-
* "last_cursor": "eyJjcmVhdGVkX2F0IjoiMjAyNC0xMi0yOCIsImlkIjoiZmluYWw0NTYifQ==",
|
155
|
-
* "total": 42
|
156
|
-
* }
|
157
|
-
*
|
158
|
-
* Empty results:
|
159
|
-
* {
|
160
|
-
* "has_more": false,
|
161
|
-
* "first_cursor": null,
|
162
|
-
* "last_cursor": null,
|
163
|
-
* "total": 0
|
164
|
-
* }
|
165
|
-
*/
|
166
|
-
interface Pagination {
|
167
|
-
/**
|
168
|
-
* Contextual direction-aware flag: True if more items exist in the requested
|
169
|
-
* pagination direction. For 'after': more items after this page. For 'before':
|
170
|
-
* more items before this page.
|
171
|
-
*/
|
172
|
-
has_more: boolean;
|
173
|
-
/**
|
174
|
-
* Cursor of the first item in this page. Use for backward pagination. None if page
|
175
|
-
* is empty.
|
176
|
-
*/
|
177
|
-
first_cursor: string | null;
|
178
|
-
/**
|
179
|
-
* Cursor of the last item in this page. Use for forward pagination. None if page
|
180
|
-
* is empty.
|
181
|
-
*/
|
182
|
-
last_cursor: string | null;
|
183
|
-
/**
|
184
|
-
* Total number of items available across all pages. Only included when
|
185
|
-
* include_total=true was requested. Expensive operation - use sparingly.
|
186
|
-
*/
|
187
|
-
total?: number | null;
|
188
|
-
}
|
189
|
-
}
|
190
110
|
export interface FileDeleteResponse {
|
191
111
|
/**
|
192
112
|
* The ID of the deleted file
|
@@ -213,31 +133,13 @@ export interface FileUpdateParams {
|
|
213
133
|
*/
|
214
134
|
file: Uploadable;
|
215
135
|
}
|
216
|
-
export interface FileListParams {
|
217
|
-
/**
|
218
|
-
* Maximum number of items to return per page (1-100)
|
219
|
-
*/
|
220
|
-
limit?: number;
|
221
|
-
/**
|
222
|
-
* Cursor for forward pagination - get items after this position. Use last_cursor
|
223
|
-
* from previous response.
|
224
|
-
*/
|
225
|
-
after?: string | null;
|
226
|
-
/**
|
227
|
-
* Cursor for backward pagination - get items before this position. Use
|
228
|
-
* first_cursor from previous response.
|
229
|
-
*/
|
230
|
-
before?: string | null;
|
231
|
-
/**
|
232
|
-
* Whether to include total count in response (expensive operation)
|
233
|
-
*/
|
234
|
-
include_total?: boolean;
|
136
|
+
export interface FileListParams extends CursorParams {
|
235
137
|
/**
|
236
138
|
* Search query for fuzzy matching over name and description fields
|
237
139
|
*/
|
238
140
|
q?: string | null;
|
239
141
|
}
|
240
142
|
export declare namespace Files {
|
241
|
-
export { type FileObject as FileObject, type PaginationWithTotal as PaginationWithTotal, type
|
143
|
+
export { type FileObject as FileObject, type PaginationWithTotal as PaginationWithTotal, type FileDeleteResponse as FileDeleteResponse, type FileObjectsCursor as FileObjectsCursor, type FileCreateParams as FileCreateParams, type FileUpdateParams as FileUpdateParams, type FileListParams as FileListParams, };
|
242
144
|
}
|
243
145
|
//# sourceMappingURL=files.d.mts.map
|