@studyfetch/sdk 1.19.0 → 1.21.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 +16 -0
- package/package.json +1 -1
- package/resources/v1/components.d.mts +0 -5
- package/resources/v1/components.d.mts.map +1 -1
- package/resources/v1/components.d.ts +0 -5
- package/resources/v1/components.d.ts.map +1 -1
- package/resources/v1/components.js +0 -1
- package/resources/v1/components.js.map +1 -1
- package/resources/v1/components.mjs +0 -1
- package/resources/v1/components.mjs.map +1 -1
- package/resources/v1/index.d.mts +1 -1
- package/resources/v1/index.d.mts.map +1 -1
- package/resources/v1/index.d.ts +1 -1
- package/resources/v1/index.d.ts.map +1 -1
- package/resources/v1/index.js.map +1 -1
- package/resources/v1/index.mjs.map +1 -1
- package/resources/v1/materials/index.d.mts +1 -1
- package/resources/v1/materials/index.d.mts.map +1 -1
- package/resources/v1/materials/index.d.ts +1 -1
- package/resources/v1/materials/index.d.ts.map +1 -1
- package/resources/v1/materials/index.js.map +1 -1
- package/resources/v1/materials/index.mjs.map +1 -1
- package/resources/v1/materials/materials.d.mts +24 -3
- package/resources/v1/materials/materials.d.mts.map +1 -1
- package/resources/v1/materials/materials.d.ts +24 -3
- package/resources/v1/materials/materials.d.ts.map +1 -1
- package/resources/v1/materials/materials.js +5 -2
- package/resources/v1/materials/materials.js.map +1 -1
- package/resources/v1/materials/materials.mjs +5 -2
- package/resources/v1/materials/materials.mjs.map +1 -1
- package/resources/v1/upload/component.d.mts +116 -9
- package/resources/v1/upload/component.d.mts.map +1 -1
- package/resources/v1/upload/component.d.ts +116 -9
- package/resources/v1/upload/component.d.ts.map +1 -1
- package/resources/v1/upload/component.js +43 -14
- package/resources/v1/upload/component.js.map +1 -1
- package/resources/v1/upload/component.mjs +43 -14
- package/resources/v1/upload/component.mjs.map +1 -1
- package/resources/v1/upload/index.d.mts +1 -1
- package/resources/v1/upload/index.d.mts.map +1 -1
- package/resources/v1/upload/index.d.ts +1 -1
- package/resources/v1/upload/index.d.ts.map +1 -1
- package/resources/v1/upload/index.js.map +1 -1
- package/resources/v1/upload/index.mjs +1 -1
- package/resources/v1/upload/index.mjs.map +1 -1
- package/resources/v1/upload/upload.d.mts +2 -2
- package/resources/v1/upload/upload.d.mts.map +1 -1
- package/resources/v1/upload/upload.d.ts +2 -2
- package/resources/v1/upload/upload.d.ts.map +1 -1
- package/resources/v1/upload/upload.js.map +1 -1
- package/resources/v1/upload/upload.mjs +1 -1
- package/resources/v1/upload/upload.mjs.map +1 -1
- package/resources/v1/v1.d.mts +2 -2
- package/resources/v1/v1.d.mts.map +1 -1
- package/resources/v1/v1.d.ts +2 -2
- package/resources/v1/v1.d.ts.map +1 -1
- package/resources/v1/v1.js.map +1 -1
- package/resources/v1/v1.mjs.map +1 -1
- package/src/resources/v1/components.ts +0 -6
- package/src/resources/v1/index.ts +1 -0
- package/src/resources/v1/materials/index.ts +1 -0
- package/src/resources/v1/materials/materials.ts +29 -2
- package/src/resources/v1/upload/component.ts +162 -14
- package/src/resources/v1/upload/index.ts +8 -1
- package/src/resources/v1/upload/upload.ts +16 -2
- package/src/resources/v1/v1.ts +2 -0
- 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,38 +1,145 @@
|
|
|
1
1
|
import { APIResource } from "../../../core/resource.mjs";
|
|
2
2
|
import { APIPromise } from "../../../core/api-promise.mjs";
|
|
3
|
+
import { type Uploadable } from "../../../core/uploads.mjs";
|
|
3
4
|
import { RequestOptions } from "../../../internal/request-options.mjs";
|
|
4
5
|
export declare class Component extends APIResource {
|
|
5
6
|
/**
|
|
7
|
+
* Complete a file upload after using presigned URL
|
|
8
|
+
*
|
|
6
9
|
* @example
|
|
7
10
|
* ```ts
|
|
8
11
|
* await client.v1.upload.component.completeUpload(
|
|
9
12
|
* 'componentId',
|
|
13
|
+
* {
|
|
14
|
+
* materialId: 'materialId',
|
|
15
|
+
* organizationId: 'organizationId',
|
|
16
|
+
* s3Key: 's3Key',
|
|
17
|
+
* },
|
|
10
18
|
* );
|
|
11
19
|
* ```
|
|
12
20
|
*/
|
|
13
|
-
completeUpload(componentID: string, options?: RequestOptions): APIPromise<void>;
|
|
21
|
+
completeUpload(componentID: string, body: ComponentCompleteUploadParams, options?: RequestOptions): APIPromise<void>;
|
|
14
22
|
/**
|
|
23
|
+
* Get a presigned URL for direct file upload
|
|
24
|
+
*
|
|
15
25
|
* @example
|
|
16
26
|
* ```ts
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
27
|
+
* const response =
|
|
28
|
+
* await client.v1.upload.component.getPresignedURL(
|
|
29
|
+
* 'componentId',
|
|
30
|
+
* {
|
|
31
|
+
* contentType: 'application/pdf',
|
|
32
|
+
* filename: 'document.pdf',
|
|
33
|
+
* folderId: 'folderId',
|
|
34
|
+
* organizationId: 'organizationId',
|
|
35
|
+
* },
|
|
36
|
+
* );
|
|
20
37
|
* ```
|
|
21
38
|
*/
|
|
22
|
-
getPresignedURL(componentID: string, options?: RequestOptions): APIPromise<
|
|
39
|
+
getPresignedURL(componentID: string, body: ComponentGetPresignedURLParams, options?: RequestOptions): APIPromise<ComponentGetPresignedURLResponse>;
|
|
23
40
|
/**
|
|
41
|
+
* Upload a file to a component
|
|
42
|
+
*
|
|
24
43
|
* @example
|
|
25
44
|
* ```ts
|
|
26
|
-
* await client.v1.upload.component.uploadFile('componentId'
|
|
45
|
+
* await client.v1.upload.component.uploadFile('componentId', {
|
|
46
|
+
* file: fs.createReadStream('path/to/file'),
|
|
47
|
+
* folderId: 'folderId',
|
|
48
|
+
* organizationId: 'organizationId',
|
|
49
|
+
* });
|
|
27
50
|
* ```
|
|
28
51
|
*/
|
|
29
|
-
uploadFile(componentID: string, options?: RequestOptions): APIPromise<void>;
|
|
52
|
+
uploadFile(componentID: string, body: ComponentUploadFileParams, options?: RequestOptions): APIPromise<void>;
|
|
30
53
|
/**
|
|
54
|
+
* Upload a file from URL to a component
|
|
55
|
+
*
|
|
31
56
|
* @example
|
|
32
57
|
* ```ts
|
|
33
|
-
* await client.v1.upload.component.uploadURL('componentId'
|
|
58
|
+
* await client.v1.upload.component.uploadURL('componentId', {
|
|
59
|
+
* folderId: 'folderId',
|
|
60
|
+
* name: 'my-document.pdf',
|
|
61
|
+
* organizationId: 'organizationId',
|
|
62
|
+
* url: 'https://example.com/document.pdf',
|
|
63
|
+
* });
|
|
34
64
|
* ```
|
|
35
65
|
*/
|
|
36
|
-
uploadURL(componentID: string, options?: RequestOptions): APIPromise<void>;
|
|
66
|
+
uploadURL(componentID: string, body: ComponentUploadURLParams, options?: RequestOptions): APIPromise<void>;
|
|
67
|
+
}
|
|
68
|
+
export interface ComponentGetPresignedURLResponse {
|
|
69
|
+
/**
|
|
70
|
+
* The S3 key for the file
|
|
71
|
+
*/
|
|
72
|
+
key?: string;
|
|
73
|
+
/**
|
|
74
|
+
* The presigned URL for uploading
|
|
75
|
+
*/
|
|
76
|
+
uploadUrl?: string;
|
|
77
|
+
}
|
|
78
|
+
export interface ComponentCompleteUploadParams {
|
|
79
|
+
/**
|
|
80
|
+
* The ID of the material that was uploaded
|
|
81
|
+
*/
|
|
82
|
+
materialId: string;
|
|
83
|
+
/**
|
|
84
|
+
* The ID of the organization
|
|
85
|
+
*/
|
|
86
|
+
organizationId: string;
|
|
87
|
+
/**
|
|
88
|
+
* The S3 key of the uploaded file
|
|
89
|
+
*/
|
|
90
|
+
s3Key: string;
|
|
91
|
+
}
|
|
92
|
+
export interface ComponentGetPresignedURLParams {
|
|
93
|
+
/**
|
|
94
|
+
* The MIME type of the file
|
|
95
|
+
*/
|
|
96
|
+
contentType: string;
|
|
97
|
+
/**
|
|
98
|
+
* The name of the file to upload
|
|
99
|
+
*/
|
|
100
|
+
filename: string;
|
|
101
|
+
/**
|
|
102
|
+
* The ID of the folder to upload to
|
|
103
|
+
*/
|
|
104
|
+
folderId: string;
|
|
105
|
+
/**
|
|
106
|
+
* The ID of the organization
|
|
107
|
+
*/
|
|
108
|
+
organizationId: string;
|
|
109
|
+
}
|
|
110
|
+
export interface ComponentUploadFileParams {
|
|
111
|
+
/**
|
|
112
|
+
* The file to upload
|
|
113
|
+
*/
|
|
114
|
+
file: Uploadable;
|
|
115
|
+
/**
|
|
116
|
+
* The ID of the folder to upload to
|
|
117
|
+
*/
|
|
118
|
+
folderId: string;
|
|
119
|
+
/**
|
|
120
|
+
* The ID of the organization
|
|
121
|
+
*/
|
|
122
|
+
organizationId: string;
|
|
123
|
+
}
|
|
124
|
+
export interface ComponentUploadURLParams {
|
|
125
|
+
/**
|
|
126
|
+
* The ID of the folder to upload to
|
|
127
|
+
*/
|
|
128
|
+
folderId: string;
|
|
129
|
+
/**
|
|
130
|
+
* The name for the uploaded file
|
|
131
|
+
*/
|
|
132
|
+
name: string;
|
|
133
|
+
/**
|
|
134
|
+
* The ID of the organization
|
|
135
|
+
*/
|
|
136
|
+
organizationId: string;
|
|
137
|
+
/**
|
|
138
|
+
* The URL of the file to upload
|
|
139
|
+
*/
|
|
140
|
+
url: string;
|
|
141
|
+
}
|
|
142
|
+
export declare namespace Component {
|
|
143
|
+
export { type ComponentGetPresignedURLResponse as ComponentGetPresignedURLResponse, type ComponentCompleteUploadParams as ComponentCompleteUploadParams, type ComponentGetPresignedURLParams as ComponentGetPresignedURLParams, type ComponentUploadFileParams as ComponentUploadFileParams, type ComponentUploadURLParams as ComponentUploadURLParams, };
|
|
37
144
|
}
|
|
38
145
|
//# sourceMappingURL=component.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;
|
|
1
|
+
{"version":3,"file":"component.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,KAAK,UAAU,EAAE;OAEnB,EAAE,cAAc,EAAE;AAIzB,qBAAa,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;;;;;OAcG;IACH,cAAc,CACZ,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,6BAA6B,EACnC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,IAAI,CAAC;IAQnB;;;;;;;;;;;;;;;;OAgBG;IACH,eAAe,CACb,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,8BAA8B,EACpC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,gCAAgC,CAAC;IAO/C;;;;;;;;;;;OAWG;IACH,UAAU,CACR,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,yBAAyB,EAC/B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,IAAI,CAAC;IAUnB;;;;;;;;;;;;OAYG;IACH,SAAS,CAAC,WAAW,EAAE,MAAM,EAAE,IAAI,EAAE,wBAAwB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC;CAO3G;AAED,MAAM,WAAW,gCAAgC;IAC/C;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,6BAA6B;IAC5C;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,8BAA8B;IAC7C;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,yBAAyB;IACxC;;OAEG;IACH,IAAI,EAAE,UAAU,CAAC;IAEjB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,gCAAgC,IAAI,gCAAgC,EACzE,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
|
|
@@ -1,38 +1,145 @@
|
|
|
1
1
|
import { APIResource } from "../../../core/resource.js";
|
|
2
2
|
import { APIPromise } from "../../../core/api-promise.js";
|
|
3
|
+
import { type Uploadable } from "../../../core/uploads.js";
|
|
3
4
|
import { RequestOptions } from "../../../internal/request-options.js";
|
|
4
5
|
export declare class Component extends APIResource {
|
|
5
6
|
/**
|
|
7
|
+
* Complete a file upload after using presigned URL
|
|
8
|
+
*
|
|
6
9
|
* @example
|
|
7
10
|
* ```ts
|
|
8
11
|
* await client.v1.upload.component.completeUpload(
|
|
9
12
|
* 'componentId',
|
|
13
|
+
* {
|
|
14
|
+
* materialId: 'materialId',
|
|
15
|
+
* organizationId: 'organizationId',
|
|
16
|
+
* s3Key: 's3Key',
|
|
17
|
+
* },
|
|
10
18
|
* );
|
|
11
19
|
* ```
|
|
12
20
|
*/
|
|
13
|
-
completeUpload(componentID: string, options?: RequestOptions): APIPromise<void>;
|
|
21
|
+
completeUpload(componentID: string, body: ComponentCompleteUploadParams, options?: RequestOptions): APIPromise<void>;
|
|
14
22
|
/**
|
|
23
|
+
* Get a presigned URL for direct file upload
|
|
24
|
+
*
|
|
15
25
|
* @example
|
|
16
26
|
* ```ts
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
27
|
+
* const response =
|
|
28
|
+
* await client.v1.upload.component.getPresignedURL(
|
|
29
|
+
* 'componentId',
|
|
30
|
+
* {
|
|
31
|
+
* contentType: 'application/pdf',
|
|
32
|
+
* filename: 'document.pdf',
|
|
33
|
+
* folderId: 'folderId',
|
|
34
|
+
* organizationId: 'organizationId',
|
|
35
|
+
* },
|
|
36
|
+
* );
|
|
20
37
|
* ```
|
|
21
38
|
*/
|
|
22
|
-
getPresignedURL(componentID: string, options?: RequestOptions): APIPromise<
|
|
39
|
+
getPresignedURL(componentID: string, body: ComponentGetPresignedURLParams, options?: RequestOptions): APIPromise<ComponentGetPresignedURLResponse>;
|
|
23
40
|
/**
|
|
41
|
+
* Upload a file to a component
|
|
42
|
+
*
|
|
24
43
|
* @example
|
|
25
44
|
* ```ts
|
|
26
|
-
* await client.v1.upload.component.uploadFile('componentId'
|
|
45
|
+
* await client.v1.upload.component.uploadFile('componentId', {
|
|
46
|
+
* file: fs.createReadStream('path/to/file'),
|
|
47
|
+
* folderId: 'folderId',
|
|
48
|
+
* organizationId: 'organizationId',
|
|
49
|
+
* });
|
|
27
50
|
* ```
|
|
28
51
|
*/
|
|
29
|
-
uploadFile(componentID: string, options?: RequestOptions): APIPromise<void>;
|
|
52
|
+
uploadFile(componentID: string, body: ComponentUploadFileParams, options?: RequestOptions): APIPromise<void>;
|
|
30
53
|
/**
|
|
54
|
+
* Upload a file from URL to a component
|
|
55
|
+
*
|
|
31
56
|
* @example
|
|
32
57
|
* ```ts
|
|
33
|
-
* await client.v1.upload.component.uploadURL('componentId'
|
|
58
|
+
* await client.v1.upload.component.uploadURL('componentId', {
|
|
59
|
+
* folderId: 'folderId',
|
|
60
|
+
* name: 'my-document.pdf',
|
|
61
|
+
* organizationId: 'organizationId',
|
|
62
|
+
* url: 'https://example.com/document.pdf',
|
|
63
|
+
* });
|
|
34
64
|
* ```
|
|
35
65
|
*/
|
|
36
|
-
uploadURL(componentID: string, options?: RequestOptions): APIPromise<void>;
|
|
66
|
+
uploadURL(componentID: string, body: ComponentUploadURLParams, options?: RequestOptions): APIPromise<void>;
|
|
67
|
+
}
|
|
68
|
+
export interface ComponentGetPresignedURLResponse {
|
|
69
|
+
/**
|
|
70
|
+
* The S3 key for the file
|
|
71
|
+
*/
|
|
72
|
+
key?: string;
|
|
73
|
+
/**
|
|
74
|
+
* The presigned URL for uploading
|
|
75
|
+
*/
|
|
76
|
+
uploadUrl?: string;
|
|
77
|
+
}
|
|
78
|
+
export interface ComponentCompleteUploadParams {
|
|
79
|
+
/**
|
|
80
|
+
* The ID of the material that was uploaded
|
|
81
|
+
*/
|
|
82
|
+
materialId: string;
|
|
83
|
+
/**
|
|
84
|
+
* The ID of the organization
|
|
85
|
+
*/
|
|
86
|
+
organizationId: string;
|
|
87
|
+
/**
|
|
88
|
+
* The S3 key of the uploaded file
|
|
89
|
+
*/
|
|
90
|
+
s3Key: string;
|
|
91
|
+
}
|
|
92
|
+
export interface ComponentGetPresignedURLParams {
|
|
93
|
+
/**
|
|
94
|
+
* The MIME type of the file
|
|
95
|
+
*/
|
|
96
|
+
contentType: string;
|
|
97
|
+
/**
|
|
98
|
+
* The name of the file to upload
|
|
99
|
+
*/
|
|
100
|
+
filename: string;
|
|
101
|
+
/**
|
|
102
|
+
* The ID of the folder to upload to
|
|
103
|
+
*/
|
|
104
|
+
folderId: string;
|
|
105
|
+
/**
|
|
106
|
+
* The ID of the organization
|
|
107
|
+
*/
|
|
108
|
+
organizationId: string;
|
|
109
|
+
}
|
|
110
|
+
export interface ComponentUploadFileParams {
|
|
111
|
+
/**
|
|
112
|
+
* The file to upload
|
|
113
|
+
*/
|
|
114
|
+
file: Uploadable;
|
|
115
|
+
/**
|
|
116
|
+
* The ID of the folder to upload to
|
|
117
|
+
*/
|
|
118
|
+
folderId: string;
|
|
119
|
+
/**
|
|
120
|
+
* The ID of the organization
|
|
121
|
+
*/
|
|
122
|
+
organizationId: string;
|
|
123
|
+
}
|
|
124
|
+
export interface ComponentUploadURLParams {
|
|
125
|
+
/**
|
|
126
|
+
* The ID of the folder to upload to
|
|
127
|
+
*/
|
|
128
|
+
folderId: string;
|
|
129
|
+
/**
|
|
130
|
+
* The name for the uploaded file
|
|
131
|
+
*/
|
|
132
|
+
name: string;
|
|
133
|
+
/**
|
|
134
|
+
* The ID of the organization
|
|
135
|
+
*/
|
|
136
|
+
organizationId: string;
|
|
137
|
+
/**
|
|
138
|
+
* The URL of the file to upload
|
|
139
|
+
*/
|
|
140
|
+
url: string;
|
|
141
|
+
}
|
|
142
|
+
export declare namespace Component {
|
|
143
|
+
export { type ComponentGetPresignedURLResponse as ComponentGetPresignedURLResponse, type ComponentCompleteUploadParams as ComponentCompleteUploadParams, type ComponentGetPresignedURLParams as ComponentGetPresignedURLParams, type ComponentUploadFileParams as ComponentUploadFileParams, type ComponentUploadURLParams as ComponentUploadURLParams, };
|
|
37
144
|
}
|
|
38
145
|
//# sourceMappingURL=component.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;
|
|
1
|
+
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,KAAK,UAAU,EAAE;OAEnB,EAAE,cAAc,EAAE;AAIzB,qBAAa,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;;;;;OAcG;IACH,cAAc,CACZ,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,6BAA6B,EACnC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,IAAI,CAAC;IAQnB;;;;;;;;;;;;;;;;OAgBG;IACH,eAAe,CACb,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,8BAA8B,EACpC,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,gCAAgC,CAAC;IAO/C;;;;;;;;;;;OAWG;IACH,UAAU,CACR,WAAW,EAAE,MAAM,EACnB,IAAI,EAAE,yBAAyB,EAC/B,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,IAAI,CAAC;IAUnB;;;;;;;;;;;;OAYG;IACH,SAAS,CAAC,WAAW,EAAE,MAAM,EAAE,IAAI,EAAE,wBAAwB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,IAAI,CAAC;CAO3G;AAED,MAAM,WAAW,gCAAgC;IAC/C;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,6BAA6B;IAC5C;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;CACf;AAED,MAAM,WAAW,8BAA8B;IAC7C;;OAEG;IACH,WAAW,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,yBAAyB;IACxC;;OAEG;IACH,IAAI,EAAE,UAAU,CAAC;IAEjB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;CACxB;AAED,MAAM,WAAW,wBAAwB;IACvC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,CAAC,OAAO,WAAW,SAAS,CAAC;IACjC,OAAO,EACL,KAAK,gCAAgC,IAAI,gCAAgC,EACzE,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
|
|
@@ -4,56 +4,85 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.Component = void 0;
|
|
5
5
|
const resource_1 = require("../../../core/resource.js");
|
|
6
6
|
const headers_1 = require("../../../internal/headers.js");
|
|
7
|
+
const uploads_1 = require("../../../internal/uploads.js");
|
|
7
8
|
const path_1 = require("../../../internal/utils/path.js");
|
|
8
9
|
class Component extends resource_1.APIResource {
|
|
9
10
|
/**
|
|
11
|
+
* Complete a file upload after using presigned URL
|
|
12
|
+
*
|
|
10
13
|
* @example
|
|
11
14
|
* ```ts
|
|
12
15
|
* await client.v1.upload.component.completeUpload(
|
|
13
16
|
* 'componentId',
|
|
17
|
+
* {
|
|
18
|
+
* materialId: 'materialId',
|
|
19
|
+
* organizationId: 'organizationId',
|
|
20
|
+
* s3Key: 's3Key',
|
|
21
|
+
* },
|
|
14
22
|
* );
|
|
15
23
|
* ```
|
|
16
24
|
*/
|
|
17
|
-
completeUpload(componentID, options) {
|
|
25
|
+
completeUpload(componentID, body, options) {
|
|
18
26
|
return this._client.post((0, path_1.path) `/api/v1/upload/component/${componentID}/complete`, {
|
|
27
|
+
body,
|
|
19
28
|
...options,
|
|
20
29
|
headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
|
|
21
30
|
});
|
|
22
31
|
}
|
|
23
32
|
/**
|
|
33
|
+
* Get a presigned URL for direct file upload
|
|
34
|
+
*
|
|
24
35
|
* @example
|
|
25
36
|
* ```ts
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
37
|
+
* const response =
|
|
38
|
+
* await client.v1.upload.component.getPresignedURL(
|
|
39
|
+
* 'componentId',
|
|
40
|
+
* {
|
|
41
|
+
* contentType: 'application/pdf',
|
|
42
|
+
* filename: 'document.pdf',
|
|
43
|
+
* folderId: 'folderId',
|
|
44
|
+
* organizationId: 'organizationId',
|
|
45
|
+
* },
|
|
46
|
+
* );
|
|
29
47
|
* ```
|
|
30
48
|
*/
|
|
31
|
-
getPresignedURL(componentID, options) {
|
|
49
|
+
getPresignedURL(componentID, body, options) {
|
|
32
50
|
return this._client.post((0, path_1.path) `/api/v1/upload/component/${componentID}/presigned-url`, {
|
|
51
|
+
body,
|
|
33
52
|
...options,
|
|
34
|
-
headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
|
|
35
53
|
});
|
|
36
54
|
}
|
|
37
55
|
/**
|
|
56
|
+
* Upload a file to a component
|
|
57
|
+
*
|
|
38
58
|
* @example
|
|
39
59
|
* ```ts
|
|
40
|
-
* await client.v1.upload.component.uploadFile('componentId'
|
|
60
|
+
* await client.v1.upload.component.uploadFile('componentId', {
|
|
61
|
+
* file: fs.createReadStream('path/to/file'),
|
|
62
|
+
* folderId: 'folderId',
|
|
63
|
+
* organizationId: 'organizationId',
|
|
64
|
+
* });
|
|
41
65
|
* ```
|
|
42
66
|
*/
|
|
43
|
-
uploadFile(componentID, options) {
|
|
44
|
-
return this._client.post((0, path_1.path) `/api/v1/upload/component/${componentID}/file`, {
|
|
45
|
-
...options,
|
|
46
|
-
headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
|
|
47
|
-
});
|
|
67
|
+
uploadFile(componentID, body, options) {
|
|
68
|
+
return this._client.post((0, path_1.path) `/api/v1/upload/component/${componentID}/file`, (0, uploads_1.multipartFormRequestOptions)({ body, ...options, headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]) }, this._client));
|
|
48
69
|
}
|
|
49
70
|
/**
|
|
71
|
+
* Upload a file from URL to a component
|
|
72
|
+
*
|
|
50
73
|
* @example
|
|
51
74
|
* ```ts
|
|
52
|
-
* await client.v1.upload.component.uploadURL('componentId'
|
|
75
|
+
* await client.v1.upload.component.uploadURL('componentId', {
|
|
76
|
+
* folderId: 'folderId',
|
|
77
|
+
* name: 'my-document.pdf',
|
|
78
|
+
* organizationId: 'organizationId',
|
|
79
|
+
* url: 'https://example.com/document.pdf',
|
|
80
|
+
* });
|
|
53
81
|
* ```
|
|
54
82
|
*/
|
|
55
|
-
uploadURL(componentID, options) {
|
|
83
|
+
uploadURL(componentID, body, options) {
|
|
56
84
|
return this._client.post((0, path_1.path) `/api/v1/upload/component/${componentID}/url`, {
|
|
85
|
+
body,
|
|
57
86
|
...options,
|
|
58
87
|
headers: (0, headers_1.buildHeaders)([{ Accept: '*/*' }, options?.headers]),
|
|
59
88
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.js","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;
|
|
1
|
+
{"version":3,"file":"component.js","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,wDAAqD;AAGrD,0DAAyD;AAEzD,0DAAwE;AACxE,0DAAoD;AAEpD,MAAa,SAAU,SAAQ,sBAAW;IACxC;;;;;;;;;;;;;;OAcG;IACH,cAAc,CACZ,WAAmB,EACnB,IAAmC,EACnC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,4BAA4B,WAAW,WAAW,EAAE;YAC/E,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;OAgBG;IACH,eAAe,CACb,WAAmB,EACnB,IAAoC,EACpC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,4BAA4B,WAAW,gBAAgB,EAAE;YACpF,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;OAWG;IACH,UAAU,CACR,WAAmB,EACnB,IAA+B,EAC/B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CACtB,IAAA,WAAI,EAAA,4BAA4B,WAAW,OAAO,EAClD,IAAA,qCAA2B,EACzB,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,EAAE,EAClF,IAAI,CAAC,OAAO,CACb,CACF,CAAC;IACJ,CAAC;IAED;;;;;;;;;;;;OAYG;IACH,SAAS,CAAC,WAAmB,EAAE,IAA8B,EAAE,OAAwB;QACrF,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAA,WAAI,EAAA,4BAA4B,WAAW,MAAM,EAAE;YAC1E,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF;AAtGD,8BAsGC"}
|
|
@@ -1,56 +1,85 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../../../core/resource.mjs";
|
|
3
3
|
import { buildHeaders } from "../../../internal/headers.mjs";
|
|
4
|
+
import { multipartFormRequestOptions } from "../../../internal/uploads.mjs";
|
|
4
5
|
import { path } from "../../../internal/utils/path.mjs";
|
|
5
6
|
export class Component extends APIResource {
|
|
6
7
|
/**
|
|
8
|
+
* Complete a file upload after using presigned URL
|
|
9
|
+
*
|
|
7
10
|
* @example
|
|
8
11
|
* ```ts
|
|
9
12
|
* await client.v1.upload.component.completeUpload(
|
|
10
13
|
* 'componentId',
|
|
14
|
+
* {
|
|
15
|
+
* materialId: 'materialId',
|
|
16
|
+
* organizationId: 'organizationId',
|
|
17
|
+
* s3Key: 's3Key',
|
|
18
|
+
* },
|
|
11
19
|
* );
|
|
12
20
|
* ```
|
|
13
21
|
*/
|
|
14
|
-
completeUpload(componentID, options) {
|
|
22
|
+
completeUpload(componentID, body, options) {
|
|
15
23
|
return this._client.post(path `/api/v1/upload/component/${componentID}/complete`, {
|
|
24
|
+
body,
|
|
16
25
|
...options,
|
|
17
26
|
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
18
27
|
});
|
|
19
28
|
}
|
|
20
29
|
/**
|
|
30
|
+
* Get a presigned URL for direct file upload
|
|
31
|
+
*
|
|
21
32
|
* @example
|
|
22
33
|
* ```ts
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
34
|
+
* const response =
|
|
35
|
+
* await client.v1.upload.component.getPresignedURL(
|
|
36
|
+
* 'componentId',
|
|
37
|
+
* {
|
|
38
|
+
* contentType: 'application/pdf',
|
|
39
|
+
* filename: 'document.pdf',
|
|
40
|
+
* folderId: 'folderId',
|
|
41
|
+
* organizationId: 'organizationId',
|
|
42
|
+
* },
|
|
43
|
+
* );
|
|
26
44
|
* ```
|
|
27
45
|
*/
|
|
28
|
-
getPresignedURL(componentID, options) {
|
|
46
|
+
getPresignedURL(componentID, body, options) {
|
|
29
47
|
return this._client.post(path `/api/v1/upload/component/${componentID}/presigned-url`, {
|
|
48
|
+
body,
|
|
30
49
|
...options,
|
|
31
|
-
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
32
50
|
});
|
|
33
51
|
}
|
|
34
52
|
/**
|
|
53
|
+
* Upload a file to a component
|
|
54
|
+
*
|
|
35
55
|
* @example
|
|
36
56
|
* ```ts
|
|
37
|
-
* await client.v1.upload.component.uploadFile('componentId'
|
|
57
|
+
* await client.v1.upload.component.uploadFile('componentId', {
|
|
58
|
+
* file: fs.createReadStream('path/to/file'),
|
|
59
|
+
* folderId: 'folderId',
|
|
60
|
+
* organizationId: 'organizationId',
|
|
61
|
+
* });
|
|
38
62
|
* ```
|
|
39
63
|
*/
|
|
40
|
-
uploadFile(componentID, options) {
|
|
41
|
-
return this._client.post(path `/api/v1/upload/component/${componentID}/file`, {
|
|
42
|
-
...options,
|
|
43
|
-
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
44
|
-
});
|
|
64
|
+
uploadFile(componentID, body, options) {
|
|
65
|
+
return this._client.post(path `/api/v1/upload/component/${componentID}/file`, multipartFormRequestOptions({ body, ...options, headers: buildHeaders([{ Accept: '*/*' }, options?.headers]) }, this._client));
|
|
45
66
|
}
|
|
46
67
|
/**
|
|
68
|
+
* Upload a file from URL to a component
|
|
69
|
+
*
|
|
47
70
|
* @example
|
|
48
71
|
* ```ts
|
|
49
|
-
* await client.v1.upload.component.uploadURL('componentId'
|
|
72
|
+
* await client.v1.upload.component.uploadURL('componentId', {
|
|
73
|
+
* folderId: 'folderId',
|
|
74
|
+
* name: 'my-document.pdf',
|
|
75
|
+
* organizationId: 'organizationId',
|
|
76
|
+
* url: 'https://example.com/document.pdf',
|
|
77
|
+
* });
|
|
50
78
|
* ```
|
|
51
79
|
*/
|
|
52
|
-
uploadURL(componentID, options) {
|
|
80
|
+
uploadURL(componentID, body, options) {
|
|
53
81
|
return this._client.post(path `/api/v1/upload/component/${componentID}/url`, {
|
|
82
|
+
body,
|
|
54
83
|
...options,
|
|
55
84
|
headers: buildHeaders([{ Accept: '*/*' }, options?.headers]),
|
|
56
85
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component.mjs","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;
|
|
1
|
+
{"version":3,"file":"component.mjs","sourceRoot":"","sources":["../../../src/resources/v1/upload/component.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAGf,EAAE,YAAY,EAAE;OAEhB,EAAE,2BAA2B,EAAE;OAC/B,EAAE,IAAI,EAAE;AAEf,MAAM,OAAO,SAAU,SAAQ,WAAW;IACxC;;;;;;;;;;;;;;OAcG;IACH,cAAc,CACZ,WAAmB,EACnB,IAAmC,EACnC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,4BAA4B,WAAW,WAAW,EAAE;YAC/E,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;OAgBG;IACH,eAAe,CACb,WAAmB,EACnB,IAAoC,EACpC,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,4BAA4B,WAAW,gBAAgB,EAAE;YACpF,IAAI;YACJ,GAAG,OAAO;SACX,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;OAWG;IACH,UAAU,CACR,WAAmB,EACnB,IAA+B,EAC/B,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CACtB,IAAI,CAAA,4BAA4B,WAAW,OAAO,EAClD,2BAA2B,CACzB,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC,EAAE,EAClF,IAAI,CAAC,OAAO,CACb,CACF,CAAC;IACJ,CAAC;IAED;;;;;;;;;;;;OAYG;IACH,SAAS,CAAC,WAAmB,EAAE,IAA8B,EAAE,OAAwB;QACrF,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,CAAA,4BAA4B,WAAW,MAAM,EAAE;YAC1E,IAAI;YACJ,GAAG,OAAO;YACV,OAAO,EAAE,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,OAAO,CAAC,CAAC;SAC7D,CAAC,CAAC;IACL,CAAC;CACF"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { Component } from "./component.mjs";
|
|
1
|
+
export { Component, type ComponentGetPresignedURLResponse, type ComponentCompleteUploadParams, type ComponentGetPresignedURLParams, type ComponentUploadFileParams, type ComponentUploadURLParams, } from "./component.mjs";
|
|
2
2
|
export { Upload } from "./upload.mjs";
|
|
3
3
|
//# sourceMappingURL=index.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":"OAEO,
|
|
1
|
+
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":"OAEO,EACL,SAAS,EACT,KAAK,gCAAgC,EACrC,KAAK,6BAA6B,EAClC,KAAK,8BAA8B,EACnC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,GAC9B;OACM,EAAE,MAAM,EAAE"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { Component } from "./component.js";
|
|
1
|
+
export { Component, type ComponentGetPresignedURLResponse, type ComponentCompleteUploadParams, type ComponentGetPresignedURLParams, type ComponentUploadFileParams, type ComponentUploadURLParams, } from "./component.js";
|
|
2
2
|
export { Upload } from "./upload.js";
|
|
3
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":"OAEO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":"OAEO,EACL,SAAS,EACT,KAAK,gCAAgC,EACrC,KAAK,6BAA6B,EAClC,KAAK,8BAA8B,EACnC,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,GAC9B;OACM,EAAE,MAAM,EAAE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,4CAOqB;AANnB,sGAAA,SAAS,OAAA;AAOX,sCAAkC;AAAzB,gGAAA,MAAM,OAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,
|
|
1
|
+
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../../../src/resources/v1/upload/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EACL,SAAS,GAMV;OACM,EAAE,MAAM,EAAE"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { APIResource } from "../../../core/resource.mjs";
|
|
2
2
|
import * as ComponentAPI from "./component.mjs";
|
|
3
|
-
import { Component } from "./component.mjs";
|
|
3
|
+
import { Component, ComponentCompleteUploadParams, ComponentGetPresignedURLParams, ComponentGetPresignedURLResponse, ComponentUploadFileParams, ComponentUploadURLParams } from "./component.mjs";
|
|
4
4
|
export declare class Upload extends APIResource {
|
|
5
5
|
component: ComponentAPI.Component;
|
|
6
6
|
}
|
|
7
7
|
export declare namespace Upload {
|
|
8
|
-
export { Component as Component };
|
|
8
|
+
export { Component as Component, type ComponentGetPresignedURLResponse as ComponentGetPresignedURLResponse, type ComponentCompleteUploadParams as ComponentCompleteUploadParams, type ComponentGetPresignedURLParams as ComponentGetPresignedURLParams, type ComponentUploadFileParams as ComponentUploadFileParams, type ComponentUploadURLParams as ComponentUploadURLParams, };
|
|
9
9
|
}
|
|
10
10
|
//# sourceMappingURL=upload.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upload.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,
|
|
1
|
+
{"version":3,"file":"upload.d.mts","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,EACL,SAAS,EACT,6BAA6B,EAC7B,8BAA8B,EAC9B,gCAAgC,EAChC,yBAAyB,EACzB,wBAAwB,EACzB;AAED,qBAAa,MAAO,SAAQ,WAAW;IACrC,SAAS,EAAE,YAAY,CAAC,SAAS,CAA4C;CAC9E;AAID,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EACL,SAAS,IAAI,SAAS,EACtB,KAAK,gCAAgC,IAAI,gCAAgC,EACzE,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { APIResource } from "../../../core/resource.js";
|
|
2
2
|
import * as ComponentAPI from "./component.js";
|
|
3
|
-
import { Component } from "./component.js";
|
|
3
|
+
import { Component, ComponentCompleteUploadParams, ComponentGetPresignedURLParams, ComponentGetPresignedURLResponse, ComponentUploadFileParams, ComponentUploadURLParams } from "./component.js";
|
|
4
4
|
export declare class Upload extends APIResource {
|
|
5
5
|
component: ComponentAPI.Component;
|
|
6
6
|
}
|
|
7
7
|
export declare namespace Upload {
|
|
8
|
-
export { Component as Component };
|
|
8
|
+
export { Component as Component, type ComponentGetPresignedURLResponse as ComponentGetPresignedURLResponse, type ComponentCompleteUploadParams as ComponentCompleteUploadParams, type ComponentGetPresignedURLParams as ComponentGetPresignedURLParams, type ComponentUploadFileParams as ComponentUploadFileParams, type ComponentUploadURLParams as ComponentUploadURLParams, };
|
|
9
9
|
}
|
|
10
10
|
//# sourceMappingURL=upload.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upload.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,
|
|
1
|
+
{"version":3,"file":"upload.d.ts","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,EACL,SAAS,EACT,6BAA6B,EAC7B,8BAA8B,EAC9B,gCAAgC,EAChC,yBAAyB,EACzB,wBAAwB,EACzB;AAED,qBAAa,MAAO,SAAQ,WAAW;IACrC,SAAS,EAAE,YAAY,CAAC,SAAS,CAA4C;CAC9E;AAID,MAAM,CAAC,OAAO,WAAW,MAAM,CAAC;IAC9B,OAAO,EACL,SAAS,IAAI,SAAS,EACtB,KAAK,gCAAgC,IAAI,gCAAgC,EACzE,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,8BAA8B,IAAI,8BAA8B,EACrE,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,wBAAwB,IAAI,wBAAwB,GAC1D,CAAC;CACH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upload.js","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,wDAAqD;AACrD,qEAA4C;AAC5C,
|
|
1
|
+
{"version":3,"file":"upload.js","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,wDAAqD;AACrD,qEAA4C;AAC5C,8CAOqB;AAErB,MAAa,MAAO,SAAQ,sBAAW;IAAvC;;QACE,cAAS,GAA2B,IAAI,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC/E,CAAC;CAAA;AAFD,wBAEC;AAED,MAAM,CAAC,SAAS,GAAG,qBAAS,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../../../core/resource.mjs";
|
|
3
3
|
import * as ComponentAPI from "./component.mjs";
|
|
4
|
-
import { Component } from "./component.mjs";
|
|
4
|
+
import { Component, } from "./component.mjs";
|
|
5
5
|
export class Upload extends APIResource {
|
|
6
6
|
constructor() {
|
|
7
7
|
super(...arguments);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upload.mjs","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,
|
|
1
|
+
{"version":3,"file":"upload.mjs","sourceRoot":"","sources":["../../../src/resources/v1/upload/upload.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OACf,KAAK,YAAY;OACjB,EACL,SAAS,GAMV;AAED,MAAM,OAAO,MAAO,SAAQ,WAAW;IAAvC;;QACE,cAAS,GAA2B,IAAI,YAAY,CAAC,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC/E,CAAC;CAAA;AAED,MAAM,CAAC,SAAS,GAAG,SAAS,CAAC"}
|