All Documents
Current Document

Content is empty

If you don't find the content you expect, please try another search term

Documentation

PUT Bucket Version

Last updated:2021-09-14 16:18:08

Description

This PUT operation uses the version resource to set the multi version settings of user space. If you use this interface, you need to be the owner of this space. Users can open or close multiple versions through this interface:

  • Open status: all files uploaded to the storage space will be identified with a unique version ID.

  • Closed status: all files uploaded to the storage space will identify a version ID with a value of null.

Request

Grammar

PUT /?versioning HTTP/1.1
Host: {BucketName}.{endpoint}
Date: {date}
Authorization: {SignatureValue}

<VersioningConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
   <Status>string</Status>
</VersioningConfiguration>.

Note:

Request parameters

The interface does not use request parameters.

Request header

This interface only uses common request headers. For more information, please click Public request headers.

Request content

Name Description
Status The multi version state of the storage space.
Type: String
Valid value: Enabled Suspended

Response

Response header

This interface can use all common response headers. For more information, please click Public response headers.

Response content

The interface does not return the corresponding content.

Special errors

The interface does not return any special errors.

Example

Example of opening a multi version request

PUT /?versioning HTTP/1.1
Host: ks3-example.ks3-cn-beijing.ksyuncs.com
Date: Fri, 26 Dec 2014 06:38:43 GMT
Authorization: authorization string
Content-Type: text/plain
Content-Length: 124

<VersioningConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/"> 
  <Status>Enabled</Status> 
</VersioningConfiguration>

Response example

HTTP/1.1 200 OK
Date: Fri, 26 Dec 2014 06:38:43 GMT
Server: Tengine

Example of closing a multi version request

PUT /?versioning HTTP/1.1
Host: ks3-example.ks3-cn-beijing.ksyuncs.com
Date: Fri, 26 Dec 2014 06:38:43 GMT
Authorization: authorization string
Content-Type: text/plain
Content-Length: 124

<VersioningConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/"> 
  <Status>Suspended</Status> 
</VersioningConfiguration>

Example of a response to closing a log

HTTP/1.1 200 OK
Date: Fri, 26 Dec 2014 06:38:43 GMT
Server: Tengine
On this page
Pure ModeNormal Mode

Pure Mode

Click to preview the document content in full screen
Feedback