Skip to content

Instantly share code, notes, and snippets.

@Mohammad-Faisal
Created March 10, 2021 12:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Mohammad-Faisal/938077b65ad096aaabee3cab97115b4c to your computer and use it in GitHub Desktop.
Save Mohammad-Faisal/938077b65ad096aaabee3cab97115b4c to your computer and use it in GitHub Desktop.
function generatePreSignedGetUrl( fileName , fileType) {
myBucket.getSignedUrl('getObject', {
Key: fileName,
ContentType: fileType,
Expires: URL_EXPIRATION_TIME
} , (err , url) => {
return url // API Response Here
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment