@epilot/file-client 1.1.8 → 1.2.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/dist/definition.js +1 -1
- package/dist/openapi.d.ts +44 -5
- package/package.json +1 -1
- package/src/openapi.d.ts +44 -5
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 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":"Upload and manage all files stored in epilot"},"tags":[{"name":"files","description":"Files"}],"security":[{"EpilotAuth":[]}],"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":{"s3ref":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"example":{"bucket":"epilot-files-prod","key":"123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}}]},"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"}}}}}}}}},"/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"],"parameters":[{"name":"file_entity_id","in":"query","description":"file entity id","schema":{"$ref":"#/components/schemas/FileEntityId"}}],"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":{"s3ref":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"example":{"bucket":"epilot-files-prod","key":"123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}}]},"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"},"public_url":{"description":"Returned only if file is permanent i.e. file_entity_id is passed","type":"string","format":"url","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/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","schema":{"$ref":"#/components/schemas/FileEntityId"}},{"name":"version","in":"query","description":"index of file version","schema":{"type":"integer","default":0}},{"name":"attachment","in":"query","description":"Controls the Content-Disposition header to control browser behaviour. Set to true to trigger download.","schema":{"type":"boolean","default":true}},{"name":"s3_key","in":"query","schema":{"type":"string"}},{"name":"s3_bucket","in":"query","schema":{"type":"string"}}],"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":{}}}}}},"/v1/files:previewS3":{"post":{"operationId":"previewS3File","summary":"previewS3File","description":"Generate thumbnail preview from an s3 reference for a file entity","tags":["files"],"parameters":[{"name":"w","in":"query","description":"width","schema":{"type":"integer"}},{"name":"h","in":"query","description":"height","schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3Reference"}}}},"responses":{"200":{"description":"Generated thumbnail image","content":{"image/png":{},"image/jpeg":{}}}}}},"/v1/files/delete":{"delete":{"operationId":"deleteFile","summary":"deleteFile","description":"Delete file entity","tags":["files"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteFilePayload"}}}},"responses":{"200":{"description":"File delete response"}}}}},"components":{"securitySchemes":{"EpilotAuth":{"type":"http","scheme":"bearer","description":"Authorization header with epilot OAuth2 bearer token","bearerFormat":"JWT"}},"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-read"]},"public_url":{"description":"Direct URL for file (public only if file access control is public-read)","type":"string","format":"url","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"},"type":{"description":"Human readable type for file","type":"string","enum":["document","document_template","text","image","video","audio","spreadsheet","presentation","font","archive","application","unknown"]},"mime_type":{"type":"string","description":"MIME type of the file","example":"application/pdf"},"size_bytes":{"type":"integer","minimum":0,"description":"File size in bytes"},"versions":{"type":"array","items":{"type":"object","properties":{"s3ref":{"$ref":"#/components/schemas/S3Reference"}}}}}},"UploadFilePayload":{"type":"object","properties":{"filename":{"type":"string","example":"document.pdf"},"mime_type":{"description":"MIME type of file","type":"string","example":"application/pdf","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"},"document_type":{"type":"string","enum":["document","document_template","text","image","video","audio","spreadsheet","presentation","font","archive","application","unknown"]},"filename":{"type":"string","example":"document.pdf"},"_tags":{"type":"array","items":{"type":"string"}},"access_control":{"type":"string","default":"private","enum":["private","public-read"]}},"required":["s3ref"]},"DeleteFilePayload":{"type":"object","properties":{"s3ref":{"$ref":"#/components/schemas/S3Reference"}},"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},"mime_type":{"type":"string","example":"image/jpeg"}}}]}}}}')}},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)})());
|
|
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":"Upload and manage all files stored in epilot"},"tags":[{"name":"files","description":"Files"}],"security":[{"EpilotAuth":[]}],"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":{"s3ref":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"example":{"bucket":"epilot-files-prod","key":"123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}}]},"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"}}}}}}}}},"/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"],"parameters":[{"name":"file_entity_id","in":"query","description":"file entity id","schema":{"$ref":"#/components/schemas/FileEntityId"}}],"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":{"s3ref":{"allOf":[{"$ref":"#/components/schemas/S3Reference"},{"example":{"bucket":"epilot-files-prod","key":"123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"}}]},"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"},"public_url":{"description":"Returned only if file is permanent i.e. file_entity_id is passed","type":"string","format":"url","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/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}},{"name":"attachment","in":"query","description":"Controls the Content-Disposition header to control browser behaviour. Set to true to trigger download.","schema":{"type":"boolean","default":true}}],"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:downloadS3":{"post":{"operationId":"downloadS3File","summary":"downloadS3File","description":"Generate pre-signed download S3 url for a file","tags":["files"],"parameters":[{"name":"s3_key","in":"query","required":true,"schema":{"type":"string"}},{"name":"s3_bucket","in":"query","required":true,"schema":{"type":"string"}},{"name":"attachment","in":"query","description":"Controls the Content-Disposition header to control browser behaviour. Set to true to trigger download.","schema":{"type":"boolean","default":true}}],"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":{}}}}}},"/v1/files:previewS3":{"post":{"operationId":"previewS3File","summary":"previewS3File","description":"Generate thumbnail preview from an s3 reference for a file entity","tags":["files"],"parameters":[{"name":"w","in":"query","description":"width","schema":{"type":"integer"}},{"name":"h","in":"query","description":"height","schema":{"type":"integer"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/S3Reference"}}}},"responses":{"200":{"description":"Generated thumbnail image","content":{"image/png":{},"image/jpeg":{}}}}}},"/v1/files/delete":{"delete":{"operationId":"deleteFile","summary":"deleteFile","description":"Delete file entity","tags":["files"],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeleteFilePayload"}}}},"responses":{"200":{"description":"File delete response"}}}}},"components":{"securitySchemes":{"EpilotAuth":{"type":"http","scheme":"bearer","description":"Authorization header with epilot OAuth2 bearer token","bearerFormat":"JWT"}},"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-read"]},"public_url":{"description":"Direct URL for file (public only if file access control is public-read)","type":"string","format":"url","example":"https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf"},"type":{"description":"Human readable type for file","type":"string","enum":["document","document_template","text","image","video","audio","spreadsheet","presentation","font","archive","application","unknown"]},"mime_type":{"type":"string","description":"MIME type of the file","example":"application/pdf"},"size_bytes":{"type":"integer","minimum":0,"description":"File size in bytes"},"versions":{"type":"array","items":{"type":"object","properties":{"s3ref":{"$ref":"#/components/schemas/S3Reference"}}}}}},"UploadFilePayload":{"type":"object","properties":{"filename":{"type":"string","example":"document.pdf"},"mime_type":{"description":"MIME type of file","type":"string","example":"application/pdf","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"},"document_type":{"type":"string","enum":["document","document_template","text","image","video","audio","spreadsheet","presentation","font","archive","application","unknown"]},"filename":{"type":"string","example":"document.pdf"},"_tags":{"type":"array","items":{"type":"string"}},"access_control":{"type":"string","default":"private","enum":["private","public-read"]}},"required":["s3ref"]},"DeleteFilePayload":{"type":"object","properties":{"s3ref":{"$ref":"#/components/schemas/S3Reference"}},"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},"mime_type":{"type":"string","example":"image/jpeg"}}}]}}}}')}},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
|
@@ -126,18 +126,35 @@ declare namespace Paths {
|
|
|
126
126
|
namespace Parameters {
|
|
127
127
|
export type Attachment = boolean;
|
|
128
128
|
export type Id = Components.Schemas.FileEntityId;
|
|
129
|
-
export type S3Bucket = string;
|
|
130
|
-
export type S3Key = string;
|
|
131
129
|
export type Version = number;
|
|
132
130
|
}
|
|
133
131
|
export interface PathParameters {
|
|
134
|
-
id
|
|
132
|
+
id: Parameters.Id;
|
|
135
133
|
}
|
|
136
134
|
export interface QueryParameters {
|
|
137
135
|
version?: Parameters.Version;
|
|
138
136
|
attachment?: Parameters.Attachment;
|
|
139
|
-
|
|
140
|
-
|
|
137
|
+
}
|
|
138
|
+
namespace Responses {
|
|
139
|
+
export interface $200 {
|
|
140
|
+
/**
|
|
141
|
+
* example:
|
|
142
|
+
* https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123
|
|
143
|
+
*/
|
|
144
|
+
download_url?: string; // uri
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
namespace DownloadS3File {
|
|
149
|
+
namespace Parameters {
|
|
150
|
+
export type Attachment = boolean;
|
|
151
|
+
export type S3Bucket = string;
|
|
152
|
+
export type S3Key = string;
|
|
153
|
+
}
|
|
154
|
+
export interface QueryParameters {
|
|
155
|
+
s3_key: Parameters.S3Key;
|
|
156
|
+
s3_bucket: Parameters.S3Bucket;
|
|
157
|
+
attachment?: Parameters.Attachment;
|
|
141
158
|
}
|
|
142
159
|
namespace Responses {
|
|
143
160
|
export interface $200 {
|
|
@@ -310,6 +327,16 @@ export interface OperationMethods {
|
|
|
310
327
|
data?: any,
|
|
311
328
|
config?: AxiosRequestConfig
|
|
312
329
|
): OperationResponse<Paths.DownloadFile.Responses.$200>
|
|
330
|
+
/**
|
|
331
|
+
* downloadS3File - downloadS3File
|
|
332
|
+
*
|
|
333
|
+
* Generate pre-signed download S3 url for a file
|
|
334
|
+
*/
|
|
335
|
+
'downloadS3File'(
|
|
336
|
+
parameters?: Parameters<Paths.DownloadS3File.QueryParameters> | null,
|
|
337
|
+
data?: any,
|
|
338
|
+
config?: AxiosRequestConfig
|
|
339
|
+
): OperationResponse<Paths.DownloadS3File.Responses.$200>
|
|
313
340
|
/**
|
|
314
341
|
* previewFile - previewFile
|
|
315
342
|
*
|
|
@@ -402,6 +429,18 @@ export interface PathsDictionary {
|
|
|
402
429
|
config?: AxiosRequestConfig
|
|
403
430
|
): OperationResponse<Paths.DownloadFile.Responses.$200>
|
|
404
431
|
}
|
|
432
|
+
['/v1/files:downloadS3']: {
|
|
433
|
+
/**
|
|
434
|
+
* downloadS3File - downloadS3File
|
|
435
|
+
*
|
|
436
|
+
* Generate pre-signed download S3 url for a file
|
|
437
|
+
*/
|
|
438
|
+
'post'(
|
|
439
|
+
parameters?: Parameters<Paths.DownloadS3File.QueryParameters> | null,
|
|
440
|
+
data?: any,
|
|
441
|
+
config?: AxiosRequestConfig
|
|
442
|
+
): OperationResponse<Paths.DownloadS3File.Responses.$200>
|
|
443
|
+
}
|
|
405
444
|
['/v1/files/{id}/preview']: {
|
|
406
445
|
/**
|
|
407
446
|
* previewFile - previewFile
|
package/package.json
CHANGED
package/src/openapi.d.ts
CHANGED
|
@@ -126,18 +126,35 @@ declare namespace Paths {
|
|
|
126
126
|
namespace Parameters {
|
|
127
127
|
export type Attachment = boolean;
|
|
128
128
|
export type Id = Components.Schemas.FileEntityId;
|
|
129
|
-
export type S3Bucket = string;
|
|
130
|
-
export type S3Key = string;
|
|
131
129
|
export type Version = number;
|
|
132
130
|
}
|
|
133
131
|
export interface PathParameters {
|
|
134
|
-
id
|
|
132
|
+
id: Parameters.Id;
|
|
135
133
|
}
|
|
136
134
|
export interface QueryParameters {
|
|
137
135
|
version?: Parameters.Version;
|
|
138
136
|
attachment?: Parameters.Attachment;
|
|
139
|
-
|
|
140
|
-
|
|
137
|
+
}
|
|
138
|
+
namespace Responses {
|
|
139
|
+
export interface $200 {
|
|
140
|
+
/**
|
|
141
|
+
* example:
|
|
142
|
+
* https://epilot-files-prod.s3.eu-central-1.amazonaws.com/123/temp/4d689aeb-1497-4410-a9fe-b36ca9ac4389/document.pdf?AWSParams=123
|
|
143
|
+
*/
|
|
144
|
+
download_url?: string; // uri
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
namespace DownloadS3File {
|
|
149
|
+
namespace Parameters {
|
|
150
|
+
export type Attachment = boolean;
|
|
151
|
+
export type S3Bucket = string;
|
|
152
|
+
export type S3Key = string;
|
|
153
|
+
}
|
|
154
|
+
export interface QueryParameters {
|
|
155
|
+
s3_key: Parameters.S3Key;
|
|
156
|
+
s3_bucket: Parameters.S3Bucket;
|
|
157
|
+
attachment?: Parameters.Attachment;
|
|
141
158
|
}
|
|
142
159
|
namespace Responses {
|
|
143
160
|
export interface $200 {
|
|
@@ -310,6 +327,16 @@ export interface OperationMethods {
|
|
|
310
327
|
data?: any,
|
|
311
328
|
config?: AxiosRequestConfig
|
|
312
329
|
): OperationResponse<Paths.DownloadFile.Responses.$200>
|
|
330
|
+
/**
|
|
331
|
+
* downloadS3File - downloadS3File
|
|
332
|
+
*
|
|
333
|
+
* Generate pre-signed download S3 url for a file
|
|
334
|
+
*/
|
|
335
|
+
'downloadS3File'(
|
|
336
|
+
parameters?: Parameters<Paths.DownloadS3File.QueryParameters> | null,
|
|
337
|
+
data?: any,
|
|
338
|
+
config?: AxiosRequestConfig
|
|
339
|
+
): OperationResponse<Paths.DownloadS3File.Responses.$200>
|
|
313
340
|
/**
|
|
314
341
|
* previewFile - previewFile
|
|
315
342
|
*
|
|
@@ -402,6 +429,18 @@ export interface PathsDictionary {
|
|
|
402
429
|
config?: AxiosRequestConfig
|
|
403
430
|
): OperationResponse<Paths.DownloadFile.Responses.$200>
|
|
404
431
|
}
|
|
432
|
+
['/v1/files:downloadS3']: {
|
|
433
|
+
/**
|
|
434
|
+
* downloadS3File - downloadS3File
|
|
435
|
+
*
|
|
436
|
+
* Generate pre-signed download S3 url for a file
|
|
437
|
+
*/
|
|
438
|
+
'post'(
|
|
439
|
+
parameters?: Parameters<Paths.DownloadS3File.QueryParameters> | null,
|
|
440
|
+
data?: any,
|
|
441
|
+
config?: AxiosRequestConfig
|
|
442
|
+
): OperationResponse<Paths.DownloadS3File.Responses.$200>
|
|
443
|
+
}
|
|
405
444
|
['/v1/files/{id}/preview']: {
|
|
406
445
|
/**
|
|
407
446
|
* previewFile - previewFile
|