@epilot/file-client 0.1.0 → 0.1.4
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/dist/definition.js +1 -1
- package/dist/openapi.d.ts +113 -33
- package/package.json +1 -1
- package/src/openapi.d.ts +113 -33
package/dist/definition.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,t){for(var i in t)e[i]=t[i];t.__esModule&&Object.defineProperty(e,"__esModule",{value:!0})}(exports,(()=>{"use strict";var e={914:function(e,t,i){var
|
|
1
|
+
!function(e,t){for(var i in t)e[i]=t[i];t.__esModule&&Object.defineProperty(e,"__esModule",{value:!0})}(exports,(()=>{"use strict";var e={914:function(e,t,i){var a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var n=a(i(279));t.default=n.default},279:e=>{e.exports=JSON.parse('{"openapi":"3.0.3","info":{"title":"File API","version":"0.1.0","description":"File Upload and Management for epilot SaaS"},"tags":[{"name":"files","description":"Files"}],"security":[{"EpilotAuth":[]},{"AsOrganization":[]}],"paths":{"/v1/files/public/upload":{"post":{"operationId":"uploadFilePublic","summary":"uploadFilePublic","security":[],"description":"Create pre-signed S3 URL to upload a file to keep temporarily (one week).\\n\\nUse the createFile operation to store file file permanently.\\n","tags":["files"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadFilePayload"}}}},"responses":{"201":{"description":"Pre-signed URL for POST / PUT upload","content":{"application/json":{"schema":{"type":"object","properties":{"upload_url":{"type":"string","format":"url","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123"},"s3ref":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"example":{"bucket":"epilot-files-prod","key":"123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}}]}}}}}}}}},"/v1/files/upload":{"post":{"operationId":"uploadFile","summary":"uploadFile","description":"Create pre-signed S3 URL to upload a file to keep temporarily (one week).\\n\\nUse the createFile operation to store file file permanently.\\n","tags":["files"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadFilePayload","type":"object"}}}},"responses":{"201":{"description":"Pre-signed URL for POST / PUT upload","content":{"application/json":{"schema":{"type":"object","properties":{"upload_url":{"type":"string","format":"url","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123"},"s3ref":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"example":{"bucket":"epilot-files-prod","key":"123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}}]}}}}}}}}},"/v1/files":{"post":{"operationId":"saveFile","summary":"saveFile","description":"Create / Update a permanent File entity\\n\\nMakes file object permanent\\n\\nSaves metadata to file entity\\n","tags":["files"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveFilePayload"}}}},"responses":{"201":{"description":"Created File Entity","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FileEntity"}}}}}}},"/v1/files/{id}/download":{"get":{"operationId":"downloadFile","summary":"downloadFile","description":"Generate pre-signed download S3 url for a file","tags":["files"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/FileEntityId"}},{"name":"version","in":"query","description":"index of file version","schema":{"type":"integer","default":0}}],"responses":{"200":{"description":"Generated thumbnail image","content":{"application/json":{"schema":{"type":"object","properties":{"download_url":{"type":"string","format":"uri","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123"}}}}}}}}},"/v1/files/{id}/preview":{"get":{"operationId":"previewFile","summary":"previewFile","description":"Generate thumbnail preview for a file entity","tags":["files"],"parameters":[{"name":"id","in":"path","required":true,"schema":{"$ref":"#/components/schemas/FileEntityId"}},{"name":"version","in":"query","description":"index of file version","schema":{"type":"integer","default":0}},{"name":"w","in":"query","description":"width","schema":{"type":"integer"}},{"name":"h","in":"query","description":"height","schema":{"type":"integer"}}],"responses":{"200":{"description":"Generated thumbnail image","content":{"image/png":{},"image/jpeg":{}}}}}}},"components":{"securitySchemes":{"EpilotAuth":{"type":"http","scheme":"bearer","description":"Epilot Bearer Token"},"AsOrganization":{"type":"apiKey","in":"header","name":"x-ivy-org-id","description":"Set organization id when using internal auth"}},"schemas":{"FileEntityId":{"type":"string","example":"ef7d985c-2385-44f4-9c71-ae06a52264f8"},"FileEntity":{"type":"object","properties":{"_id":{"$ref":"#/components/schemas/FileEntityId"},"filename":{"type":"string","example":"document.pdf"},"access_control":{"type":"string","default":"private","enum":["private","public"]},"versions":{"type":"array","items":{"type":"object","properties":{"s3ref":{"$ref":"#/components/schemas/S3Reference"}}}}}},"UploadFilePayload":{"type":"object","properties":{"filename":{"type":"string","example":"document.pdf"},"content_type":{"description":"MIME type of file","type":"string","example":"image/png","default":"application/octet-stream"}},"required":["filename"]},"SaveFilePayload":{"type":"object","properties":{"s3ref":{"$ref":"#/components/schemas/S3Reference"},"file_entity_id":{"type":"string","description":"if passed, adds a new version to existing file entity"},"filename":{"type":"string","example":"document.pdf"},"access_control":{"type":"string","default":"private","enum":["private","public"]}},"required":["s3ref"]},"S3Reference":{"type":"object","properties":{"bucket":{"type":"string","example":"epilot-files-prod"},"key":{"type":"string","example":"123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}},"required":["bucket","key"]},"FileItem":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"type":"object","properties":{"filename":{"type":"string","example":"document.pdf"},"size_bytes":{"type":"integer","example":1234}}}]}}}}')}},t={};return function i(a){if(t[a])return t[a].exports;var n=t[a]={exports:{}};return e[a].call(n.exports,n,n.exports,i),n.exports}(914)})());
|
package/dist/openapi.d.ts
CHANGED
|
@@ -26,15 +26,6 @@ declare namespace Components {
|
|
|
26
26
|
* ef7d985c-2385-44f4-9c71-ae06a52264f8
|
|
27
27
|
*/
|
|
28
28
|
export type FileEntityId = string;
|
|
29
|
-
export interface FileEntityPayload {
|
|
30
|
-
/**
|
|
31
|
-
* example:
|
|
32
|
-
* document.pdf
|
|
33
|
-
*/
|
|
34
|
-
filename?: string;
|
|
35
|
-
access_control?: "private" | "public";
|
|
36
|
-
versions?: FileItem[];
|
|
37
|
-
}
|
|
38
29
|
export interface FileItem {
|
|
39
30
|
/**
|
|
40
31
|
* example:
|
|
@@ -69,15 +60,35 @@ declare namespace Components {
|
|
|
69
60
|
*/
|
|
70
61
|
key: string;
|
|
71
62
|
}
|
|
63
|
+
export interface SaveFilePayload {
|
|
64
|
+
s3ref: S3Reference;
|
|
65
|
+
/**
|
|
66
|
+
* if passed, adds a new version to existing file entity
|
|
67
|
+
*/
|
|
68
|
+
file_entity_id?: string;
|
|
69
|
+
/**
|
|
70
|
+
* example:
|
|
71
|
+
* document.pdf
|
|
72
|
+
*/
|
|
73
|
+
filename?: string;
|
|
74
|
+
access_control?: "private" | "public";
|
|
75
|
+
}
|
|
76
|
+
export interface UploadFilePayload {
|
|
77
|
+
/**
|
|
78
|
+
* example:
|
|
79
|
+
* document.pdf
|
|
80
|
+
*/
|
|
81
|
+
filename: string;
|
|
82
|
+
/**
|
|
83
|
+
* MIME type of file
|
|
84
|
+
* example:
|
|
85
|
+
* image/png
|
|
86
|
+
*/
|
|
87
|
+
content_type?: string;
|
|
88
|
+
}
|
|
72
89
|
}
|
|
73
90
|
}
|
|
74
91
|
declare namespace Paths {
|
|
75
|
-
namespace CreateFile {
|
|
76
|
-
export type RequestBody = Components.Schemas.FileEntityPayload;
|
|
77
|
-
namespace Responses {
|
|
78
|
-
export type $201 = Components.Schemas.FileEntity;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
92
|
namespace DownloadFile {
|
|
82
93
|
namespace Parameters {
|
|
83
94
|
export type Id = Components.Schemas.FileEntityId;
|
|
@@ -115,14 +126,45 @@ declare namespace Paths {
|
|
|
115
126
|
h?: Parameters.H;
|
|
116
127
|
}
|
|
117
128
|
}
|
|
129
|
+
namespace SaveFile {
|
|
130
|
+
export type RequestBody = Components.Schemas.SaveFilePayload;
|
|
131
|
+
namespace Responses {
|
|
132
|
+
export type $201 = Components.Schemas.FileEntity;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
118
135
|
namespace UploadFile {
|
|
119
|
-
export
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
136
|
+
export type RequestBody = Components.Schemas.UploadFilePayload;
|
|
137
|
+
namespace Responses {
|
|
138
|
+
export interface $201 {
|
|
139
|
+
/**
|
|
140
|
+
* example:
|
|
141
|
+
* https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123
|
|
142
|
+
*/
|
|
143
|
+
upload_url?: string; // url
|
|
144
|
+
/**
|
|
145
|
+
* example:
|
|
146
|
+
* {
|
|
147
|
+
* "bucket": "epilot-files-prod",
|
|
148
|
+
* "key": "123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"
|
|
149
|
+
* }
|
|
150
|
+
*/
|
|
151
|
+
s3ref?: {
|
|
152
|
+
/**
|
|
153
|
+
* example:
|
|
154
|
+
* epilot-files-prod
|
|
155
|
+
*/
|
|
156
|
+
bucket: string;
|
|
157
|
+
/**
|
|
158
|
+
* example:
|
|
159
|
+
* 123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf
|
|
160
|
+
*/
|
|
161
|
+
key: string;
|
|
162
|
+
};
|
|
163
|
+
}
|
|
125
164
|
}
|
|
165
|
+
}
|
|
166
|
+
namespace UploadFilePublic {
|
|
167
|
+
export type RequestBody = Components.Schemas.UploadFilePayload;
|
|
126
168
|
namespace Responses {
|
|
127
169
|
export interface $201 {
|
|
128
170
|
/**
|
|
@@ -155,6 +197,19 @@ declare namespace Paths {
|
|
|
155
197
|
}
|
|
156
198
|
|
|
157
199
|
export interface OperationMethods {
|
|
200
|
+
/**
|
|
201
|
+
* uploadFilePublic - uploadFilePublic
|
|
202
|
+
*
|
|
203
|
+
* Create pre-signed S3 URL to upload a file to keep temporarily (one week).
|
|
204
|
+
*
|
|
205
|
+
* Use the createFile operation to store file file permanently.
|
|
206
|
+
*
|
|
207
|
+
*/
|
|
208
|
+
'uploadFilePublic'(
|
|
209
|
+
parameters?: Parameters<UnknownParamsObject> | null,
|
|
210
|
+
data?: Paths.UploadFilePublic.RequestBody,
|
|
211
|
+
config?: AxiosRequestConfig
|
|
212
|
+
): OperationResponse<Paths.UploadFilePublic.Responses.$201>
|
|
158
213
|
/**
|
|
159
214
|
* uploadFile - uploadFile
|
|
160
215
|
*
|
|
@@ -169,15 +224,20 @@ export interface OperationMethods {
|
|
|
169
224
|
config?: AxiosRequestConfig
|
|
170
225
|
): OperationResponse<Paths.UploadFile.Responses.$201>
|
|
171
226
|
/**
|
|
172
|
-
*
|
|
227
|
+
* saveFile - saveFile
|
|
228
|
+
*
|
|
229
|
+
* Create / Update a permanent File entity
|
|
230
|
+
*
|
|
231
|
+
* Makes file object permanent
|
|
232
|
+
*
|
|
233
|
+
* Saves metadata to file entity
|
|
173
234
|
*
|
|
174
|
-
* Create a permanent File entity
|
|
175
235
|
*/
|
|
176
|
-
'
|
|
236
|
+
'saveFile'(
|
|
177
237
|
parameters?: Parameters<UnknownParamsObject> | null,
|
|
178
|
-
data?: Paths.
|
|
238
|
+
data?: Paths.SaveFile.RequestBody,
|
|
179
239
|
config?: AxiosRequestConfig
|
|
180
|
-
): OperationResponse<Paths.
|
|
240
|
+
): OperationResponse<Paths.SaveFile.Responses.$201>
|
|
181
241
|
/**
|
|
182
242
|
* downloadFile - downloadFile
|
|
183
243
|
*
|
|
@@ -201,7 +261,22 @@ export interface OperationMethods {
|
|
|
201
261
|
}
|
|
202
262
|
|
|
203
263
|
export interface PathsDictionary {
|
|
204
|
-
['/v1/files
|
|
264
|
+
['/v1/files/public/upload']: {
|
|
265
|
+
/**
|
|
266
|
+
* uploadFilePublic - uploadFilePublic
|
|
267
|
+
*
|
|
268
|
+
* Create pre-signed S3 URL to upload a file to keep temporarily (one week).
|
|
269
|
+
*
|
|
270
|
+
* Use the createFile operation to store file file permanently.
|
|
271
|
+
*
|
|
272
|
+
*/
|
|
273
|
+
'post'(
|
|
274
|
+
parameters?: Parameters<UnknownParamsObject> | null,
|
|
275
|
+
data?: Paths.UploadFilePublic.RequestBody,
|
|
276
|
+
config?: AxiosRequestConfig
|
|
277
|
+
): OperationResponse<Paths.UploadFilePublic.Responses.$201>
|
|
278
|
+
}
|
|
279
|
+
['/v1/files/upload']: {
|
|
205
280
|
/**
|
|
206
281
|
* uploadFile - uploadFile
|
|
207
282
|
*
|
|
@@ -218,17 +293,22 @@ export interface PathsDictionary {
|
|
|
218
293
|
}
|
|
219
294
|
['/v1/files']: {
|
|
220
295
|
/**
|
|
221
|
-
*
|
|
296
|
+
* saveFile - saveFile
|
|
297
|
+
*
|
|
298
|
+
* Create / Update a permanent File entity
|
|
299
|
+
*
|
|
300
|
+
* Makes file object permanent
|
|
301
|
+
*
|
|
302
|
+
* Saves metadata to file entity
|
|
222
303
|
*
|
|
223
|
-
* Create a permanent File entity
|
|
224
304
|
*/
|
|
225
305
|
'post'(
|
|
226
306
|
parameters?: Parameters<UnknownParamsObject> | null,
|
|
227
|
-
data?: Paths.
|
|
307
|
+
data?: Paths.SaveFile.RequestBody,
|
|
228
308
|
config?: AxiosRequestConfig
|
|
229
|
-
): OperationResponse<Paths.
|
|
309
|
+
): OperationResponse<Paths.SaveFile.Responses.$201>
|
|
230
310
|
}
|
|
231
|
-
['/v1/files/{id}
|
|
311
|
+
['/v1/files/{id}/download']: {
|
|
232
312
|
/**
|
|
233
313
|
* downloadFile - downloadFile
|
|
234
314
|
*
|
|
@@ -240,7 +320,7 @@ export interface PathsDictionary {
|
|
|
240
320
|
config?: AxiosRequestConfig
|
|
241
321
|
): OperationResponse<Paths.DownloadFile.Responses.$200>
|
|
242
322
|
}
|
|
243
|
-
['/v1/files/{id}
|
|
323
|
+
['/v1/files/{id}/preview']: {
|
|
244
324
|
/**
|
|
245
325
|
* previewFile - previewFile
|
|
246
326
|
*
|
package/package.json
CHANGED
package/src/openapi.d.ts
CHANGED
|
@@ -26,15 +26,6 @@ declare namespace Components {
|
|
|
26
26
|
* ef7d985c-2385-44f4-9c71-ae06a52264f8
|
|
27
27
|
*/
|
|
28
28
|
export type FileEntityId = string;
|
|
29
|
-
export interface FileEntityPayload {
|
|
30
|
-
/**
|
|
31
|
-
* example:
|
|
32
|
-
* document.pdf
|
|
33
|
-
*/
|
|
34
|
-
filename?: string;
|
|
35
|
-
access_control?: "private" | "public";
|
|
36
|
-
versions?: FileItem[];
|
|
37
|
-
}
|
|
38
29
|
export interface FileItem {
|
|
39
30
|
/**
|
|
40
31
|
* example:
|
|
@@ -69,15 +60,35 @@ declare namespace Components {
|
|
|
69
60
|
*/
|
|
70
61
|
key: string;
|
|
71
62
|
}
|
|
63
|
+
export interface SaveFilePayload {
|
|
64
|
+
s3ref: S3Reference;
|
|
65
|
+
/**
|
|
66
|
+
* if passed, adds a new version to existing file entity
|
|
67
|
+
*/
|
|
68
|
+
file_entity_id?: string;
|
|
69
|
+
/**
|
|
70
|
+
* example:
|
|
71
|
+
* document.pdf
|
|
72
|
+
*/
|
|
73
|
+
filename?: string;
|
|
74
|
+
access_control?: "private" | "public";
|
|
75
|
+
}
|
|
76
|
+
export interface UploadFilePayload {
|
|
77
|
+
/**
|
|
78
|
+
* example:
|
|
79
|
+
* document.pdf
|
|
80
|
+
*/
|
|
81
|
+
filename: string;
|
|
82
|
+
/**
|
|
83
|
+
* MIME type of file
|
|
84
|
+
* example:
|
|
85
|
+
* image/png
|
|
86
|
+
*/
|
|
87
|
+
content_type?: string;
|
|
88
|
+
}
|
|
72
89
|
}
|
|
73
90
|
}
|
|
74
91
|
declare namespace Paths {
|
|
75
|
-
namespace CreateFile {
|
|
76
|
-
export type RequestBody = Components.Schemas.FileEntityPayload;
|
|
77
|
-
namespace Responses {
|
|
78
|
-
export type $201 = Components.Schemas.FileEntity;
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
92
|
namespace DownloadFile {
|
|
82
93
|
namespace Parameters {
|
|
83
94
|
export type Id = Components.Schemas.FileEntityId;
|
|
@@ -115,14 +126,45 @@ declare namespace Paths {
|
|
|
115
126
|
h?: Parameters.H;
|
|
116
127
|
}
|
|
117
128
|
}
|
|
129
|
+
namespace SaveFile {
|
|
130
|
+
export type RequestBody = Components.Schemas.SaveFilePayload;
|
|
131
|
+
namespace Responses {
|
|
132
|
+
export type $201 = Components.Schemas.FileEntity;
|
|
133
|
+
}
|
|
134
|
+
}
|
|
118
135
|
namespace UploadFile {
|
|
119
|
-
export
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
136
|
+
export type RequestBody = Components.Schemas.UploadFilePayload;
|
|
137
|
+
namespace Responses {
|
|
138
|
+
export interface $201 {
|
|
139
|
+
/**
|
|
140
|
+
* example:
|
|
141
|
+
* https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123
|
|
142
|
+
*/
|
|
143
|
+
upload_url?: string; // url
|
|
144
|
+
/**
|
|
145
|
+
* example:
|
|
146
|
+
* {
|
|
147
|
+
* "bucket": "epilot-files-prod",
|
|
148
|
+
* "key": "123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"
|
|
149
|
+
* }
|
|
150
|
+
*/
|
|
151
|
+
s3ref?: {
|
|
152
|
+
/**
|
|
153
|
+
* example:
|
|
154
|
+
* epilot-files-prod
|
|
155
|
+
*/
|
|
156
|
+
bucket: string;
|
|
157
|
+
/**
|
|
158
|
+
* example:
|
|
159
|
+
* 123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf
|
|
160
|
+
*/
|
|
161
|
+
key: string;
|
|
162
|
+
};
|
|
163
|
+
}
|
|
125
164
|
}
|
|
165
|
+
}
|
|
166
|
+
namespace UploadFilePublic {
|
|
167
|
+
export type RequestBody = Components.Schemas.UploadFilePayload;
|
|
126
168
|
namespace Responses {
|
|
127
169
|
export interface $201 {
|
|
128
170
|
/**
|
|
@@ -155,6 +197,19 @@ declare namespace Paths {
|
|
|
155
197
|
}
|
|
156
198
|
|
|
157
199
|
export interface OperationMethods {
|
|
200
|
+
/**
|
|
201
|
+
* uploadFilePublic - uploadFilePublic
|
|
202
|
+
*
|
|
203
|
+
* Create pre-signed S3 URL to upload a file to keep temporarily (one week).
|
|
204
|
+
*
|
|
205
|
+
* Use the createFile operation to store file file permanently.
|
|
206
|
+
*
|
|
207
|
+
*/
|
|
208
|
+
'uploadFilePublic'(
|
|
209
|
+
parameters?: Parameters<UnknownParamsObject> | null,
|
|
210
|
+
data?: Paths.UploadFilePublic.RequestBody,
|
|
211
|
+
config?: AxiosRequestConfig
|
|
212
|
+
): OperationResponse<Paths.UploadFilePublic.Responses.$201>
|
|
158
213
|
/**
|
|
159
214
|
* uploadFile - uploadFile
|
|
160
215
|
*
|
|
@@ -169,15 +224,20 @@ export interface OperationMethods {
|
|
|
169
224
|
config?: AxiosRequestConfig
|
|
170
225
|
): OperationResponse<Paths.UploadFile.Responses.$201>
|
|
171
226
|
/**
|
|
172
|
-
*
|
|
227
|
+
* saveFile - saveFile
|
|
228
|
+
*
|
|
229
|
+
* Create / Update a permanent File entity
|
|
230
|
+
*
|
|
231
|
+
* Makes file object permanent
|
|
232
|
+
*
|
|
233
|
+
* Saves metadata to file entity
|
|
173
234
|
*
|
|
174
|
-
* Create a permanent File entity
|
|
175
235
|
*/
|
|
176
|
-
'
|
|
236
|
+
'saveFile'(
|
|
177
237
|
parameters?: Parameters<UnknownParamsObject> | null,
|
|
178
|
-
data?: Paths.
|
|
238
|
+
data?: Paths.SaveFile.RequestBody,
|
|
179
239
|
config?: AxiosRequestConfig
|
|
180
|
-
): OperationResponse<Paths.
|
|
240
|
+
): OperationResponse<Paths.SaveFile.Responses.$201>
|
|
181
241
|
/**
|
|
182
242
|
* downloadFile - downloadFile
|
|
183
243
|
*
|
|
@@ -201,7 +261,22 @@ export interface OperationMethods {
|
|
|
201
261
|
}
|
|
202
262
|
|
|
203
263
|
export interface PathsDictionary {
|
|
204
|
-
['/v1/files
|
|
264
|
+
['/v1/files/public/upload']: {
|
|
265
|
+
/**
|
|
266
|
+
* uploadFilePublic - uploadFilePublic
|
|
267
|
+
*
|
|
268
|
+
* Create pre-signed S3 URL to upload a file to keep temporarily (one week).
|
|
269
|
+
*
|
|
270
|
+
* Use the createFile operation to store file file permanently.
|
|
271
|
+
*
|
|
272
|
+
*/
|
|
273
|
+
'post'(
|
|
274
|
+
parameters?: Parameters<UnknownParamsObject> | null,
|
|
275
|
+
data?: Paths.UploadFilePublic.RequestBody,
|
|
276
|
+
config?: AxiosRequestConfig
|
|
277
|
+
): OperationResponse<Paths.UploadFilePublic.Responses.$201>
|
|
278
|
+
}
|
|
279
|
+
['/v1/files/upload']: {
|
|
205
280
|
/**
|
|
206
281
|
* uploadFile - uploadFile
|
|
207
282
|
*
|
|
@@ -218,17 +293,22 @@ export interface PathsDictionary {
|
|
|
218
293
|
}
|
|
219
294
|
['/v1/files']: {
|
|
220
295
|
/**
|
|
221
|
-
*
|
|
296
|
+
* saveFile - saveFile
|
|
297
|
+
*
|
|
298
|
+
* Create / Update a permanent File entity
|
|
299
|
+
*
|
|
300
|
+
* Makes file object permanent
|
|
301
|
+
*
|
|
302
|
+
* Saves metadata to file entity
|
|
222
303
|
*
|
|
223
|
-
* Create a permanent File entity
|
|
224
304
|
*/
|
|
225
305
|
'post'(
|
|
226
306
|
parameters?: Parameters<UnknownParamsObject> | null,
|
|
227
|
-
data?: Paths.
|
|
307
|
+
data?: Paths.SaveFile.RequestBody,
|
|
228
308
|
config?: AxiosRequestConfig
|
|
229
|
-
): OperationResponse<Paths.
|
|
309
|
+
): OperationResponse<Paths.SaveFile.Responses.$201>
|
|
230
310
|
}
|
|
231
|
-
['/v1/files/{id}
|
|
311
|
+
['/v1/files/{id}/download']: {
|
|
232
312
|
/**
|
|
233
313
|
* downloadFile - downloadFile
|
|
234
314
|
*
|
|
@@ -240,7 +320,7 @@ export interface PathsDictionary {
|
|
|
240
320
|
config?: AxiosRequestConfig
|
|
241
321
|
): OperationResponse<Paths.DownloadFile.Responses.$200>
|
|
242
322
|
}
|
|
243
|
-
['/v1/files/{id}
|
|
323
|
+
['/v1/files/{id}/preview']: {
|
|
244
324
|
/**
|
|
245
325
|
* previewFile - previewFile
|
|
246
326
|
*
|