AWS SDK Version 4 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

The configuration information for the bucket.

Inheritance Hierarchy

System.Object
  Amazon.S3.Model.PutBucketConfiguration

Namespace: Amazon.S3.Model
Assembly: AWSSDK.S3.dll
Version: 3.x.y.z

Syntax

C#
public class PutBucketConfiguration

The PutBucketConfiguration type exposes the following members

Constructors

NameDescription
Public Method PutBucketConfiguration()

Properties

NameTypeDescription
Public Property BucketInfo Amazon.S3.Model.BucketInfo

Gets and sets the property BucketInfo.

Specifies the information about the bucket that will be created.

This functionality is only supported by directory buckets.

Public Property Location Amazon.S3.Model.LocationInfo

Gets and sets the property Location.

Specifies the location where the bucket will be created.

Directory buckets - The location type is Availability Zone or Local Zone. To use the Local Zone location type, your account must be enabled for Local Zones. Otherwise, you get an HTTP 403 Forbidden error with the error code AccessDenied. To learn more, see Enable accounts for Local Zones in the Amazon S3 User Guide.

This functionality is only supported by directory buckets.

Public Property LocationConstraint Amazon.S3.BucketLocationConstraint

Gets and sets the property LocationConstraint.

Specifies the Region where the bucket will be created. You might choose a Region to optimize latency, minimize costs, or address regulatory requirements. For example, if you reside in Europe, you will probably find it advantageous to create buckets in the Europe (Ireland) Region.

If you don't specify a Region, the bucket is created in the US East (N. Virginia) Region (us-east-1) by default. Configurations using the value EU will create a bucket in eu-west-1.

For a list of the valid values for all of the Amazon Web Services Regions, see Regions and Endpoints.

This functionality is not supported for directory buckets.

Public Property Tags System.Collections.Generic.List<Amazon.S3.Model.Tag>

Gets and sets the property Tags.

An array of tags that you can apply to the bucket that you're creating. Tags are key-value pairs of metadata used to categorize and organize your buckets, track costs, and control access.

This parameter is only supported for S3 directory buckets. For more information, see Using tags with directory buckets.

Starting with version 4 of the SDK this property will default to null. If no data for this property is returned from the service the property will also be null. This was changed to improve performance and allow the SDK and caller to distinguish between a property not set or a property being empty to clear out a value. To retain the previous SDK behavior set the AWSConfigs.InitializeCollections static property to true.

Version Information

.NET:
Supported in: 8.0 and newer, Core 3.1

.NET Standard:
Supported in: 2.0

.NET Framework:
Supported in: 4.7.2 and newer