@vizzly/api-client 0.0.76 → 0.0.77
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.
|
@@ -288,4 +288,12 @@ export declare class VizzlyQueryEngineApi extends Api {
|
|
|
288
288
|
create_upload_table: DataOptimiser.ActionStatus<{}>;
|
|
289
289
|
}>>>;
|
|
290
290
|
private buildCreateUploadTableRequest;
|
|
291
|
+
/** Generate pre-signed URL to perform static storage operations */
|
|
292
|
+
generateSignedUrl(params: RequestParams<{
|
|
293
|
+
companyId: string;
|
|
294
|
+
dataSourceId: string;
|
|
295
|
+
fileName: string;
|
|
296
|
+
purpose: 'upload' | 'download';
|
|
297
|
+
}>): Promise<import("../types").Response<DataOptimiser.GenerateSignedUrlResponse>>;
|
|
298
|
+
private buildGenerateSignedUrlRequest;
|
|
291
299
|
}
|
|
@@ -673,5 +673,25 @@ class VizzlyQueryEngineApi extends Api_1.Api {
|
|
|
673
673
|
acceptedAuthParams: ['queryEngineApiKey'],
|
|
674
674
|
};
|
|
675
675
|
}
|
|
676
|
+
/** Generate pre-signed URL to perform static storage operations */
|
|
677
|
+
generateSignedUrl(params) {
|
|
678
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
679
|
+
return yield this.execute(this.buildGenerateSignedUrlRequest(params));
|
|
680
|
+
});
|
|
681
|
+
}
|
|
682
|
+
buildGenerateSignedUrlRequest(params) {
|
|
683
|
+
return {
|
|
684
|
+
path: Path_1.Path.buildPath(`/api/v1/data-optimiser/signed-url`, ''),
|
|
685
|
+
method: 'post',
|
|
686
|
+
abortSignal: params.abortSignal,
|
|
687
|
+
body: {
|
|
688
|
+
company: { id: params.companyId },
|
|
689
|
+
dataSourceId: params.dataSourceId,
|
|
690
|
+
fileName: params.fileName,
|
|
691
|
+
purpose: params.purpose,
|
|
692
|
+
},
|
|
693
|
+
acceptedAuthParams: ['queryEngineApiKey'],
|
|
694
|
+
};
|
|
695
|
+
}
|
|
676
696
|
}
|
|
677
697
|
exports.VizzlyQueryEngineApi = VizzlyQueryEngineApi;
|
package/dist/types.d.ts
CHANGED
|
@@ -618,5 +618,12 @@ export declare namespace DataOptimiser {
|
|
|
618
618
|
destinationAddress: string[];
|
|
619
619
|
}>;
|
|
620
620
|
}>;
|
|
621
|
+
export type GenerateSignedUrlResponse = {
|
|
622
|
+
url: string;
|
|
623
|
+
requiredHeaders: {
|
|
624
|
+
[key: string]: string;
|
|
625
|
+
};
|
|
626
|
+
method: 'GET' | 'PUT';
|
|
627
|
+
};
|
|
621
628
|
export {};
|
|
622
629
|
}
|