File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -141,7 +141,7 @@ export interface OAuth2Adapter {
141
141
142
142
export interface StorageAdapter {
143
143
/**
144
- * This method should return the presigned URL for the given key capable of upload.
144
+ * This method should return the presigned URL for the given key capable of upload (PUT multipart form data to it) .
145
145
* The PUT method should fail if the file already exists.
146
146
* @param key - The key of the file to be uploaded e.g. "uploads/file.txt"
147
147
* @param expiresIn - The expiration time in seconds for the presigned URL
@@ -150,11 +150,14 @@ export interface StorageAdapter {
150
150
getUploadSignedUrl ( key : string , contentType : string , expiresIn ?: number ) : Promise < string > ;
151
151
152
152
/**
153
- * This method should return the presigned URL for the given key capable of download
153
+ * This method should return the URL for the given key capable of download (200 GET request with response or 200 HEAD request without response).
154
+ * If adapter configured to use public storage, this method should return the public URL of the file.
155
+ * If adapter configured to use private storage, this method should return the presigned URL for the file.
156
+ *
154
157
* @param key - The key of the file to be downloaded e.g. "uploads/file.txt"
155
158
* @param expiresIn - The expiration time in seconds for the presigned URL
156
159
*/
157
- getDownloadSignedUrl ( key : string , expiresIn ?: number ) : Promise < string > ;
160
+ getDownloadUrl ( key : string , expiresIn ?: number ) : Promise < string > ;
158
161
159
162
/**
160
163
* This method should mark the file for deletion.
You can’t perform that action at this time.
0 commit comments