Skip to main content

DeleteBucketCors

Deletes the CORS configuration information set for the bucket.

Description​

The DeleteBucketCors operation removes the CORS (Cross-Origin Resource Sharing) configuration information from a bucket. CORS defines a way for client web applications that are loaded in one domain to interact with resources in a different domain.

note
  • To use this operation, you must have permission to perform the s3:PutBucketCORS action.
  • If you delete the CORS configuration, all cross-origin requests will be denied.
  • This operation will succeed even if there is no CORS configuration on the bucket.

Request Syntax​

DELETE /?cors HTTP/1.1
Host: BucketName.qstorage.quilibrium.com
x-amz-expected-bucket-owner: OwnerAccountId
Values in italics indicate user input and should be replaced with actual values.

This operation does not have a request body.

Request Parameters​

Headers​

NameDescriptionRequiredType
x-amz-expected-bucket-ownerThe account ID of the expected bucket ownerNotext

Examples​

Example 1: Delete CORS configuration from a bucket​

DELETE /?cors HTTP/1.1
Host: my-bucket.qstorage.quilibrium.com
Values in italics indicate user input and should be replaced with actual values.
HTTP/1.1 204
x-amz-id-2: Example7qoYGN7uMuFuYS6m7a4l
x-amz-request-id: TX234S0F24A06C7
Date: _Wed, 01 Mar 2024 12:00:00 GMT_
Values in italics indicate variable response values.

Response Syntax​

HTTP/1.1 204
x-amz-id-2: RequestId
x-amz-request-id: AmazonRequestId
Date: ISO8601Date
Values in italics indicate variable response values.

Response Elements​

Response Headers​

NameDescriptionRequiredType
x-amz-id-2An identifier for the requestNoString
x-amz-request-idA unique identifier for the requestNoString
DateThe date and time at which the response was sentNoString

Special Errors​

Error CodeDescription
NoSuchBucketThe specified bucket does not exist
403Forbidden. Authentication failed or you do not have permission to delete the CORS configuration

Permissions​

You must have the s3:PutBucketCORS permission.

Try It Out​

Test DeleteBucketCors

Delete the CORS configuration from a bucket.

Coming Soon

This feature is currently under development and will be available soon.