Put Bucket Lifecycle
Provides the ability to set the lifecycle configuration on the bucket. The user needs to be the bucket owner or to have been granted s3:PutLifecycleConfiguration permission on the bucket.
PUT /?lifecycle HTTP/1.1
Host: {bucket}.{region}.cdn77-storage.comRequest Entities
| Name | Description |
|---|---|
Rulenone | A container holding elements with information about a single lifecycle rule. |
IDstring | A unique string identifying the rule. It may contain up to 255 characters including spaces. |
Statusstring | A string that specifies whether or not the lifecycle rule will be acted upon. The only valid values are Enabled or Disabled. |
Prefixstring | A string specifying the objects to which the rule will be applied. When provided, only objects whose keys begin with the prefix will be acted upon. If empty or not present, all objects in the bucket will be affected. |
Expirationnone | When present, matching objects are expired and automatically deleted. This container will specify either a Date or Days element. |
Daysinteger | An integer specifying the number of days after an object’s creation until the rule takes effect. |
Datenone | A date in ISO 8601 format specifying the day that the rule takes effect. The action will be run at midnight UTC. |
AbortIncompleteMultipartUploadnone | When present, incomplete multipart uploads of matching objects will be removed. This container will specify a DaysAfterInitiation element. |
DaysAfterInitiationinteger | An integer specifying the number of days after an incomplete multipart upload was initiated until the rule takes effect. |
Example
<LifecycleConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
<Rule>
<ID>Expire old project versions</ID>
<Prefix>project/</Prefix>
<Status>Enabled</Status>
<Expiration>
<Days>30</Days>
</Expiration>
</Rule>
<Rule>
<ID>Remove uncompleted uploads</ID>
<Status>Enabled</Status>
<Prefix/>
<AbortIncompleteMultipartUpload>
<DaysAfterInitiation>1</DaysAfterInitiation>
</AbortIncompleteMultipartUpload>
</Rule>
</LifecycleConfiguration>Updated on 13th November, 2026