Enabling versioning for a bucket example

Here’s a sample PUT request that enables versioning for the finance bucket. The versioning request body is in a file named versioning.xml.

Request body

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<VersioningConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
     <Status>Enabled</Status>
</VersioningConfiguration>

Request with s3curl command line

./s3curl.pl --id=lgreen --put versioning.xml -- -k
     "https://europe.hcp.example.com/finance?versioning"

Request headers

PUT /finance?versioning HTTP/1.1
Host: europe.hcp.example.com
Date: Wed, 20 Mar 2013 13:40:15 +0000
Authorization: AWS bGdyZWVu:ETdibK607bVlNdxb0aKCttJU33U=
Content-Length: 182

Response headers

HTTP/1.1 200 OK
Date: Wed, 20 Mar 2013 13:40:15 GMT
Server: HCP V7.0.0.16
Location: /finance
Content-Length: 0

Trademarks and Legal Disclaimer

© 2016 Hitachi Data Systems Corporation. All rights reserved.