GetBucketDefaultStorageClass
This operation is not supported for directory buckets.
Returns the default storage class of the general purpose bucket. Amazon S3 uses the default storage class for new objects that you write to the bucket without the x-amz-storage-class request header. If you haven't set a default storage class for the bucket, Amazon S3 returns STANDARD. For more information, see Setting the default storage class for a bucket in the Amazon S3 User Guide.
To use this operation, you must have the s3:GetBucketDefaultStorageClass permission.
The following operations are related to GetBucketDefaultStorageClass:
Request Syntax
GET /?default-storage-class HTTP/1.1
Host: Bucket.s3.amazonaws.com
x-amz-expected-bucket-owner: ExpectedBucketOwner
URI Request Parameters
The request uses the following URI parameters.
- Bucket
-
The name of the general purpose bucket.
Required: Yes
- x-amz-expected-bucket-owner
-
The AWS account ID of the general purpose bucket's owner.
Request Body
The request does not have a request body.
Response Syntax
HTTP/1.1 200
<?xml version="1.0" encoding="UTF-8"?>
<DefaultStorageClassConfiguration>
<DefaultStorageClass>string</DefaultStorageClass>
</DefaultStorageClassConfiguration>
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in XML format by the service.
- DefaultStorageClassConfiguration
-
Root level tag for the DefaultStorageClassConfiguration parameters.
Required: Yes
- DefaultStorageClass
-
The default storage class of the general purpose bucket. Valid values are
STANDARDandINTELLIGENT_TIERING.Type: String
Valid Values:
STANDARD | INTELLIGENT_TIERING
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: