lpares12
CDCloudflare Developers
•Created by lpares12 on 10/3/2024 in #general-help
PUT object with presigned URL sets the incorrect Type in R2 object
Hey!
I'm trying to put an object to a bucket using presigned URL. But for some reason in the R2 I can always see the file type:
application/x-www-form-urlencoded
even when the file is a jpg, png,...
This is the code I'm using in nodejs:
The image is correctly uploaded, but the type in the R2 bucket is wrong as explained before. If I download the image, I can open it correctly and windows shows it as a .jpg as expected.
To generate the presigned URL I use python's boto3 package:
I saw this post of a user having a similar problem on your forums, but with no response: https://community.cloudflare.com/t/jpg-on-r2-served-with-wrong-content-type/484955/13 replies
CDCloudflare Developers
•Created by lpares12 on 7/9/2024 in #general-help
R2: Create a presigned URL with Temporary access credentials
Hi! I'd like to know what's the proper way to create a presigned URL for an object with temporary access credentials. Is that even possible?
This is my try with typescript:
22 replies