PutBucketVersioning
Sets the versioning state of an existing bucket. You can set the versioning state with the value Enabled, which enables versioning for the objects in the bucket.
If the versioning state has never been set on a bucket, the bucket has no versioning state. When you enabled versioning on the bucket, the bucket is in the versioning state and cannot be set back to non-versioning state.
Request Syntax
PUT /bucket/?versioning HTTP/1.1 Host: msdps3.server:8443 <?xml version="1.0" encoding="UTF-8"?> <VersioningConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/"> <Status>string</Status> </VersioningConfiguration>
Request Parameters
Bucket
Name of the bucket that contains the objects.
Required: Yes
Type: String
Request body
Status
The versioning state of the bucket.
Valid Values: Enabled
Required: Yes
Type: String
Response Syntax
HTTP/1.1 200
Possible Error Response
Success
HTTP status code 200.
AccessDenied
Access Denied.
HTTP status code 403.
NoSuchBucket
The specified bucket does not exist.
HTTP status code 404.
InternalError
Request failed because of an internal server error.
HTTP status code 500.