3

Im using AWS s3 to store files, i need to add User-Defined Metadata

"Content-Disposition": attachment;filename=filename.txt when uploading the file/object to aws so i would be able to download it, when uploading with javascript i need to add x-amz-meta-content-disposition, now in s3 the metadate Key is stored as x-amz-meta-content-disposition but the file is not downloding, when i remove manually in AWS console the first part x-amz-meta- and only leave content-disposition then im able to download.

Now my question is: how can i upload the file using javascript and x-amz-meta- should be removed and just be "Content-Disposition": attachment;filename=filename.txt

2 Answers 2

2

This has been reported as a bug few times:

Thus I think you are experiencing same.

Sign up to request clarification or add additional context in comments.

Comments

0

Hi if you guys want to add metadata Content-Disposition: attachmemt? then simply try run cp command or sync command with this argument...

aws s3 sync s3://bucketname/ s3://newbucketname/ --content-disposition "attachment"

this will work

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.